code cleanup + change color of timebar
This commit is contained in:
@@ -116,6 +116,7 @@ WindowRace::WindowRace(DataBase *db, QWidget *parent) :
|
||||
this->ui->pbTime->setMinimum(0);
|
||||
this->ui->pbTime->setTextVisible(false);
|
||||
this->ui->pbTime->setStyleSheet("QProgressBar::chunk { color: #05B8CC;}");
|
||||
this->ui->pbTime->setValue(0);
|
||||
|
||||
}
|
||||
void WindowRace::prepareNextRace(){
|
||||
@@ -148,6 +149,9 @@ void WindowRace::prepareNextRace(){
|
||||
this->ui->pbTime->setStyleSheet("QProgressBar::chunk { color: #05B8CC;}");
|
||||
this->ui->pbTime->setValue(0);
|
||||
|
||||
//countdown
|
||||
this->ui->lCountdown->setStyleSheet("QLabel { color: black; }");
|
||||
|
||||
//Ampel Setup
|
||||
ui->WAmpel15->hide();
|
||||
ui->WAmpel25->hide();
|
||||
@@ -247,8 +251,8 @@ void WindowRace::countdownUpdate(){
|
||||
if(!paused){
|
||||
countdownValue -= 1;
|
||||
if(countdownValue <= 15){
|
||||
ui->lCountdown->setStyleSheet("QLabel { color: red; }");
|
||||
this->ui->pbTime->setStyleSheet( "QProgressBar::chunk { background-color: yellow; }");
|
||||
this->ui->lCountdown->setStyleSheet("QLabel { color: red; }");
|
||||
this->ui->pbTime->setStyleSheet( "QProgressBar::chunk { background-color: orange; }");
|
||||
//this->ui->pbTime->
|
||||
}
|
||||
if(countdownValue <= -1){
|
||||
|
||||
Reference in New Issue
Block a user