aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormathias <mathias>2005-03-16 22:44:48 (GMT)
committermathias <mathias>2005-03-16 22:44:48 (GMT)
commit150777e336db88c2dbfd2a257171ce51bec7a718 (patch)
treee986e538cc14bd40773b02f46c7bb6c0b484c128 /src
parentabce9a0c27b6e6697c30282723b581fbd6684b5e (diff)
downloadfluxbox_paul-150777e336db88c2dbfd2a257171ce51bec7a718.zip
fluxbox_paul-150777e336db88c2dbfd2a257171ce51bec7a718.tar.bz2
fix for #1152450, when having multiple screens the rootCommand's were
called too often: m_root_menu is locked for the current screen when loading the style for the current screen, but not for the screens already initialized and thus its executed when called thru Theme::reconfigure(); now only the themes on the same screen are affected by the load-routine.
Diffstat (limited to 'src')
-rw-r--r--src/FbTk/Theme.cc6
-rw-r--r--src/Screen.cc3
2 files changed, 6 insertions, 3 deletions
diff --git a/src/FbTk/Theme.cc b/src/FbTk/Theme.cc
index 7f6e9dc..e6a07d0 100644
--- a/src/FbTk/Theme.cc
+++ b/src/FbTk/Theme.cc
@@ -135,8 +135,10 @@ bool ThemeManager::load(const std::string &filename, int screen_num) {
135 theme_it = m_themelist.begin(); 135 theme_it = m_themelist.begin();
136 for (; theme_it != theme_it_end; ++theme_it) { 136 for (; theme_it != theme_it_end; ++theme_it) {
137 // send reconfiguration signal to theme and listeners 137 // send reconfiguration signal to theme and listeners
138 (*theme_it)->reconfigTheme(); 138 if (screen_num < 0 || (*theme_it)->screenNum() == screen_num) {
139 (*theme_it)->reconfigSig().notify(); 139 (*theme_it)->reconfigTheme();
140 (*theme_it)->reconfigSig().notify();
141 }
140 } 142 }
141 return true; 143 return true;
142} 144}
diff --git a/src/Screen.cc b/src/Screen.cc
index 106ba00..fae0aff 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -368,7 +368,8 @@ BScreen::BScreen(FbTk::ResourceManager &rm,
368 // So we lock root theme temporary so it doesn't uses RootTheme::reconfigTheme 368 // So we lock root theme temporary so it doesn't uses RootTheme::reconfigTheme
369 // This must be fixed in the future. 369 // This must be fixed in the future.
370 m_root_theme->lock(true); 370 m_root_theme->lock(true);
371 FbTk::ThemeManager::instance().load(fluxbox->getStyleFilename()); 371 FbTk::ThemeManager::instance().load(fluxbox->getStyleFilename(),
372 m_root_theme->screenNum());
372 m_root_theme->lock(false); 373 m_root_theme->lock(false);
373 m_root_theme->setLineAttributes(*resource.gc_line_width, 374 m_root_theme->setLineAttributes(*resource.gc_line_width,
374 *resource.gc_line_style, 375 *resource.gc_line_style,