DolphinQt/Settings: Split setting of the user style into two functions.

This makes it so that if you just want to reload the current style (eg. on program start, or in response to a system event), you don't need to know the name of the currently selected user style. It's also more consistent with the way the 'userstyle/enabled' flag works.
This commit is contained in:
Admiral H. Curtiss 2023-11-04 17:56:43 +01:00
commit 6d585b6eb6
No known key found for this signature in database
GPG key ID: F051B4C4044F33FB
6 changed files with 20 additions and 14 deletions

View file

@ -57,12 +57,15 @@ public:
void SetSystemDark(bool dark);
bool IsSystemDark();
bool IsThemeDark();
void SetCurrentUserStyle(const QString& stylesheet_name);
QString GetCurrentUserStyle() const;
void SetUserStyleName(const QString& stylesheet_name);
QString GetUserStyleName() const;
void SetUserStylesEnabled(bool enabled);
bool AreUserStylesEnabled() const;
// this evaluates the current stylesheet settings and refreshes the GUI with them
void ApplyStyle();
void GetToolTipStyle(QColor& window_color, QColor& text_color, QColor& emphasis_text_color,
QColor& border_color, const QPalette& palette,
const QPalette& high_contrast_palette) const;