]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/toolbar/toolbar.cpp
a temporary hack to make testing wxTLW/Univ easier
[wxWidgets.git] / samples / toolbar / toolbar.cpp
index c0a98dd8dc8c087150e5ae374757c5019d698574..c839ceee559e4bbc4e63433ff162321a00d9a0c0 100644 (file)
@@ -152,6 +152,8 @@ private:
 
 const int ID_TOOLBAR = 500;
 
 
 const int ID_TOOLBAR = 500;
 
+static const long TOOLBAR_STYLE = wxNO_BORDER | wxTB_FLAT | wxTB_DOCKABLE;
+
 enum
 {
     IDM_TOOLBAR_TOGGLETOOLBARSIZE = 200,
 enum
 {
     IDM_TOOLBAR_TOGGLETOOLBARSIZE = 200,
@@ -240,7 +242,7 @@ void MyFrame::RecreateToolbar()
 
     SetToolBar(NULL);
 
 
     SetToolBar(NULL);
 
-    long style = wxNO_BORDER | wxTB_FLAT | wxTB_DOCKABLE;
+    long style = TOOLBAR_STYLE;
     style |= m_horzToolbar ? wxTB_HORIZONTAL : wxTB_VERTICAL;
 
     toolBar = CreateToolBar(style, ID_TOOLBAR);
     style |= m_horzToolbar ? wxTB_HORIZONTAL : wxTB_VERTICAL;
 
     toolBar = CreateToolBar(style, ID_TOOLBAR);
@@ -465,7 +467,7 @@ void MyFrame::OnToggleAnotherToolbar(wxCommandEvent& WXUNUSED(event))
     {
         m_tbar = new wxToolBar(this, -1,
                                wxDefaultPosition, wxDefaultSize,
     {
         m_tbar = new wxToolBar(this, -1,
                                wxDefaultPosition, wxDefaultSize,
-                               wxTB_VERTICAL);
+                               TOOLBAR_STYLE | wxTB_VERTICAL);
         m_tbar->AddTool(wxID_HELP, wxBITMAP(help),
                         wxNullBitmap, FALSE,
                         NULL,
         m_tbar->AddTool(wxID_HELP, wxBITMAP(help),
                         wxNullBitmap, FALSE,
                         NULL,
@@ -604,8 +606,6 @@ void MyFrame::OnToolEnter(wxCommandEvent& event)
 
 void MyFrame::OnToggleFullScreen(wxCommandEvent& event)
 {
 
 void MyFrame::OnToggleFullScreen(wxCommandEvent& event)
 {
-#ifdef __WXMSW__
     ShowFullScreen(!IsFullScreen());
     ShowFullScreen(!IsFullScreen());
-#endif
 }
 
 }