aboutsummaryrefslogtreecommitdiff
path: root/src/Screen.cc
diff options
context:
space:
mode:
authorPavel Labath <pavelo@centrum.sk>2011-07-14 11:02:29 (GMT)
committerPavel Labath <pavelo@centrum.sk>2011-07-14 11:02:29 (GMT)
commit3c64f7b271b9fd96b946e16526d43e7306098ed7 (patch)
tree21cf146e946f577c1f8b333a64cafc8949706110 /src/Screen.cc
parent46f07f06e586cf9bc84d6065ca05a460b9c9c0d5 (diff)
downloadfluxbox_pavel-3c64f7b271b9fd96b946e16526d43e7306098ed7.zip
fluxbox_pavel-3c64f7b271b9fd96b946e16526d43e7306098ed7.tar.bz2
Attach a modifiedSig handler to the session.menuFile resource
Diffstat (limited to 'src/Screen.cc')
-rw-r--r--src/Screen.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Screen.cc b/src/Screen.cc
index d0bafba..ea6b7a4 100644
--- a/src/Screen.cc
+++ b/src/Screen.cc
@@ -813,8 +813,6 @@ BScreen::addExtraWindowMenu(const FbTk::FbString &label, const FbTk::RefCount<Fb
813} 813}
814 814
815void BScreen::reconfigure() { 815void BScreen::reconfigure() {
816 Fluxbox *fluxbox = Fluxbox::instance();
817
818 focusedWinFrameTheme()->setAlpha(*resource.focused_alpha); 816 focusedWinFrameTheme()->setAlpha(*resource.focused_alpha);
819 unfocusedWinFrameTheme()->setAlpha(*resource.unfocused_alpha); 817 unfocusedWinFrameTheme()->setAlpha(*resource.unfocused_alpha);
820 m_menutheme->setAlpha(*resource.menu_alpha); 818 m_menutheme->setAlpha(*resource.menu_alpha);
@@ -833,7 +831,6 @@ void BScreen::reconfigure() {
833 m_workspaces_list[i]->setName( resource.workspace_names.get()[i] ); 831 m_workspaces_list[i]->setName( resource.workspace_names.get()[i] );
834 832
835 // update menu filenames 833 // update menu filenames
836 m_rootmenu->reloadHelper()->setMainFile(fluxbox->getMenuFilename());
837 m_windowmenu->reloadHelper()->setMainFile(windowMenuFilename()); 834 m_windowmenu->reloadHelper()->setMainFile(windowMenuFilename());
838 835
839 // reconfigure workspaces 836 // reconfigure workspaces
@@ -1350,7 +1347,10 @@ void BScreen::reassociateWindow(FluxboxWindow *w, unsigned int wkspc_id,
1350void BScreen::initMenus() { 1347void BScreen::initMenus() {
1351 m_workspacemenu = MenuCreator::createMenuType("workspacemenu", screenNumber()); 1348 m_workspacemenu = MenuCreator::createMenuType("workspacemenu", screenNumber());
1352 1349
1353 m_rootmenu->reloadHelper()->setMainFile(Fluxbox::instance()->getMenuFilename()); 1350 m_tracker.join(Fluxbox::instance()->getMenuResource().modifiedSig(),
1351 MemFun(*m_rootmenu->reloadHelper(), &FbTk::AutoReloadHelper::setMainFile));
1352 m_rootmenu->reloadHelper()->setMainFile(*Fluxbox::instance()->getMenuResource());
1353
1354 m_windowmenu->reloadHelper()->setMainFile(windowMenuFilename()); 1354 m_windowmenu->reloadHelper()->setMainFile(windowMenuFilename());
1355} 1355}
1356 1356
@@ -1364,7 +1364,7 @@ void BScreen::rereadMenu() {
1364 1364
1365 m_rootmenu->removeAll(); 1365 m_rootmenu->removeAll();
1366 try { 1366 try {
1367 l.loadfile(FbTk::StringUtil::expandFilename(fb->getMenuFilename()).c_str()); 1367 l.loadfile(FbTk::StringUtil::expandFilename(*fb->getMenuResource()).c_str());
1368 l.call(0, 1); 1368 l.call(0, 1);
1369 MenuCreator::createMenu(*m_rootmenu, l, m_rootmenu->reloadHelper()); 1369 MenuCreator::createMenu(*m_rootmenu, l, m_rootmenu->reloadHelper());
1370 } 1370 }