Bug 768086: Inconsistent text-layer focusing from text style editor

do not place cursor when it is already there
This commit is contained in:
Massimo Valentini 2016-06-28 18:15:52 +02:00
parent 8e9a89d0b9
commit b37ca78151
1 changed files with 5 additions and 1 deletions

View File

@ -309,8 +309,12 @@ gimp_text_tool_editor_button_press (GimpTextTool *text_tool,
switch (press_type)
{
GtkTextIter start, end;
case GIMP_BUTTON_PRESS_NORMAL:
gtk_text_buffer_place_cursor (buffer, &cursor);
if (gtk_text_buffer_get_selection_bounds (buffer, &start, &end) ||
gtk_text_iter_compare (&start, &cursor))
gtk_text_buffer_place_cursor (buffer, &cursor);
break;
case GIMP_BUTTON_PRESS_DOUBLE: