aboutsummaryrefslogtreecommitdiff
path: root/src/Toolbar.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Toolbar.cc')
-rw-r--r--src/Toolbar.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Toolbar.cc b/src/Toolbar.cc
index 89ba9cf..18f07fc 100644
--- a/src/Toolbar.cc
+++ b/src/Toolbar.cc
@@ -287,7 +287,8 @@ Toolbar::Toolbar(BScreen &scrn, FbTk::XLayer &layer, size_t width):
287} 287}
288 288
289Toolbar::~Toolbar() { 289Toolbar::~Toolbar() {
290 Fluxbox::instance()->keys()->unregisterWindow(window().window()); 290 if (Fluxbox::instance()->keys())
291 Fluxbox::instance()->keys()->unregisterWindow(window().window());
291 FbTk::EventManager::instance()->remove(window()); 292 FbTk::EventManager::instance()->remove(window());
292 // remove menu items before we delete tools so we dont end up 293 // remove menu items before we delete tools so we dont end up
293 // with dangling pointers to old submenu items (internal menus) 294 // with dangling pointers to old submenu items (internal menus)