Mercurial > pidgin
changeset 10367:5fe89d2df440
[gaim-migrate @ 11586]
(14:59:04) SimGuy: make all the gtkprefs widget functions use const char*
keys
(14:59:12) SimGuy: (consistency)
(14:59:24) SimGuy: it's only for 2.0.0, cause it's api changing
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Tue, 14 Dec 2004 20:03:38 +0000 |
parents | fbb78553cae1 |
children | ffb5f76d6188 |
files | src/gtkprefs.c src/gtkprefs.h |
diffstat | 2 files changed, 7 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/src/gtkprefs.c Tue Dec 14 19:36:23 2004 +0000 +++ b/src/gtkprefs.c Tue Dec 14 20:03:38 2004 +0000 @@ -88,7 +88,7 @@ GtkWidget * gaim_gtk_prefs_labeled_spin_button(GtkWidget *box, const gchar *title, - char *key, int min, int max, GtkSizeGroup *sg) + const char *key, int min, int max, GtkSizeGroup *sg) { GtkWidget *hbox; GtkWidget *label; @@ -109,7 +109,7 @@ adjust = gtk_adjustment_new(val, min, max, 1, 1, 1); spin = gtk_spin_button_new(GTK_ADJUSTMENT(adjust), 1, 0); - g_object_set_data(G_OBJECT(spin), "val", key); + g_object_set_data(G_OBJECT(spin), "val", (char *)key); if (max < 10000) gtk_widget_set_size_request(spin, 50, -1); else @@ -133,14 +133,14 @@ static void entry_set(GtkEntry *entry, gpointer data) { - char *key = (char*)data; + const char *key = (const char*)data; gaim_prefs_set_string(key, gtk_entry_get_text(entry)); } GtkWidget * -gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title, char *key, - GtkSizeGroup *sg) +gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title, + const char *key, GtkSizeGroup *sg) { GtkWidget *hbox, *label, *entry; const gchar *value;
--- a/src/gtkprefs.h Tue Dec 14 19:36:23 2004 +0000 +++ b/src/gtkprefs.h Tue Dec 14 20:03:38 2004 +0000 @@ -62,7 +62,7 @@ * value of a checkbox. */ GtkWidget *gaim_gtk_prefs_labeled_spin_button(GtkWidget *page, - const gchar *title, char *key, int min, int max, GtkSizeGroup *sg); + const gchar *title, const char *key, int min, int max, GtkSizeGroup *sg); /** * Add a new entry representing a string preference @@ -77,7 +77,7 @@ * checkbox. */ GtkWidget *gaim_gtk_prefs_labeled_entry(GtkWidget *page, const gchar *title, - char *key, GtkSizeGroup *sg); + const char *key, GtkSizeGroup *sg); /** * Add a new dropdown representing a preference of the specified type