/////////////////////////////////////////////////////////////////////////////
-// Program: wxWindows Widgets Sample
+// Program: wxWidgets Widgets Sample
// Name: radiobox.cpp
// Purpose: Part of the widgets sample showing wxRadioBox
// Author: Vadim Zeitlin
#pragma hdrstop
#endif
+#if wxUSE_RADIOBOX
+
// for all others, include the necessary headers
#ifndef WX_PRECOMP
#include "wx/log.h"
#include "wx/sizer.h"
#include "widgets.h"
-#if 1
+
#include "icons/radiobox.xpm"
// ----------------------------------------------------------------------------
class RadioWidgetsPage : public WidgetsPage
{
public:
- RadioWidgetsPage(wxNotebook *notebook, wxImageList *imaglist);
- virtual ~RadioWidgetsPage();
+ RadioWidgetsPage(wxBookCtrl *book, wxImageList *imaglist);
+ virtual ~RadioWidgetsPage(){};
+
+ virtual wxControl *GetWidget() const { return m_radio; }
protected:
// event handlers
IMPLEMENT_WIDGETS_PAGE(RadioWidgetsPage, _T("Radio"));
-RadioWidgetsPage::RadioWidgetsPage(wxNotebook *notebook,
- wxImageList *imaglist)
- : WidgetsPage(notebook)
+RadioWidgetsPage::RadioWidgetsPage(wxBookCtrl *book,
+ wxImageList *imaglist)
+ : WidgetsPage(book)
{
imaglist->Add(wxBitmap(radio_xpm));
sizerTop->Fit(this);
}
-RadioWidgetsPage::~RadioWidgetsPage()
-{
-}
-
// ----------------------------------------------------------------------------
// operations
// ----------------------------------------------------------------------------
event.Enable(enable);
}
-#endif
+#endif // wxUSE_RADIOBOX