activity labels in red, when active
This commit is contained in:
parent
ffe4052832
commit
3a93ae2b37
@ -71,7 +71,6 @@ PylonRecorder::PylonRecorder(QWidget *parent)
|
|||||||
QLabel *loadLabel = new QLabel("Load:", this);
|
QLabel *loadLabel = new QLabel("Load:", this);
|
||||||
|
|
||||||
writingLabel = new QLabel("writing");
|
writingLabel = new QLabel("writing");
|
||||||
//writingLabel->setStyleSheet("QLabel { color : gray; }");
|
|
||||||
writingLabel->setEnabled(false);
|
writingLabel->setEnabled(false);
|
||||||
grabbingLabel = new QLabel("grabbing");
|
grabbingLabel = new QLabel("grabbing");
|
||||||
//grabbingLabel->setStyleSheet("QLabel { color : gray; }");
|
//grabbingLabel->setStyleSheet("QLabel { color : gray; }");
|
||||||
@ -480,8 +479,8 @@ void PylonRecorder::writerDone() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void PylonRecorder::displayActivity() {
|
void PylonRecorder::displayActivity() {
|
||||||
grabbingLabel->setEnabled(labelSwitch && grabbing);
|
grabbingLabel->setStyleSheet((labelSwitch && grabbing) ? activeLabelStyleHigh : activeLabelStyleLow);
|
||||||
writingLabel->setEnabled(labelSwitch && writing);
|
writingLabel->setStyleSheet((labelSwitch && writing) ? activeLabelStyleHigh : activeLabelStyleLow);
|
||||||
labelSwitch = !labelSwitch;
|
labelSwitch = !labelSwitch;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -85,6 +85,10 @@ private:
|
|||||||
Writer *writer;
|
Writer *writer;
|
||||||
bool grabbing, stopRequest, writing, labelSwitch;
|
bool grabbing, stopRequest, writing, labelSwitch;
|
||||||
QPalette progressPalette;
|
QPalette progressPalette;
|
||||||
|
QString activeLabelStyleHigh = "QLabel { color : red; }";
|
||||||
|
QString activeLabelStyleLow = "QLabel { color : cmyk(0, 255, 255, 0, 50); }";
|
||||||
|
QString inactiveLabelStyle = ("QLabel { color :gray; }");
|
||||||
|
|
||||||
|
|
||||||
#if defined(QT_PRINTSUPPORT_LIB) && QT_CONFIG(printer)
|
#if defined(QT_PRINTSUPPORT_LIB) && QT_CONFIG(printer)
|
||||||
QPrinter printer;
|
QPrinter printer;
|
||||||
|
Loading…
Reference in New Issue
Block a user