diff options
author | Christian Dywan <christian@twotoasts.de> | 2019-03-28 20:51:09 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-28 20:51:09 +0100 |
commit | 3b076e26ead96fd54e88d9952fd9b50c7a3e5c14 (patch) | |
tree | bf47050f3171dd5745456383d2d91c38fd8cb5c0 | |
parent | 4f2933db24384d37b11b4694b01dc97d7d1f6503 (diff) | |
download | midori-git-3b076e26ead96fd54e88d9952fd9b50c7a3e5c14.tar.gz |
Only limit automatic urlbar focus to blanks (#307)
The condition added in #274 had the unintended side-effect of ignoring
explicit urlbar focus via ^L or F6 hotkeys. So let's make the action
unbiased again and focus the urlbar directly.
-rw-r--r-- | core/browser.vala | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/browser.vala b/core/browser.vala index f12fdb6d..27558715 100644 --- a/core/browser.vala +++ b/core/browser.vala @@ -315,7 +315,9 @@ namespace Midori { search_entry.text = tab.get_find_controller ().get_search_text () ?? ""; search.visible = search_entry.text != ""; search.search_mode_enabled = search.visible; - goto_activated (); + if (navigationbar.urlbar.blank) { + navigationbar.urlbar.grab_focus (); + } return Source.REMOVE; }, Priority.LOW); } else { @@ -509,9 +511,7 @@ namespace Midori { void goto_activated () { if (!tab.pinned) { navigationbar.show (); - if (navigationbar.urlbar.blank) { - navigationbar.urlbar.grab_focus (); - } + navigationbar.urlbar.grab_focus (); } } |