aboutsummaryrefslogtreecommitdiff
path: root/src/Remember.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Remember.cc')
-rw-r--r--src/Remember.cc19
1 files changed, 9 insertions, 10 deletions
diff --git a/src/Remember.cc b/src/Remember.cc
index 0fa778f..6a611bf 100644
--- a/src/Remember.cc
+++ b/src/Remember.cc
@@ -29,7 +29,6 @@
29#include "FbMenu.hh" 29#include "FbMenu.hh"
30#include "FbCommands.hh" 30#include "FbCommands.hh"
31#include "fluxbox.hh" 31#include "fluxbox.hh"
32#include "WindowCmd.hh"
33#include "Layer.hh" 32#include "Layer.hh"
34 33
35#include "FbTk/I18n.hh" 34#include "FbTk/I18n.hh"
@@ -250,23 +249,23 @@ public:
250 } 249 }
251 250
252 bool isSelected() const { 251 bool isSelected() const {
253 if (WindowCmd<void>::window() == 0) 252 if (FbMenu::window() == 0)
254 return false; 253 return false;
255 254
256 if (WindowCmd<void>::window()->numClients()) // ensure it HAS clients 255 if (FbMenu::window()->numClients()) // ensure it HAS clients
257 return Remember::instance().isRemembered(WindowCmd<void>::window()->winClient(), m_attrib); 256 return Remember::instance().isRemembered(FbMenu::window()->winClient(), m_attrib);
258 else 257 else
259 return false; 258 return false;
260 } 259 }
261 260
262 bool isEnabled() const { 261 bool isEnabled() const {
263 if (WindowCmd<void>::window() == 0) 262 if (FbMenu::window() == 0)
264 return false; 263 return false;
265 264
266 if (m_attrib != Remember::REM_JUMPWORKSPACE) 265 if (m_attrib != Remember::REM_JUMPWORKSPACE)
267 return true; 266 return true;
268 else if (WindowCmd<void>::window()->numClients()) 267 else if (FbMenu::window()->numClients())
269 return (Remember::instance().isRemembered(WindowCmd<void>::window()->winClient(), Remember::REM_WORKSPACE)); 268 return (Remember::instance().isRemembered(FbMenu::window()->winClient(), Remember::REM_WORKSPACE));
270 else 269 else
271 return false; 270 return false;
272 } 271 }
@@ -274,11 +273,11 @@ public:
274 void click(int button, int time, unsigned int mods) { 273 void click(int button, int time, unsigned int mods) {
275 // reconfigure only does stuff if the apps file has changed 274 // reconfigure only does stuff if the apps file has changed
276 Remember::instance().checkReload(); 275 Remember::instance().checkReload();
277 if (WindowCmd<void>::window() != 0) { 276 if (FbMenu::window() != 0) {
278 if (isSelected()) { 277 if (isSelected()) {
279 Remember::instance().forgetAttrib(WindowCmd<void>::window()->winClient(), m_attrib); 278 Remember::instance().forgetAttrib(FbMenu::window()->winClient(), m_attrib);
280 } else { 279 } else {
281 Remember::instance().rememberAttrib(WindowCmd<void>::window()->winClient(), m_attrib); 280 Remember::instance().rememberAttrib(FbMenu::window()->winClient(), m_attrib);
282 } 281 }
283 } 282 }
284 Remember::instance().save(); 283 Remember::instance().save();