Cleanup Theme-related Code (#4450)
This commit is contained in:
@@ -149,7 +149,7 @@ void QuickSwitcherPopup::themeChangedEvent()
|
||||
const QString selCol =
|
||||
(this->theme->isLightTheme()
|
||||
? "#68B1FF" // Copied from Theme::splits.input.styleSheet
|
||||
: this->theme->tabs.selected.backgrounds.regular.color().name());
|
||||
: this->theme->tabs.selected.backgrounds.regular.name());
|
||||
|
||||
const QString listStyle =
|
||||
QString(
|
||||
|
||||
@@ -51,12 +51,12 @@ void NotebookButton::paintEvent(QPaintEvent *event)
|
||||
|
||||
if (mouseDown_ || mouseOver_)
|
||||
{
|
||||
background = this->theme->tabs.regular.backgrounds.hover.color();
|
||||
background = this->theme->tabs.regular.backgrounds.hover;
|
||||
foreground = this->theme->tabs.regular.text;
|
||||
}
|
||||
else
|
||||
{
|
||||
background = this->theme->tabs.regular.backgrounds.regular.color();
|
||||
background = this->theme->tabs.regular.backgrounds.regular;
|
||||
foreground = this->theme->tabs.regular.text;
|
||||
}
|
||||
|
||||
|
||||
@@ -109,7 +109,7 @@ void GenericListView::refreshTheme(const Theme &theme)
|
||||
const QString selCol =
|
||||
(theme.isLightTheme()
|
||||
? "#68B1FF" // Copied from Theme::splits.input.styleSheet
|
||||
: theme.tabs.selected.backgrounds.regular.color().name());
|
||||
: theme.tabs.selected.backgrounds.regular.name());
|
||||
|
||||
const QString listStyle =
|
||||
QString(
|
||||
|
||||
@@ -688,10 +688,9 @@ void SplitContainer::paintEvent(QPaintEvent * /*event*/)
|
||||
rect.top() + rect.height() / 2 + (s / 2));
|
||||
}
|
||||
|
||||
QBrush accentColor =
|
||||
(QApplication::activeWindow() == this->window()
|
||||
? this->theme->tabs.selected.backgrounds.regular
|
||||
: this->theme->tabs.selected.backgrounds.unfocused);
|
||||
auto accentColor = (QApplication::activeWindow() == this->window()
|
||||
? this->theme->tabs.selected.backgrounds.regular
|
||||
: this->theme->tabs.selected.backgrounds.unfocused);
|
||||
|
||||
painter.fillRect(0, 0, width(), 1, accentColor);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user