aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLibravatar Keshav Bhatt <keshavnrj@gmail.com>2022-07-04 23:43:48 +0530
committerLibravatar Keshav Bhatt <keshavnrj@gmail.com>2022-07-05 00:35:39 +0530
commit8a74ccbcfc1471bbd3fad54250a3d22398e62772 (patch)
tree307b0c4a5a1362de206c96a0c70da52bc3cae35a /src
parent6c6275c34bfc4d1e37dfa50495c977af485f9cf0 (diff)
downloadwhatsie-8a74ccbcfc1471bbd3fad54250a3d22398e62772.tar.gz
whatsie-8a74ccbcfc1471bbd3fad54250a3d22398e62772.zip
chore(ui): update ui color
- update color to match vendor specified one in settings widget - add bottom strip in lock dialog
Diffstat (limited to 'src')
-rw-r--r--src/lock.cpp29
-rw-r--r--src/lock.ui712
-rw-r--r--src/settingswidget.cpp48
-rw-r--r--src/settingswidget.ui8
4 files changed, 445 insertions, 352 deletions
diff --git a/src/lock.cpp b/src/lock.cpp
index 3c47fb2..46b38cd 100644
--- a/src/lock.cpp
+++ b/src/lock.cpp
@@ -96,13 +96,15 @@ void Lock::applyThemeQuirks() {
})");
ui->widget_2->setStyleSheet(R"(QWidget#widget_2 {
- border-radius: 5px;
- background-image: url(":/icons/texture.png");
- background-color: palette(shadow);
+ border-top-left-radius: 4px;
+ border-top-right-radius: 4px;
+ background-image: url(":/icons/texture.png");
+ background-color: palette(shadow);
})");
ui->widget->setStyleSheet(R"(QWidget#widget{
- border-radius: 5px;
+ border-top-left-radius: 4px;
+ border-top-right-radius: 4px;
background-image:url(":/icons/texture.png");
background-color:palette(shadow);
})");
@@ -110,6 +112,20 @@ void Lock::applyThemeQuirks() {
ui->centerWidget->setStyleSheet(R"(QWidget#centerWidget {
background-image: url(":/icons/wa_bg.png");
})");
+
+ // little quirks
+ QString border = "border-bottom-right-radius: 4px;"
+ "border-bottom-left-radius: 4px;";
+ QString lightBg = "background-color: rgb(37, 211, 102);";
+ QString darkBg = "background-color: rgb(0, 117, 96);";
+ if (QString::compare(settings.value("windowTheme", "light").toString(),
+ "dark", Qt::CaseInsensitive) == 0) { // light
+ ui->bottomLine->setStyleSheet(darkBg + border);
+ ui->bottomLine_2->setStyleSheet(darkBg + border);
+ } else { // dark
+ ui->bottomLine->setStyleSheet(lightBg + border);
+ ui->bottomLine_2->setStyleSheet(lightBg + border);
+ }
}
Lock::~Lock() { delete ui; }
@@ -132,10 +148,7 @@ void Lock::keyReleaseEvent(QKeyEvent *event) {
bool Lock::event(QEvent *e) { return QWidget::event(e); }
-bool Lock::getIsLocked() const
-{
- return isLocked;
-}
+bool Lock::getIsLocked() const { return isLocked; }
void Lock::on_passcode1_textChanged(const QString &arg1) {
if (arg1.contains(" ")) {
diff --git a/src/lock.ui b/src/lock.ui
index 264bb7d..de4df9a 100644
--- a/src/lock.ui
+++ b/src/lock.ui
@@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>810</width>
- <height>510</height>
+ <width>936</width>
+ <height>680</height>
</rect>
</property>
<property name="sizePolicy">
@@ -96,181 +96,216 @@
</spacer>
</item>
<item>
- <widget class="QWidget" name="widget_2" native="true">
- <property name="styleSheet">
- <string notr="true"/>
+ <layout class="QVBoxLayout" name="verticalLayout_10">
+ <property name="spacing">
+ <number>0</number>
</property>
- <layout class="QVBoxLayout" name="verticalLayout_4">
- <property name="spacing">
- <number>10</number>
- </property>
- <property name="sizeConstraint">
- <enum>QLayout::SetMinimumSize</enum>
- </property>
- <property name="leftMargin">
- <number>20</number>
- </property>
- <property name="topMargin">
- <number>20</number>
- </property>
- <property name="rightMargin">
- <number>20</number>
- </property>
- <property name="bottomMargin">
- <number>20</number>
- </property>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_2">
+ <property name="rightMargin">
+ <number>0</number>
+ </property>
+ <property name="bottomMargin">
+ <number>0</number>
+ </property>
+ <item>
+ <widget class="QWidget" name="widget_2" native="true">
+ <property name="styleSheet">
+ <string notr="true"/>
+ </property>
+ <layout class="QVBoxLayout" name="verticalLayout_4">
+ <property name="spacing">
+ <number>10</number>
+ </property>
+ <property name="sizeConstraint">
+ <enum>QLayout::SetMinimumSize</enum>
+ </property>
+ <property name="leftMargin">
+ <number>20</number>
+ </property>
<property name="topMargin">
- <number>0</number>
+ <number>20</number>
+ </property>
+ <property name="rightMargin">
+ <number>20</number>
</property>
<property name="bottomMargin">
- <number>5</number>
+ <number>20</number>
</property>
<item>
- <spacer name="horizontalSpacer">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
+ <layout class="QHBoxLayout" name="horizontalLayout_2">
+ <property name="topMargin">
+ <number>0</number>
</property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>20</height>
- </size>
+ <property name="bottomMargin">
+ <number>5</number>
</property>
- </spacer>
+ <item>
+ <spacer name="horizontalSpacer">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QLabel" name="label">
+ <property name="minimumSize">
+ <size>
+ <width>128</width>
+ <height>128</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background-color:transparent;</string>
+ </property>
+ <property name="text">
+ <string/>
+ </property>
+ <property name="pixmap">
+ <pixmap resource="icons.qrc">:/icons/app/icon-128.png</pixmap>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer_2">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
</item>
<item>
- <widget class="QLabel" name="label">
+ <widget class="QLabel" name="label_3">
+ <property name="font">
+ <font>
+ <pointsize>14</pointsize>
+ </font>
+ </property>
+ <property name="text">
+ <string>Set lock passcode</string>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ <property name="wordWrap">
+ <bool>true</bool>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLineEdit" name="passcode1">
<property name="minimumSize">
<size>
- <width>128</width>
- <height>128</height>
+ <width>0</width>
+ <height>30</height>
</size>
</property>
- <property name="styleSheet">
- <string notr="true">background-color:transparent;</string>
+ <property name="echoMode">
+ <enum>QLineEdit::Password</enum>
</property>
- <property name="text">
- <string/>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ <property name="placeholderText">
+ <string>enter passcode</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLineEdit" name="passcode2">
+ <property name="minimumSize">
+ <size>
+ <width>0</width>
+ <height>30</height>
+ </size>
</property>
- <property name="pixmap">
- <pixmap resource="icons.qrc">:/icons/app/icon-128.png</pixmap>
+ <property name="echoMode">
+ <enum>QLineEdit::Password</enum>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
+ <property name="placeholderText">
+ <string>enter passcode again</string>
+ </property>
</widget>
</item>
<item>
- <spacer name="horizontalSpacer_2">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
+ <widget class="QPushButton" name="setPass">
+ <property name="minimumSize">
+ <size>
+ <width>0</width>
+ <height>30</height>
+ </size>
+ </property>
+ <property name="text">
+ <string>Set Pass Code</string>
</property>
- <property name="sizeHint" stdset="0">
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="cancelSetting">
+ <property name="minimumSize">
<size>
- <width>40</width>
- <height>20</height>
+ <width>0</width>
+ <height>30</height>
</size>
</property>
- </spacer>
+ <property name="text">
+ <string>Cancel</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="caps2">
+ <property name="text">
+ <string>Warning: Caps Lock is On</string>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ </widget>
</item>
</layout>
- </item>
- <item>
- <widget class="QLabel" name="label_3">
- <property name="font">
- <font>
- <pointsize>14</pointsize>
- </font>
- </property>
- <property name="text">
- <string>Set lock passcode</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="wordWrap">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLineEdit" name="passcode1">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="echoMode">
- <enum>QLineEdit::Password</enum>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="placeholderText">
- <string>enter passcode</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLineEdit" name="passcode2">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="echoMode">
- <enum>QLineEdit::Password</enum>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="placeholderText">
- <string>enter passcode again</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="setPass">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="text">
- <string>Set Pass Code</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="cancelSetting">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="text">
- <string>Cancel</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLabel" name="caps2">
- <property name="text">
- <string>Warning: Caps Lock is On</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- </widget>
- </item>
- </layout>
- </widget>
+ </widget>
+ </item>
+ <item>
+ <widget class="QWidget" name="bottomLine_2" native="true">
+ <property name="minimumSize">
+ <size>
+ <width>6</width>
+ <height>0</height>
+ </size>
+ </property>
+ <property name="maximumSize">
+ <size>
+ <width>16777215</width>
+ <height>6</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background-color: rgb(6, 207, 156);
+border-bottom-right-radius: 4px;
+border-bottom-left-radius: 4px;</string>
+ </property>
+ <layout class="QVBoxLayout" name="verticalLayout_11"/>
+ </widget>
+ </item>
+ </layout>
</item>
<item>
<spacer name="horizontalSpacer_8">
@@ -398,127 +433,213 @@
</spacer>
</item>
<item>
- <widget class="QWidget" name="widget" native="true">
- <property name="styleSheet">
- <string notr="true"/>
+ <layout class="QVBoxLayout" name="verticalLayout_8">
+ <property name="spacing">
+ <number>0</number>
+ </property>
+ <property name="rightMargin">
+ <number>0</number>
</property>
- <layout class="QVBoxLayout" name="verticalLayout_3">
- <property name="spacing">
- <number>10</number>
- </property>
- <property name="leftMargin">
- <number>20</number>
- </property>
- <property name="topMargin">
- <number>20</number>
- </property>
- <property name="rightMargin">
- <number>20</number>
- </property>
- <property name="bottomMargin">
- <number>20</number>
- </property>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_3">
+ <property name="bottomMargin">
+ <number>0</number>
+ </property>
+ <item>
+ <widget class="QWidget" name="widget" native="true">
+ <property name="styleSheet">
+ <string notr="true"/>
+ </property>
+ <layout class="QVBoxLayout" name="verticalLayout_3">
+ <property name="spacing">
+ <number>10</number>
+ </property>
+ <property name="leftMargin">
+ <number>20</number>
+ </property>
<property name="topMargin">
- <number>0</number>
+ <number>20</number>
+ </property>
+ <property name="rightMargin">
+ <number>20</number>
</property>
<property name="bottomMargin">
- <number>0</number>
+ <number>20</number>
</property>
<item>
- <spacer name="horizontalSpacer_3">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
+ <layout class="QHBoxLayout" name="horizontalLayout_3">
+ <property name="topMargin">
+ <number>0</number>
</property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>20</height>
- </size>
+ <property name="bottomMargin">
+ <number>0</number>
</property>
- </spacer>
+ <item>
+ <spacer name="horizontalSpacer_3">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QLabel" name="label_2">
+ <property name="minimumSize">
+ <size>
+ <width>128</width>
+ <height>128</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background-color:transparent;</string>
+ </property>
+ <property name="text">
+ <string/>
+ </property>
+ <property name="pixmap">
+ <pixmap resource="icons.qrc">:/icons/app/icon-128.png</pixmap>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer_4">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
</item>
<item>
- <widget class="QLabel" name="label_2">
- <property name="minimumSize">
- <size>
- <width>128</width>
- <height>128</height>
- </size>
+ <layout class="QHBoxLayout" name="horizontalLayout_6">
+ <property name="bottomMargin">
+ <number>0</number>
</property>
- <property name="styleSheet">
- <string notr="true">background-color:transparent;</string>
+ <item>
+ <spacer name="horizontalSpacer_9">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QLabel" name="label_5">
+ <property name="minimumSize">
+ <size>
+ <width>32</width>
+ <height>32</height>
+ </size>
+ </property>
+ <property name="maximumSize">
+ <size>
+ <width>32</width>
+ <height>32</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background-color:transparent;</string>
+ </property>
+ <property name="text">
+ <string/>
+ </property>
+ <property name="pixmap">
+ <pixmap resource="icons.qrc">:/icons/lock-2-fill.png</pixmap>
+ </property>
+ <property name="scaledContents">
+ <bool>true</bool>
+ </property>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer_10">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
+ </item>
+ <item>
+ <widget class="QLabel" name="label_4">
+ <property name="font">
+ <font>
+ <pointsize>14</pointsize>
+ </font>
</property>
<property name="text">
- <string/>
- </property>
- <property name="pixmap">
- <pixmap resource="icons.qrc">:/icons/app/icon-128.png</pixmap>
+ <string>Enter your passcode to get access to app</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
+ <property name="wordWrap">
+ <bool>true</bool>
+ </property>
</widget>
</item>
<item>
- <spacer name="horizontalSpacer_4">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
- </property>
- <property name="sizeHint" stdset="0">
+ <widget class="QLineEdit" name="passcodeLogin">
+ <property name="minimumSize">
<size>
- <width>40</width>
- <height>20</height>
+ <width>0</width>
+ <height>30</height>
</size>
</property>
- </spacer>
- </item>
- </layout>
- </item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_6">
- <property name="bottomMargin">
- <number>0</number>
- </property>
- <item>
- <spacer name="horizontalSpacer_9">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
+ <property name="echoMode">
+ <enum>QLineEdit::Password</enum>
</property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>20</height>
- </size>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
</property>
- </spacer>
+ <property name="placeholderText">
+ <string>enter your passcode</string>
+ </property>
+ </widget>
</item>
<item>
- <widget class="QLabel" name="label_5">
+ <widget class="QPushButton" name="unlock">
<property name="minimumSize">
<size>
- <width>32</width>
- <height>32</height>
+ <width>0</width>
+ <height>30</height>
</size>
</property>
- <property name="maximumSize">
- <size>
- <width>32</width>
- <height>32</height>
- </size>
- </property>
- <property name="styleSheet">
- <string notr="true">background-color:transparent;</string>
- </property>
<property name="text">
- <string/>
+ <string>Unlock</string>
</property>
- <property name="pixmap">
- <pixmap resource="icons.qrc">:/icons/lock-2-fill.png</pixmap>
- </property>
- <property name="scaledContents">
- <bool>true</bool>
+ </widget>
+ </item>
+ <item>
+ <widget class="QLabel" name="caps1">
+ <property name="text">
+ <string>Warning: Caps Lock is On</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
@@ -526,95 +647,44 @@
</widget>
</item>
<item>
- <spacer name="horizontalSpacer_10">
- <property name="orientation">
- <enum>Qt::Horizontal</enum>
+ <widget class="QLabel" name="wrong">
+ <property name="text">
+ <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Wrong Passcode, Please try again.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
- <property name="sizeHint" stdset="0">
- <size>
- <width>40</width>
- <height>20</height>
- </size>
+ <property name="alignment">
+ <set>Qt::AlignCenter</set>
+ </property>
+ <property name="wordWrap">
+ <bool>true</bool>
</property>
- </spacer>
+ </widget>
</item>
</layout>
- </item>
- <item>
- <widget class="QLabel" name="label_4">
- <property name="font">
- <font>
- <pointsize>14</pointsize>
- </font>
- </property>
- <property name="text">
- <string>Enter your passcode to get access to app</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="wordWrap">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLineEdit" name="passcodeLogin">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="echoMode">
- <enum>QLineEdit::Password</enum>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="placeholderText">
- <string>enter your passcode</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="unlock">
- <property name="minimumSize">
- <size>
- <width>0</width>
- <height>30</height>
- </size>
- </property>
- <property name="text">
- <string>Unlock</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLabel" name="caps1">
- <property name="text">
- <string>Warning: Caps Lock is On</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QLabel" name="wrong">
- <property name="text">
- <string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Wrong Passcode, Please try again.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
- </property>
- <property name="alignment">
- <set>Qt::AlignCenter</set>
- </property>
- <property name="wordWrap">
- <bool>true</bool>
- </property>
- </widget>
- </item>
- </layout>
- </widget>
+ </widget>
+ </item>
+ <item>
+ <widget class="QWidget" name="bottomLine" native="true">
+ <property name="minimumSize">
+ <size>
+ <width>6</width>
+ <height>0</height>
+ </size>
+ </property>
+ <property name="maximumSize">
+ <size>
+ <width>16777215</width>
+ <height>6</height>
+ </size>
+ </property>
+ <property name="styleSheet">
+ <string notr="true">background-color: rgb(6, 207, 156);
+border-bottom-right-radius: 4px;
+border-bottom-left-radius: 4px;</string>
+ </property>
+ <layout class="QVBoxLayout" name="verticalLayout_9"/>
+ </widget>
+ </item>
+ </layout>
</item>
<item>
<spacer name="horizontalSpacer_5">
diff --git a/src/settingswidget.cpp b/src/settingswidget.cpp
index a58a967..1a385f1 100644
--- a/src/settingswidget.cpp
+++ b/src/settingswidget.cpp
@@ -56,7 +56,8 @@ SettingsWidget::SettingsWidget(QWidget *parent, int screenNumber,
ui->startMinimized->setChecked(
settings.value("startMinimized", false).toBool());
- this->appAutoLockingSetChecked(settings.value("appAutoLocking", defaultAppAutoLock).toBool());
+ this->appAutoLockingSetChecked(
+ settings.value("appAutoLocking", defaultAppAutoLock).toBool());
ui->autoLockDurationSpinbox->setValue(
settings.value("autoLockDuration", defaultAppAutoLockDuration).toInt());
@@ -303,9 +304,8 @@ void SettingsWidget::on_deleteCache_clicked() {
void SettingsWidget::on_deletePersistentData_clicked() {
QMessageBox msgBox;
- msgBox.setText(
- "This will delete Persistent Data ! Persistent data includes "
- "persistent cookies, HTML5 local storage, and visited links.");
+ msgBox.setText("This will delete Persistent Data ! Persistent data includes "
+ "persistent cookies, HTML5 local storage, and visited links.");
msgBox.setIconPixmap(
QPixmap(":/icons/information-line.png")
.scaled(42, 42, Qt::KeepAspectRatio, Qt::SmoothTransformation));
@@ -344,13 +344,25 @@ void SettingsWidget::applyThemeQuirks() {
// little quirks
if (QString::compare(ui->themeComboBox->currentText(), "dark",
Qt::CaseInsensitive) == 0) {
- ui->bottomLine->setStyleSheet("background-color: rgb(5, 97, 98);");
+ ui->bottomLine->setStyleSheet("background-color: rgb(0, 117, 96);");
ui->label_7->setStyleSheet(
"color:#c2c5d1;padding: 0px 8px 0px 8px;background:transparent;");
+ ui->headerWidget->setStyleSheet("background-color: qlineargradient("
+ "spread:reflect, x1:0, y1:1, x2:1, y2:1,"
+ "stop:0 rgba(0, 117, 96, 255), "
+ "stop:0.328358 rgba(0, 117, 96, 144),"
+ "stop:0.61194 rgba(0, 117, 96, 78),"
+ "stop:0.895522 rgba(0, 117, 96, 6));");
} else {
- ui->bottomLine->setStyleSheet("background-color: rgb(74, 223, 131);");
+ ui->bottomLine->setStyleSheet("background-color: rgb(37, 211, 102);");
ui->label_7->setStyleSheet(
"color:#1e1f21;padding: 0px 8px 0px 8px;background:transparent;");
+ ui->headerWidget->setStyleSheet("background-color: qlineargradient("
+ "spread:reflect, x1:0, y1:1, x2:1, y2:1,"
+ "stop:0 rgba(37, 211, 102, 200), "
+ "stop:0.328358 rgba(37, 211, 102, 122),"
+ "stop:0.61194 rgba(37, 211, 102, 68),"
+ "stop:0.895522 rgba(37, 211, 102, 6));");
}
}
@@ -429,18 +441,18 @@ void SettingsWidget::appAutoLockingSetChecked(bool checked) {
ui->appAutoLockcheckBox->blockSignals(false);
}
-void SettingsWidget::toggleTheme()
-{
- //disable automatic theme first
- if(settings.value("automaticTheme", false).toBool()){
- emit notify(tr("Automatic theme switching was disabled due to manual theme toggle."));
- ui->automaticThemeCheckBox->setChecked(false);
- }
- if(ui->themeComboBox->currentIndex() == 0){
- ui->themeComboBox->setCurrentIndex(1);
- }else{
- ui->themeComboBox->setCurrentIndex(0);
- }
+void SettingsWidget::toggleTheme() {
+ // disable automatic theme first
+ if (settings.value("automaticTheme", false).toBool()) {
+ emit notify(tr(
+ "Automatic theme switching was disabled due to manual theme toggle."));
+ ui->automaticThemeCheckBox->setChecked(false);
+ }
+ if (ui->themeComboBox->currentIndex() == 0) {
+ ui->themeComboBox->setCurrentIndex(1);
+ } else {
+ ui->themeComboBox->setCurrentIndex(0);
+ }
}
void SettingsWidget::setCurrentPasswordText(QString str) {
diff --git a/src/settingswidget.ui b/src/settingswidget.ui
index 900d949..1b259a8 100644
--- a/src/settingswidget.ui
+++ b/src/settingswidget.ui
@@ -38,9 +38,7 @@
</sizepolicy>
</property>
<property name="styleSheet">
- <string notr="true">/*background-color: qlineargradient(spread:reflect, x1:0, y1:1, x2:1, y2:1, stop:0 rgba(63, 129, 216, 255), stop:0.328358 rgba(63, 129, 216, 111), stop:0.61194 rgba(63, 129, 216, 48), stop:0.895522 rgba(63, 129, 216, 15));*/
-
-background-color: qlineargradient(spread:reflect, x1:0, y1:1, x2:1, y2:1, stop:0 rgba(28, 139, 130, 255), stop:0.328358 rgba(28, 139, 130, 144), stop:0.61194 rgba(28, 139, 130, 78), stop:0.895522 rgba(28, 139, 130, 6));
+ <string notr="true">
</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_7">
@@ -97,7 +95,7 @@ background:transparent;
<property name="geometry">
<rect>
<x>0</x>
- <y>-14</y>
+ <y>0</y>
<width>677</width>
<height>791</height>
</rect>
@@ -1070,7 +1068,7 @@ background:transparent;
</size>
</property>
<property name="styleSheet">
- <string notr="true">background-color: rgb(74, 223, 131);</string>
+ <string notr="true">background-color: rgb(6, 207, 156);</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4"/>
</widget>