diff --git a/sleepyhead/SleepLib/calcs.cpp b/sleepyhead/SleepLib/calcs.cpp index 8cbe3dbf..1c4d5b5f 100644 --- a/sleepyhead/SleepLib/calcs.cpp +++ b/sleepyhead/SleepLib/calcs.cpp @@ -319,7 +319,8 @@ void FlowParser::calcPeaks(EventDataType *input, int samples) double flowstart = m_flow->first(); double lasttime, time; - double peakmax = flowstart, peakmin = flowstart; + //double peakmax = flowstart, + //double peakmin = flowstart; time = lasttime = flowstart; breaths.clear(); @@ -343,9 +344,10 @@ void FlowParser::calcPeaks(EventDataType *input, int samples) int sps = 1000 / m_rate; - int len = 0, lastk = 0; + int len = 0; + //int lastk = 0; - qint64 sttime = time; + //qint64 sttime = time; // For each samples, find the peak upper and lower breath components for (int k = 0; k < samples; k++) { @@ -365,16 +367,16 @@ void FlowParser::calcPeaks(EventDataType *input, int samples) // Set max for start of the upper breath cycle max = c; - peakmax = time; + //peakmax = time; // Starting point of next breath cycle start = k; - sttime = time; + //sttime = time; } } else if (c > max) { // Update upper breath peak max = c; - peakmax = time; + //peakmax = time; } } @@ -384,13 +386,13 @@ void FlowParser::calcPeaks(EventDataType *input, int samples) if (lastc >= zeroline) { // Set min for start of the lower breath cycle min = c; - peakmin = time; + //peakmin = time; middle = k; } else if (c < min) { // Update lower breath peak min = c; - peakmin = time; + //peakmin = time; } } @@ -398,7 +400,7 @@ void FlowParser::calcPeaks(EventDataType *input, int samples) lasttime = time; time += rate; lastc = c; - lastk = k; + //lastk = k; } } @@ -705,7 +707,7 @@ void FlowParser::calc(bool calcResp, bool calcTv, bool calcTi, bool calcTe, bool void FlowParser::flagUserEvents(ChannelID code, EventDataType restriction, EventDataType duration) { int numbreaths = breaths.size(); - EventDataType val, mx, mn; + //EventDataType mx, mn; QVector br; QVector bstart; @@ -756,10 +758,10 @@ void FlowParser::flagUserEvents(ChannelID code, EventDataType restriction, Event bm = p->middle; // breath middle be = p->end; // breath end - mx = p->max; - mn = p->min; +// mx = p->max; +// mn = p->min; - val = mx - mn; // the total height from top to bottom of this breath + //val = mx - mn; // the total height from top to bottom of this breath // Scan the breath in the flow data and stop at the first location more than the cutoff value // (Only really needs to scan to the middle.. I'm not sure why I made it go all the way to the end.) @@ -1040,7 +1042,7 @@ int calcAHIGraph(Session *session) EventDataType ahi, rdi; - qint64 ti = first, lastti = first; + qint64 ti = first; //, lastti = first; double avgahi = 0; double avgrdi = 0; @@ -1078,7 +1080,7 @@ int calcAHIGraph(Session *session) cnt++; } - lastti = ti; + //lastti = ti; ti += window_size_ms; } while (ti < last); @@ -1104,7 +1106,7 @@ int calcAHIGraph(Session *session) } cnt++; - lastti = ti; + //lastti = ti; ti += window_step; } } @@ -1404,7 +1406,7 @@ void zMaskProfile::updatePressureMin() //EventDataType perc=0.1; //EventDataType tmp,l1,l2; //int idx1, idx2, - int lks; + //int lks; double SN; double percentile = 0.40; @@ -1423,7 +1425,7 @@ void zMaskProfile::updatePressureMin() for (it = pressureleaks.begin(); it != plend; it++) { pressure = it.key(); QMap &leakmap = it.value(); - lks = leakmap.size(); + //lks = leakmap.size(); SN = 0; // First sum total counts of all leaks @@ -1535,7 +1537,7 @@ void zMaskProfile::updateProfile(Session *session) long cnt = 0, vcnt; int n; - EventDataType maxcnt, maxval, lastval, lastcnt; + EventDataType maxcnt, maxval, lastval; //, lastcnt; QMap >::iterator plend = pressureleaks.end(); @@ -1552,14 +1554,14 @@ void zMaskProfile::updateProfile(Session *session) n = leakval.size(); sum = 0; - maxcnt = 0, maxval = 0, lastval = 0, lastcnt = 0; + maxcnt = 0, maxval = 0, lastval = 0;//, lastcnt = 0; lvend = leakval.end(); for (lit = leakval.begin(); lit != lvend; ++lit) { cnt += lit.value(); if (lit.value() > maxcnt) { - lastcnt = maxcnt; + //lastcnt = maxcnt; maxcnt = lit.value(); lastval = maxval; maxval = lit.key(); @@ -1820,7 +1822,7 @@ void flagLargeLeaks(Session *session) if (!count) continue; leaktime = 0; - EventDataType leakvalue = 0; + //EventDataType leakvalue = 0; lastvalue = -1; @@ -1830,7 +1832,7 @@ void flagLargeLeaks(Session *session) if (value >= threshold) { if (lastvalue < threshold) { leaktime = time; - leakvalue = value; + //leakvalue = value; } } else if (lastvalue > threshold) { if (!LL) { @@ -1948,7 +1950,7 @@ int calcSPO2Drop(Session *session) EventList *pc = new EventList(EVL_Event, 1, 0, 0, 0, 0, true); qint64 lastt; - EventDataType lv = 0; + //EventDataType lv = 0; int li = 0; // Fix me.. Time scale varies. @@ -2039,7 +2041,7 @@ int calcSPO2Drop(Session *session) val = baseline; lastt = 0; - lv = val; + //lv = val; min = val; diff --git a/sleepyhead/SleepLib/day.cpp b/sleepyhead/SleepLib/day.cpp index 186caa8c..7da68f9b 100644 --- a/sleepyhead/SleepLib/day.cpp +++ b/sleepyhead/SleepLib/day.cpp @@ -308,7 +308,7 @@ EventDataType Day::settings_avg(ChannelID code) } } - val = (cnt > 0) ? val /= EventDataType(cnt) : val; + val = (cnt > 0) ? (val / EventDataType(cnt)) : val; return val; } @@ -550,7 +550,7 @@ EventDataType Day::rangeWavg(ChannelID code, qint64 st, qint64 et) for (EL = EVEC.value().begin(); EL != EVEC_end; ++EL) { EventList * el = *EL; if (el->count() < 1) continue; - EventDataType lastdata = el->data(0); + //EventDataType lastdata = el->data(0); qint64 lasttime = el->time(0); if (lasttime < st) @@ -562,7 +562,7 @@ EventDataType Day::rangeWavg(ChannelID code, qint64 st, qint64 et) if (time < st) { lasttime = st; - lastdata = data; + //lastdata = data; continue; } @@ -577,7 +577,7 @@ EventDataType Day::rangeWavg(ChannelID code, qint64 st, qint64 et) if (time >= et) break; lasttime = time; - lastdata = data; + //lastdata = data; } } } diff --git a/sleepyhead/SleepLib/loader_plugins/cms50f37_loader.cpp b/sleepyhead/SleepLib/loader_plugins/cms50f37_loader.cpp index eed8c681..4ccb44d4 100644 --- a/sleepyhead/SleepLib/loader_plugins/cms50f37_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/cms50f37_loader.cpp @@ -681,13 +681,13 @@ void CMS50F37Loader::syncClock() { QDate date = QDate::currentDate(); int year = date.year(); - quint8 yh = year / 100; - quint8 yl = year % 100; - quint8 mon = date.month(); - quint8 day = date.day(); - quint8 wd = date.dayOfWeek() % 7; + quint8 yh = (year / 100) | 0x80; + quint8 yl = (year % 100) | 0x80; + quint8 mon = date.month() | 0x80; + quint8 day = date.day() | 0x80; + quint8 wd = (date.dayOfWeek() % 7) | 0x80; - quint8 datecmd[] = { 0x7d, 0x81, 0xb2, (yh | 0x80), yl |0x80, mon|0x80, day|0x80, wd|0x80, 0x80 }; + quint8 datecmd[] = { 0x7d, 0x81, 0xb2, yh, yl, mon, day, wd, 0x80 }; timectr = 0; if (serial.write((char *)datecmd, 9) == -1) { @@ -705,11 +705,11 @@ void CMS50F37Loader::syncClock() QApplication::processEvents(); QTime ctime = QTime::currentTime(); - quint8 h = ctime.hour(); - quint8 m = ctime.minute(); - quint8 s = ctime.second(); + quint8 h = ctime.hour() | 0x80; + quint8 m = ctime.minute() | 0x80; + quint8 s = ctime.second() | 0x80; - quint8 timecmd[] = { 0x7d, 0x81, 0xb1, h | 0x80, m |0x80, s|0x80, 0x80, 0x80, 0x80 }; + quint8 timecmd[] = { 0x7d, 0x81, 0xb1, h, m, s, 0x80, 0x80, 0x80 }; timectr = 0; if (serial.write((char *)timecmd, 9) == -1) { diff --git a/sleepyhead/SleepLib/loader_plugins/icon_loader.cpp b/sleepyhead/SleepLib/loader_plugins/icon_loader.cpp index 208c2050..98d15f88 100644 --- a/sleepyhead/SleepLib/loader_plugins/icon_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/icon_loader.cpp @@ -660,7 +660,7 @@ bool FPIconLoader::OpenSummary(Machine *mach, QString filename) quint16 d1, d2, d3; - int runtime, usage; + int usage; //,runtime; QDate date; @@ -676,7 +676,7 @@ bool FPIconLoader::OpenSummary(Machine *mach, QString filename) // the following two quite often match in value in >> a1; // 0x04 Run Time in >> a2; // 0x05 Usage Time - runtime = a1 * 360; // durations are in tenth of an hour intervals + //runtime = a1 * 360; // durations are in tenth of an hour intervals usage = a2 * 360; in >> a3; // 0x06 // Ramps??? diff --git a/sleepyhead/SleepLib/loader_plugins/intellipap_loader.cpp b/sleepyhead/SleepLib/loader_plugins/intellipap_loader.cpp index cb691b16..54b52b0c 100644 --- a/sleepyhead/SleepLib/loader_plugins/intellipap_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/intellipap_loader.cpp @@ -166,7 +166,8 @@ int IntellipapLoader::Open(QString path) bool ok; - EventDataType min_pressure = 0, max_pressure = 0, ramp_pressure = 0, set_epap = 0, set_ipap = 0, set_ps = 0, ramp_time = 0; + //EventDataType min_pressure = 0, max_pressure = 0, set_ipap = 0, set_ps = 0, + EventDataType ramp_pressure = 0, set_epap = 0, ramp_time = 0; int papmode = 0, smartflex = 0, smartflexmode = 0; while (1) { @@ -191,15 +192,15 @@ int IntellipapLoader::Open(QString path) } else if (key == INT_PROP_Model) { info.model = value; } else if (key == INT_PROP_MinPressure) { - min_pressure = value.toFloat() / 10.0; + //min_pressure = value.toFloat() / 10.0; } else if (key == INT_PROP_MaxPressure) { - max_pressure = value.toFloat() / 10.0; + //max_pressure = value.toFloat() / 10.0; } else if (key == INT_PROP_IPAP) { - set_ipap = value.toFloat() / 10.0; + //set_ipap = value.toFloat() / 10.0; } else if (key == INT_PROP_EPAP) { set_epap = value.toFloat() / 10.0; } else if (key == INT_PROP_PS) { - set_ps = value.toFloat() / 10.0; + //set_ps = value.toFloat() / 10.0; } else if (key == INT_PROP_RampPressure) { ramp_pressure = value.toFloat() / 10.0; } else if (key == INT_PROP_RampTime) { @@ -375,7 +376,7 @@ int IntellipapLoader::Open(QString path) long pos = 0; int rampval = 0; sid = 0; - SessionID lastsid = 0; + //SessionID lastsid = 0; //int last_minp=0, last_maxp=0, last_ps=0, last_pres = 0; @@ -506,7 +507,7 @@ int IntellipapLoader::Open(QString path) break; } else { } - lastsid = sid; + //lastsid = sid; } pos += 26; diff --git a/sleepyhead/SleepLib/loader_plugins/mseries_loader.cpp b/sleepyhead/SleepLib/loader_plugins/mseries_loader.cpp index 3e1c4072..2ff1ab28 100644 --- a/sleepyhead/SleepLib/loader_plugins/mseries_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/mseries_loader.cpp @@ -177,7 +177,7 @@ int MSeriesLoader::Open(QString path) QList head, tail; controlblock += 3; - quint16 datastarts, dataends, tmp16, h16, t16; + quint16 datastarts, dataends, h16, t16;//, tmp16, if (controlblock[0]) { datastarts = controlblock[1] | (controlblock[2] << 8); @@ -199,7 +199,7 @@ int MSeriesLoader::Open(QString path) controlblock += 6; count -= 2; - tmp16 = controlblock[0] | controlblock[1] << 8; + //tmp16 = controlblock[0] | controlblock[1] << 8; controlblock += 2; @@ -228,7 +228,7 @@ int MSeriesLoader::Open(QString path) unsigned char *cb = controlblock; quint16 u1, u2, u3, u4, d1; - quint32 ts, st, lt; + quint32 ts, st; //, lt; QDateTime dt; QDate date; QTime time; @@ -255,13 +255,14 @@ int MSeriesLoader::Open(QString path) unsigned char *endcard = (unsigned char *)block.data() + dataends; bool done = false; - qint64 ti; + //qint64 ti; int cnt = 0; do { ts = cb[0] << 24 | cb[1] << 16 | cb[2] << 8 | cb[3]; - lt = st = ts; - ti = qint64(ts) * 1000L; + //lt = + st = ts; + //ti = qint64(ts) * 1000L; dt = QDateTime::fromTime_t(ts); date = dt.date(); time = dt.time(); @@ -290,9 +291,9 @@ int MSeriesLoader::Open(QString path) if ((cb[0] & 0xc0) == 0xc0) { cb += 2; u1 &= 0x0fff; // time delta?? - lt = ts; + //lt = ts; ts = st + (u1 * 60); - ti = qint64(ts) * 1000L; + //ti = qint64(ts) * 1000L; d1 = cb[0] << 8 | cb[1]; u2 = cb[2] << 8 | cb[3]; @@ -333,7 +334,7 @@ int MSeriesLoader::Open(QString path) done = false; //bool first=true; - quint8 exch; + //quint8 exch; cnt = 0; do { @@ -355,7 +356,7 @@ int MSeriesLoader::Open(QString path) while (cb < endcard) { if (((cb[0] & 0xc0) != 0xc0) || ((cb[0] & 0xf0) == 0xf0)) { // what is this for?? - exch = cb[0]; + //exch = cb[0]; cb++; } diff --git a/sleepyhead/SleepLib/loader_plugins/prs1_loader.cpp b/sleepyhead/SleepLib/loader_plugins/prs1_loader.cpp index 7fbbc2e3..4c87742e 100644 --- a/sleepyhead/SleepLib/loader_plugins/prs1_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/prs1_loader.cpp @@ -1350,10 +1350,10 @@ bool PRS1Import::ParseCompliance() FlexMode flexmode = FLEX_Unknown; flex &= 0xf8; - bool split = false; + //bool split = false; if (flex & 0x40) { // This bit defines the Flex setting for the CPAP component of the Split night - split = true; + // split = true; } if (flex & 0x80) { // CFlex bit if (flex & 8) { // Plus bit @@ -2220,7 +2220,7 @@ QList PRS1Loader::ParseFile(QString path) unsigned char * header; int cnt = 0; - int lastheadersize = 0; + //int lastheadersize = 0; int lastblocksize = 0; int cruft = 0; @@ -2320,7 +2320,7 @@ QList PRS1Loader::ParseFile(QString path) int headersize = headerBA.size(); lastblocksize = blocksize; - lastheadersize = headersize; + //lastheadersize = headersize; blocksize -= headersize; // Check header checksum diff --git a/sleepyhead/SleepLib/loader_plugins/resmed_loader.cpp b/sleepyhead/SleepLib/loader_plugins/resmed_loader.cpp index fa53b655..09d57aa4 100644 --- a/sleepyhead/SleepLib/loader_plugins/resmed_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/resmed_loader.cpp @@ -159,7 +159,7 @@ void ResmedLoader::ParseSTR(Machine *mach, QStringList strfiles) EDFSignal *sig = nullptr; quint32 laston = 0; - bool skipday; + //bool skipday; int size = str.GetNumDataRecords(); int cnt=0; @@ -170,7 +170,7 @@ void ResmedLoader::ParseSTR(Machine *mach, QStringList strfiles) uint timestamp = dt.toTime_t(); int recstart = rec * maskon->nr; - skipday = false; + // skipday = false; if ((++cnt % 10) == 0) { // TODO: Change me to emit once MachineLoader is QObjectified... if (qprogress) { qprogress->setValue(10.0 + (float(cnt) / float(size) * 90.0)); } @@ -1208,7 +1208,7 @@ int PeekAnnotations(const QString & path, quint32 &start, quint32 &end) QString t; - double duration; + //double duration; char *data; char c; long pos; @@ -1229,7 +1229,7 @@ int PeekAnnotations(const QString & path, quint32 &start, quint32 &end) data = (char *)edf.edfsignals[s].data; pos = 0; tt = edf.startdate; - duration = 0; + //duration = 0; while (pos < recs) { c = data[pos]; @@ -1261,7 +1261,7 @@ int PeekAnnotations(const QString & path, quint32 &start, quint32 &end) tt = edf.startdate + qint64(d * 1000.0); - duration = 0; + //duration = 0; // First entry if (data[pos] == 21) { @@ -1274,7 +1274,7 @@ int PeekAnnotations(const QString & path, quint32 &start, quint32 &end) pos++; } while ((data[pos] != 20) && (pos < recs)); // start code - duration = t.toDouble(&ok); + //duration = t.toDouble(&ok); if (!ok) { qDebug() << "Faulty EDF Annotations file (at %" << pos << ") " << edf.filename; @@ -1551,6 +1551,8 @@ int ResmedLoader::scanFiles(Machine * mach, QString datalog_path) gz = true; } else { gz = false; } + Q_UNUSED(gz) + // Skip if this file is in the already imported list if (skipfiles.contains(filename)) continue; @@ -2034,10 +2036,10 @@ int ResmedLoader::Open(QString path) QVector dayused; dayused.resize(days); - time_t time = stredf.startdate / 1000L; // == 12pm on first day + //time_t time = stredf.startdate / 1000L; // == 12pm on first day // reset time to first day - time = stredf.startdate / 1000; + //time = stredf.startdate / 1000; /////////////////////////////////////////////////////////////////////////////////// // Scan DATALOG files, sort, and import any new sessions @@ -2050,8 +2052,8 @@ int ResmedLoader::Open(QString path) //////////////////////////////////////////////////////////////////////////////////// - int size = m->sessionlist.size(); - int cnt=0; + //int size = m->sessionlist.size(); + //int cnt=0; Session * sess; @@ -2117,8 +2119,8 @@ int ResmedLoader::Open(QString path) /// - size = strsess.size(); - cnt=0; + //size = strsess.size(); + //cnt=0; quint32 ignoreolder = p_profile->session->ignoreOlderSessionsDate().toTime_t(); bool ignoreold = p_profile->session->ignoreOlderSessions(); @@ -2405,6 +2407,8 @@ bool ResmedLoader::LoadCSL(Session *sess, const QString & path) // sess->updateLast(tt); } + Q_UNUSED(duration) + return true; } diff --git a/sleepyhead/SleepLib/loader_plugins/weinmann_loader.cpp b/sleepyhead/SleepLib/loader_plugins/weinmann_loader.cpp index fcfd3264..86150a8c 100644 --- a/sleepyhead/SleepLib/loader_plugins/weinmann_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/weinmann_loader.cpp @@ -191,8 +191,8 @@ int WeinmannLoader::Open(QString path) p = comp; QDateTime dt_epoch(QDate(2000,1,1), QTime(0,0,0)); - int epoch = dt_epoch.toTime_t(); - epoch = 0; + //int epoch = dt_epoch.toTime_t(); + //epoch = 0; float flow_sample_duration = 1000.0 / 5; diff --git a/sleepyhead/SleepLib/loader_plugins/zeo_loader.cpp b/sleepyhead/SleepLib/loader_plugins/zeo_loader.cpp index a3c1604e..0a19b120 100644 --- a/sleepyhead/SleepLib/loader_plugins/zeo_loader.cpp +++ b/sleepyhead/SleepLib/loader_plugins/zeo_loader.cpp @@ -107,8 +107,10 @@ int ZEOLoader::OpenFile(QString filename) qint64 st, tt; int stage; - int ZQ, TotalZ, TimeToZ, TimeInWake, TimeInREM, TimeInLight, TimeInDeep, Awakenings; - int AlarmReason, SnoozeTime, WakeTone, WakeWindow, AlarmType, MorningFeel; + int ZQ, TimeToZ, TimeInWake, TimeInREM, TimeInLight, TimeInDeep, Awakenings; + + //int AlarmReason, SnoozeTime, WakeTone, WakeWindow, AlarmType, TotalZ; + int MorningFeel; QString FirmwareVersion, MyZeoVersion; QDateTime FirstAlarmRing, LastAlarmRing, FirstSnoozeTime, LastSnoozeTime, SetAlarmTime; @@ -120,7 +122,7 @@ int ZEOLoader::OpenFile(QString filename) int idxZQ = header.indexOf("ZQ"); - int idxTotalZ = header.indexOf("Total Z"); + //int idxTotalZ = header.indexOf("Total Z"); int idxAwakenings = header.indexOf("Awakenings"); int idxSG = header.indexOf("Sleep Graph"); int idxDSG = header.indexOf("Detailed Sleep Graph"); @@ -132,11 +134,11 @@ int ZEOLoader::OpenFile(QString filename) int idxStartOfNight = header.indexOf("Start of Night"); int idxEndOfNight = header.indexOf("End of Night"); int idxRiseTime = header.indexOf("Rise Time"); - int idxAlarmReason = header.indexOf("Alarm Reason"); - int idxSnoozeTime = header.indexOf("Snooze Time"); - int idxWakeTone = header.indexOf("Wake Tone"); - int idxWakeWindow = header.indexOf("Wake Window"); - int idxAlarmType = header.indexOf("Alarm Type"); +// int idxAlarmReason = header.indexOf("Alarm Reason"); +// int idxSnoozeTime = header.indexOf("Snooze Time"); +// int idxWakeTone = header.indexOf("Wake Tone"); +// int idxWakeWindow = header.indexOf("Wake Window"); +// int idxAlarmType = header.indexOf("Alarm Type"); int idxFirstAlaramRing = header.indexOf("First Alarm Ring"); int idxLastAlaramRing = header.indexOf("Last Alarm Ring"); int idxFirstSnoozeTime = header.indexOf("First Snooze Time"); @@ -160,9 +162,9 @@ int ZEOLoader::OpenFile(QString filename) if (!ok) { dodgy = true; } - TotalZ = linecomp[idxTotalZ].toInt(&ok); +// TotalZ = linecomp[idxTotalZ].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } TimeToZ = linecomp[idxTimeToZ].toInt(&ok); @@ -200,25 +202,25 @@ int ZEOLoader::OpenFile(QString filename) if (!rise_time.isValid()) { dodgy = true; } - AlarmReason = linecomp[idxAlarmReason].toInt(&ok); +// AlarmReason = linecomp[idxAlarmReason].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } - SnoozeTime = linecomp[idxSnoozeTime].toInt(&ok); +// SnoozeTime = linecomp[idxSnoozeTime].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } - WakeTone = linecomp[idxWakeTone].toInt(&ok); +// WakeTone = linecomp[idxWakeTone].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } - WakeWindow = linecomp[idxWakeWindow].toInt(&ok); +// WakeWindow = linecomp[idxWakeWindow].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } - AlarmType = linecomp[idxAlarmType].toInt(&ok); +// AlarmType = linecomp[idxAlarmType].toInt(&ok); - if (!ok) { dodgy = true; } +// if (!ok) { dodgy = true; } if (!linecomp[idxFirstAlaramRing].isEmpty()) { FirstAlarmRing = QDateTime::fromString(linecomp[idxFirstAlaramRing], "MM/dd/yyyy HH:mm"); diff --git a/sleepyhead/SleepLib/profiles.cpp b/sleepyhead/SleepLib/profiles.cpp index 75951fe6..d38e2233 100644 --- a/sleepyhead/SleepLib/profiles.cpp +++ b/sleepyhead/SleepLib/profiles.cpp @@ -422,9 +422,9 @@ QString Environment::searchInPath(const QString &executable, const QStringList & #endif // Borrowed from QtCreator (http://stackoverflow.com/questions/3490336/how-to-reveal-in-finder-or-show-in-explorer-with-qt) -void showInGraphicalShell(const QString &pathIn) +void showInGraphicalShell(const QString & /*pathIn*/) { - QWidget * parent = NULL; + //QWidget * parent = NULL; // Mac, Windows support folder or file. #if defined(Q_OS_WIN) @@ -442,7 +442,7 @@ void showInGraphicalShell(const QString &pathIn) param += QDir::toNativeSeparators(pathIn); QProcess::startDetached(explorer, QStringList(param)); #elif defined(Q_OS_MAC) - Q_UNUSED(parent) + // Q_UNUSED(parent) QStringList scriptArgs; scriptArgs << QLatin1String("-e") << QString::fromLatin1("tell application \"Finder\" to reveal POSIX file \"%1\"") diff --git a/sleepyhead/sleepyhead.pro b/sleepyhead/sleepyhead.pro index 55d1b334..5d47bd7c 100644 --- a/sleepyhead/sleepyhead.pro +++ b/sleepyhead/sleepyhead.pro @@ -29,11 +29,6 @@ DEFINES += LOCK_RESMED_SESSIONS #CONFIG += c++11 CONFIG += rtti - -*-g++* { - QMAKE_CXXFLAGS += -Wno-unused-variable -} - #static { # CONFIG += static # QTPLUGIN += qsvg qgif qpng