diff options
author | Srinivasa Ragavan <sragavan@novell.com> | 2009-06-11 19:15:40 +0800 |
---|---|---|
committer | Srinivasa Ragavan <sragavan@novell.com> | 2009-06-11 19:15:40 +0800 |
commit | 6a1c8278914f37aafe0fc2fb9997041fbfb3ef85 (patch) | |
tree | 56384e825bb8d4ccea5f5460d7dbe4b346ae8941 /composer | |
parent | 1db4cae4fed89733f824801a67847da277a5c255 (diff) | |
download | gsoc2013-evolution-6a1c8278914f37aafe0fc2fb9997041fbfb3ef85.tar.gz gsoc2013-evolution-6a1c8278914f37aafe0fc2fb9997041fbfb3ef85.tar.zst gsoc2013-evolution-6a1c8278914f37aafe0fc2fb9997041fbfb3ef85.zip |
Changes for Anjal: Pack Send/Save draft, instead of the combo box for
Icon view.
Diffstat (limited to 'composer')
-rw-r--r-- | composer/e-composer-private.c | 90 |
1 files changed, 36 insertions, 54 deletions
diff --git a/composer/e-composer-private.c b/composer/e-composer-private.c index 30cf5ac2c2..2d2efab187 100644 --- a/composer/e-composer-private.c +++ b/composer/e-composer-private.c @@ -88,7 +88,6 @@ e_composer_private_init (EMsgComposer *composer) GtkWidget *widget; GtkWidget *container; GtkWidget *send_widget; - GtkWidget *exp_box; const gchar *path; gchar *filename; gint ii; @@ -138,11 +137,43 @@ 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); + composer_setup_charset_menu (composer); + + if (error != NULL) { + /* Henceforth, bad things start happening. */ + g_critical ("%s", error->message); + g_clear_error (&error); + } + + /* 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); + 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); + + /* Construct the attachment paned. */ + + widget = e_attachment_paned_new (); + gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0); + priv->attachment_paned = g_object_ref (widget); + gtk_widget_show (widget); + if (composer->lite) { - GtkWidget *tmp, *tmp1, *tmp_box; + GtkWidget *tmp, *tmp1, *tmp_box, *container; + GtkWidget *combo = e_attachment_paned_get_view_combo (widget); + gtk_widget_hide (combo); + container = e_attachment_paned_get_controls_container (widget); + tmp_box = gtk_hbox_new (FALSE, 0); tmp = gtk_hbox_new (FALSE, 0); @@ -177,59 +208,10 @@ e_composer_private_init (EMsgComposer *composer) 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_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); - 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) { - /* Henceforth, bad things start happening. */ - g_critical ("%s", error->message); - g_clear_error (&error); + gtk_box_pack_end (container, tmp_box, FALSE, FALSE, 3); } - /* 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); - 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); - - /* Construct the attachment paned. */ - - widget = e_attachment_paned_new (); - gtk_box_pack_start (GTK_BOX (container), widget, TRUE, TRUE, 0); - 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 |