From 9fb35cf18009442686df164132c451479c98d536 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 16 Dec 1999 17:39:07 +0000 Subject: [PATCH] small fix to the sample git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@4990 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- samples/toolbar/toolbar.cpp | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/samples/toolbar/toolbar.cpp b/samples/toolbar/toolbar.cpp index e5fb895027..9106c8f504 100644 --- a/samples/toolbar/toolbar.cpp +++ b/samples/toolbar/toolbar.cpp @@ -32,12 +32,12 @@ #include // define this to 1 to use wxToolBarSimple instead of the native one -#define USE_GENERIC_TBAR 1 +#define USE_GENERIC_TBAR 0 #if USE_GENERIC_TBAR #if !wxUSE_TOOLBAR_SIMPLE - #error "wxToolBarSimple is not compiled in, set wxUSE_TOOLBAR_SIMPLE "\ - "to 1 in setup.h and recompile the library." + #error wxToolBarSimple is not compiled in, set wxUSE_TOOLBAR_SIMPLE \ + to 1 in setup.h and recompile the library. #else #include #endif @@ -217,6 +217,13 @@ void MyFrame::RecreateToolbar() wxBitmap toolBarBitmaps[8]; toolBarBitmaps[0] = wxBITMAP(new); +#if 0 + toolBar->AddTool(wxID_NEW, toolBarBitmaps[0], wxNullBitmap, FALSE, -1, -1, + (wxObject *) NULL, "New file"); + toolBar->Realize(); + return; +#endif + toolBarBitmaps[1] = wxBITMAP(open); if ( !m_smallToolbar ) { @@ -372,7 +379,7 @@ void MyFrame::OnToggleToolbarRows(wxCommandEvent& WXUNUSED(event)) GetToolBar()->SetRows(m_horzToolbar ? m_rows : 10 / m_rows); - //RecreateToolbar(); + //RecreateToolbar(); -- this is unneeded } void MyFrame::OnToggleToolbarOrient(wxCommandEvent& WXUNUSED(event)) -- 2.45.2