freeze text before autosave and thaw afterwards
authorPaul Mangan <paul@claws-mail.org>
Thu, 6 Mar 2003 10:46:00 +0000 (10:46 +0000)
committerPaul Mangan <paul@claws-mail.org>
Thu, 6 Mar 2003 10:46:00 +0000 (10:46 +0000)
src/compose.c

index de724c8d20dc1a8b7d8360a94fbe85883cc507aa..d54e0e3bf65dfebd858d3e508ebdf490a29649e2 100644 (file)
@@ -6889,8 +6889,11 @@ static void text_inserted(GtkWidget *widget, const gchar *text,
 
        
        if (prefs_common.autosave && 
-           gtk_stext_get_length(GTK_STEXT(widget)) % prefs_common.autosave_length == 0)
+           gtk_stext_get_length(GTK_STEXT(widget)) % prefs_common.autosave_length == 0) {
+               gtk_stext_freeze(GTK_STEXT(text));
                compose_draft_cb((gpointer)compose, 2, NULL);
+               gtk_stext_thaw(GTK_STEXT(text));                
+       }
 }
 
 static gboolean compose_send_control_enter(Compose *compose)