anjuta r3828 - in branches/anjuta-2-4: . plugins/sourceview



Author: jhs
Date: Mon Apr  7 18:34:42 2008
New Revision: 3828
URL: http://svn.gnome.org/viewvc/anjuta?rev=3828&view=rev

Log:
2008-04-07  Johannes Schmid  <jhs gnome org>

	* plugins/sourceview/sourceview.c (idocument_cut),
	(idocument_copy), (idocument_paste):
	Block insert-text signal on cut/copy/paste (backport from trunk)

Modified:
   branches/anjuta-2-4/ChangeLog
   branches/anjuta-2-4/plugins/sourceview/sourceview.c

Modified: branches/anjuta-2-4/plugins/sourceview/sourceview.c
==============================================================================
--- branches/anjuta-2-4/plugins/sourceview/sourceview.c	(original)
+++ branches/anjuta-2-4/plugins/sourceview/sourceview.c	Mon Apr  7 18:34:42 2008
@@ -1200,21 +1200,27 @@
 idocument_cut(IAnjutaDocument* edit, GError** ee)
 {
 	Sourceview* sv = ANJUTA_SOURCEVIEW(edit);
+	g_signal_handlers_block_by_func (sv->priv->document, on_insert_text, sv);
 	anjuta_view_cut_clipboard(sv->priv->view);
+	g_signal_handlers_unblock_by_func (sv->priv->document, on_insert_text, sv);
 }
 
 static void 
 idocument_copy(IAnjutaDocument* edit, GError** ee)
 {
 	Sourceview* sv = ANJUTA_SOURCEVIEW(edit);
+	g_signal_handlers_block_by_func (sv->priv->document, on_insert_text, sv);
 	anjuta_view_copy_clipboard(sv->priv->view);
+	g_signal_handlers_unblock_by_func (sv->priv->document, on_insert_text, sv);
 }
 
 static void 
 idocument_paste(IAnjutaDocument* edit, GError** ee)
 {
 	Sourceview* sv = ANJUTA_SOURCEVIEW(edit);
+	g_signal_handlers_block_by_func (sv->priv->document, on_insert_text, sv);
 	anjuta_view_paste_clipboard(sv->priv->view);
+	g_signal_handlers_unblock_by_func (sv->priv->document, on_insert_text, sv);
 }
 
 static void 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]