* src/modest-text-utils.[ch]:
[modest] / src / maemo / modest-msg-edit-window.c
index 5a4180c..96eb886 100644 (file)
@@ -1219,17 +1219,9 @@ set_msg (ModestMsgEditWindow *self, TnyMsg *msg, gboolean preserve_is_rich)
 
        if (preserve_is_rich && !is_html) {
                wp_text_buffer_enable_rich_text (WP_TEXT_BUFFER (priv->text_buffer), FALSE);
-               /* We must do this here in order to reset the undo
-                  list, because otherwise this action could be
-                  reverted */
-               wp_text_buffer_reset_buffer (WP_TEXT_BUFFER (priv->text_buffer), FALSE);
        /* Get the default format required from configuration */
        } else if (!modest_conf_get_bool (modest_runtime_get_conf (), MODEST_CONF_PREFER_FORMATTED_TEXT, NULL)) {
                wp_text_buffer_enable_rich_text (WP_TEXT_BUFFER (priv->text_buffer), FALSE);
-               /* We must do this here in order to reset the undo
-                  list, because otherwise this action could be
-                  reverted */
-               wp_text_buffer_reset_buffer (WP_TEXT_BUFFER (priv->text_buffer), FALSE);
        }
 
        /* Set the default focus depending on having already a To: field or not */
@@ -1594,6 +1586,8 @@ get_formatted_data (ModestMsgEditWindow *edit_window)
 
        wp_text_buffer_save_document (WP_TEXT_BUFFER(priv->text_buffer), get_formatted_data_cb, &string_buffer);
 
+       modest_text_utils_hyperlinkify (string_buffer);
+
        gtk_text_buffer_set_modified (priv->text_buffer, TRUE);
 
        return g_string_free (string_buffer, FALSE);
@@ -2266,7 +2260,7 @@ modest_msg_edit_window_offer_attach_file (ModestMsgEditWindow *window)
                
        priv = MODEST_MSG_EDIT_WINDOW_GET_PRIVATE (window);
 
-       if (modest_platform_check_memory_low (MODEST_WINDOW(window)))
+       if (modest_platform_check_memory_low (MODEST_WINDOW(window), TRUE))
                return;
        
        dialog = hildon_file_chooser_dialog_new (GTK_WINDOW (window), GTK_FILE_CHOOSER_ACTION_OPEN);
@@ -2667,10 +2661,9 @@ modest_msg_edit_window_open_addressbook (ModestMsgEditWindow *window,
        /* we check for low-mem; in that case, show a warning, and don't allow
         * for the addressbook
         */
-       if (modest_platform_check_memory_low (MODEST_WINDOW(window)))
+       if (modest_platform_check_memory_low (MODEST_WINDOW(window), TRUE))
                return;
 
-
        priv = MODEST_MSG_EDIT_WINDOW_GET_PRIVATE (window);
 
        if (editor == NULL) {