]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/spinctrl.cpp
Remove wxT from prototype
[wxWidgets.git] / src / gtk / spinctrl.cpp
index f35eca84452dcb4b55f319d834ae7db6b883e4eb..e2c07c0b74f737ffc71b0d4134cc5e92cfa63602 100644 (file)
@@ -21,7 +21,9 @@
     #include "wx/wxcrtvararg.h"
 #endif
 
     #include "wx/wxcrtvararg.h"
 #endif
 
+#include <gtk/gtk.h>
 #include "wx/gtk/private.h"
 #include "wx/gtk/private.h"
+#include "wx/gtk/private/gtk2-compat.h"
 
 //-----------------------------------------------------------------------------
 // data
 
 //-----------------------------------------------------------------------------
 // data
@@ -195,7 +197,7 @@ bool wxSpinCtrlGTKBase::GetSnapToTicks() const
 {
     wxCHECK_MSG(m_widget, false, "invalid spin button");
 
 {
     wxCHECK_MSG(m_widget, false, "invalid spin button");
 
-    return gtk_spin_button_get_snap_to_ticks( GTK_SPIN_BUTTON(m_widget) );
+    return gtk_spin_button_get_snap_to_ticks( GTK_SPIN_BUTTON(m_widget) ) != 0;
 }
 
 void wxSpinCtrlGTKBase::SetValue( const wxString& value )
 }
 
 void wxSpinCtrlGTKBase::SetValue( const wxString& value )
@@ -325,10 +327,15 @@ void wxSpinCtrlGTKBase::OnChar( wxKeyEvent &event )
 
 GdkWindow *wxSpinCtrlGTKBase::GTKGetWindow(wxArrayGdkWindows& windows) const
 {
 
 GdkWindow *wxSpinCtrlGTKBase::GTKGetWindow(wxArrayGdkWindows& windows) const
 {
+#ifdef __WXGTK3__
+    // no access to internal GdkWindows
+    wxUnusedVar(windows);
+#else
     GtkSpinButton* spinbutton = GTK_SPIN_BUTTON(m_widget);
 
     windows.push_back(spinbutton->entry.text_area);
     windows.push_back(spinbutton->panel);
     GtkSpinButton* spinbutton = GTK_SPIN_BUTTON(m_widget);
 
     windows.push_back(spinbutton->entry.text_area);
     windows.push_back(spinbutton->panel);
+#endif
 
     return NULL;
 }
 
     return NULL;
 }