Add Sign/Encrypt toggle buttons to Compose toolbar.
[claws.git] / src / toolbar.h
index ea37aeaebb6d9c9025364794e9132d2d1669d9fe..ef824565623800f21043fd368a5a059692f301c4 100644 (file)
@@ -1,6 +1,6 @@
 /*
- * Sylpheed -- a GTK+ based, lightweight, and fast e-mail client
- * Copyright (C) 2001-2007 Hiroyuki Yamamoto and the Claws Mail team
+ * Claws Mail -- a GTK+ based, lightweight, and fast e-mail client
+ * Copyright (C) 2001-2017 Hiroyuki Yamamoto and the Claws Mail team
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -14,7 +14,6 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program. If not, see <http://www.gnu.org/licenses/>.
- * 
  */
 
 #ifndef __CUSTOM_TOOLBAR_H__
@@ -26,7 +25,7 @@
 
 typedef struct _Toolbar Toolbar;
 typedef struct _ToolbarItem ToolbarItem;
-typedef struct _ToolbarSylpheedActions ToolbarSylpheedActions;
+typedef struct _ToolbarClawsActions ToolbarClawsActions;
 
 typedef enum {
        TOOLBAR_MAIN = 0,       
@@ -34,6 +33,8 @@ typedef enum {
        TOOLBAR_MSGVIEW
 } ToolbarType;
 
+#define NUM_TOOLBARS   3
+
 typedef enum 
 {
        COMPOSEBUTTON_MAIL,
@@ -67,6 +68,7 @@ struct _Toolbar {
        
        GtkWidget *trash_btn;
        GtkWidget *delete_btn;
+       GtkWidget *delete_dup_btn;
        GtkWidget *prev_btn;
        GtkWidget *next_btn;
        GtkWidget *exec_btn;
@@ -77,6 +79,8 @@ struct _Toolbar {
        GtkWidget *learn_ham_icon;
        
        GtkWidget *cancel_inc_btn;
+       GtkWidget *cancel_send_btn;
+       GtkWidget *cancel_all_btn;
        
        ComposeButtonType compose_btn_type;
        LearnButtonType learn_btn_type;
@@ -87,21 +91,26 @@ struct _Toolbar {
        GtkWidget *insert_btn;
        GtkWidget *attach_btn;
        GtkWidget *sig_btn;
+       GtkWidget *repsig_btn;
        GtkWidget *exteditor_btn;
        GtkWidget *linewrap_current_btn;
        GtkWidget *linewrap_all_btn;
        GtkWidget *addrbook_btn;
-#ifdef USE_ASPELL
-       GtkWidget *spellcheck_btn;
-#endif
 
        GtkWidget *open_mail_btn;
        GtkWidget *close_window_btn;
 
+       GtkWidget *preferences_btn;
+
        GSList    *action_list;
        GSList    *item_list;
 
-       GtkTooltips *tooltips;
+#ifdef USE_ENCHANT
+       GtkWidget *spellcheck_btn;
+#endif
+
+       GtkWidget *privacy_sign_btn;
+       GtkWidget *privacy_encrypt_btn;
 };
 
 struct _ToolbarItem {
@@ -129,9 +138,9 @@ struct _ToolbarItem {
 
 #define TOOLBAR_DESTROY_ACTIONS(action_list) \
 { \
-       ToolbarSylpheedActions *action; \
+       ToolbarClawsActions *action; \
        while (action_list != NULL) { \
-               action = (ToolbarSylpheedActions*)action_list->data;\
+               action = (ToolbarClawsActions*)action_list->data;\
                action_list = \
                        g_slist_remove(action_list, action);\
                if (action->name) \
@@ -144,8 +153,8 @@ struct _ToolbarItem {
 
 
 
-/* enum holds available actions for both 
-   Compose Toolbar and Main Toolbar 
+/* enum holds available actions for both
+   Compose Toolbar and Main Toolbar
 */
 enum {
        /* main toolbar */
@@ -162,41 +171,60 @@ enum {
        A_FORWARD,
        A_TRASH,
        A_DELETE_REAL,
+       A_DELETE_DUP,
        A_EXECUTE,
        A_GOTO_PREV,
        A_GOTO_NEXT,
+
        A_IGNORE_THREAD,
        A_WATCH_THREAD,
+       A_MARK,
+       A_UNMARK,
+       A_LOCK,
+       A_UNLOCK,
+       A_ALL_READ,
+       A_ALL_UNREAD,
+       A_READ,
+       A_UNREAD,
+
        A_PRINT,
        A_LEARN_SPAM,
        A_GO_FOLDERS,
+       A_PREFERENCES,
 
        /* compose toolbar */
        A_SEND,
-       A_SENDL,
+       A_SEND_LATER,
        A_DRAFT,
        A_INSERT,
        A_ATTACH,
        A_SIG,
+       A_REP_SIG,
        A_EXTEDITOR,
        A_LINEWRAP_CURRENT,
        A_LINEWRAP_ALL,
        A_ADDRBOOK,
-#ifdef USE_ASPELL
+#ifdef USE_ENCHANT
        A_CHECK_SPELLING,
 #endif
+       A_PRIVACY_SIGN,
+       A_PRIVACY_ENCRYPT,
 
        /* common items */
-       A_SYL_ACTIONS,
+       A_CLAWS_ACTIONS,
        A_CANCEL_INC,
+       A_CANCEL_SEND,
+       A_CANCEL_ALL,
        A_CLOSE,
 
        A_SEPARATOR,
 
+       A_CLAWS_PLUGINS,
+
        N_ACTION_VAL
 };
 
-struct _ToolbarSylpheedActions {
+struct _ToolbarClawsActions {
        GtkWidget *widget;
        gchar     *name;
 };
@@ -257,4 +285,5 @@ void toolbar_set_learn_button               (Toolbar        *toolbar,
                                         LearnButtonType  learn_btn_type);
 const gchar *toolbar_get_short_text    (int action);
 int         toolbar_get_icon           (int action);
+gboolean toolbar_check_action_btns     (ToolbarType    type);
 #endif /* __CUSTOM_TOOLBAR_H__ */