summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2023-03-21 08:42:14 +0000
committerCaolán McNamara <caolanm@redhat.com>2023-03-21 09:53:47 +0000
commit4fd7d1a9e64ed256d442ef997c80bce92afe839b (patch)
treecc4844540719e2e34c0af7b799a3f61858853f24 /cui
parent8f0a337afd8cf40a74e6668b4441903a1b49f4ae (diff)
cid#1524485 'Constant' variable guards dead code
Change-Id: I3a4dfb0e35db481c94a1f5cb56f078cc9e060a73 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/149196 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'cui')
-rw-r--r--cui/source/options/optgdlg.cxx20
1 files changed, 2 insertions, 18 deletions
diff --git a/cui/source/options/optgdlg.cxx b/cui/source/options/optgdlg.cxx
index b0bca101bdaa..04de401c4121 100644
--- a/cui/source/options/optgdlg.cxx
+++ b/cui/source/options/optgdlg.cxx
@@ -665,7 +665,6 @@ std::unique_ptr<SfxTabPage> OfaViewTabPage::Create( weld::Container* pPage, weld
bool OfaViewTabPage::FillItemSet( SfxItemSet* )
{
bool bModified = false;
- bool bMenuOptModified = false;
bool bDarkModeOptModified = false;
bool bRepaintWindows(false);
std::shared_ptr<comphelper::ConfigurationChanges> xChanges(comphelper::ConfigurationChanges::create());
@@ -799,23 +798,8 @@ bool OfaViewTabPage::FillItemSet( SfxItemSet* )
xChanges->commit();
- if (bMenuOptModified || bDarkModeOptModified)
- {
- // Set changed settings to the application instance
- AllSettings aAllSettings = Application::GetSettings();
-
- if (bMenuOptModified)
- {
- StyleSettings aStyleSettings = aAllSettings.GetStyleSettings();
- aAllSettings.SetStyleSettings(aStyleSettings);
- }
-
- if (bDarkModeOptModified)
- MiscSettings::SetDarkMode(m_xAppearanceStyleLB->get_active());
-
- Application::MergeSystemSettings( aAllSettings );
- Application::SetSettings(aAllSettings);
- }
+ if (bDarkModeOptModified)
+ MiscSettings::SetDarkMode(m_xAppearanceStyleLB->get_active());
if ( bAppearanceChanged )
{