--- pidgin/gtkprefs.c.orig 2009-09-15 09:22:37 +0400 +++ pidgin/gtkprefs.c 2009-09-15 11:17:34 +0400 @@ -57,6 +57,8 @@ #include "gtkutils.h" #include "pidginstock.h" +#include + #define PROXYHOST 0 #define PROXYPORT 1 #define PROXYUSER 2 @@ -573,6 +575,10 @@ gtk_combo_box_set_active(GTK_COMBO_BOX(combo_box), 0); } +static char +_str_The_default_Pidgin_buddy_list_theme [1024], +_str_The_default_Pidgin_status_icon_theme [1024]; + static void prefs_themes_refresh(void) { @@ -580,6 +586,32 @@ gchar *filename; GtkTreeIter iter; + static int first_call = 1; + + if (first_call) { /* FIXME: this should be done in a regular way */ + + _str_The_default_Pidgin_buddy_list_theme [0] = + _str_The_default_Pidgin_status_icon_theme[0] = '\0'; + + strcat (_str_The_default_Pidgin_buddy_list_theme, "("); + strcat (_str_The_default_Pidgin_buddy_list_theme, _("Default") ); + strcat (_str_The_default_Pidgin_buddy_list_theme, ") - "); + strcat (_str_The_default_Pidgin_buddy_list_theme, _("None") ); + strcat (_str_The_default_Pidgin_buddy_list_theme, "\n"); + strcat (_str_The_default_Pidgin_buddy_list_theme, _("The default Pidgin buddy list theme") ); + strcat (_str_The_default_Pidgin_buddy_list_theme, ""); + + strcat (_str_The_default_Pidgin_status_icon_theme, "("); + strcat (_str_The_default_Pidgin_status_icon_theme, _("Default") ); + strcat (_str_The_default_Pidgin_status_icon_theme, ") - "); + strcat (_str_The_default_Pidgin_status_icon_theme, _("None") ); + strcat (_str_The_default_Pidgin_status_icon_theme, "\n"); + strcat (_str_The_default_Pidgin_status_icon_theme, _("The default Pidgin status icon theme") ); + strcat (_str_The_default_Pidgin_status_icon_theme, ""); + + first_call = 0; + } + /* refresh the list of themes in the manager */ purple_theme_manager_refresh(); @@ -596,15 +628,14 @@ gtk_list_store_clear(prefs_blist_themes); gtk_list_store_append(prefs_blist_themes, &iter); gtk_list_store_set(prefs_blist_themes, &iter, 0, pixbuf, 1, - "(Default) - None\n" - "The default Pidgin buddy list theme___", 2, "", -1); + _str_The_default_Pidgin_buddy_list_theme, 2, "", -1); /* status icon themes */ gtk_list_store_clear(prefs_status_icon_themes); gtk_list_store_append(prefs_status_icon_themes, &iter); gtk_list_store_set(prefs_status_icon_themes, &iter, 0, pixbuf, 1, - "(Default) - None\n" - "The default Pidgin status icon theme", 2, "", -1); + _str_The_default_Pidgin_status_icon_theme, 2, "", -1); + g_object_unref(G_OBJECT(pixbuf)); purple_theme_manager_for_each_theme(prefs_themes_sort); @@ -1770,7 +1801,7 @@ G_CALLBACK(network_stun_server_changed_cb), NULL); gtk_widget_show(entry); - pidgin_add_widget_to_vbox(GTK_BOX(vbox), "ST_UN server:", + pidgin_add_widget_to_vbox(GTK_BOX(vbox), _("ST_UN server:"), sg, entry, TRUE, NULL); hbox = gtk_hbox_new(FALSE, PIDGIN_HIG_BOX_SPACE); @@ -1877,14 +1908,14 @@ G_CALLBACK(network_turn_server_changed_cb), NULL); gtk_widget_show(entry); - hbox = pidgin_add_widget_to_vbox(GTK_BOX(vbox), "_TURN server:", + hbox = pidgin_add_widget_to_vbox(GTK_BOX(vbox), _("_TURN server:"), sg, entry, TRUE, NULL); pidgin_prefs_labeled_spin_button(hbox, _("_Port:"), "/purple/network/turn_port", 0, 65535, NULL); - hbox = pidgin_prefs_labeled_entry(vbox, "_Username:", + hbox = pidgin_prefs_labeled_entry(vbox, _("_Username:"), "/purple/network/turn_username", sg); - pidgin_prefs_labeled_password(hbox, "_Password:", + pidgin_prefs_labeled_password(hbox, _("_Password:"), "/purple/network/turn_password", NULL); if (purple_running_gnome()) {