comparison src/dialogs.c @ 3472:d33ec392a5e1

[gaim-migrate @ 3523] Rob McQueen went and removed all the GTK version preprocessor statements. Thanks! committer: Tailor Script <tailor@pidgin.im>
author Sean Egan <seanegan@gmail.com>
date Thu, 29 Aug 2002 21:40:08 +0000
parents 7a3f16a375a5
children 0073a014e55b
comparison
equal deleted inserted replaced
3471:7fb93ecd631c 3472:d33ec392a5e1
41 41
42 #include <gtk/gtk.h> 42 #include <gtk/gtk.h>
43 #include "gaim.h" 43 #include "gaim.h"
44 #include "gtkimhtml.h" 44 #include "gtkimhtml.h"
45 #include "prpl.h" 45 #include "prpl.h"
46 #ifdef USE_APPLET
47 #include "applet.h"
48 #endif
49 46
50 #include "pixmaps/gnome_preferences.xpm" 47 #include "pixmaps/gnome_preferences.xpm"
51 #include "pixmaps/cancel.xpm" 48 #include "pixmaps/cancel.xpm"
52 #include "pixmaps/save.xpm" 49 #include "pixmaps/save.xpm"
53 #include "pixmaps/ok.xpm" 50 #include "pixmaps/ok.xpm"
3408 gchar *away_message; 3405 gchar *away_message;
3409 3406
3410 if (!ca->mess) 3407 if (!ca->mess)
3411 am = g_new0(struct away_message, 1); 3408 am = g_new0(struct away_message, 1);
3412 else { 3409 else {
3413 #ifdef USE_APPLET
3414 char *awayname = g_strdup_printf("away/%s", ca->mess->name);
3415 applet_widget_unregister_callback(APPLET_WIDGET(applet), awayname);
3416 g_free(awayname);
3417 #endif
3418 am = ca->mess; 3410 am = ca->mess;
3419 } 3411 }
3420 3412
3421 g_snprintf(am->name, sizeof(am->name), "%s", gtk_entry_get_text(GTK_ENTRY(ca->entry))); 3413 g_snprintf(am->name, sizeof(am->name), "%s", gtk_entry_get_text(GTK_ENTRY(ca->entry)));
3422 text_len = gtk_text_get_length(GTK_TEXT(ca->text)); 3414 text_len = gtk_text_get_length(GTK_TEXT(ca->text));
4602 gdk_window_set_icon(w, NULL, icon_pm, icon_bm); 4594 gdk_window_set_icon(w, NULL, icon_pm, icon_bm);
4603 if (mainwindow) 4595 if (mainwindow)
4604 gdk_window_set_group(w, mainwindow->window); 4596 gdk_window_set_group(w, mainwindow->window);
4605 #endif 4597 #endif
4606 } 4598 }
4607 4599
4608 GtkWidget *pixbuf_button(char *text, char *iconfile) 4600 GtkWidget *pixbuf_button(char *text, char *iconfile)
4609 { 4601 {
4610 GtkWidget *button, *image, *label, *bbox; 4602 GtkWidget *button, *image, *label, *bbox;
4611 button = gtk_button_new(); 4603 button = gtk_button_new();
4612 bbox = gtk_hbox_new(FALSE, 5); 4604 bbox = gtk_hbox_new(FALSE, 5);
4626 gtk_box_pack_start(GTK_BOX(bbox), label, FALSE, FALSE, 0); 4618 gtk_box_pack_start(GTK_BOX(bbox), label, FALSE, FALSE, 0);
4627 } 4619 }
4628 gtk_widget_show_all(bbox); 4620 gtk_widget_show_all(bbox);
4629 return button; 4621 return button;
4630 } 4622 }
4631
4632 4623
4633 GtkWidget *picture_button(GtkWidget *window, char *text, char **xpm) 4624 GtkWidget *picture_button(GtkWidget *window, char *text, char **xpm)
4634 { 4625 {
4635 GtkWidget *button; 4626 GtkWidget *button;
4636 GtkWidget *button_box, *button_box_2, *button_box_3; 4627 GtkWidget *button_box, *button_box_2, *button_box_3;