[gthumb] tags dialog: adding a tag removes all the other tags
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gthumb] tags dialog: adding a tag removes all the other tags
- Date: Thu, 2 Nov 2017 09:26:33 +0000 (UTC)
commit b97a7035c877b4f7f5ac1f2f6a95d09b9bdbe7e9
Author: Paolo Bacchilega <paobac src gnome org>
Date: Thu Nov 2 10:01:13 2017 +0100
tags dialog: adding a tag removes all the other tags
do not select the entry content after opening the dialog
[bug #777234]
gthumb/gth-tags-entry.c | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/gthumb/gth-tags-entry.c b/gthumb/gth-tags-entry.c
index ad11b3b..8f102fc 100644
--- a/gthumb/gth-tags-entry.c
+++ b/gthumb/gth-tags-entry.c
@@ -1098,6 +1098,17 @@ expand_button_toggled_cb (GtkToggleButton *button,
}
+static gboolean
+entry_focus_in_event_cb (GtkWidget *widget,
+ GdkEvent *event,
+ gpointer user_data)
+{
+ GthTagsEntry *self = user_data;
+ gtk_editable_set_position (GTK_EDITABLE (self->priv->entry), -1);
+ return GDK_EVENT_PROPAGATE;
+}
+
+
static void
gth_tags_entry_init (GthTagsEntry *self)
{
@@ -1150,6 +1161,10 @@ gth_tags_entry_init (GthTagsEntry *self)
gtk_entry_set_completion (GTK_ENTRY (self->priv->entry), self->priv->completion);
gtk_widget_show (self->priv->entry);
gtk_box_pack_start (GTK_BOX (hbox), self->priv->entry, TRUE, TRUE, 0);
+ g_signal_connect (self->priv->entry,
+ "focus-in-event",
+ G_CALLBACK (entry_focus_in_event_cb),
+ self);
/* expand button */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]