]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/spinbutt.cpp
Added wxGTK-only cmn dialogs.
[wxWidgets.git] / src / gtk1 / spinbutt.cpp
index e5826709025fdd44b1699f1881073dd12f607f05..66f5af6bc3f61173df9c126c4690cc69a8ad7b3f 100644 (file)
@@ -13,6 +13,9 @@
 #endif
 
 #include "wx/spinbutt.h"
+
+#ifdef wxUSE_SPINBTN
+
 #include "wx/utils.h"
 #include <math.h>
 
@@ -42,7 +45,7 @@ static void gtk_spinbutt_callback( GtkWidget *WXUNUSED(widget), wxSpinButton *wi
 {
     if (g_isIdle) wxapp_install_idle_handler();
 
-    if (!win->HasVMT()) return;
+    if (!win->m_hasVMT) return;
     if (g_blockEventsOnDrag) return;
 
     float diff = win->m_adjust->value - win->m_oldPos;
@@ -111,9 +114,7 @@ bool wxSpinButton::Create(wxWindow *parent, wxWindowID id, const wxPoint& pos, c
                         (GtkSignalFunc) gtk_spinbutt_callback,
                         (gpointer) this );
 
-    m_parent->AddChild( this );
-
-    (m_parent->m_insertCallback)( m_parent, this );
+    m_parent->DoAddChild( this );
 
     PostCreation();
 
@@ -210,3 +211,5 @@ wxSpinEvent::wxSpinEvent(wxEventType commandType, int id):
   wxScrollEvent(commandType, id)
 {
 }
+
+#endif
\ No newline at end of file