mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-17 11:10:45 +00:00
Always create CSR event list
This commit is contained in:
parent
d38d2c8404
commit
51e0a7b06d
@ -2812,7 +2812,8 @@ bool ResmedLoader::LoadCSL(Session *sess, const QString & path)
|
|||||||
time.start();
|
time.start();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
EventList *CSR = nullptr;
|
// Always create CSR event list so that overview always finds something
|
||||||
|
EventList *CSR = sess->AddEventList(CPAP_CSR, EVL_Event);
|
||||||
|
|
||||||
// Allow for empty sessions..
|
// Allow for empty sessions..
|
||||||
qint64 csr_starts = 0;
|
qint64 csr_starts = 0;
|
||||||
@ -2830,9 +2831,9 @@ bool ResmedLoader::LoadCSL(Session *sess, const QString & path)
|
|||||||
if (anno->text == "CSR Start") {
|
if (anno->text == "CSR Start") {
|
||||||
csr_starts = tt;
|
csr_starts = tt;
|
||||||
} else if (anno->text == "CSR End") {
|
} else if (anno->text == "CSR End") {
|
||||||
if ( ! CSR) {
|
// if ( ! CSR) {
|
||||||
CSR = sess->AddEventList(CPAP_CSR, EVL_Event);
|
// CSR = sess->AddEventList(CPAP_CSR, EVL_Event);
|
||||||
}
|
// }
|
||||||
if (csr_starts > 0) {
|
if (csr_starts > 0) {
|
||||||
if (sess->checkInside(csr_starts)) {
|
if (sess->checkInside(csr_starts)) {
|
||||||
CSR->AddEvent(tt, double(tt - csr_starts) / 1000.0);
|
CSR->AddEvent(tt, double(tt - csr_starts) / 1000.0);
|
||||||
|
Loading…
Reference in New Issue
Block a user