diff --git a/src/FbMenu.cc b/src/FbMenu.cc index 28710423..4cc2b069 100644 --- a/src/FbMenu.cc +++ b/src/FbMenu.cc @@ -26,7 +26,15 @@ #include "WindowCmd.hh" #include "FbTk/AutoReloadHelper.hh" -FluxboxWindow *FbMenu::s_window = 0; +namespace { + +FluxboxWindow* s_window = 0; + +} + +void FbMenu::setWindow(FluxboxWindow* win) { s_window = win; } +FluxboxWindow* FbMenu::window() { return s_window; } + FbMenu::FbMenu(FbTk::ThemeProxy &tm, FbTk::ImageControl &imgctrl, FbTk::Layer &layer): diff --git a/src/FbMenu.hh b/src/FbMenu.hh index 23c2ad58..193149f1 100644 --- a/src/FbMenu.hh +++ b/src/FbMenu.hh @@ -37,6 +37,11 @@ class MenuTheme; /// a layered and shaped menu class FbMenu:public FbTk::Menu { public: + + static void setWindow(FluxboxWindow *win); + static FluxboxWindow *window(); + + FbMenu(FbTk::ThemeProxy &tm, FbTk::ImageControl &imgctrl, FbTk::Layer &layer); virtual ~FbMenu() { } @@ -49,13 +54,9 @@ public: void setReloadHelper(FbTk::AutoReloadHelper *helper) { m_reloader.reset(helper); } FbTk::AutoReloadHelper *reloadHelper() { return m_reloader.get(); } - static void setWindow(FluxboxWindow *win) { s_window = win; } - static FluxboxWindow *window() { return s_window; } - private: FbTk::LayerItem m_layeritem; std::auto_ptr m_reloader; - static FluxboxWindow *s_window; }; #endif // FBMENU_HH