]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/spinbutt.cpp
don't use wxString::FromASCII() with possibly non-ASCII strings (fixes asserts when...
[wxWidgets.git] / src / gtk / spinbutt.cpp
index b886fbc324cf549b2cfa5855ccfc857db96769b8..45138d8ae483481fc4baffeeb43d91499e0eecf1 100644 (file)
@@ -107,6 +107,7 @@ bool wxSpinButton::Create(wxWindow *parent,
     m_pos = 0;
 
     m_widget = gtk_spin_button_new_with_range(0, 100, 1);
     m_pos = 0;
 
     m_widget = gtk_spin_button_new_with_range(0, 100, 1);
+    g_object_ref(m_widget);
 
     gtk_spin_button_set_wrap( GTK_SPIN_BUTTON(m_widget),
                               (int)(m_windowStyle & wxSP_WRAP) );
 
     gtk_spin_button_set_wrap( GTK_SPIN_BUTTON(m_widget),
                               (int)(m_windowStyle & wxSP_WRAP) );