pidgin: 48534a19: Reset 'undo' history when a message is s...
sadrul at pidgin.im
sadrul at pidgin.im
Wed Jun 2 23:25:33 EDT 2010
-----------------------------------------------------------------
Revision: 48534a1964f1e97c7be7d751cf33f9edbdf90422
Ancestor: df74d7caca3d52c69d1513a3e75f8b0b31ce5de9
Author: sadrul at pidgin.im
Date: 2010-06-03T02:19:28
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/48534a1964f1e97c7be7d751cf33f9edbdf90422
Modified files:
pidgin/gtkconv.c
ChangeLog:
Reset 'undo' history when a message is sent.
-------------- next part --------------
============================================================
--- pidgin/gtkconv.c e16029d77834443edabb800e46530fb476afb54a
+++ pidgin/gtkconv.c cef422192a37a5966dba76f5b879e24470fce162
@@ -282,6 +282,15 @@ static void
}
static void
+conversation_entry_clear(PidginConversation *gtkconv)
+{
+ GtkIMHtml *imhtml = GTK_IMHTML(gtkconv->entry);
+ gtk_source_undo_manager_begin_not_undoable_action(imhtml->undo_manager);
+ gtk_imhtml_clear(imhtml);
+ gtk_source_undo_manager_end_not_undoable_action(imhtml->undo_manager);
+}
+
+static void
clear_formatting_cb(GtkIMHtml *imhtml, PidginConversation *gtkconv)
{
default_formatize(gtkconv);
@@ -557,7 +566,7 @@ send_cb(GtkWidget *widget, PidginConvers
account = purple_conversation_get_account(conv);
if (check_for_and_do_command(conv)) {
- gtk_imhtml_clear(GTK_IMHTML(gtkconv->entry));
+ conversation_entry_clear(gtkconv);
return;
}
@@ -612,7 +621,7 @@ send_cb(GtkWidget *widget, PidginConvers
g_free(clean);
g_free(buf);
- gtk_imhtml_clear(GTK_IMHTML(gtkconv->entry));
+ conversation_entry_clear(gtkconv);
gtkconv_set_unseen(gtkconv, PIDGIN_UNSEEN_NONE);
}
More information about the Commits
mailing list