aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mail/ChangeLog9
-rw-r--r--mail/em-composer-prefs.c27
-rw-r--r--mail/mail-config.glade18
3 files changed, 43 insertions, 11 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 1cf028425a..053cf113a8 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,5 +1,14 @@
2008-03-27 Milan Crha <mcrha@redhat.com>
+ ** Fix for bug #502826 (original patch by nickspoon0)
+
+ * mail-config.glade:
+ * em-composer-prefs.c: (attach_style_reply_new_order),
+ (attach_style_info_reply), (em_composer_prefs_construct):
+ Reword and reorder Reply Style items in the Preferences.
+
+2008-03-27 Milan Crha <mcrha@redhat.com>
+
** Fix for bug #488175
* message-list.c: (ml_tree_value_at):
diff --git a/mail/em-composer-prefs.c b/mail/em-composer-prefs.c
index 11857c14ba..1f90b6ee3b 100644
--- a/mail/em-composer-prefs.c
+++ b/mail/em-composer-prefs.c
@@ -720,6 +720,19 @@ spell_setup_check_options (EMComposerPrefs *prefs)
* End of Spell checking
*/
+static int
+attach_style_reply_new_order (int style_id, gboolean from_enum_to_option_id)
+{
+ int values[] = {MAIL_CONFIG_REPLY_ATTACH, 0, MAIL_CONFIG_REPLY_OUTLOOK, 1, MAIL_CONFIG_REPLY_QUOTED, 2, MAIL_CONFIG_REPLY_DO_NOT_QUOTE, 3, -1, -1};
+ int i;
+
+ for (i = from_enum_to_option_id ? 0 : 1; values[i] != -1; i += 2) {
+ if (values[i] == style_id)
+ return values [from_enum_to_option_id ? i + 1 : i - 1];
+ }
+
+ return style_id;
+}
static void
attach_style_info (GtkWidget *item, gpointer user_data)
@@ -732,6 +745,16 @@ attach_style_info (GtkWidget *item, gpointer user_data)
}
static void
+attach_style_info_reply (GtkWidget *item, gpointer user_data)
+{
+ int *style = user_data;
+
+ g_object_set_data ((GObject *) item, "style", GINT_TO_POINTER (attach_style_reply_new_order (*style, FALSE)));
+
+ (*style)++;
+}
+
+static void
toggle_button_toggled (GtkToggleButton *toggle, EMComposerPrefs *prefs)
{
const char *key;
@@ -975,10 +998,10 @@ em_composer_prefs_construct (EMComposerPrefs *prefs)
prefs->reply_style = GTK_OPTION_MENU (glade_xml_get_widget (gui, "omenuReplyStyle"));
style = gconf_client_get_int (prefs->gconf, "/apps/evolution/mail/format/reply_style", NULL);
- gtk_option_menu_set_history (prefs->reply_style, style);
+ gtk_option_menu_set_history (prefs->reply_style, attach_style_reply_new_order (style, TRUE));
style = 0;
gtk_container_foreach (GTK_CONTAINER (gtk_option_menu_get_menu (prefs->reply_style)),
- attach_style_info, &style);
+ attach_style_info_reply, &style);
option_menu_connect (prefs, prefs->reply_style, G_CALLBACK (style_activate),
"/apps/evolution/mail/format/reply_style");
diff --git a/mail/mail-config.glade b/mail/mail-config.glade
index 8c722ed581..25a83cf157 100644
--- a/mail/mail-config.glade
+++ b/mail/mail-config.glade
@@ -7146,38 +7146,38 @@ For example: &quot;Work&quot; or &quot;Personal&quot;</property>
<child internal-child="menu">
<widget class="GtkMenu" id="convertwidget33">
<property name="visible">True</property>
-
<child>
- <widget class="GtkMenuItem" id="convertwidget34">
+ <widget class="GtkMenuItem" id="convertwidget36">
<property name="visible">True</property>
- <property name="label" translatable="yes">Quote original message</property>
+ <property name="label" translatable="yes">Attachment</property>
<property name="use_underline">True</property>
</widget>
</child>
<child>
- <widget class="GtkMenuItem" id="convertwidget35">
+ <widget class="GtkMenuItem" id="convertwidget50">
<property name="visible">True</property>
- <property name="label" translatable="yes">Do not quote original message</property>
+ <property name="label" translatable="yes">Inline (Outlook style)</property>
<property name="use_underline">True</property>
</widget>
</child>
<child>
- <widget class="GtkMenuItem" id="convertwidget36">
+ <widget class="GtkMenuItem" id="convertwidget34">
<property name="visible">True</property>
- <property name="label" translatable="yes">Attach original message</property>
+ <property name="label" translatable="yes">Quoted</property>
<property name="use_underline">True</property>
</widget>
</child>
<child>
- <widget class="GtkMenuItem" id="convertwidget50">
+ <widget class="GtkMenuItem" id="convertwidget35">
<property name="visible">True</property>
- <property name="label" translatable="yes">Inline original message (Outlook style)</property>
+ <property name="label" translatable="yes">Do not quote</property>
<property name="use_underline">True</property>
</widget>
</child>
+
</widget>
</child>
</widget>