Commit e3d25b3c authored by Carlos Garnacho's avatar Carlos Garnacho
Browse files

entry: Don't show text handles too eagerly on button press

Instead do so on button release, or after text selection dragging
starts.
parent c3075f1d
......@@ -4254,6 +4254,9 @@ gtk_entry_button_press (GtkWidget *widget,
is_touchscreen = test_touchscreen ||
gdk_device_get_source (source) == GDK_SOURCE_TOUCHSCREEN;
if (is_touchscreen)
gtk_entry_ensure_text_handles (entry);
priv->select_words = FALSE;
priv->select_lines = FALSE;
......@@ -4333,12 +4336,8 @@ gtk_entry_button_press (GtkWidget *widget,
else
{
gtk_editable_set_position (editable, tmp_pos);
if (is_touchscreen)
{
gtk_entry_ensure_text_handles (entry);
gtk_entry_update_handles (entry, GTK_TEXT_HANDLE_MODE_CURSOR);
}
gtk_entry_update_handles (entry, GTK_TEXT_HANDLE_MODE_NONE);
}
break;
......@@ -4450,6 +4449,7 @@ gtk_entry_button_release (GtkWidget *widget,
}
else if (is_touchscreen)
{
gtk_entry_update_handles (entry, GTK_TEXT_HANDLE_MODE_CURSOR);
gtk_entry_selection_bubble_popup_set (entry);
if (priv->magnifier_popover)
gtk_widget_hide (priv->magnifier_popover);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment