From 9b0e9dc0aeffd627ce2bdea049cc7c47bb7418f0 Mon Sep 17 00:00:00 2001 From: Srinivasa Ragavan Date: Fri, 22 May 2009 17:00:53 +0530 Subject: Johnny's composer changes for Anjal. --- composer/Makefile.am | 28 +++++++----- composer/e-composer-from-header.h | 2 +- composer/e-composer-header-table.c | 36 ++++++++++++--- composer/e-composer-header.c | 89 ++++++++++++++++++++++++++++++++++++++ composer/e-composer-header.h | 3 ++ composer/e-composer-name-header.c | 28 ++++++++++++ composer/e-composer-name-header.h | 9 ++++ composer/e-composer-private.c | 79 ++++++++++++++++++++++++++++++++- composer/e-composer-text-header.c | 21 +++++++-- composer/e-composer-text-header.h | 11 +++-- composer/e-msg-composer.c | 38 +++++++++++++++- composer/e-msg-composer.h | 5 +++ 12 files changed, 320 insertions(+), 29 deletions(-) (limited to 'composer') diff --git a/composer/Makefile.am b/composer/Makefile.am index 578805cc06..97debe59d0 100644 --- a/composer/Makefile.am +++ b/composer/Makefile.am @@ -5,6 +5,19 @@ errordir = $(privdatadir)/errors @EVO_PLUGIN_RULE@ noinst_LTLIBRARIES = libcomposer.la +libcomposerincludedir = $(privincludedir)/composer +libcomposerinclude_HEADERS = \ + e-composer-header.h \ + e-composer-header-table.h \ + e-composer-from-header.h \ + e-composer-name-header.h \ + e-composer-post-header.h \ + e-composer-private.h \ + e-composer-text-header.h \ + e-composer-common.h \ + e-composer-actions.h \ + e-composer-autosave.h \ + e-msg-composer.h INCLUDES = \ -I$(top_srcdir) \ @@ -27,27 +40,18 @@ INCLUDES = \ libcomposer_la_SOURCES = \ $(IDL_GENERATED) \ $(HTML_EDITOR_GENERATED) \ + $(libcomposerinclude_HEADERS) \ e-composer-actions.c \ - e-composer-actions.h \ e-composer-autosave.c \ - e-composer-autosave.h \ - e-composer-common.h \ e-composer-header.c \ - e-composer-header.h \ e-composer-header-table.c \ - e-composer-header-table.h \ e-composer-from-header.c \ - e-composer-from-header.h \ e-composer-name-header.c \ - e-composer-name-header.h \ e-composer-post-header.c \ - e-composer-post-header.h \ e-composer-private.c \ - e-composer-private.h \ e-composer-text-header.c \ - e-composer-text-header.h \ - e-msg-composer.c \ - e-msg-composer.h + e-msg-composer.c + uidir = $(evolutionuidir) ui_DATA = evolution-composer.ui diff --git a/composer/e-composer-from-header.h b/composer/e-composer-from-header.h index 74fda9ae03..f8c6dc6f18 100644 --- a/composer/e-composer-from-header.h +++ b/composer/e-composer-from-header.h @@ -26,7 +26,7 @@ #include #include -#include "e-account-combo-box.h" +#include #include "e-composer-header.h" /* Standard GObject macros */ diff --git a/composer/e-composer-header-table.c b/composer/e-composer-header-table.c index 267bfbf1e7..df96d763ba 100644 --- a/composer/e-composer-header-table.c +++ b/composer/e-composer-header-table.c @@ -31,6 +31,8 @@ #include "e-composer-post-header.h" #include "e-composer-text-header.h" +extern gboolean composer_lite; + #define E_COMPOSER_HEADER_TABLE_GET_PRIVATE(obj) \ (G_TYPE_INSTANCE_GET_PRIVATE \ ((obj), E_TYPE_COMPOSER_HEADER_TABLE, EComposerHeaderTablePrivate)) @@ -68,6 +70,7 @@ struct _EComposerHeaderTablePrivate { GtkWidget *signature_label; GtkWidget *signature_combo_box; ENameSelector *name_selector; + GtkHBox *actions_container; }; static gpointer parent_class; @@ -502,8 +505,16 @@ composer_header_table_constructor (GType type, gtk_table_attach ( GTK_TABLE (object), priv->headers[ii]->input_widget, 1, 4, ii, ii + 1, GTK_FILL | GTK_EXPAND, 0, 0, 3); + if (composer_lite && priv->headers[ii]->action_widget) { + /* Pack the widgets to the end. Helps formatting when hiding the From field */ + gtk_box_pack_end ((GtkBox *)priv->actions_container, priv->headers[ii]->action_widget, + FALSE, FALSE, 6); + } } + if (composer_lite) + gtk_widget_show_all ((GtkWidget *)priv->actions_container); + ii = E_COMPOSER_HEADER_FROM; /* Leave room in the "From" row for signature stuff. */ @@ -528,6 +539,19 @@ composer_header_table_constructor (GType type, GTK_TABLE (object), priv->signature_combo_box, 3, 4, ii, ii + 1, 0, 0, 0, 3); + if (composer_lite) { + ii = E_COMPOSER_HEADER_TO; + + /* Leave room for the action buttons. */ + gtk_container_child_set ( + GTK_CONTAINER (object), + priv->headers[ii]->input_widget, + "right-attach", 2, NULL); + + gtk_table_attach (GTK_TABLE (object), (GtkWidget *)priv->actions_container, 2, 4, E_COMPOSER_HEADER_TO, + E_COMPOSER_HEADER_TO + 1, GTK_FILL, 0, 0, 3); + } + return object; } @@ -898,6 +922,8 @@ composer_header_table_init (EComposerHeaderTable *table) name_selector = e_name_selector_new (); table->priv->name_selector = name_selector; + table->priv->actions_container = (GtkHBox *)gtk_hbox_new (FALSE, 6); + header = e_composer_from_header_new (_("Fr_om:")); composer_header_table_bind_header ("account", "changed", header); composer_header_table_bind_header ("account-list", "refreshed", header); @@ -907,21 +933,21 @@ composer_header_table_init (EComposerHeaderTable *table) composer_header_table_from_changed_cb), table); table->priv->headers[E_COMPOSER_HEADER_FROM] = header; - header = e_composer_text_header_new_label (_("_Reply-To:")); + header = e_composer_text_header_new_label (_("_Reply-To:"), ""); composer_header_table_bind_header ("reply-to", "changed", header); table->priv->headers[E_COMPOSER_HEADER_REPLY_TO] = header; - header = e_composer_name_header_new (_("_To:"), name_selector); + header = e_composer_name_header_new_with_label (_("_To:"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_TO); composer_header_table_bind_header ("destinations-to", "changed", header); table->priv->headers[E_COMPOSER_HEADER_TO] = header; - header = e_composer_name_header_new (_("_Cc:"), name_selector); + header = e_composer_name_header_new_with_action (_("_Cc:"), _("Show CC"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_CC); composer_header_table_bind_header ("destinations-cc", "changed", header); table->priv->headers[E_COMPOSER_HEADER_CC] = header; - header = e_composer_name_header_new (_("_Bcc:"), name_selector); + header = e_composer_name_header_new_with_action (_("_Bcc:"), _("Show BCC"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_BCC); composer_header_table_bind_header ("destinations-bcc", "changed", header); table->priv->headers[E_COMPOSER_HEADER_BCC] = header; @@ -930,7 +956,7 @@ composer_header_table_init (EComposerHeaderTable *table) composer_header_table_bind_header ("post-to", "changed", header); table->priv->headers[E_COMPOSER_HEADER_POST_TO] = header; - header = e_composer_text_header_new_label (_("S_ubject:")); + header = e_composer_text_header_new_label (_("S_ubject:"), NULL); composer_header_table_bind_header ("subject", "changed", header); table->priv->headers[E_COMPOSER_HEADER_SUBJECT] = header; diff --git a/composer/e-composer-header.c b/composer/e-composer-header.c index 272556969d..20967c6853 100644 --- a/composer/e-composer-header.c +++ b/composer/e-composer-header.c @@ -1,3 +1,5 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */ + /* * * This program is free software; you can redistribute it and/or @@ -28,6 +30,8 @@ enum { PROP_0, PROP_BUTTON, PROP_LABEL, + PROP_ADDACTION, + PROP_ADDACTION_TEXT, PROP_SENSITIVE, PROP_VISIBLE }; @@ -41,6 +45,8 @@ enum { struct _EComposerHeaderPrivate { gchar *label; gboolean button; + gchar *addaction_text; + gboolean addaction; /*For Add button.*/ guint sensitive : 1; guint visible : 1; @@ -57,6 +63,20 @@ composer_header_button_clicked_cb (GtkButton *button, g_signal_emit (header, signal_ids[CLICKED], 0); } +static void +composer_header_addaction_clicked_cb (GtkButton *button, + EComposerHeader *header) +{ + gtk_widget_hide ((GtkWidget *)button); + e_composer_header_set_visible (header, TRUE); +} + +static void +link_clicked_cb (GtkLinkButton *button, const gchar *link_, gpointer user_data) +{ + return; +} + static GObject * composer_header_constructor (GType type, guint n_construct_properties, @@ -84,6 +104,27 @@ composer_header_constructor (GType type, gtk_label_set_mnemonic_widget ( GTK_LABEL (widget), header->input_widget); } + + if (header->priv->addaction) { + GtkWidget *box, *tmp; + char *str; + + header->action_widget = gtk_button_new (); + box = gtk_hbox_new (FALSE, 0); + tmp = gtk_image_new_from_stock("gtk-add", GTK_ICON_SIZE_BUTTON); + gtk_box_pack_start((GtkBox *)box, tmp, FALSE, FALSE, 3); + tmp = gtk_label_new (NULL); + str = g_strdup_printf ("%s", header->priv->addaction_text); + gtk_label_set_markup((GtkLabel *)tmp, str); + gtk_box_pack_start((GtkBox *)box, tmp, FALSE, FALSE, 3); + gtk_container_add((GtkContainer *)header->action_widget, box); + gtk_widget_show_all(header->action_widget); + g_signal_connect ( + header->action_widget, "clicked", + G_CALLBACK (composer_header_addaction_clicked_cb), + header); + } + header->title_widget = g_object_ref_sink (widget); g_free (header->priv->label); @@ -107,6 +148,14 @@ composer_header_set_property (GObject *object, priv->button = g_value_get_boolean (value); return; + case PROP_ADDACTION: /* construct only */ + priv->addaction = g_value_get_boolean (value); + return; + + case PROP_ADDACTION_TEXT:/* construct only */ + priv->addaction_text = g_value_dup_string (value); + return; + case PROP_LABEL: /* construct only */ priv->label = g_value_dup_string (value); return; @@ -127,6 +176,15 @@ composer_header_set_property (GObject *object, G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec); } +void +e_composer_header_set_property (GObject *object, + guint property_id, + const GValue *value, + GParamSpec *pspec) +{ + composer_header_set_property (object, property_id, value, pspec); +} + static void composer_header_get_property (GObject *object, guint property_id, @@ -142,6 +200,15 @@ composer_header_get_property (GObject *object, g_value_set_boolean (value, priv->button); return; + case PROP_ADDACTION: /* construct only */ + g_value_set_boolean (value, priv->button); + return; + + case PROP_ADDACTION_TEXT: /* construct only */ + g_value_take_string ( + value, priv->addaction_text); + return; + case PROP_LABEL: /* construct only */ g_value_take_string ( value, e_composer_header_get_label ( @@ -208,6 +275,28 @@ composer_header_class_init (EComposerHeaderClass *class) G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY)); + g_object_class_install_property ( + object_class, + PROP_ADDACTION, + g_param_spec_boolean ( + "addaction", + NULL, + NULL, + FALSE, + G_PARAM_READWRITE | + G_PARAM_CONSTRUCT_ONLY)); + + g_object_class_install_property ( + object_class, + PROP_ADDACTION_TEXT, + g_param_spec_string ( + "addaction_text", + NULL, + NULL, + NULL, + G_PARAM_READWRITE | + G_PARAM_CONSTRUCT_ONLY)); + g_object_class_install_property ( object_class, PROP_LABEL, diff --git a/composer/e-composer-header.h b/composer/e-composer-header.h index db9582dc3f..126af5fb77 100644 --- a/composer/e-composer-header.h +++ b/composer/e-composer-header.h @@ -49,6 +49,7 @@ struct _EComposerHeader { GObject parent; GtkWidget *title_widget; GtkWidget *input_widget; + GtkWidget *action_widget; EComposerHeaderPrivate *priv; }; @@ -64,6 +65,8 @@ void e_composer_header_set_sensitive (EComposerHeader *header, gboolean e_composer_header_get_visible (EComposerHeader *header); void e_composer_header_set_visible (EComposerHeader *header, gboolean visible); +void e_composer_header_set_property (GObject *object, guint property_id, + const GValue *value, GParamSpec *pspec); void e_composer_header_set_title_tooltip (EComposerHeader *header, const gchar *tooltip); diff --git a/composer/e-composer-name-header.c b/composer/e-composer-name-header.c index 5aab95d776..472208edd3 100644 --- a/composer/e-composer-name-header.c +++ b/composer/e-composer-name-header.c @@ -117,10 +117,12 @@ composer_name_header_constructor (GType type, entry = E_NAME_SELECTOR_ENTRY ( e_name_selector_peek_section_list ( priv->name_selector, label)); + e_name_selector_entry_set_contact_editor_func ( entry, e_contact_editor_new); e_name_selector_entry_set_contact_list_editor_func ( entry, e_contact_list_editor_new); + g_signal_connect ( entry, "changed", G_CALLBACK (composer_name_header_entry_changed_cb), object); @@ -261,6 +263,32 @@ e_composer_name_header_new (const gchar *label, "button", TRUE, "name-selector", name_selector, NULL); } +EComposerHeader * +e_composer_name_header_new_with_label (const gchar *label, + ENameSelector *name_selector) +{ + return g_object_new ( + E_TYPE_COMPOSER_NAME_HEADER, "label", label, + "button", FALSE, "name-selector", name_selector, + "addaction", FALSE, "visible", TRUE, + NULL); +} + +EComposerHeader * +e_composer_name_header_new_with_action (const gchar *label, + const gchar *action_label, + ENameSelector *name_selector) +{ + g_return_val_if_fail (E_IS_NAME_SELECTOR (name_selector), NULL); + + return g_object_new ( + E_TYPE_COMPOSER_NAME_HEADER, "label", label, + "button", FALSE, "name-selector", name_selector, + "addaction_text", action_label, + "addaction", action_label != NULL, + NULL); +} + ENameSelector * e_composer_name_header_get_name_selector (EComposerNameHeader *header) { diff --git a/composer/e-composer-name-header.h b/composer/e-composer-name-header.h index f95c33fce3..af38666d59 100644 --- a/composer/e-composer-name-header.h +++ b/composer/e-composer-name-header.h @@ -62,6 +62,15 @@ struct _EComposerNameHeaderClass { GType e_composer_name_header_get_type (void); EComposerHeader * e_composer_name_header_new (const gchar *label, ENameSelector *name_selector); +/*No button. Just a label.*/ +EComposerHeader * e_composer_name_header_new_with_label (const gchar *label, + ENameSelector *name_selector); + +/*No button. Label with a Link button for show/hide.*/ +EComposerHeader * e_composer_name_header_new_with_action (const gchar *label, + const gchar *action, + ENameSelector *name_selector); + ENameSelector * e_composer_name_header_get_name_selector (EComposerNameHeader *header); EDestination ** e_composer_name_header_get_destinations diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c index fe5b66ceee..ef151d024e 100644 --- a/composer/e-composer-private.c +++ b/composer/e-composer-private.c @@ -17,6 +17,7 @@ #include "e-composer-private.h" #include "e-util/e-util-private.h" +#include "e-util/e-icon-factory.h" static void composer_setup_charset_menu (EMsgComposer *composer) @@ -88,6 +89,7 @@ e_composer_private_init (EMsgComposer *composer) GtkWidget *widget; GtkWidget *container; GtkWidget *send_widget; + GtkWidget *exp_box; const gchar *path; gchar *filename; gint ii; @@ -96,6 +98,15 @@ e_composer_private_init (EMsgComposer *composer) editor = GTKHTML_EDITOR (composer); ui_manager = gtkhtml_editor_get_ui_manager (editor); + if (composer->lite) { + widget = gtkhtml_editor_get_managed_widget (editor, "/main-menu"); + gtk_widget_hide (widget); + widget = gtkhtml_editor_get_managed_widget (editor, "/main-toolbar"); + gtk_toolbar_set_style ((GtkToolbar *)widget, GTK_TOOLBAR_BOTH_HORIZ); + gtk_widget_hide (widget); + + } + priv->charset_actions = gtk_action_group_new ("charset"); priv->composer_actions = gtk_action_group_new ("composer"); @@ -128,6 +139,64 @@ e_composer_private_init (EMsgComposer *composer) send_widget = gtk_ui_manager_get_widget (ui_manager, path); gtk_tool_item_set_is_important (GTK_TOOL_ITEM (send_widget), TRUE); + exp_box = gtk_hbox_new (FALSE, 0); + gtk_widget_show(exp_box); + if (composer->lite) { + GtkWidget *tmp, *tmp1, *tmp_box; + + tmp_box = gtk_hbox_new (FALSE, 0); + + tmp = gtk_hbox_new (FALSE, 0); + tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon("mail-send", E_ICON_SIZE_BUTTON)); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); + tmp1 = gtk_label_new_with_mnemonic (_("S_end")); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 6); + gtk_widget_show_all(tmp); + gtk_widget_reparent (send_widget, tmp_box); + gtk_box_set_child_packing ((GtkBox *)tmp_box, send_widget, FALSE, FALSE, 6, GTK_PACK_END); + gtk_tool_item_set_is_important (GTK_TOOL_ITEM (send_widget), TRUE); + send_widget = gtk_bin_get_child ((GtkBin *)send_widget); + gtk_container_remove((GtkContainer *)send_widget, gtk_bin_get_child ((GtkBin *)send_widget)); + gtk_container_add((GtkContainer *)send_widget, tmp); + gtk_button_set_relief ((GtkButton *)send_widget, GTK_RELIEF_NORMAL); + + path = "/main-toolbar/pre-main-toolbar/save-draft"; + send_widget = gtk_ui_manager_get_widget (ui_manager, path); + tmp = gtk_hbox_new (FALSE, 0); + tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon(GTK_STOCK_SAVE, E_ICON_SIZE_BUTTON)); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); + tmp1 = gtk_label_new_with_mnemonic (_("Save draft")); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 3); + gtk_widget_show_all(tmp); + gtk_widget_reparent (send_widget, tmp_box); + gtk_box_set_child_packing ((GtkBox *)tmp_box, send_widget, FALSE, FALSE, 6, GTK_PACK_END); + gtk_tool_item_set_is_important (GTK_TOOL_ITEM (send_widget), TRUE); + send_widget = gtk_bin_get_child ((GtkBin *)send_widget); + gtk_container_remove((GtkContainer *)send_widget, gtk_bin_get_child ((GtkBin *)send_widget)); + gtk_container_add((GtkContainer *)send_widget, tmp); + gtk_button_set_relief ((GtkButton *)send_widget, GTK_RELIEF_NORMAL); + + path = "/main-toolbar/pre-main-toolbar/attach"; + send_widget = gtk_ui_manager_get_widget (ui_manager, path); + tmp = gtk_hbox_new (FALSE, 0); + tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon("gtk-add", E_ICON_SIZE_BUTTON)); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); + tmp1 = gtk_label_new_with_mnemonic (_("Add attachment")); + gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 3); + gtk_widget_show_all(tmp); + gtk_widget_reparent (send_widget, tmp_box); + gtk_box_set_child_packing ((GtkBox *)tmp_box, send_widget, FALSE, FALSE, 6, GTK_PACK_START); + gtk_tool_item_set_is_important (GTK_TOOL_ITEM (send_widget), TRUE); + send_widget = gtk_bin_get_child ((GtkBin *)send_widget); + gtk_container_remove((GtkContainer *)send_widget, gtk_bin_get_child ((GtkBin *)send_widget)); + gtk_container_add((GtkContainer *)send_widget, tmp); + gtk_button_set_relief ((GtkButton *)send_widget, GTK_RELIEF_NORMAL); + + gtk_widget_show(tmp_box); + gtk_box_pack_end ((GtkBox *)exp_box, tmp_box, TRUE, TRUE, 0); + gtk_box_pack_end ((GtkBox *)editor->vbox, exp_box, FALSE, FALSE, 3); + + } composer_setup_charset_menu (composer); if (error != NULL) { @@ -139,11 +208,15 @@ e_composer_private_init (EMsgComposer *composer) /* Construct the header table. */ container = editor->vbox; - + widget = e_composer_header_table_new (); gtk_container_set_border_width (GTK_CONTAINER (widget), 6); gtk_box_pack_start (GTK_BOX (editor->vbox), widget, FALSE, FALSE, 0); - gtk_box_reorder_child (GTK_BOX (editor->vbox), widget, 2); + if (composer->lite) + gtk_box_reorder_child (GTK_BOX (editor->vbox), widget, 0); + else + gtk_box_reorder_child (GTK_BOX (editor->vbox), widget, 2); + priv->header_table = g_object_ref (widget); gtk_widget_show (widget); @@ -154,6 +227,8 @@ e_composer_private_init (EMsgComposer *composer) priv->attachment_paned = g_object_ref (widget); gtk_widget_show (widget); + g_object_set_data ((GObject *)composer, "vbox", editor->vbox); + /* Reparent the scrolled window containing the GtkHTML widget * into the content area of the top attachment pane. */ diff --git a/composer/e-composer-text-header.c b/composer/e-composer-text-header.c index 2945720c90..e676ef941c 100644 --- a/composer/e-composer-text-header.c +++ b/composer/e-composer-text-header.c @@ -1,3 +1,7 @@ +/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */ + +/*Modified for Anjal - Johnny Jacob */ + /* * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public @@ -21,6 +25,11 @@ #define E_COMPOSER_TEXT_HEADER_GET_ENTRY(header) \ (GTK_ENTRY (E_COMPOSER_HEADER (header)->input_widget)) +struct _EComposerTextHeaderPrivate { + GtkLinkButton *linkbtn; + guint destination_index; +}; + static gpointer parent_class; static void @@ -99,19 +108,23 @@ e_composer_text_header_get_type (void) } EComposerHeader * -e_composer_text_header_new_label (const gchar *label) +e_composer_text_header_new_label (const gchar *label, const gchar *action_label) { return g_object_new ( E_TYPE_COMPOSER_TEXT_HEADER, "label", label, - "button", FALSE, NULL); + "button", FALSE, "addaction", action_label && *action_label, + "addaction_text", action_label, + "visible", action_label == NULL, NULL); } EComposerHeader * -e_composer_text_header_new_button (const gchar *label) +e_composer_text_header_new_button (const gchar *label, const gchar *action_label) { return g_object_new ( E_TYPE_COMPOSER_TEXT_HEADER, "label", label, - "button", TRUE, NULL); + "button", TRUE, "addaction", action_label != NULL, + "addaction_text", action_label, + "visible", action_label == NULL, NULL); } const gchar * diff --git a/composer/e-composer-text-header.h b/composer/e-composer-text-header.h index c0c4708595..79e972d3c6 100644 --- a/composer/e-composer-text-header.h +++ b/composer/e-composer-text-header.h @@ -57,10 +57,13 @@ struct _EComposerTextHeaderClass { }; GType e_composer_text_header_get_type (void); -EComposerHeader * e_composer_text_header_new_label - (const gchar *label); -EComposerHeader * e_composer_text_header_new_button - (const gchar *label); + +EComposerHeader * +e_composer_text_header_new_label (const gchar *label, const gchar *action_label); + +EComposerHeader * +e_composer_text_header_new_button (const gchar *label, const gchar *action_label); + const gchar * e_composer_text_header_get_text (EComposerTextHeader *header); void e_composer_text_header_set_text (EComposerTextHeader *header, const gchar *text); diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index 9b526f63ac..3bf82a229f 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -119,6 +119,8 @@ enum { LAST_SIGNAL }; +gboolean composer_lite = FALSE; + static gpointer parent_class; static guint signals[LAST_SIGNAL]; @@ -1429,7 +1431,14 @@ msg_composer_update_preferences (GConfClient *client, GError *error = NULL; editor = GTKHTML_EDITOR (composer); - + + if (entry) { + if (strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_INLINE_SPELLING_KEY) != 0 && + strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_LINKS_KEY) != 0 && + strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_SMILEYS_KEY) != 0) + return; + } + enable = gconf_client_get_bool ( client, COMPOSER_GCONF_INLINE_SPELLING_KEY, &error); if (error == NULL) @@ -2146,6 +2155,7 @@ msg_composer_init (EMsgComposer *composer) GtkHTML *html; gint n_targets; + composer->lite = composer_lite; composer->priv = E_MSG_COMPOSER_GET_PRIVATE (composer); e_composer_private_init (composer); @@ -2277,6 +2287,32 @@ e_msg_composer_new (void) return g_object_new (E_TYPE_MSG_COMPOSER, NULL); } + +void +e_msg_composer_set_lite (void) +{ + composer_lite = TRUE; +} + +gboolean +e_msg_composer_get_lite (void) +{ + return composer_lite; +} + +EMsgComposer * +e_msg_composer_lite_new (void) +{ + EMsgComposer *composer; + + /* Init lite-composer for ever for the session */ + composer_lite = TRUE; + + composer = e_msg_composer_new (); + + return composer; +} + static void e_msg_composer_set_pending_body (EMsgComposer *composer, gchar *text, diff --git a/composer/e-msg-composer.h b/composer/e-msg-composer.h index 7a279ba230..bf712d2928 100644 --- a/composer/e-msg-composer.h +++ b/composer/e-msg-composer.h @@ -60,6 +60,7 @@ typedef struct _EMsgComposerPrivate EMsgComposerPrivate; struct _EMsgComposer { GtkhtmlEditor parent; EMsgComposerPrivate *priv; + gboolean lite; }; struct _EMsgComposerClass { @@ -70,10 +71,14 @@ struct _EAttachmentBar; GType e_msg_composer_get_type (void); EMsgComposer * e_msg_composer_new (void); +EMsgComposer * e_msg_composer_lite_new (void); + EMsgComposer * e_msg_composer_new_with_message (CamelMimeMessage *msg); EMsgComposer * e_msg_composer_new_from_url (const gchar *url); EMsgComposer * e_msg_composer_new_redirect (CamelMimeMessage *message, const gchar *resent_from); +void e_msg_composer_set_lite (void); +gboolean e_msg_composer_get_lite (void); void e_msg_composer_send (EMsgComposer *composer); void e_msg_composer_save_draft (EMsgComposer *composer); -- cgit From 2087f385e566fcc3a79060e93c921afed310c2a9 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Sun, 24 May 2009 11:06:13 -0400 Subject: Prefer icons from GTK's cache instead of our own. --- composer/e-composer-private.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'composer') diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c index ef151d024e..a41a06f814 100644 --- a/composer/e-composer-private.c +++ b/composer/e-composer-private.c @@ -17,7 +17,6 @@ #include "e-composer-private.h" #include "e-util/e-util-private.h" -#include "e-util/e-icon-factory.h" static void composer_setup_charset_menu (EMsgComposer *composer) @@ -147,7 +146,8 @@ e_composer_private_init (EMsgComposer *composer) tmp_box = gtk_hbox_new (FALSE, 0); tmp = gtk_hbox_new (FALSE, 0); - tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon("mail-send", E_ICON_SIZE_BUTTON)); + tmp1 = gtk_image_new_from_icon_name ( + "mail-send", GTK_ICON_SIZE_BUTTON); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); tmp1 = gtk_label_new_with_mnemonic (_("S_end")); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 6); @@ -163,7 +163,8 @@ e_composer_private_init (EMsgComposer *composer) path = "/main-toolbar/pre-main-toolbar/save-draft"; send_widget = gtk_ui_manager_get_widget (ui_manager, path); tmp = gtk_hbox_new (FALSE, 0); - tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon(GTK_STOCK_SAVE, E_ICON_SIZE_BUTTON)); + tmp1 = gtk_image_new_from_stock ( + GTK_STOCK_SAVE, GTK_ICON_SIZE_BUTTON); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); tmp1 = gtk_label_new_with_mnemonic (_("Save draft")); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 3); @@ -179,7 +180,8 @@ e_composer_private_init (EMsgComposer *composer) path = "/main-toolbar/pre-main-toolbar/attach"; send_widget = gtk_ui_manager_get_widget (ui_manager, path); tmp = gtk_hbox_new (FALSE, 0); - tmp1 = gtk_image_new_from_pixbuf (e_icon_factory_get_icon("gtk-add", E_ICON_SIZE_BUTTON)); + tmp1 = gtk_image_new_from_stock ( + GTK_STOCK_ADD, GTK_ICON_SIZE_BUTTON); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); tmp1 = gtk_label_new_with_mnemonic (_("Add attachment")); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 3); -- cgit From 05a85647b7f649ef76a51fed8ee21eaec84232d4 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Mon, 25 May 2009 23:24:45 -0400 Subject: Fix compiler warnings in composer. --- composer/e-composer-actions.c | 2 +- composer/e-composer-header-table.c | 1 - composer/e-composer-header.c | 6 ------ 3 files changed, 1 insertion(+), 8 deletions(-) (limited to 'composer') diff --git a/composer/e-composer-actions.c b/composer/e-composer-actions.c index 247ac7794f..077c0c5ec0 100644 --- a/composer/e-composer-actions.c +++ b/composer/e-composer-actions.c @@ -444,7 +444,7 @@ static GtkToggleActionEntry toggle_entries[] = { N_("S/MIME Sig_n"), NULL, N_("Sign this message with your S/MIME Signature Certificate"), - NULL, /* Handled by property bindings */ + G_CALLBACK (action_smime_sign_cb), FALSE }, { "view-bcc", diff --git a/composer/e-composer-header-table.c b/composer/e-composer-header-table.c index df96d763ba..ef03fb4f73 100644 --- a/composer/e-composer-header-table.c +++ b/composer/e-composer-header-table.c @@ -1025,7 +1025,6 @@ e_composer_header_table_get_header (EComposerHeaderTable *table, { g_return_val_if_fail (E_IS_COMPOSER_HEADER_TABLE (table), NULL); g_return_val_if_fail (type < E_COMPOSER_NUM_HEADERS, NULL); - g_return_val_if_fail (type >= 0, NULL); return table->priv->headers[type]; } diff --git a/composer/e-composer-header.c b/composer/e-composer-header.c index 20967c6853..674e7a6cee 100644 --- a/composer/e-composer-header.c +++ b/composer/e-composer-header.c @@ -71,12 +71,6 @@ composer_header_addaction_clicked_cb (GtkButton *button, e_composer_header_set_visible (header, TRUE); } -static void -link_clicked_cb (GtkLinkButton *button, const gchar *link_, gpointer user_data) -{ - return; -} - static GObject * composer_header_constructor (GType type, guint n_construct_properties, -- cgit From 06563bd114ddc75e6b0efceddf1f6b2478ca9718 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 26 May 2009 22:39:40 -0400 Subject: Remove Attach toolbar button from composer. This was an oversight from the attachment UI rewrite. --- composer/evolution-composer.ui | 1 - 1 file changed, 1 deletion(-) (limited to 'composer') diff --git a/composer/evolution-composer.ui b/composer/evolution-composer.ui index c22368383c..1e72d9eafc 100644 --- a/composer/evolution-composer.ui +++ b/composer/evolution-composer.ui @@ -58,7 +58,6 @@ - -- cgit From 75a36a295adb64a012521c01724d6b2951986653 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 26 May 2009 22:55:38 -0400 Subject: Fix composer header regression caused by Anjal merge. --- composer/e-composer-header-table.c | 13 ++++++++----- composer/e-composer-name-header.c | 16 +++++++--------- composer/e-composer-private.c | 6 +++--- composer/e-msg-composer.c | 8 ++++---- 4 files changed, 22 insertions(+), 21 deletions(-) (limited to 'composer') diff --git a/composer/e-composer-header-table.c b/composer/e-composer-header-table.c index ef03fb4f73..33041301b5 100644 --- a/composer/e-composer-header-table.c +++ b/composer/e-composer-header-table.c @@ -70,7 +70,7 @@ struct _EComposerHeaderTablePrivate { GtkWidget *signature_label; GtkWidget *signature_combo_box; ENameSelector *name_selector; - GtkHBox *actions_container; + GtkHBox *actions_container; }; static gpointer parent_class; @@ -514,7 +514,7 @@ composer_header_table_constructor (GType type, if (composer_lite) gtk_widget_show_all ((GtkWidget *)priv->actions_container); - + ii = E_COMPOSER_HEADER_FROM; /* Leave room in the "From" row for signature stuff. */ @@ -937,17 +937,20 @@ composer_header_table_init (EComposerHeaderTable *table) composer_header_table_bind_header ("reply-to", "changed", header); table->priv->headers[E_COMPOSER_HEADER_REPLY_TO] = header; - header = e_composer_name_header_new_with_label (_("_To:"), name_selector); + header = e_composer_name_header_new_with_label ( + _("_To:"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_TO); composer_header_table_bind_header ("destinations-to", "changed", header); table->priv->headers[E_COMPOSER_HEADER_TO] = header; - header = e_composer_name_header_new_with_action (_("_Cc:"), _("Show CC"), name_selector); + header = e_composer_name_header_new_with_action ( + _("_Cc:"), _("Show CC"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_CC); composer_header_table_bind_header ("destinations-cc", "changed", header); table->priv->headers[E_COMPOSER_HEADER_CC] = header; - header = e_composer_name_header_new_with_action (_("_Bcc:"), _("Show BCC"), name_selector); + header = e_composer_name_header_new_with_action ( + _("_Bcc:"), _("Show BCC"), name_selector); e_composer_header_set_input_tooltip (header, HEADER_TOOLTIP_BCC); composer_header_table_bind_header ("destinations-bcc", "changed", header); table->priv->headers[E_COMPOSER_HEADER_BCC] = header; diff --git a/composer/e-composer-name-header.c b/composer/e-composer-name-header.c index 472208edd3..ed4e60c6f9 100644 --- a/composer/e-composer-name-header.c +++ b/composer/e-composer-name-header.c @@ -265,28 +265,26 @@ e_composer_name_header_new (const gchar *label, EComposerHeader * e_composer_name_header_new_with_label (const gchar *label, - ENameSelector *name_selector) + ENameSelector *name_selector) { return g_object_new ( E_TYPE_COMPOSER_NAME_HEADER, "label", label, - "button", FALSE, "name-selector", name_selector, - "addaction", FALSE, "visible", TRUE, - NULL); + "button", TRUE, "name-selector", name_selector, + "addaction", FALSE, "visible", TRUE, NULL); } EComposerHeader * e_composer_name_header_new_with_action (const gchar *label, - const gchar *action_label, - ENameSelector *name_selector) + const gchar *action_label, + ENameSelector *name_selector) { g_return_val_if_fail (E_IS_NAME_SELECTOR (name_selector), NULL); return g_object_new ( E_TYPE_COMPOSER_NAME_HEADER, "label", label, - "button", FALSE, "name-selector", name_selector, + "button", TRUE, "name-selector", name_selector, "addaction_text", action_label, - "addaction", action_label != NULL, - NULL); + "addaction", action_label != NULL, NULL); } ENameSelector * diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c index a41a06f814..0a1a91f6c0 100644 --- a/composer/e-composer-private.c +++ b/composer/e-composer-private.c @@ -159,7 +159,7 @@ e_composer_private_init (EMsgComposer *composer) gtk_container_remove((GtkContainer *)send_widget, gtk_bin_get_child ((GtkBin *)send_widget)); gtk_container_add((GtkContainer *)send_widget, tmp); gtk_button_set_relief ((GtkButton *)send_widget, GTK_RELIEF_NORMAL); - + path = "/main-toolbar/pre-main-toolbar/save-draft"; send_widget = gtk_ui_manager_get_widget (ui_manager, path); tmp = gtk_hbox_new (FALSE, 0); @@ -185,7 +185,7 @@ e_composer_private_init (EMsgComposer *composer) gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 0); tmp1 = gtk_label_new_with_mnemonic (_("Add attachment")); gtk_box_pack_start ((GtkBox *)tmp, tmp1, FALSE, FALSE, 3); - gtk_widget_show_all(tmp); + gtk_widget_show_all(tmp); gtk_widget_reparent (send_widget, tmp_box); gtk_box_set_child_packing ((GtkBox *)tmp_box, send_widget, FALSE, FALSE, 6, GTK_PACK_START); gtk_tool_item_set_is_important (GTK_TOOL_ITEM (send_widget), TRUE); @@ -210,7 +210,7 @@ e_composer_private_init (EMsgComposer *composer) /* Construct the header table. */ container = editor->vbox; - + widget = e_composer_header_table_new (); gtk_container_set_border_width (GTK_CONTAINER (widget), 6); gtk_box_pack_start (GTK_BOX (editor->vbox), widget, FALSE, FALSE, 0); diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index 3bf82a229f..a715774e0d 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -1431,14 +1431,14 @@ msg_composer_update_preferences (GConfClient *client, GError *error = NULL; editor = GTKHTML_EDITOR (composer); - + if (entry) { if (strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_INLINE_SPELLING_KEY) != 0 && strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_LINKS_KEY) != 0 && strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_SMILEYS_KEY) != 0) return; } - + enable = gconf_client_get_bool ( client, COMPOSER_GCONF_INLINE_SPELLING_KEY, &error); if (error == NULL) @@ -2294,7 +2294,7 @@ e_msg_composer_set_lite (void) composer_lite = TRUE; } -gboolean +gboolean e_msg_composer_get_lite (void) { return composer_lite; @@ -2308,7 +2308,7 @@ e_msg_composer_lite_new (void) /* Init lite-composer for ever for the session */ composer_lite = TRUE; - composer = e_msg_composer_new (); + composer = e_msg_composer_new (); return composer; } -- cgit From e4afd3f9fb962ea1295a0657ec9f83a427829171 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 26 May 2009 23:21:02 -0400 Subject: Remove trailing whitespace, again. --- composer/e-composer-actions.c | 2 +- composer/e-composer-actions.h | 2 +- composer/e-composer-autosave.c | 2 +- composer/e-composer-autosave.h | 2 +- composer/e-composer-common.h | 2 +- composer/e-composer-from-header.c | 2 +- composer/e-composer-from-header.h | 2 +- composer/e-composer-header-table.c | 4 ++-- composer/e-composer-header-table.h | 2 +- composer/e-composer-header.c | 2 +- composer/e-composer-header.h | 4 ++-- composer/e-composer-name-header.c | 4 ++-- composer/e-composer-name-header.h | 2 +- composer/e-composer-post-header.c | 2 +- composer/e-composer-post-header.h | 2 +- composer/e-composer-private.c | 4 ++-- composer/e-composer-private.h | 2 +- composer/e-composer-text-header.c | 4 ++-- composer/e-composer-text-header.h | 2 +- composer/e-msg-composer.c | 12 ++++++------ composer/e-msg-composer.h | 2 +- 21 files changed, 31 insertions(+), 31 deletions(-) (limited to 'composer') diff --git a/composer/e-composer-actions.c b/composer/e-composer-actions.c index 077c0c5ec0..3b40d270f0 100644 --- a/composer/e-composer-actions.c +++ b/composer/e-composer-actions.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-actions.h b/composer/e-composer-actions.h index da3e470d81..5d49cde158 100644 --- a/composer/e-composer-actions.h +++ b/composer/e-composer-actions.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-autosave.c b/composer/e-composer-autosave.c index 842deae9c9..5da5842d8c 100644 --- a/composer/e-composer-autosave.c +++ b/composer/e-composer-autosave.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-autosave.h b/composer/e-composer-autosave.h index 7c97338019..fe03b7b0bc 100644 --- a/composer/e-composer-autosave.h +++ b/composer/e-composer-autosave.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-common.h b/composer/e-composer-common.h index 832b38001f..28affba2ad 100644 --- a/composer/e-composer-common.h +++ b/composer/e-composer-common.h @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-from-header.c b/composer/e-composer-from-header.c index 68b6c0c14a..4dadfa7ac7 100644 --- a/composer/e-composer-from-header.c +++ b/composer/e-composer-from-header.c @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-from-header.h b/composer/e-composer-from-header.h index f8c6dc6f18..d2603bd664 100644 --- a/composer/e-composer-from-header.h +++ b/composer/e-composer-from-header.h @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-header-table.c b/composer/e-composer-header-table.c index 33041301b5..f25c3b722c 100644 --- a/composer/e-composer-header-table.c +++ b/composer/e-composer-header-table.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ @@ -548,7 +548,7 @@ composer_header_table_constructor (GType type, priv->headers[ii]->input_widget, "right-attach", 2, NULL); - gtk_table_attach (GTK_TABLE (object), (GtkWidget *)priv->actions_container, 2, 4, E_COMPOSER_HEADER_TO, + gtk_table_attach (GTK_TABLE (object), (GtkWidget *)priv->actions_container, 2, 4, E_COMPOSER_HEADER_TO, E_COMPOSER_HEADER_TO + 1, GTK_FILL, 0, 0, 3); } diff --git a/composer/e-composer-header-table.h b/composer/e-composer-header-table.h index 817863031c..91ad56da46 100644 --- a/composer/e-composer-header-table.h +++ b/composer/e-composer-header-table.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-header.c b/composer/e-composer-header.c index 674e7a6cee..7b7cb9bcf2 100644 --- a/composer/e-composer-header.c +++ b/composer/e-composer-header.c @@ -13,7 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-header.h b/composer/e-composer-header.h index 126af5fb77..eb339d647c 100644 --- a/composer/e-composer-header.h +++ b/composer/e-composer-header.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ @@ -65,7 +65,7 @@ void e_composer_header_set_sensitive (EComposerHeader *header, gboolean e_composer_header_get_visible (EComposerHeader *header); void e_composer_header_set_visible (EComposerHeader *header, gboolean visible); -void e_composer_header_set_property (GObject *object, guint property_id, +void e_composer_header_set_property (GObject *object, guint property_id, const GValue *value, GParamSpec *pspec); void e_composer_header_set_title_tooltip (EComposerHeader *header, diff --git a/composer/e-composer-name-header.c b/composer/e-composer-name-header.c index ed4e60c6f9..bfc9441fb7 100644 --- a/composer/e-composer-name-header.c +++ b/composer/e-composer-name-header.c @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) @@ -282,7 +282,7 @@ e_composer_name_header_new_with_action (const gchar *label, return g_object_new ( E_TYPE_COMPOSER_NAME_HEADER, "label", label, - "button", TRUE, "name-selector", name_selector, + "button", TRUE, "name-selector", name_selector, "addaction_text", action_label, "addaction", action_label != NULL, NULL); } diff --git a/composer/e-composer-name-header.h b/composer/e-composer-name-header.h index af38666d59..100d6c8980 100644 --- a/composer/e-composer-name-header.h +++ b/composer/e-composer-name-header.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-post-header.c b/composer/e-composer-post-header.c index bb971d53bf..59d81b80ac 100644 --- a/composer/e-composer-post-header.c +++ b/composer/e-composer-post-header.c @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-post-header.h b/composer/e-composer-post-header.h index 666d043df2..40dc5a8d58 100644 --- a/composer/e-composer-post-header.h +++ b/composer/e-composer-post-header.h @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c index 0a1a91f6c0..2a2cea6a4c 100644 --- a/composer/e-composer-private.c +++ b/composer/e-composer-private.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ @@ -101,7 +101,7 @@ e_composer_private_init (EMsgComposer *composer) widget = gtkhtml_editor_get_managed_widget (editor, "/main-menu"); gtk_widget_hide (widget); widget = gtkhtml_editor_get_managed_widget (editor, "/main-toolbar"); - gtk_toolbar_set_style ((GtkToolbar *)widget, GTK_TOOLBAR_BOTH_HORIZ); + gtk_toolbar_set_style ((GtkToolbar *)widget, GTK_TOOLBAR_BOTH_HORIZ); gtk_widget_hide (widget); } diff --git a/composer/e-composer-private.h b/composer/e-composer-private.h index 8dc9b4be93..49d9ae6d74 100644 --- a/composer/e-composer-private.h +++ b/composer/e-composer-private.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ diff --git a/composer/e-composer-text-header.c b/composer/e-composer-text-header.c index e676ef941c..e765237a2d 100644 --- a/composer/e-composer-text-header.c +++ b/composer/e-composer-text-header.c @@ -14,7 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) */ @@ -122,7 +122,7 @@ e_composer_text_header_new_button (const gchar *label, const gchar *action_label { return g_object_new ( E_TYPE_COMPOSER_TEXT_HEADER, "label", label, - "button", TRUE, "addaction", action_label != NULL, + "button", TRUE, "addaction", action_label != NULL, "addaction_text", action_label, "visible", action_label == NULL, NULL); } diff --git a/composer/e-composer-text-header.h b/composer/e-composer-text-header.h index 79e972d3c6..74fb86f9b0 100644 --- a/composer/e-composer-text-header.h +++ b/composer/e-composer-text-header.h @@ -11,7 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index a715774e0d..946bff28c1 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Authors: @@ -1434,7 +1434,7 @@ msg_composer_update_preferences (GConfClient *client, if (entry) { if (strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_INLINE_SPELLING_KEY) != 0 && - strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_LINKS_KEY) != 0 && + strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_LINKS_KEY) != 0 && strcmp(gconf_entry_get_key(entry), COMPOSER_GCONF_MAGIC_SMILEYS_KEY) != 0) return; } @@ -2928,13 +2928,13 @@ e_msg_composer_new_with_message (CamelMimeMessage *message) /* Remove any other X-Evolution-* headers that may have been set */ xev = mail_tool_remove_xevolution_headers (message); camel_header_raw_clear (&xev); - + /* Check for receipt request */ if (camel_medium_get_header (CAMEL_MEDIUM (message), "Disposition-Notification-To")) { action = GTK_TOGGLE_ACTION (ACTION (REQUEST_READ_RECEIPT)); gtk_toggle_action_set_active (action, TRUE); } - + /* Check for mail priority */ if (camel_medium_get_header (CAMEL_MEDIUM (message), "X-Priority")) { action = GTK_TOGGLE_ACTION (ACTION (PRIORITIZE_MESSAGE)); @@ -3907,7 +3907,7 @@ e_msg_composer_request_close_all (void) /* Try to autosave before closing. If it fails for * some reason, the CLOSE action will still detect - * unsaved changes and prompt the user. + * unsaved changes and prompt the user. * * FIXME If it /does/ prompt the user, the Cancel * button will act the same as Discard Changes, @@ -4094,7 +4094,7 @@ e_load_spell_languages (void) const GtkhtmlSpellLanguage *language; language = gtkhtml_spell_language_lookup (NULL); - + if (language) { spell_languages = g_list_prepend ( spell_languages, (gpointer) language); diff --git a/composer/e-msg-composer.h b/composer/e-msg-composer.h index bf712d2928..b9985f7f44 100644 --- a/composer/e-msg-composer.h +++ b/composer/e-msg-composer.h @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Authors: -- cgit