]> Pileus Git - ~andy/gtk/commitdiff
Prevent the first row being focused on map. (#137351, Niklas Knutsson)
authorMatthias Clasen <mclasen@redhat.com>
Mon, 9 Jan 2006 19:22:33 +0000 (19:22 +0000)
committerMatthias Clasen <matthiasc@src.gnome.org>
Mon, 9 Jan 2006 19:22:33 +0000 (19:22 +0000)
2006-01-09  Matthias Clasen  <mclasen@redhat.com>

* gtk/gtkentrycompletion.c (_gtk_entry_completion_popup):
Prevent the first row being focused on map.  (#137351,
Niklas Knutsson)

ChangeLog
ChangeLog.pre-2-10
gtk/gtkentrycompletion.c

index 5d2da707331fb89559a6735ee01c83285760aa5b..5d7ca846006b4ed6407c7e1bdc0beb041480c83c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2006-01-09  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkentrycompletion.c (_gtk_entry_completion_popup): 
+       Prevent the first row being focused on map.  (#137351,
+       Niklas Knutsson)
+
 2006-01-09  Johan Dahlin  <jdahlin@async.com.br>
 
        * gtk/gtk.symbols:
index 5d2da707331fb89559a6735ee01c83285760aa5b..5d7ca846006b4ed6407c7e1bdc0beb041480c83c 100644 (file)
@@ -1,3 +1,9 @@
+2006-01-09  Matthias Clasen  <mclasen@redhat.com>
+
+       * gtk/gtkentrycompletion.c (_gtk_entry_completion_popup): 
+       Prevent the first row being focused on map.  (#137351,
+       Niklas Knutsson)
+
 2006-01-09  Johan Dahlin  <jdahlin@async.com.br>
 
        * gtk/gtk.symbols:
index 73505c8153700ace7f65c34ce5e3b66961e039ff..77dd5d9287980fea415544e1418da66593f4cf89 100644 (file)
@@ -1446,7 +1446,14 @@ _gtk_entry_completion_popup (GtkEntryCompletion *completion)
   if (GTK_IS_WINDOW (toplevel))
     gtk_window_group_add_window (_gtk_window_get_group (GTK_WINDOW (toplevel)), 
                                 GTK_WINDOW (completion->priv->popup_window));
+
+  /* prevent the first row being focused */
+  gtk_widget_grab_focus (completion->priv->tree_view);
+
+  gtk_tree_selection_unselect_all (gtk_tree_view_get_selection (GTK_TREE_VIEW (completion->priv->tree_view)));
+  gtk_tree_selection_unselect_all (gtk_tree_view_get_selection (GTK_TREE_VIEW (completion->priv->action_view)));
   
+
   gtk_widget_show (completion->priv->popup_window);
     
   gtk_grab_add (completion->priv->popup_window);