aboutsummaryrefslogtreecommitdiff
path: root/src/WindowMenuAccessor.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/WindowMenuAccessor.hh')
-rw-r--r--src/WindowMenuAccessor.hh4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/WindowMenuAccessor.hh b/src/WindowMenuAccessor.hh
index 91994b9..383923b 100644
--- a/src/WindowMenuAccessor.hh
+++ b/src/WindowMenuAccessor.hh
@@ -37,7 +37,9 @@ public:
37 37
38 operator Ret() const { 38 operator Ret() const {
39 FluxboxWindow *fbwin = FbMenu::window(); 39 FluxboxWindow *fbwin = FbMenu::window();
40 return fbwin ? (fbwin->*m_getter)() : m_def; 40 if (fbwin)
41 return (Ret)(fbwin->*m_getter)();
42 return m_def;
41 } 43 }
42 FbTk::Accessor<Ret> &operator =(const Ret &val) { 44 FbTk::Accessor<Ret> &operator =(const Ret &val) {
43 FluxboxWindow *fbwin = FbMenu::window(); 45 FluxboxWindow *fbwin = FbMenu::window();