From 29344f2ea86d3ea81bd5686728e7c4045062a0aa Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Thu, 5 Jul 2001 15:31:23 +0000 Subject: Don't scroll to the cursor on grab, ungrab, noop, and copy commands. 2001-07-05 Christopher James Lahey * gal/e-text/e-text.c (e_text_command): Don't scroll to the cursor on grab, ungrab, noop, and copy commands. svn path=/trunk/; revision=10808 --- widgets/text/e-text.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'widgets') diff --git a/widgets/text/e-text.c b/widgets/text/e-text.c index 2b26e07a72..fadb390c4f 100644 --- a/widgets/text/e-text.c +++ b/widgets/text/e-text.c @@ -3435,6 +3435,7 @@ e_text_command(ETextEventProcessor *tep, ETextEventProcessorCommand *command, gp { EText *text = E_TEXT(data); int sel_start, sel_end; + gboolean scroll = TRUE; switch (command->action) { case E_TEP_MOVE: @@ -3491,6 +3492,7 @@ e_text_command(ETextEventProcessor *tep, ETextEventProcessorCommand *command, gp if (text->timer) { g_timer_reset(text->timer); } + scroll = FALSE; break; case E_TEP_PASTE: e_text_get_selection (text, clipboard_atom, command->time); @@ -3515,15 +3517,18 @@ e_text_command(ETextEventProcessor *tep, ETextEventProcessorCommand *command, gp GDK_BUTTON_RELEASE_MASK | GDK_POINTER_MOTION_MASK, text->i_cursor, command->time); + scroll = FALSE; break; case E_TEP_UNGRAB: gnome_canvas_item_ungrab (GNOME_CANVAS_ITEM(text), command->time); + scroll = FALSE; break; case E_TEP_NOP: + scroll = FALSE; break; } - if (!text->button_down) { + if (scroll && !text->button_down) { int x; int i; struct line *lines = text->lines; -- cgit