comparison pidgin/gtkprefs.c @ 15507:311315e979f7

gtkutils changes
author Sean Egan <seanegan@gmail.com>
date Sat, 03 Feb 2007 08:45:32 +0000
parents 6fde15c1dcfc
children 535f002e7b0f 75ffc646647f
comparison
equal deleted inserted replaced
15506:e4c39e261389 15507:311315e979f7
121 if (sg) { 121 if (sg) {
122 gtk_size_group_add_widget(sg, label); 122 gtk_size_group_add_widget(sg, label);
123 gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5); 123 gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5);
124 } 124 }
125 125
126 gaim_set_accessible_label (spin, label); 126 pidgin_set_accessible_label (spin, label);
127 127
128 return hbox; 128 return hbox;
129 } 129 }
130 130
131 static void 131 static void
165 if(sg) { 165 if(sg) {
166 gtk_size_group_add_widget(sg, label); 166 gtk_size_group_add_widget(sg, label);
167 gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5); 167 gtk_misc_set_alignment(GTK_MISC(label), 0.0, 0.5);
168 } 168 }
169 169
170 gaim_set_accessible_label(entry, label); 170 pidgin_set_accessible_label(entry, label);
171 171
172 return hbox; 172 return hbox;
173 } 173 }
174 174
175 static void 175 static void
237 menu = gtk_menu_new(); 237 menu = gtk_menu_new();
238 #endif 238 #endif
239 239
240 if (label != NULL) { 240 if (label != NULL) {
241 gtk_label_set_mnemonic_widget(GTK_LABEL(label), dropdown); 241 gtk_label_set_mnemonic_widget(GTK_LABEL(label), dropdown);
242 gaim_set_accessible_label (dropdown, label); 242 pidgin_set_accessible_label (dropdown, label);
243 } 243 }
244 244
245 if (type == GAIM_PREF_INT) 245 if (type == GAIM_PREF_INT)
246 stored_int = gaim_prefs_get_int(key); 246 stored_int = gaim_prefs_get_int(key);
247 else if (type == GAIM_PREF_STRING) 247 else if (type == GAIM_PREF_STRING)
694 gtk_tree_path_free(path); 694 gtk_tree_path_free(path);
695 } 695 }
696 696
697 gtk_widget_show_all(ret); 697 gtk_widget_show_all(ret);
698 698
699 gaim_set_accessible_label (view, label); 699 pidgin_set_accessible_label (view, label);
700 700
701 return ret; 701 return ret;
702 } 702 }
703 703
704 static void 704 static void
1056 */ 1056 */
1057 if (gaim_network_get_my_ip(-1) != NULL) 1057 if (gaim_network_get_my_ip(-1) != NULL)
1058 gtk_entry_set_text(GTK_ENTRY(entry), 1058 gtk_entry_set_text(GTK_ENTRY(entry),
1059 gaim_network_get_my_ip(-1)); 1059 gaim_network_get_my_ip(-1));
1060 1060
1061 gaim_set_accessible_label (entry, label); 1061 pidgin_set_accessible_label (entry, label);
1062 1062
1063 1063
1064 if (gaim_prefs_get_bool("/core/network/auto_ip")) { 1064 if (gaim_prefs_get_bool("/core/network/auto_ip")) {
1065 gtk_widget_set_sensitive(GTK_WIDGET(table), FALSE); 1065 gtk_widget_set_sensitive(GTK_WIDGET(table), FALSE);
1066 } 1066 }
1126 gtk_entry_set_text(GTK_ENTRY(entry), 1126 gtk_entry_set_text(GTK_ENTRY(entry),
1127 gaim_proxy_info_get_host(proxy_info)); 1127 gaim_proxy_info_get_host(proxy_info));
1128 1128
1129 hbox = gtk_hbox_new(TRUE, 5); 1129 hbox = gtk_hbox_new(TRUE, 5);
1130 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); 1130 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
1131 gaim_set_accessible_label (entry, label); 1131 pidgin_set_accessible_label (entry, label);
1132 1132
1133 label = gtk_label_new_with_mnemonic(_("_Port:")); 1133 label = gtk_label_new_with_mnemonic(_("_Port:"));
1134 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5); 1134 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
1135 gtk_table_attach(GTK_TABLE(table), label, 2, 3, 0, 1, GTK_FILL, 0, 0, 0); 1135 gtk_table_attach(GTK_TABLE(table), label, 2, 3, 0, 1, GTK_FILL, 0, 0, 0);
1136 1136
1145 g_snprintf(buf, sizeof(buf), "%d", 1145 g_snprintf(buf, sizeof(buf), "%d",
1146 gaim_proxy_info_get_port(proxy_info)); 1146 gaim_proxy_info_get_port(proxy_info));
1147 1147
1148 gtk_entry_set_text(GTK_ENTRY(entry), buf); 1148 gtk_entry_set_text(GTK_ENTRY(entry), buf);
1149 } 1149 }
1150 gaim_set_accessible_label (entry, label); 1150 pidgin_set_accessible_label (entry, label);
1151 1151
1152 label = gtk_label_new_with_mnemonic(_("_User:")); 1152 label = gtk_label_new_with_mnemonic(_("_User:"));
1153 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5); 1153 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
1154 gtk_table_attach(GTK_TABLE(table), label, 0, 1, 1, 2, GTK_FILL, 0, 0, 0); 1154 gtk_table_attach(GTK_TABLE(table), label, 0, 1, 1, 2, GTK_FILL, 0, 0, 0);
1155 1155
1163 gtk_entry_set_text(GTK_ENTRY(entry), 1163 gtk_entry_set_text(GTK_ENTRY(entry),
1164 gaim_proxy_info_get_username(proxy_info)); 1164 gaim_proxy_info_get_username(proxy_info));
1165 1165
1166 hbox = gtk_hbox_new(TRUE, 5); 1166 hbox = gtk_hbox_new(TRUE, 5);
1167 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); 1167 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
1168 gaim_set_accessible_label (entry, label); 1168 pidgin_set_accessible_label (entry, label);
1169 1169
1170 label = gtk_label_new_with_mnemonic(_("Pa_ssword:")); 1170 label = gtk_label_new_with_mnemonic(_("Pa_ssword:"));
1171 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5); 1171 gtk_misc_set_alignment(GTK_MISC(label), 1.0, 0.5);
1172 gtk_table_attach(GTK_TABLE(table), label, 2, 3, 1, 2, GTK_FILL, 0, 0, 0); 1172 gtk_table_attach(GTK_TABLE(table), label, 2, 3, 1, 2, GTK_FILL, 0, 0, 0);
1173 1173
1181 G_CALLBACK(proxy_print_option), (void *)PROXYPASS); 1181 G_CALLBACK(proxy_print_option), (void *)PROXYPASS);
1182 1182
1183 if (proxy_info != NULL && gaim_proxy_info_get_password(proxy_info) != NULL) 1183 if (proxy_info != NULL && gaim_proxy_info_get_password(proxy_info) != NULL)
1184 gtk_entry_set_text(GTK_ENTRY(entry), 1184 gtk_entry_set_text(GTK_ENTRY(entry),
1185 gaim_proxy_info_get_password(proxy_info)); 1185 gaim_proxy_info_get_password(proxy_info));
1186 gaim_set_accessible_label (entry, label); 1186 pidgin_set_accessible_label (entry, label);
1187 } 1187 }
1188 1188
1189 gtk_widget_show_all(ret); 1189 gtk_widget_show_all(ret);
1190 if (proxy_info == NULL || 1190 if (proxy_info == NULL ||
1191 gaim_proxy_info_get_type(proxy_info) == GAIM_PROXY_NONE || 1191 gaim_proxy_info_get_type(proxy_info) == GAIM_PROXY_NONE ||
1296 gtk_size_group_add_widget(sg, label); 1296 gtk_size_group_add_widget(sg, label);
1297 1297
1298 hbox = gtk_hbox_new(FALSE, 0); 1298 hbox = gtk_hbox_new(FALSE, 0);
1299 label = pidgin_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT, 1299 label = pidgin_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT,
1300 "/gaim/gtk/browsers/place", 1300 "/gaim/gtk/browsers/place",
1301 _("Browser default"), GAIM_BROWSER_DEFAULT, 1301 _("Browser default"), PIDGIN_BROWSER_DEFAULT,
1302 _("Existing window"), GAIM_BROWSER_CURRENT, 1302 _("Existing window"), PIDGIN_BROWSER_CURRENT,
1303 _("New window"), GAIM_BROWSER_NEW_WINDOW, 1303 _("New window"), PIDGIN_BROWSER_NEW_WINDOW,
1304 _("New tab"), GAIM_BROWSER_NEW_TAB, 1304 _("New tab"), PIDGIN_BROWSER_NEW_TAB,
1305 NULL); 1305 NULL);
1306 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); 1306 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5);
1307 gtk_size_group_add_widget(sg, label); 1307 gtk_size_group_add_widget(sg, label);
1308 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); 1308 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
1309 1309
1332 1332
1333 gtk_entry_set_text(GTK_ENTRY(entry), 1333 gtk_entry_set_text(GTK_ENTRY(entry),
1334 gaim_prefs_get_path("/gaim/gtk/browsers/command")); 1334 gaim_prefs_get_path("/gaim/gtk/browsers/command"));
1335 g_signal_connect(G_OBJECT(entry), "focus-out-event", 1335 g_signal_connect(G_OBJECT(entry), "focus-out-event",
1336 G_CALLBACK(manual_browser_set), NULL); 1336 G_CALLBACK(manual_browser_set), NULL);
1337 gaim_set_accessible_label (entry, label); 1337 pidgin_set_accessible_label (entry, label);
1338 1338
1339 gtk_widget_show_all(ret); 1339 gtk_widget_show_all(ret);
1340 return ret; 1340 return ret;
1341 } 1341 }
1342 #endif /*_WIN32*/ 1342 #endif /*_WIN32*/
1631 sound_changed1_cb, hbox); 1631 sound_changed1_cb, hbox);
1632 gtk_widget_set_sensitive(hbox, 1632 gtk_widget_set_sensitive(hbox,
1633 !strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"), 1633 !strcmp(gaim_prefs_get_string("/gaim/gtk/sound/method"),
1634 "custom")); 1634 "custom"));
1635 1635
1636 gaim_set_accessible_label (entry, label); 1636 pidgin_set_accessible_label (entry, label);
1637 #endif /* _WIN32 */ 1637 #endif /* _WIN32 */
1638 1638
1639 vbox = pidgin_make_frame (ret, _("Sound Options")); 1639 vbox = pidgin_make_frame (ret, _("Sound Options"));
1640 pidgin_prefs_checkbox(_("Sounds when conversation has _focus"), 1640 pidgin_prefs_checkbox(_("Sounds when conversation has _focus"),
1641 "/gaim/gtk/sound/conv_focus", vbox); 1641 "/gaim/gtk/sound/conv_focus", vbox);
2032 gaim_prefs_add_none("/plugins/gtk"); 2032 gaim_prefs_add_none("/plugins/gtk");
2033 2033
2034 #ifndef _WIN32 2034 #ifndef _WIN32
2035 /* Browsers */ 2035 /* Browsers */
2036 gaim_prefs_add_none("/gaim/gtk/browsers"); 2036 gaim_prefs_add_none("/gaim/gtk/browsers");
2037 gaim_prefs_add_int("/gaim/gtk/browsers/place", GAIM_BROWSER_DEFAULT); 2037 gaim_prefs_add_int("/gaim/gtk/browsers/place", PIDGIN_BROWSER_DEFAULT);
2038 gaim_prefs_add_path("/gaim/gtk/browsers/command", ""); 2038 gaim_prefs_add_path("/gaim/gtk/browsers/command", "");
2039 gaim_prefs_add_string("/gaim/gtk/browsers/browser", "mozilla"); 2039 gaim_prefs_add_string("/gaim/gtk/browsers/browser", "mozilla");
2040 #endif 2040 #endif
2041 2041
2042 /* Plugins */ 2042 /* Plugins */