Mercurial > pidgin.yaz
comparison pidgin/gtklog.c @ 19873:91c35a2c2705
Stringing log windows
author | Gabriel Schulhof <nix@go-nix.ca> |
---|---|
date | Fri, 17 Aug 2007 22:30:52 +0000 |
parents | 8feb06a1c3c1 |
children | 9c091f83c185 |
comparison
equal
deleted
inserted
replaced
19872:dd5e6f06be8f | 19873:91c35a2c2705 |
---|---|
520 | 520 |
521 logs = logs->next; | 521 logs = logs->next; |
522 } | 522 } |
523 } | 523 } |
524 | 524 |
525 static PidginLogViewer *display_log_viewer(struct log_viewer_hash_t *ht, GList *logs, | 525 static PidginLogViewer *display_log_viewer(GtkWindow *parent, struct log_viewer_hash_t *ht, GList *logs, |
526 const char *title, GtkWidget *icon, int log_size) | 526 const char *title, GtkWidget *icon, int log_size) |
527 { | 527 { |
528 PidginLogViewer *lv; | 528 PidginLogViewer *lv; |
529 GtkWidget *title_box; | 529 GtkWidget *title_box; |
530 char *text; | 530 char *text; |
566 | 566 |
567 if (ht != NULL) | 567 if (ht != NULL) |
568 g_hash_table_insert(log_viewers, ht, lv); | 568 g_hash_table_insert(log_viewers, ht, lv); |
569 | 569 |
570 /* Window ***********/ | 570 /* Window ***********/ |
571 lv->window = gtk_dialog_new_with_buttons(title, NULL, 0, | 571 lv->window = gtk_dialog_new_with_buttons(title, parent, 0, |
572 GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, NULL); | 572 GTK_STOCK_CLOSE, GTK_RESPONSE_CLOSE, NULL); |
573 #ifdef _WIN32 | 573 #ifdef _WIN32 |
574 /* Steal the "HELP" response and use it to trigger browsing to the logs folder */ | 574 /* Steal the "HELP" response and use it to trigger browsing to the logs folder */ |
575 gtk_dialog_add_button(GTK_DIALOG(lv->window), _("_Browse logs folder"), GTK_RESPONSE_HELP); | 575 gtk_dialog_add_button(GTK_DIALOG(lv->window), _("_Browse logs folder"), GTK_RESPONSE_HELP); |
576 #endif | 576 #endif |
720 title, gtk_image_new_from_pixbuf(pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_MEDIUM)), | 720 title, gtk_image_new_from_pixbuf(pidgin_create_prpl_icon(account, PIDGIN_PRPL_ICON_MEDIUM)), |
721 purple_log_get_total_size(type, screenname, account)); | 721 purple_log_get_total_size(type, screenname, account)); |
722 g_free(title); | 722 g_free(title); |
723 } | 723 } |
724 | 724 |
725 void pidgin_log_show_contact(PurpleContact *contact) { | 725 void pidgin_log_show_contact(GtkWindow *parent, PurpleContact *contact) { |
726 struct log_viewer_hash_t *ht = g_new0(struct log_viewer_hash_t, 1); | 726 struct log_viewer_hash_t *ht = g_new0(struct log_viewer_hash_t, 1); |
727 PurpleBlistNode *child; | 727 PurpleBlistNode *child; |
728 PidginLogViewer *lv = NULL; | 728 PidginLogViewer *lv = NULL; |
729 GList *logs = NULL; | 729 GList *logs = NULL; |
730 GdkPixbuf *pixbuf; | 730 GdkPixbuf *pixbuf; |