diff options
author | Not Zed <NotZed@Ximian.com> | 2004-05-13 14:57:22 +0800 |
---|---|---|
committer | Michael Zucci <zucchi@src.gnome.org> | 2004-05-13 14:57:22 +0800 |
commit | cf9a0987d91a362480ba13fc6f901c27c8e40a08 (patch) | |
tree | 55ce4e81256229d27e6f3f4c91a5202a8ebc8360 /mail/em-folder-view.c | |
parent | 6c7aa314e8c8e87ea3db30d5d935ea45e95b7543 (diff) | |
download | gsoc2013-evolution-cf9a0987d91a362480ba13fc6f901c27c8e40a08.tar.gz gsoc2013-evolution-cf9a0987d91a362480ba13fc6f901c27c8e40a08.tar.zst gsoc2013-evolution-cf9a0987d91a362480ba13fc6f901c27c8e40a08.zip |
re-enabled the reply to selection stuff. I worked out how to make it work;
2004-05-13 Not Zed <NotZed@Ximian.com>
* em-folder-view.c (emfv_message_reply): re-enabled the reply to
selection stuff. I worked out how to make it work; I think.
* em-format-html-display.c (efhd_html_button_press_event): if we
aren't on a clickable object, do a null popup event instead.
* em-folder-view.c (emfv_format_popup_event): do the full popup if
we aren't on anything (not on a uri or part). See #8414.
svn path=/trunk/; revision=25894
Diffstat (limited to 'mail/em-folder-view.c')
-rw-r--r-- | mail/em-folder-view.c | 23 |
1 files changed, 13 insertions, 10 deletions
diff --git a/mail/em-folder-view.c b/mail/em-folder-view.c index fae2f6f11f..d5c1d9c2e6 100644 --- a/mail/em-folder-view.c +++ b/mail/em-folder-view.c @@ -1237,15 +1237,9 @@ emfv_message_reply(EMFolderView *emfv, int mode) /* HACK: Nasty internal gtkhtml poking going on here */ - /* Disabled since there's no simple way to find out if - gtkhtml has the primary selection right now */ - - /* Ugh, to use the clipboard we need to request the selection - and have an async callback - painful to deal with */ - - /*clip = gtk_clipboard_get(GDK_SELECTION_PRIMARY);*/ - if (FALSE /*gtk_clipboard_get_owner(clip) == (GObject *)emfv->preview*/ + if (((EMFormatHTML *)emfv->preview)->html->engine->selection && ((EMFormatHTML *)emfv->preview)->html->engine->primary) { + /* && GTK_WIDGET_HAS_FOCUS(emfv->preview->formathtml.html)*/ CamelMimeMessage *msg, *src; struct _camel_header_raw *header; HTMLEngineSaveState *state; @@ -1275,8 +1269,6 @@ emfv_message_reply(EMFolderView *emfv, int mode) } else { em_utils_reply_to_message_by_uid (emfv->folder, emfv->list->cursor_uid, mode); } - - /*g_object_unref(clip);*/ } static void @@ -2094,6 +2086,17 @@ emfv_format_popup_event(EMFormatHTMLDisplay *efhd, GdkEventButton *event, const EMPopupTarget *target; GtkMenu *menu; + if (uri == NULL && part == NULL) { + /* So we don't try and popup with nothing selected - rather odd result! */ + GPtrArray *uids = message_list_get_selected(emfv->list); + int doit = uids->len > 0; + + message_list_free_uids(emfv->list, uids); + if (doit) + emfv_popup(emfv, event); + return doit; + } + /* FIXME: this maybe should just fit on em-html-display, it has access to the snooped part type */ |