GNOME Bugzilla – Bug 471132
Highlighting a suggestion with the keyboard changes the URL entry in Epiphany; breaks Smart Bookmarks
Last modified: 2007-09-08 05:59:15 UTC
The bug has been opened on https://bugs.launchpad.net/ubuntu/+source/epiphany-browser/+bug/134304 "... When using the location entry to search with a Smart Bookmark, if the text you have entered shows any matches for URLs in your history, then navigating past these items with the keyboard causes the entered text to change. By the time you get to the Smart Bookmark, your entered text does not change back. I don't know the best way to deal with this. Why do we need to change the text in the entry at all? It seems a bit rude to destroy whatever the user has typed in. See attached video for clarity. ... Package: epiphany-browser 2.19.90-0ubuntu1 ... http://launchpadlibrarian.net/8955689/Ephy%20Bug Ephy Bug (315.1 KiB, application/ogg)"
This one is for Xan...
Agreed, this is pretty bad, but I'm afraid it has to be patched at the gtk level. As a workaround you can use Up to jump to the Smart Bookmarks though.
Another workaround is to put your favourite smart bookmark on the toolbar, or to use the smart bookmarks loookup extension to feed selected text to a smart bookmark.
Xan: so what should happen is when you move down through the completions and come to the first 'action' menu item in the drop-down, the original text is restored to the entry? I think this should be re-assigned to gtk+.
Moving to GTK+ and attaching a swarm of patches, the second one is about the last comment on bug 457384, the other just address a number of small issues I found while fixing this.
Created attachment 94524 [details] [review] [1/4] Set the completion prefix on key_press, not on the default completion signal handlers. gtk/gtkentry.c | 3 +++ gtk/gtkentrycompletion.c | 6 ------ 2 files changed, 3 insertions(+), 6 deletions(-)
Created attachment 94525 [details] [review] [2/4] When returning to the entry from the treeview, put the original input back with the cursor at the end. gtk/gtkentry.c | 9 +++++++++ 1 files changed, 9 insertions(+), 0 deletions(-)
Created attachment 94526 [details] [review] [3/4] Make bailing out of the popup work over the action rows too. gtk/gtkentry.c | 6 +----- 1 files changed, 1 insertions(+), 5 deletions(-)
Created attachment 94527 [details] [review] [4/4] Do not *always* handle the signal on Return, only if there is some selection in the treeview. gtk/gtkentry.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-)
Created attachment 94528 [details] [review] [0/4] Reset completion prefix on actions too. Of course getting it right would be too much. *This* is the first patch in the series.
Just noticed "last comment on bug foo" is not very resistant historically speaking. So patch [0/4] addresses comment http://bugzilla.gnome.org/show_bug.cgi?id=457384#c3.
Matthias: could these patches please be applied before the 2.12.0 release ? They're rather important for Epiphany.
gtk_entry_completion_key_press() is getting a bit messy... but I guess these patches make sense.
2007-09-08 Matthias Clasen <mclasen@redhat.com> * gtk/gtkentrycompletion.c: * gtk/gtkentry.c: Apply a number of patches by Xan Lopez to improve the interaction between actions and inline selection. (#471132)