comparison src/dialogs.c @ 1694:bea407767ac1

[gaim-migrate @ 1704] Sounds on buddy pounce. This may need a better AU file, im not sure yet. committer: Tailor Script <tailor@pidgin.im>
author Rob Flynn <gaim@robflynn.com>
date Mon, 09 Apr 2001 08:33:09 +0000
parents 0f7d2284296f
children 644056e095f1
comparison
equal deleted inserted replaced
1693:6ccd49e6f24c 1694:bea407767ac1
132 GtkWidget *p_signon; 132 GtkWidget *p_signon;
133 GtkWidget *p_unaway; 133 GtkWidget *p_unaway;
134 GtkWidget *p_unidle; 134 GtkWidget *p_unidle;
135 GtkWidget *save; 135 GtkWidget *save;
136 GtkWidget *menu; 136 GtkWidget *menu;
137 GtkWidget *sound;
138 GtkWidget *soundentry;
137 139
138 struct aim_user *user; 140 struct aim_user *user;
139 }; 141 };
140 142
141 struct findbyemail { 143 struct findbyemail {
1012 } 1014 }
1013 1015
1014 g_snprintf(bp->name, 80, "%s", gtk_entry_get_text(GTK_ENTRY(b->nameentry))); 1016 g_snprintf(bp->name, 80, "%s", gtk_entry_get_text(GTK_ENTRY(b->nameentry)));
1015 g_snprintf(bp->message, 2048, "%s", gtk_entry_get_text(GTK_ENTRY(b->messentry))); 1017 g_snprintf(bp->message, 2048, "%s", gtk_entry_get_text(GTK_ENTRY(b->messentry)));
1016 g_snprintf(bp->command, 2048, "%s", gtk_entry_get_text(GTK_ENTRY(b->commentry))); 1018 g_snprintf(bp->command, 2048, "%s", gtk_entry_get_text(GTK_ENTRY(b->commentry)));
1019 g_snprintf(bp->sound, 2048, "%s", gtk_entry_get_text(GTK_ENTRY(b->soundentry)));
1017 g_snprintf(bp->pouncer, 80, "%s", b->user->username); 1020 g_snprintf(bp->pouncer, 80, "%s", b->user->username);
1018 1021
1019 bp->protocol = b->user->protocol; 1022 bp->protocol = b->user->protocol;
1020 1023
1021 bp->options = 0; 1024 bp->options = 0;
1026 if (GTK_TOGGLE_BUTTON(b->sendim)->active) 1029 if (GTK_TOGGLE_BUTTON(b->sendim)->active)
1027 bp->options |= OPT_POUNCE_SEND_IM; 1030 bp->options |= OPT_POUNCE_SEND_IM;
1028 1031
1029 if (GTK_TOGGLE_BUTTON(b->command)->active) 1032 if (GTK_TOGGLE_BUTTON(b->command)->active)
1030 bp->options |= OPT_POUNCE_COMMAND; 1033 bp->options |= OPT_POUNCE_COMMAND;
1034
1035 if (GTK_TOGGLE_BUTTON(b->sound)->active)
1036 bp->options |= OPT_POUNCE_SOUND;
1031 1037
1032 if (GTK_TOGGLE_BUTTON(b->p_signon)->active) 1038 if (GTK_TOGGLE_BUTTON(b->p_signon)->active)
1033 bp->options |= OPT_POUNCE_SIGNON; 1039 bp->options |= OPT_POUNCE_SIGNON;
1034 1040
1035 if (GTK_TOGGLE_BUTTON(b->p_unaway)->active) 1041 if (GTK_TOGGLE_BUTTON(b->p_unaway)->active)
1173 b->openwindow = gtk_check_button_new_with_label(_("Open IM window on pounce")); 1179 b->openwindow = gtk_check_button_new_with_label(_("Open IM window on pounce"));
1174 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->openwindow), FALSE); 1180 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->openwindow), FALSE);
1175 gtk_box_pack_start(GTK_BOX(vbox), b->openwindow, FALSE, FALSE, 0); 1181 gtk_box_pack_start(GTK_BOX(vbox), b->openwindow, FALSE, FALSE, 0);
1176 gtk_widget_show(b->openwindow); 1182 gtk_widget_show(b->openwindow);
1177 1183
1178 b->sendim = gtk_check_button_new_with_label(_("Send IM on pounce")); 1184 b->sendim = gtk_check_button_new_with_label(_("Send IM on pounce"));
1179 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->sendim), TRUE); 1185 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->sendim), TRUE);
1180 gtk_box_pack_start(GTK_BOX(vbox), b->sendim, FALSE, FALSE, 0); 1186 gtk_box_pack_start(GTK_BOX(vbox), b->sendim, FALSE, FALSE, 0);
1181 gtk_widget_show(b->sendim); 1187 gtk_widget_show(b->sendim);
1182 1188
1183 hbox = gtk_hbox_new(FALSE, 5); 1189 hbox = gtk_hbox_new(FALSE, 5);
1215 GTK_SIGNAL_FUNC(do_new_bp), b); 1221 GTK_SIGNAL_FUNC(do_new_bp), b);
1216 gtk_widget_show(b->commentry); 1222 gtk_widget_show(b->commentry);
1217 1223
1218 gtk_widget_set_sensitive(b->commentry, FALSE); 1224 gtk_widget_set_sensitive(b->commentry, FALSE);
1219 gtk_signal_connect(GTK_OBJECT(b->command), "clicked", GTK_SIGNAL_FUNC(toggle_sensitive), b->commentry); 1225 gtk_signal_connect(GTK_OBJECT(b->command), "clicked", GTK_SIGNAL_FUNC(toggle_sensitive), b->commentry);
1226
1227 b->sound = gtk_check_button_new_with_label(_("Play sound on pounce"));
1228 gtk_toggle_button_set_state(GTK_TOGGLE_BUTTON(b->sound), FALSE);
1229 gtk_box_pack_start(GTK_BOX(vbox), b->sound, FALSE, FALSE, 0);
1230 gtk_widget_show(b->sound);
1231
1232 hbox = gtk_hbox_new(FALSE, 5);
1233 gtk_box_pack_start(GTK_BOX(vbox), hbox, TRUE, TRUE, 0);
1234 gtk_widget_show(hbox);
1235
1236 label = gtk_label_new(_("Sound:"));
1237 gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0);
1238 gtk_widget_show(label);
1239
1240 b->soundentry = gtk_entry_new();
1241 gtk_box_pack_start(GTK_BOX(hbox), b->soundentry, TRUE, TRUE, 0);
1242 gtk_signal_connect(GTK_OBJECT(b->soundentry), "activate",
1243 GTK_SIGNAL_FUNC(do_new_bp), b);
1244 gtk_widget_show(b->soundentry);
1245
1246 gtk_widget_set_sensitive(b->soundentry, FALSE);
1247 gtk_signal_connect(GTK_OBJECT(b->sound), "clicked", GTK_SIGNAL_FUNC(toggle_sensitive), b->soundentry);
1220 1248
1221 sep = gtk_hseparator_new(); 1249 sep = gtk_hseparator_new();
1222 gtk_box_pack_start(GTK_BOX(vbox), sep, FALSE, FALSE, 0); 1250 gtk_box_pack_start(GTK_BOX(vbox), sep, FALSE, FALSE, 0);
1223 gtk_widget_show(sep); 1251 gtk_widget_show(sep);
1224 1252