1 /* 2 * e-mail-signature-combo-box.h 3 * 4 * This program is free software; you can redistribute it and/or modify it 5 * under the terms of the GNU Lesser General Public License as published by 6 * the Free Software Foundation. 7 * 8 * This program is distributed in the hope that it will be useful, but 9 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 10 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 11 * for more details. 12 * 13 * You should have received a copy of the GNU Lesser General Public License 14 * along with this program; if not, see <http://www.gnu.org/licenses/>. 15 * 16 */ 17 18 #if !defined (__E_UTIL_H_INSIDE__) && !defined (LIBEUTIL_COMPILATION) 19 #error "Only <e-util/e-util.h> should be included directly." 20 #endif 21 22 #ifndef E_MAIL_SIGNATURE_COMBO_BOX_H 23 #define E_MAIL_SIGNATURE_COMBO_BOX_H 24 25 #include <gtk/gtk.h> 26 #include <libedataserver/libedataserver.h> 27 28 /* Standard GObject macros */ 29 #define E_TYPE_MAIL_SIGNATURE_COMBO_BOX \ 30 (e_mail_signature_combo_box_get_type ()) 31 #define E_MAIL_SIGNATURE_COMBO_BOX(obj) \ 32 (G_TYPE_CHECK_INSTANCE_CAST \ 33 ((obj), E_TYPE_MAIL_SIGNATURE_COMBO_BOX, EMailSignatureComboBox)) 34 #define E_MAIL_SIGNATURE_COMBO_BOX_CLASS(cls) \ 35 (G_TYPE_CHECK_CLASS_CAST \ 36 ((cls), E_TYPE_MAIL_SIGNATURE_COMBO_BOX, EMailSignatureComboBoxClass)) 37 #define E_IS_MAIL_SIGNATURE_COMBO_BOX(obj) \ 38 (G_TYPE_CHECK_INSTANCE_TYPE \ 39 ((obj), E_TYPE_MAIL_SIGNATURE_COMBO_BOX)) 40 #define E_IS_MAIL_SIGNATURE_COMBO_BOX_CLASS(cls) \ 41 (G_TYPE_CHECK_CLASS_TYPE \ 42 ((cls), E_TYPE_MAIL_SIGNATURE_COMBO_BOX)) 43 #define E_MAIL_SIGNATURE_COMBO_BOX_GET_CLASS(obj) \ 44 (G_TYPE_INSTANCE_GET_CLASS \ 45 ((obj), E_TYPE_MAIL_SIGNATURE_COMBO_BOX, EMailSignatureComboBoxClass)) 46 47 #define E_MAIL_SIGNATURE_AUTOGENERATED_UID "autogenerated" 48 49 G_BEGIN_DECLS 50 51 typedef struct _EMailSignatureComboBox EMailSignatureComboBox; 52 typedef struct _EMailSignatureComboBoxClass EMailSignatureComboBoxClass; 53 typedef struct _EMailSignatureComboBoxPrivate EMailSignatureComboBoxPrivate; 54 55 struct _EMailSignatureComboBox { 56 GtkComboBox parent; 57 EMailSignatureComboBoxPrivate *priv; 58 }; 59 60 struct _EMailSignatureComboBoxClass { 61 GtkComboBoxClass parent_class; 62 }; 63 64 GType e_mail_signature_combo_box_get_type 65 (void) G_GNUC_CONST; 66 GtkWidget * e_mail_signature_combo_box_new 67 (ESourceRegistry *registry); 68 void e_mail_signature_combo_box_refresh 69 (EMailSignatureComboBox *combo_box); 70 ESourceRegistry * 71 e_mail_signature_combo_box_get_registry 72 (EMailSignatureComboBox *combo_box); 73 const gchar * e_mail_signature_combo_box_get_identity_uid 74 (EMailSignatureComboBox *combo_box); 75 void e_mail_signature_combo_box_set_identity_uid 76 (EMailSignatureComboBox *combo_box, 77 const gchar *identity_uid); 78 const gchar * e_mail_signature_combo_box_get_identity_name 79 (EMailSignatureComboBox *combo_box); 80 void e_mail_signature_combo_box_set_identity_name 81 (EMailSignatureComboBox *combo_box, 82 const gchar *identity_name); 83 const gchar * e_mail_signature_combo_box_get_identity_address 84 (EMailSignatureComboBox *combo_box); 85 void e_mail_signature_combo_box_set_identity_address 86 (EMailSignatureComboBox *combo_box, 87 const gchar *identity_address); 88 void e_mail_signature_combo_box_set_identity 89 (EMailSignatureComboBox *combo_box, 90 const gchar *identity_uid, 91 const gchar *identity_name, 92 const gchar *identity_address); 93 void e_mail_signature_combo_box_load_selected 94 (EMailSignatureComboBox *combo_box, 95 gint io_priority, 96 GCancellable *cancellable, 97 GAsyncReadyCallback callback, 98 gpointer user_data); 99 gboolean e_mail_signature_combo_box_load_selected_finish 100 (EMailSignatureComboBox *combo_box, 101 GAsyncResult *result, 102 gchar **contents, 103 gsize *length, 104 gboolean *is_html, 105 GError **error); 106 107 G_END_DECLS 108 109 #endif /* E_MAIL_SIGNATURE_COMBO_BOX_H */ 110