]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/toolbar.cpp
assert in AddCatalog() if Init() hadn't been called and also check that we have a...
[wxWidgets.git] / src / motif / toolbar.cpp
index 98619468b59f3925a6377d1d5692e054a04398b1..b6cebddc1b88d0cb4326fed55a800c80a991347d 100644 (file)
 // For compilers that support precompilation, includes "wx.h".
 #include "wx/wxprec.h"
 
-#ifdef __VMS
-#define XtDisplay XTDISPLAY
-#endif
-
 #include "wx/toolbar.h"
 
 #ifndef WX_PRECOMP
@@ -204,11 +200,10 @@ bool wxToolBar::Create(wxWindow *parent,
     if( !wxControl::CreateControl( parent, id, pos, size, style,
                                    wxDefaultValidator, name ) )
         return false;
+    PreCreation();
 
     FixupStyle();
 
-    m_backgroundColour = wxSystemSettings::GetColour(wxSYS_COLOUR_3DFACE);
-
     Widget parentWidget = (Widget) parent->GetClientWidget();
 
     Widget toolbar = XtVaCreateManagedWidget("toolbar",
@@ -232,8 +227,6 @@ bool wxToolBar::Create(wxWindow *parent,
 
     m_mainWidget = (WXWidget) toolbar;
 
-    ChangeFont(false);
-
     wxPoint rPos = pos;
     wxSize  rSize = size;
 
@@ -242,11 +235,10 @@ bool wxToolBar::Create(wxWindow *parent,
     if( rSize.x == -1 && GetParent() )
         rSize.x = GetParent()->GetSize().x;
 
+    PostCreation();
     AttachWidget (parent, m_mainWidget, (WXWidget) NULL,
                   rPos.x, rPos.y, rSize.x, rSize.y);
 
-    ChangeBackgroundColour();
-
     return true;
 }