]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/toolbar.cpp
Fix to make frame visible under eVC 3.0
[wxWidgets.git] / src / univ / toolbar.cpp
index 45879f6613bb304605c33a8bde40e15c8c57494d..74ff8b55e0effb50ad7093cf2572c97eeeba88ed 100644 (file)
@@ -138,23 +138,6 @@ IMPLEMENT_DYNAMIC_CLASS(wxToolBar, wxControl);
 // wxToolBar creation
 // ----------------------------------------------------------------------------
 
-wxToolBar::wxToolBar()
-{
-    Init();
-}
-
-wxToolBar::wxToolBar(wxWindow *parent,
-                     wxWindowID id,
-                     const wxPoint& pos,
-                     const wxSize& size,
-                     long style,
-                     const wxString& name)
-{
-    Init();
-
-    Create(parent, id, pos, size, style, name);
-}
-
 void wxToolBar::Init()
 {
     // no tools yet
@@ -662,6 +645,8 @@ bool wxToolBar::PerformAction(const wxControlAction& action,
                               const wxString& strArg)
 {
     wxToolBarTool *tool = (wxToolBarTool*) FindById(numArg);
+    if (!tool)
+        return false;
     
     if ( action == wxACTION_TOOLBAR_TOGGLE )
     {