diff --git a/oscar/Graphs/MinutesAtPressure.cpp b/oscar/Graphs/MinutesAtPressure.cpp index 15cbe32e..ed7b427e 100644 --- a/oscar/Graphs/MinutesAtPressure.cpp +++ b/oscar/Graphs/MinutesAtPressure.cpp @@ -462,7 +462,6 @@ void RecalcMAP::updateSpanData(int ¤tLoc, int & currentEL,int& currentData void RecalcMAP::updateEventsChannel(Session*sess,ChannelID chanId, QVector &dataArray, PressureInfo & info ) { this->chanId=chanId; - int qtyEvents=0; EventDataType duration = 0, gain; qint64 t , start; @@ -502,7 +501,6 @@ void RecalcMAP::updateEventsChannel(Session*sess,ChannelID chanId, QVector if (ts>maxx) continue; if (tsmaxx) t=maxx; - qtyEvents++; updateSpanData(currentLoc , currentEL , currentData , ts , t , dataArray , info ) ; } else { if (t>maxx) continue; diff --git a/oscar/Graphs/gGraphView.cpp b/oscar/Graphs/gGraphView.cpp index 1a4bacd0..cc0969be 100644 --- a/oscar/Graphs/gGraphView.cpp +++ b/oscar/Graphs/gGraphView.cpp @@ -1413,7 +1413,6 @@ bool gGraphView::renderGraphs(QPainter &painter) // Calculate the height of pinned graphs float pinned_height = 0; // pixel height total - int pinned_graphs = 0; // count bool showTitle=!AppSetting->disableDailyGraphTitles(); bool dailyGraph= mainwin->getDaily()->graphView() == this; @@ -1435,7 +1434,6 @@ bool gGraphView::renderGraphs(QPainter &painter) h = g->height() * m_scaleY; pinned_height += h + graphSpacer; - pinned_graphs++; } py += pinned_height; // start drawing at the end of pinned space diff --git a/oscar/Graphs/gOverviewGraph.cpp b/oscar/Graphs/gOverviewGraph.cpp index feef5279..7eab6685 100644 --- a/oscar/Graphs/gOverviewGraph.cpp +++ b/oscar/Graphs/gOverviewGraph.cpp @@ -468,11 +468,8 @@ void gOverviewGraph::paint(QPainter &painter, gGraph &w, const QRegion ®ion) l_height = height; float py; EventDataType total; - - int daynum = 0; EventDataType h, tmp; - l_offset = (minx) % 86400000L; offset = float(l_offset) / 86400000.0; @@ -559,7 +556,6 @@ void gOverviewGraph::paint(QPainter &painter, gGraph &w, const QRegion ®ion) float compliance_hours = 0; - int incompliant = 0; Day *day; EventDataType hours; @@ -725,7 +721,6 @@ void gOverviewGraph::paint(QPainter &painter, gGraph &w, const QRegion ®ion) if (type == ST_HOURS) { if (tmp < compliance_hours) { col = QColor("#f04040"); - incompliant++; } else if (summary_only) { col = summaryColor; } @@ -834,10 +829,6 @@ void gOverviewGraph::paint(QPainter &painter, gGraph &w, const QRegion ®ion) lastdaygood = true; // if (Q>maxx+extra) break; } else { - if (Q < maxx) { - incompliant++; - } - lastdaygood = false; } @@ -849,8 +840,6 @@ jumpnext: px += barw; - daynum++; - //lastQ=Q; } painter.setClipping(false); diff --git a/oscar/SleepLib/calcs.cpp b/oscar/SleepLib/calcs.cpp index 81b299af..04fbfd8c 100644 --- a/oscar/SleepLib/calcs.cpp +++ b/oscar/SleepLib/calcs.cpp @@ -1,7 +1,7 @@ /* Custom CPAP/Oximetry Calculations Header * * Copyright (c) 2019-2024 The OSCAR Team - * Copyright (c) 2011-2018 Mark Watkins + * Copyright (c) 2011-2018 Mark Watkins * * This file is subject to the terms and conditions of the GNU General Public * License. See the file COPYING in the main directory of the source code @@ -1498,7 +1498,7 @@ int calcSPO2Drop(Session *session) //qint64 rtime[ringsize]={0}; //int rp=0; int min; - int cnt = 0; + // int cnt = 0; // tmp = 0; qint64 start = 0; @@ -1520,7 +1520,7 @@ int calcSPO2Drop(Session *session) if (time > start + 3600000) { break; } // just look at the first hour // tmp += val; - cnt++; + // cnt++; } } @@ -1551,7 +1551,8 @@ int calcSPO2Drop(Session *session) if (!current) { continue; } time = el->time(i); - /*ring[rp]=val; + /* + ring[rp]=val; rtime[rp]=time; rp++; rp=rp % ringsize; @@ -1572,7 +1573,8 @@ int calcSPO2Drop(Session *session) if (!cnt) { unsigned j=abs((rp-1) % ringsize); tmp=(ring[j]+val)/2; - } else tmp/=EventDataType(cnt); */ + } else tmp/=EventDataType(cnt); + */ val = baseline; lastt = 0; diff --git a/oscar/SleepLib/journal.cpp b/oscar/SleepLib/journal.cpp index 477d2192..ace43679 100644 --- a/oscar/SleepLib/journal.cpp +++ b/oscar/SleepLib/journal.cpp @@ -388,9 +388,7 @@ bool Journal::RestoreJournal(QString filename) QDate first = p_profile->FirstDay(); QDate last = p_profile->LastDay(); QDate current = QDate::currentDate(); - int error=0; - int ignored=0; - int used=0; + //int used=0; for (int idx=0 ; idx < days.size() ; idx++) { QDomElement dayElement = days.at(idx).toElement(); @@ -401,23 +399,19 @@ bool Journal::RestoreJournal(QString filename) date = newdate; } if (!date.isValid()) { - error++ ; continue; } if (date < first) { - ignored++ ; continue; } if (date > last) { - ignored++ ; continue; } if (date > current) { - error++ ; continue; } if ( RestoreDay(dayElement,date,filename) ) { - used++; + //used++; } } double user_height_cm = p_profile->user->height(); diff --git a/oscar/SleepLib/loader_plugins/sleepstyle_loader.cpp b/oscar/SleepLib/loader_plugins/sleepstyle_loader.cpp index 1ac786f5..4e41898e 100644 --- a/oscar/SleepLib/loader_plugins/sleepstyle_loader.cpp +++ b/oscar/SleepLib/loader_plugins/sleepstyle_loader.cpp @@ -688,6 +688,8 @@ bool SleepStyleLoader::OpenSummary(Machine *mach, const QString & filename) if (ts == 0xffffffff) { #ifdef DEBUGSS qDebug() << "SS SUM 0xffffffff terminator found at block" << nblock; +#else + Q_UNUSED(nblock); #endif break; } @@ -996,6 +998,8 @@ bool SleepStyleLoader::OpenDetail(Machine *mach, const QString & filename) #ifdef DEBUGSS qDebug() << "SS DET pressure events" << PR->count() << "prSessVount" << PRSessCount << "beginning" << QDateTime::fromSecsSinceEpoch(ti/1000).toString("MM/dd/yyyy hh:mm:ss"); +#else + Q_UNUSED(PRSessCount); #endif // Update indexes, process waveform and perform flagging sess->setSummaryOnly(false); diff --git a/oscar/SleepLib/machine.cpp b/oscar/SleepLib/machine.cpp index 9e870752..00d95402 100644 --- a/oscar/SleepLib/machine.cpp +++ b/oscar/SleepLib/machine.cpp @@ -1145,7 +1145,7 @@ bool Machine::SaveSummaryCache() bool Machine::Save() { //int size; - int cnt = 0; + // int cnt = 0; QString path = getDataPath(); QDir dir(path); @@ -1160,7 +1160,7 @@ bool Machine::Save() // store any event summaries.. for (s = sessionlist.begin(); s != sessionlist.end(); s++) { - cnt++; + // cnt++; if ((*s)->IsChanged()) { queTask(new SaveTask(*s, this)); diff --git a/oscar/SleepLib/machine_loader.cpp b/oscar/SleepLib/machine_loader.cpp index 3a310036..fa1eef83 100644 --- a/oscar/SleepLib/machine_loader.cpp +++ b/oscar/SleepLib/machine_loader.cpp @@ -316,7 +316,7 @@ bool compressFile(QString infile, QString outfile) int MachineLoader::Open(const QStringList & paths) { - int i, skipped = 0; + int i = 0; int size = paths.size(); for (i=0; i < size; i++) { if (isAborted()) { @@ -328,10 +328,6 @@ int MachineLoader::Open(const QStringList & paths) if (res < 0) { break; } - if (res == 0) { - // Should we report on skipped count? - skipped++; - } emit setProgressValue(i+1); QCoreApplication::processEvents(); } diff --git a/oscar/reports.cpp b/oscar/reports.cpp index d1ff1df7..c9d85da2 100644 --- a/oscar/reports.cpp +++ b/oscar/reports.cpp @@ -533,13 +533,11 @@ void Report::PrintReport(gGraphView *gv, QString name, QDate date) progress.setProgressMax(graphs.size()); int page = 1; - int gcnt = 0; for (int i = 0; i < graphs.size(); i++) { if ((top + full_graph_height + normal_height) > virt_height) { top = 0; - gcnt = 0; first = true; if (page > pages) { @@ -616,8 +614,6 @@ void Report::PrintReport(gGraphView *gv, QString name, QDate date) top += full_graph_height; - gcnt++; - progress.setProgressValue(i); QApplication::processEvents(); }