aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@novell.com>2004-07-17 00:03:44 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2004-07-17 00:03:44 +0800
commit230dd59a435687338ca6bd5ff72adc1abc9b8d97 (patch)
tree48d45d897050c5621418fdaf02636d3c632049c9 /mail
parent2c4f27374ab2aa3f1daad84c0ef5ab41a3bee230 (diff)
downloadgsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar.gz
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar.bz2
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar.lz
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar.xz
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.tar.zst
gsoc2013-evolution-230dd59a435687338ca6bd5ff72adc1abc9b8d97.zip
Chck that the selection is active. Hopefully this will fix bug #61427.
2004-07-13 Jeffrey Stedfast <fejj@novell.com> * em-folder-view.c (emfv_message_reply): Chck that the selection is active. Hopefully this will fix bug #61427. svn path=/trunk/; revision=26667
Diffstat (limited to 'mail')
-rw-r--r--mail/ChangeLog5
-rw-r--r--mail/em-folder-view.c22
2 files changed, 15 insertions, 12 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog
index 5ece10af5f..de893a4422 100644
--- a/mail/ChangeLog
+++ b/mail/ChangeLog
@@ -1,3 +1,8 @@
+2004-07-13 Jeffrey Stedfast <fejj@novell.com>
+
+ * em-folder-view.c (emfv_message_reply): Chck that the selection
+ is active. Hopefully this will fix bug #61427.
+
2004-07-13 Dan Winship <danw@novell.com>
* em-utils.c (em_utils_selection_set_urilist,
diff --git a/mail/em-folder-view.c b/mail/em-folder-view.c
index 71e24a3d40..8eb83642f1 100644
--- a/mail/em-folder-view.c
+++ b/mail/em-folder-view.c
@@ -82,6 +82,7 @@
#include <gtkhtml/htmlobject.h>
#include <gtkhtml/htmlengine.h>
#include <gtkhtml/htmlengine-save.h>
+#include <gtkhtml/htmlengine-edit-cut-and-paste.h>
#include "mail-mt.h"
#include "mail-ops.h"
@@ -1230,25 +1231,22 @@ emfv_message_post_reply (BonoboUIComponent *uic, void *data, const char *path)
static void
emfv_message_reply(EMFolderView *emfv, int mode)
{
- /* GtkClipboard *clip; */
-
+ HTMLObject *selection;
+ guint len;
+
if (emfv->list->cursor_uid == NULL)
return;
if (!em_utils_check_user_can_send_mail ((GtkWidget *) emfv))
return;
-
- /* Look away! Look away! */
-
- /* HACK: Nasty internal gtkhtml poking going on here */
-
- if (((EMFormatHTML *)emfv->preview)->html->engine->selection
- && ((EMFormatHTML *)emfv->preview)->html->engine->primary) {
- /* && GTK_WIDGET_HAS_FOCUS(emfv->preview->formathtml.html)*/
+
+ html_engine_copy_object (((EMFormatHTML *)emfv->preview)->html->engine, &selection, &len);
+ if (selection != NULL) {
HTMLEngineSaveState *state;
-
+
state = html_engine_save_buffer_new(((EMFormatHTML *)emfv->preview)->html->engine, TRUE);
- html_object_save(((EMFormatHTML *)emfv->preview)->html->engine->primary, state);
+ html_object_save (selection, state);
+ html_object_destroy (selection);
if (state->user_data && ((GString *)state->user_data)->len) {
CamelMimeMessage *msg, *src;
struct _camel_header_raw *header;