]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/widgets/gauge.cpp
more wxFD_XXX renamings (patch 1488371)
[wxWidgets.git] / samples / widgets / gauge.cpp
index 5b950ee073286c4cac7932ff9811ce5f42b7535f..f7cd1bb582c17749ff2f5ae9cc7469f7684b6456 100644 (file)
@@ -52,7 +52,7 @@
 // control ids
 enum
 {
-    GaugePage_Reset = 100,
+    GaugePage_Reset = wxID_HIGHEST,
     GaugePage_Progress,
     GaugePage_Clear,
     GaugePage_SetValue,
@@ -71,7 +71,7 @@ enum
 class GaugeWidgetsPage : public WidgetsPage
 {
 public:
-    GaugeWidgetsPage(wxBookCtrlBase *book, wxImageList *imaglist);
+    GaugeWidgetsPage(WidgetsBookCtrl *book, wxImageList *imaglist);
     virtual ~GaugeWidgetsPage();
 
     virtual wxControl *GetWidget() const { return m_gauge; }
@@ -157,14 +157,18 @@ END_EVENT_TABLE()
 // implementation
 // ============================================================================
 
-IMPLEMENT_WIDGETS_PAGE(GaugeWidgetsPage, _T("Gauge"));
+#if defined(__WXUNIVERSAL__)
+    #define FAMILY_CTRLS UNIVERSAL_CTRLS
+#else
+    #define FAMILY_CTRLS NATIVE_CTRLS
+#endif
+
+IMPLEMENT_WIDGETS_PAGE(GaugeWidgetsPage, _T("Gauge"), FAMILY_CTRLS );
 
-GaugeWidgetsPage::GaugeWidgetsPage(wxBookCtrlBase *book,
+GaugeWidgetsPage::GaugeWidgetsPage(WidgetsBookCtrl *book,
                                    wxImageList *imaglist)
-                 :WidgetsPage(book)
+                 :WidgetsPage(book, imaglist, gauge_xpm)
 {
-    imaglist->Add(wxBitmap(gauge_xpm));
-
     // init everything
     m_range = 100;