diff --git a/data/style/strawberry.css b/data/style/strawberry.css index 619710fbe..e179ba645 100644 --- a/data/style/strawberry.css +++ b/data/style/strawberry.css @@ -1,7 +1,6 @@ #playlist { background-color: %palette-base; alternate-background-color: %palette-alternate-base; - } #playlist[default_background_enabled = "true"] { @@ -45,11 +44,11 @@ QToolButton:pressed[popupMode="1"] { padding-right: 16px; } -darwin { +macos { font-size: 11pt; } -darwin QMenu { +macos QMenu { font-size: 13pt; } diff --git a/src/core/stylesheetloader.cpp b/src/core/stylesheetloader.cpp index fe50bbd04..931c690a3 100644 --- a/src/core/stylesheetloader.cpp +++ b/src/core/stylesheetloader.cpp @@ -44,6 +44,8 @@ void StyleSheetLoader::SetStyleSheet(QWidget *widget, const QString &filename) { void StyleSheetLoader::UpdateStyleSheet(QWidget *widget) { + if (!widget || !filenames_.contains(widget)) return; + QString filename(filenames_[widget]); // Load the file @@ -88,7 +90,7 @@ void StyleSheetLoader::UpdateStyleSheet(QWidget *widget) { ReplaceColor(&contents, "LinkVisited", p, QPalette::LinkVisited); #ifdef Q_OS_MACOS - contents.replace("darwin", "*"); + contents.replace("macos", "*"); #endif widget->setStyleSheet(contents);