pidgin/gtkrequest.c

changeset 33702
b5bc1f40fdee
parent 33698
e730d1a5f058
parent 33683
bf243e3394a7
child 33892
ef97228bc5f0
equal deleted inserted replaced
33701:408990fbee7b 33702:b5bc1f40fdee
46 #endif 46 #endif
47 #endif 47 #endif
48 48
49 #include "gtk3compat.h" 49 #include "gtk3compat.h"
50 50
51 #if !GTK_CHECK_VERSION(2,12,0)
52 #undef gtk_widget_set_tooltip_text
53 #define gtk_widget_set_tooltip_text(x,y)
54 #endif
55
56 static GtkWidget * create_account_field(PurpleRequestField *field); 51 static GtkWidget * create_account_field(PurpleRequestField *field);
57 52
58 typedef struct 53 typedef struct
59 { 54 {
60 PurpleRequestType type; 55 PurpleRequestType type;
464 gtk_entry_set_text(GTK_ENTRY(entry), default_value); 459 gtk_entry_set_text(GTK_ENTRY(entry), default_value);
465 460
466 if (masked) 461 if (masked)
467 { 462 {
468 gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE); 463 gtk_entry_set_visibility(GTK_ENTRY(entry), FALSE);
469 #if !GTK_CHECK_VERSION(2,16,0)
470 if (gtk_entry_get_invisible_char(GTK_ENTRY(entry)) == '*')
471 gtk_entry_set_invisible_char(GTK_ENTRY(entry), PIDGIN_INVISIBLE_CHAR);
472 #endif /* Less than GTK+ 2.16 */
473 } 464 }
474 } 465 }
475 gtk_widget_show_all(vbox); 466 gtk_widget_show_all(vbox);
476 } 467 }
477 468
910 gtk_widget_set_tooltip_text(widget, purple_request_field_get_tooltip(field)); 901 gtk_widget_set_tooltip_text(widget, purple_request_field_get_tooltip(field));
911 902
912 if (purple_request_field_string_is_masked(field)) 903 if (purple_request_field_string_is_masked(field))
913 { 904 {
914 gtk_entry_set_visibility(GTK_ENTRY(widget), FALSE); 905 gtk_entry_set_visibility(GTK_ENTRY(widget), FALSE);
915 #if !GTK_CHECK_VERSION(2,16,0)
916 if (gtk_entry_get_invisible_char(GTK_ENTRY(widget)) == '*')
917 gtk_entry_set_invisible_char(GTK_ENTRY(widget), PIDGIN_INVISIBLE_CHAR);
918 #endif /* Less than GTK+ 2.16 */
919 } 906 }
920 907
921 gtk_editable_set_editable(GTK_EDITABLE(widget), 908 gtk_editable_set_editable(GTK_EDITABLE(widget),
922 purple_request_field_string_is_editable(field)); 909 purple_request_field_string_is_editable(field));
923 910

mercurial