]> git.saurik.com Git - wxWidgets.git/commitdiff
GTK2: gtk_entry_* -> gtk_editable_* where necessary
authorMart Raudsepp <leio@gentoo.org>
Sat, 4 Feb 2006 00:50:47 +0000 (00:50 +0000)
committerMart Raudsepp <leio@gentoo.org>
Sat, 4 Feb 2006 00:50:47 +0000 (00:50 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@37296 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/gtk/textctrl.cpp

index 4af8467bf3375c09c306dfd85f975ee9bb7d5230..74425264affe64cd87ce20917f0756d6c2a15f86 100644 (file)
@@ -634,7 +634,7 @@ bool wxTextCtrl::Create( wxWindow *parent,
     if (style & wxTE_READONLY)
     {
         if (!multi_line)
-            gtk_entry_set_editable( GTK_ENTRY(m_text), FALSE );
+            gtk_editable_set_editable( GTK_EDITABLE(m_text), FALSE );
         else
             gtk_text_view_set_editable( GTK_TEXT_VIEW( m_text), FALSE);
     }
@@ -846,7 +846,7 @@ void wxTextCtrl::WriteText( const wxString &text )
         gtk_editable_insert_text( GTK_EDITABLE(m_text), buffer, strlen(buffer), &len );
 
         // Bring entry's cursor uptodate.
-        gtk_entry_set_position( GTK_ENTRY(m_text), len );
+        gtk_editable_set_position( GTK_EDITABLE(m_text), len );
     }
 
     m_modified = oldModified;
@@ -974,9 +974,7 @@ void wxTextCtrl::SetInsertionPoint( long pos )
     }
     else
     {
-        gtk_entry_set_position( GTK_ENTRY(m_text), (int)pos );
-
-        // Bring editable's cursor uptodate. Bug in GTK.
+        // FIXME: Is the editable's cursor really uptodate without double set_position in GTK2?
         gtk_editable_set_position(GTK_EDITABLE(m_text), int(pos));
     }
 }
@@ -993,7 +991,7 @@ void wxTextCtrl::SetInsertionPointEnd()
     }
     else
     {
-        gtk_entry_set_position( GTK_ENTRY(m_text), -1 );
+        gtk_editable_set_position( GTK_EDITABLE(m_text), -1 );
     }
 }
 
@@ -1007,7 +1005,7 @@ void wxTextCtrl::SetEditable( bool editable )
     }
     else
     {
-        gtk_entry_set_editable( GTK_ENTRY(m_text), editable );
+        gtk_editable_set_editable( GTK_EDITABLE(m_text), editable );
     }
 }