mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-09 12:40:43 +00:00
FIX Compilation Issues with uBuntu24.04 and Clang compiler
This commit is contained in:
parent
fa725e3d14
commit
56f815d44a
@ -462,7 +462,6 @@ void RecalcMAP::updateSpanData(int ¤tLoc, int & currentEL,int& currentData
|
||||
void RecalcMAP::updateEventsChannel(Session*sess,ChannelID chanId, QVector<int> &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<int>
|
||||
if (ts>maxx) continue;
|
||||
if (ts<minx) ts=minx;
|
||||
if (t>maxx) t=maxx;
|
||||
qtyEvents++;
|
||||
updateSpanData(currentLoc , currentEL , currentData , ts , t , dataArray , info ) ;
|
||||
} else {
|
||||
if (t>maxx) continue;
|
||||
|
@ -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
|
||||
|
@ -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);
|
||||
|
||||
|
@ -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;
|
||||
|
@ -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();
|
||||
|
@ -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);
|
||||
|
@ -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));
|
||||
|
@ -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();
|
||||
}
|
||||
|
@ -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();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user