wxButtonToolBar only useful on Mac right now

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38705 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart 2006-04-14 10:09:11 +00:00
parent e5f49cbf82
commit b887dc7b5a
4 changed files with 11 additions and 3 deletions

View File

@ -369,7 +369,9 @@ bool MyApp::OnInit()
wxMenu *sheet_menu = new wxMenu;
sheet_menu->Append(DIALOGS_PROPERTY_SHEET, _T("&Standard property sheet\tShift-Ctrl-P"));
sheet_menu->Append(DIALOGS_PROPERTY_SHEET_TOOLBOOK, _T("&Toolbook sheet\tShift-Ctrl-T"));
#ifdef __WXMAC__
sheet_menu->Append(DIALOGS_PROPERTY_SHEET_BUTTONTOOLBOOK, _T("Button &Toolbook sheet\tShift-Ctrl-U"));
#endif
file_menu->Append(wxID_ANY, _T("&Property sheets"), sheet_menu);
#endif // USE_SETTINGS_DIALOG

View File

@ -25,7 +25,8 @@
#pragma hdrstop
#endif
#if wxUSE_TOOLBAR && wxUSE_BMPBUTTON
// Currently, only for Mac as a toolbar replacement.
#if defined(__WXMAC__) && wxUSE_TOOLBAR && wxUSE_BMPBUTTON
#ifndef WX_PRECOMP
#include "wx/utils.h"

View File

@ -154,7 +154,7 @@ wxBookCtrlBase* wxPropertySheetDialog::CreateBookCtrl()
bookCtrl = new wxChoicebook(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, style );
#endif
#if wxUSE_TOOLBOOK
#if wxUSE_TOOLBAR && wxUSE_BMPBUTTON
#if defined(__WXMAC__) && wxUSE_TOOLBAR && wxUSE_BMPBUTTON
if (GetSheetStyle() & wxPROPSHEET_BUTTONTOOLBOOK)
bookCtrl = new wxToolbook(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, style|wxBK_BUTTONBAR );
else

View File

@ -27,7 +27,10 @@
#include "wx/imaglist.h"
#include "wx/sysopt.h"
#include "wx/toolbook.h"
#if defined(__WXMAC__) && wxUSE_TOOLBAR && wxUSE_BMPBUTTON
#include "wx/generic/buttonbar.h"
#endif
// ----------------------------------------------------------------------------
// various wxWidgets macros
@ -91,6 +94,7 @@ bool wxToolbook::Create(wxWindow *parent,
// TODO: make more configurable
#if defined(__WXMAC__) && wxUSE_TOOLBAR && wxUSE_BMPBUTTON
if (style & wxBK_BUTTONBAR)
{
m_bookctrl = new wxButtonToolBar
@ -103,6 +107,7 @@ bool wxToolbook::Create(wxWindow *parent,
);
}
else
#endif
{
m_bookctrl = new wxToolBar
(
@ -110,7 +115,7 @@ bool wxToolbook::Create(wxWindow *parent,
wxID_TOOLBOOKTOOLBAR,
wxDefaultPosition,
wxDefaultSize,
orient | wxTB_TEXT|wxTB_FLAT|wxTB_NODIVIDER
orient|wxTB_TEXT|wxTB_FLAT|wxTB_NODIVIDER|wxNO_BORDER
);
}