diff options
author | Stefan Walter <stefw@src.gnome.org> | 2009-03-27 05:22:23 +0000 |
---|---|---|
committer | Stefan Walter <stefw@src.gnome.org> | 2009-03-27 05:22:23 +0000 |
commit | de60fd8cfd3e7e36db22a359e3d75d353f582cb9 (patch) | |
tree | e3807bc487fe47b70bcc35ea77469eec8a929857 /gtk/gtkspinbutton.c | |
parent | e5110c50b67acc86b8007ada306f303edf74a0ce (diff) | |
download | gtk+-de60fd8cfd3e7e36db22a359e3d75d353f582cb9.tar.gz |
Use gtk_entry_xxx functions rather than using GtkEntry structure directly.
See bug #576801
svn path=/trunk/; revision=22589
Diffstat (limited to 'gtk/gtkspinbutton.c')
-rw-r--r-- | gtk/gtkspinbutton.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/gtk/gtkspinbutton.c b/gtk/gtkspinbutton.c index b24d985769..836214b97b 100644 --- a/gtk/gtkspinbutton.c +++ b/gtk/gtkspinbutton.c @@ -1427,8 +1427,10 @@ gtk_spin_button_insert_text (GtkEditable *editable, GdkWChar pos_sign; GdkWChar neg_sign; gint entry_length; + const gchar *entry_text; - entry_length = entry->text_length; + entry_length = gtk_entry_get_text_length (entry); + entry_text = gtk_entry_get_text (entry); lc = localeconv (); @@ -1463,8 +1465,8 @@ gtk_spin_button_insert_text (GtkEditable *editable, #endif for (sign=0, i=0; i<entry_length; i++) - if ((entry->text[i] == neg_sign) || - (entry->text[i] == pos_sign)) + if ((entry_text[i] == neg_sign) || + (entry_text[i] == pos_sign)) { sign = 1; break; @@ -1474,7 +1476,7 @@ gtk_spin_button_insert_text (GtkEditable *editable, return; for (dotpos=-1, i=0; i<entry_length; i++) - if (entry->text[i] == *(lc->decimal_point)) + if (entry_text[i] == *(lc->decimal_point)) { dotpos = i; break; |