Author: manolo
Date: 2012-01-12 05:17:55 -0800 (Thu, 12 Jan 2012)
New Revision: 9222
Log:
Added missing fltk3::~SysMenuBar() destructor.

Modified:
   branches/branch-3.0/include/fltk3/SysMenuBar.h
   branches/branch-3.0/test/menubar.cxx

Modified: branches/branch-3.0/include/fltk3/SysMenuBar.h
===================================================================
--- branches/branch-3.0/include/fltk3/SysMenuBar.h      2012-01-12 12:59:29 UTC 
(rev 9221)
+++ branches/branch-3.0/include/fltk3/SysMenuBar.h      2012-01-12 13:17:55 UTC 
(rev 9222)
@@ -59,6 +59,11 @@
       deactivate();                    // don't let the old area take events
       fltk3::sys_menu_bar = this;
     }
+    /** The destructor */
+    ~SysMenuBar() {
+      clear();
+      fltk3::sys_menu_bar = NULL;
+      }
     void menu(const fltk3::MenuItem *m);
     int add(const char* label, unsigned int shortcut, fltk3::Callback*, void 
*user_data=0, int flags=0);
     int insert(int index, const char* label, unsigned int shortcut, 
fltk3::Callback *cb, void *user_data=0, int flags=0);

Modified: branches/branch-3.0/test/menubar.cxx
===================================================================
--- branches/branch-3.0/test/menubar.cxx        2012-01-12 12:59:29 UTC (rev 
9221)
+++ branches/branch-3.0/test/menubar.cxx        2012-01-12 13:17:55 UTC (rev 
9222)
@@ -199,7 +199,6 @@
     smenubar->callback(test_cb);
   }
   else { // switch to window menu bar
-    smenubar->clear();
     delete smenubar;
     menubar->show();
   }

_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit

Reply via email to