Mercurial > pidgin.yaz
comparison pidgin/gtknotify.c @ 15734:80fe830ab842
Set the URGENT hint for the mail window when new mails come in and the window is open.
author | Sadrul Habib Chowdhury <imadil@gmail.com> |
---|---|
date | Mon, 26 Feb 2007 06:27:51 +0000 |
parents | 442128853bdb |
children | 427ca6a0aa87 |
comparison
equal
deleted
inserted
replaced
15733:326aab92ba64 | 15734:80fe830ab842 |
---|---|
321 | 321 |
322 dialog = gtk_dialog_new_with_buttons(_("New Mail"), NULL, 0, | 322 dialog = gtk_dialog_new_with_buttons(_("New Mail"), NULL, 0, |
323 GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, | 323 GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, |
324 NULL); | 324 NULL); |
325 gtk_window_set_role(GTK_WINDOW(dialog), "new_mail_detailed"); | 325 gtk_window_set_role(GTK_WINDOW(dialog), "new_mail_detailed"); |
326 g_signal_connect(G_OBJECT(dialog), "focus-in-event", | |
327 G_CALLBACK(pidgin_set_urgent), NULL); | |
326 | 328 |
327 gtk_dialog_add_button(GTK_DIALOG(dialog), | 329 gtk_dialog_add_button(GTK_DIALOG(dialog), |
328 _("Open All Messages"), GTK_RESPONSE_ACCEPT); | 330 _("Open All Messages"), GTK_RESPONSE_ACCEPT); |
329 | 331 |
330 button = gtk_dialog_add_button(GTK_DIALOG(dialog), | 332 button = gtk_dialog_add_button(GTK_DIALOG(dialog), |
519 (GDestroyNotify)reset_mail_dialog); | 521 (GDestroyNotify)reset_mail_dialog); |
520 mail_dialog->in_use = FALSE; | 522 mail_dialog->in_use = FALSE; |
521 g_free(label_text); | 523 g_free(label_text); |
522 if (pixbuf) | 524 if (pixbuf) |
523 g_object_unref(pixbuf); | 525 g_object_unref(pixbuf); |
524 } | 526 } else if (!GTK_WIDGET_HAS_FOCUS(dialog)) |
527 pidgin_set_urgent(GTK_WINDOW(dialog), TRUE); | |
525 | 528 |
526 return NULL; | 529 return NULL; |
527 } | 530 } |
528 | 531 |
529 static gboolean | 532 static gboolean |