mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 19:07:45 +00:00
Only apply ui_style if it has changed
This commit is contained in:
parent
e62497b037
commit
72e242267b
@ -2536,15 +2536,17 @@ void PrefUserInterface::applyRC(LyXRC & rc) const
|
|||||||
|
|
||||||
QString const uistyle = uiStyleCO->itemData(
|
QString const uistyle = uiStyleCO->itemData(
|
||||||
uiStyleCO->currentIndex()).toString();
|
uiStyleCO->currentIndex()).toString();
|
||||||
rc.ui_style = fromqstr(uistyle);
|
if (rc.ui_style != fromqstr(uistyle)) {
|
||||||
if (rc.ui_style == "default")
|
rc.ui_style = fromqstr(uistyle);
|
||||||
// FIXME: This should work with frontend::GuiApplication::setStyle(QString())
|
if (rc.ui_style == "default")
|
||||||
// Qt bug https://bugreports.qt.io/browse/QTBUG-58268
|
// FIXME: This should work with frontend::GuiApplication::setStyle(QString())
|
||||||
frontend::Alert::warning(_("Restart needed"),
|
// Qt bug https://bugreports.qt.io/browse/QTBUG-58268
|
||||||
_("Resetting the user interface style to 'Default'"
|
frontend::Alert::warning(_("Restart needed"),
|
||||||
" requires a restart of LyX."));
|
_("Resetting the user interface style to 'Default'"
|
||||||
else
|
" requires a restart of LyX."));
|
||||||
frontend::GuiApplication::setStyle(uistyle);
|
else
|
||||||
|
frontend::GuiApplication::setStyle(uistyle);
|
||||||
|
}
|
||||||
|
|
||||||
rc.ui_file = internal_path(fromqstr(uiFileED->text()));
|
rc.ui_file = internal_path(fromqstr(uiFileED->text()));
|
||||||
rc.use_system_theme_icons = useSystemThemeIconsCB->isChecked();
|
rc.use_system_theme_icons = useSystemThemeIconsCB->isChecked();
|
||||||
|
Loading…
Reference in New Issue
Block a user