From d27f1d31bc9dddd0399ac4ef8acee3327de84e9b Mon Sep 17 00:00:00 2001 From: Nicolas Mailloux Date: Sun, 7 Aug 2022 12:14:30 -0400 Subject: [PATCH] sleepDialog: Set modal bit; fix in IPD settings --- src/settings/powerdaemonsettings.cpp | 16 ++++++++++++---- src/widgets/dialogs/powerDaemon/sleepdialog.ui | 3 +++ 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/settings/powerdaemonsettings.cpp b/src/settings/powerdaemonsettings.cpp index 53a635a..4864c62 100644 --- a/src/settings/powerdaemonsettings.cpp +++ b/src/settings/powerdaemonsettings.cpp @@ -37,15 +37,23 @@ powerDaemonSettings::powerDaemonSettings(QWidget *parent) : ui->label_2->setStyleSheet("font-weight: bold"); // Icons + int controlBtnFixedLength; + if(global::deviceID == "n705\n") { + controlBtnFixedLength = 50; + } + else { + controlBtnFixedLength = 80; + } + ui->CBSDecreaseBtn->setIcon(QIcon(":/resources/minus.png")); - ui->CBSDecreaseBtn->setFixedWidth(80); + ui->CBSDecreaseBtn->setFixedWidth(controlBtnFixedLength); ui->CBSIncreaseBtn->setIcon(QIcon(":/resources/plus.png")); - ui->CBSIncreaseBtn->setFixedWidth(80); + ui->CBSIncreaseBtn->setFixedWidth(controlBtnFixedLength); ui->idleSleepDecreaseBtn->setIcon(QIcon(":/resources/minus.png")); - ui->idleSleepDecreaseBtn->setFixedWidth(80); + ui->idleSleepDecreaseBtn->setFixedWidth(controlBtnFixedLength); ui->idleSleepIncreaseBtn->setIcon(QIcon(":/resources/plus.png")); - ui->idleSleepIncreaseBtn->setFixedWidth(80); + ui->idleSleepIncreaseBtn->setFixedWidth(controlBtnFixedLength); // Padding ui->CBSDecreaseBtn->setStyleSheet("padding: 10px"); diff --git a/src/widgets/dialogs/powerDaemon/sleepdialog.ui b/src/widgets/dialogs/powerDaemon/sleepdialog.ui index 72f1fe2..14f5533 100644 --- a/src/widgets/dialogs/powerDaemon/sleepdialog.ui +++ b/src/widgets/dialogs/powerDaemon/sleepdialog.ui @@ -19,6 +19,9 @@ Form + + true +