aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-07-26 18:24:59 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-07-26 19:40:48 +0800
commit9279429501af7858716b0e317810a264192bb763 (patch)
treebbf44b7036dc7a895e185eabf325380432f17eff /mail
parent81e5428a59194dd38cf2a07b2d3f9b4b6f81f6ef (diff)
downloadgsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar.gz
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar.bz2
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar.lz
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar.xz
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.tar.zst
gsoc2013-evolution-9279429501af7858716b0e317810a264192bb763.zip
Drop the "quote-from-selection" property.
David's solution is simpler: check if the HTML widget is mapped. Avoids having to propagate the property to Srini's new classes.
Diffstat (limited to 'mail')
-rw-r--r--mail/e-mail-backend.c1
-rw-r--r--mail/e-mail-browser.c20
-rw-r--r--mail/e-mail-reader-utils.c14
-rw-r--r--mail/e-mail-reader.c42
-rw-r--r--mail/e-mail-reader.h5
5 files changed, 7 insertions, 75 deletions
diff --git a/mail/e-mail-backend.c b/mail/e-mail-backend.c
index b2e22e397d..4d2038a73c 100644
--- a/mail/e-mail-backend.c
+++ b/mail/e-mail-backend.c
@@ -374,7 +374,6 @@ mail_backend_constructed (GObject *object)
EShell *shell;
EShellBackend *shell_backend;
MailFolderCache *folder_cache;
- const gchar *data_dir;
shell_backend = E_SHELL_BACKEND (object);
shell = e_shell_backend_get_shell (shell_backend);
diff --git a/mail/e-mail-browser.c b/mail/e-mail-browser.c
index 7ddfe005ed..86cc929182 100644
--- a/mail/e-mail-browser.c
+++ b/mail/e-mail-browser.c
@@ -64,7 +64,6 @@ enum {
PROP_0,
PROP_FOCUS_TRACKER,
PROP_GROUP_BY_THREADS,
- PROP_QUOTE_FROM_SELECTION,
PROP_SHELL_BACKEND,
PROP_SHOW_DELETED,
PROP_UI_MANAGER
@@ -358,11 +357,6 @@ mail_browser_set_property (GObject *object,
g_value_get_boolean (value));
return;
- case PROP_QUOTE_FROM_SELECTION:
- e_mail_reader_set_quote_from_selection (
- E_MAIL_READER (object),
- g_value_get_boolean (value));
-
case PROP_SHELL_BACKEND:
mail_browser_set_shell_backend (
E_MAIL_BROWSER (object),
@@ -398,12 +392,6 @@ mail_browser_get_property (GObject *object,
E_MAIL_READER (object)));
return;
- case PROP_QUOTE_FROM_SELECTION:
- g_value_set_boolean (
- value, e_mail_reader_get_quote_from_selection (
- E_MAIL_READER (object)));
- return;
-
case PROP_SHELL_BACKEND:
g_value_set_object (
value, e_mail_reader_get_shell_backend (
@@ -557,8 +545,6 @@ mail_browser_constructed (GObject *object)
e_mail_reader_init (reader);
- e_mail_reader_set_quote_from_selection (reader, TRUE);
-
action_group = priv->action_group;
gtk_action_group_set_translation_domain (action_group, domain);
gtk_action_group_add_actions (
@@ -805,12 +791,6 @@ mail_browser_class_init (EMailBrowserClass *class)
PROP_GROUP_BY_THREADS,
"group-by-threads");
- /* Inherited from EMailReader */
- g_object_class_override_property (
- object_class,
- PROP_QUOTE_FROM_SELECTION,
- "quote-from-selection");
-
g_object_class_install_property (
object_class,
PROP_SHELL_BACKEND,
diff --git a/mail/e-mail-reader-utils.c b/mail/e-mail-reader-utils.c
index 8827375ed3..7d8be346bc 100644
--- a/mail/e-mail-reader-utils.c
+++ b/mail/e-mail-reader-utils.c
@@ -353,7 +353,8 @@ html_contains_nonwhitespace (const gchar *html,
}
void
-e_mail_reader_reply_to_message (EMailReader *reader, CamelMimeMessage *src_message,
+e_mail_reader_reply_to_message (EMailReader *reader,
+ CamelMimeMessage *src_message,
gint reply_mode)
{
EMFormatHTML *formatter;
@@ -384,15 +385,12 @@ e_mail_reader_reply_to_message (EMailReader *reader, CamelMimeMessage *src_messa
if (!gtk_widget_get_mapped (GTK_WIDGET(web_view)))
goto whole_message;
- if (!src_message) {
- src_message = CAMEL_MIME_MESSAGE (EM_FORMAT (formatter)->message);
- if (src_message)
- g_object_ref(src_message);
+ if (src_message == NULL) {
+ src_message = EM_FORMAT (formatter)->message;
+ if (src_message != NULL)
+ g_object_ref (src_message);
}
- if (!e_mail_reader_get_quote_from_selection (reader))
- goto whole_message;
-
if (!e_web_view_is_selection_active (web_view))
goto whole_message;
diff --git a/mail/e-mail-reader.c b/mail/e-mail-reader.c
index 4c5b3fd039..adf56fac7e 100644
--- a/mail/e-mail-reader.c
+++ b/mail/e-mail-reader.c
@@ -85,8 +85,7 @@ struct _EMailReaderPrivate {
guint folder_was_just_selected : 1;
guint restoring_message_selection : 1;
- guint group_by_threads : 1;
- guint quote_from_selection : 1;
+ guint group_by_threads : 1;
};
enum {
@@ -2756,15 +2755,6 @@ mail_reader_class_init (EMailReaderIface *iface)
FALSE,
G_PARAM_READWRITE));
- g_object_interface_install_property (
- iface,
- g_param_spec_boolean (
- "quote-from-selection",
- "Quote From Selection",
- "Quote selected text when replying",
- FALSE,
- G_PARAM_READWRITE));
-
signals[CHANGED] = g_signal_new (
"changed",
G_OBJECT_CLASS_TYPE (iface),
@@ -3503,36 +3493,6 @@ e_mail_reader_set_group_by_threads (EMailReader *reader,
g_object_notify (G_OBJECT (reader), "group-by-threads");
}
-gboolean
-e_mail_reader_get_quote_from_selection (EMailReader *reader)
-{
- EMailReaderPrivate *priv;
-
- g_return_val_if_fail (E_IS_MAIL_READER (reader), FALSE);
-
- priv = E_MAIL_READER_GET_PRIVATE (reader);
-
- return priv->quote_from_selection;
-}
-
-void
-e_mail_reader_set_quote_from_selection (EMailReader *reader,
- gboolean quote_from_selection)
-{
- EMailReaderPrivate *priv;
-
- g_return_if_fail (E_IS_MAIL_READER (reader));
-
- priv = E_MAIL_READER_GET_PRIVATE (reader);
-
- if (quote_from_selection == priv->quote_from_selection)
- return;
-
- priv->quote_from_selection = quote_from_selection;
-
- g_object_notify (G_OBJECT (reader), "quote-from-selection");
-}
-
void
e_mail_reader_create_charset_menu (EMailReader *reader,
GtkUIManager *ui_manager,
diff --git a/mail/e-mail-reader.h b/mail/e-mail-reader.h
index 842d3b0cb5..11df448b18 100644
--- a/mail/e-mail-reader.h
+++ b/mail/e-mail-reader.h
@@ -140,11 +140,6 @@ gboolean e_mail_reader_get_group_by_threads
void e_mail_reader_set_group_by_threads
(EMailReader *reader,
gboolean group_by_threads);
-gboolean e_mail_reader_get_quote_from_selection
- (EMailReader *reader);
-void e_mail_reader_set_quote_from_selection
- (EMailReader *reader,
- gboolean quote_from_selection);
void e_mail_reader_create_charset_menu
(EMailReader *reader,
GtkUIManager *ui_manager,