From c5fb694f36374e9750de93acbec83597bc039738 Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Mon, 02 Jun 2008 08:24:31 -0400
Subject: [PATCH] #1484856

---
 program/js/app.js |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/program/js/app.js b/program/js/app.js
index 8839779..71545e8 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -1838,9 +1838,9 @@
     var input_cc = rcube_find_object('_cc');
     var input_bcc = rcube_find_object('_bcc');
     var input_subject = rcube_find_object('_subject');
-    var input_message = rcube_find_object('_message');
-    
+    var editor, input_message;
     var str = '';
+    
     if (input_to && input_to.value)
       str += input_to.value+':';
     if (input_cc && input_cc.value)
@@ -1849,8 +1849,14 @@
       str += input_bcc.value+':';
     if (input_subject && input_subject.value)
       str += input_subject.value+':';
-    if (input_message && input_message.value)
+    
+    if (editor = tinyMCE.get('compose-body'))
+      str += editor.getContent();
+    else
+      {
+      input_message = rcube_find_object('_message');
       str += input_message.value;
+      }
     
     if (save)
       this.cmp_hash = str;

--
Gitblit v1.9.1