mirror of
https://gitlab.com/pholy/OSCAR-code.git
synced 2025-04-06 03:00:43 +00:00
Make the No Data view fit
This commit is contained in:
parent
b58eb3eabe
commit
3b87ae074a
29
daily.cpp
29
daily.cpp
@ -262,8 +262,8 @@ Daily::Daily(QWidget *parent,QGLWidget * shared) :
|
|||||||
|
|
||||||
//gSplitter->refresh();
|
//gSplitter->refresh();
|
||||||
|
|
||||||
gSplitter->setChildrenCollapsible(true); // We set this per widget..
|
gSplitter->setChildrenCollapsible(false); // We set this per widget..
|
||||||
gSplitter->setCollapsible(gSplitter->indexOf(SF),false);
|
//gSplitter->setCollapsible(gSplitter->indexOf(SF),false);
|
||||||
//gSplitter->setStretchFactor(gSplitter->indexOf(SF),0);
|
//gSplitter->setStretchFactor(gSplitter->indexOf(SF),0);
|
||||||
|
|
||||||
gSplitter->layout();
|
gSplitter->layout();
|
||||||
@ -459,22 +459,29 @@ void Daily::Load(QDate date)
|
|||||||
UpdateCPAPGraphs(cpap);
|
UpdateCPAPGraphs(cpap);
|
||||||
//UpdateEventsTree(ui->treeWidget,cpap);
|
//UpdateEventsTree(ui->treeWidget,cpap);
|
||||||
|
|
||||||
for (unsigned i=0;i<Graphs.size();i++) {
|
|
||||||
if (Graphs[i]->isEmpty()) {
|
|
||||||
Graphs[i]->hide();
|
|
||||||
} else {
|
|
||||||
Graphs[i]->show();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (!cpap) {// && !oxi) {
|
if (!cpap) {// && !oxi) {
|
||||||
|
gSplitter->setMinimumHeight(0);
|
||||||
NoData->setText(tr("No data for ")+date.toString(Qt::SystemLocaleLongDate));
|
NoData->setText(tr("No data for ")+date.toString(Qt::SystemLocaleLongDate));
|
||||||
if (!NoData->isVisible()) NoData->show();
|
if (!NoData->isVisible()) NoData->show();
|
||||||
if (SF->isVisible()) SF->hide();
|
for (unsigned i=0;i<Graphs.size();i++) {
|
||||||
|
Graphs[i]->hide();
|
||||||
|
}
|
||||||
|
//if (SF->isVisible()) SF->hide();
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
gSplitter->setMinimumHeight(1600);
|
||||||
if (NoData->isVisible()) NoData->hide();
|
if (NoData->isVisible()) NoData->hide();
|
||||||
if (!SF->isVisible()) SF->show();
|
for (unsigned i=0;i<Graphs.size();i++) {
|
||||||
|
if (Graphs[i]->isEmpty()) {
|
||||||
|
Graphs[i]->hide();
|
||||||
|
} else {
|
||||||
|
Graphs[i]->show();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//if (!SF->isVisible()) SF->show();
|
||||||
}
|
}
|
||||||
|
/*for (unsigned i=0;i<Graphs.size();i++) {
|
||||||
|
} */
|
||||||
|
|
||||||
//gSplitter->layout();
|
//gSplitter->layout();
|
||||||
//for (unsigned i=0;i<Graphs.size();i++) {
|
//for (unsigned i=0;i<Graphs.size();i++) {
|
||||||
|
Loading…
Reference in New Issue
Block a user