'find in page' fails to focus address bar every second time
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Canonical System Image |
Fix Released
|
High
|
Bill Filler | ||
webbrowser-app (Ubuntu) |
Fix Released
|
High
|
Ugo Riboni |
Bug Description
Steps to reproduce:
1. Open the Web Browser
2. Open the Drawer widget on the top right corner
3. Select Find In Page
4. Confirm the address bar is focused (in find in page mode) and the keyboard appears
5. Press Back to return to normal browsing view
6. Open the Drawer widget again
7. Select Find In Page again
Expected result:
The address bar (in find in page mode) is focused and the keyboard appears
Actual result:
Find in page mode is active but the address bar is not focused and the keyboard does not appear
current build number: 152
device name: krillin
channel: ubuntu-
last update: 2015-10-18 22:11:48
version version: 152
version ubuntu: 20151016
version device: 20150821-736d127
version custom: 20150925-
Related branches
- Olivier Tilloy: Approve
- PS Jenkins bot: Approve (continuous-integration)
-
Diff: 105 lines (+25/-11)3 files modifiedsrc/app/webbrowser/AddressBar.qml (+7/-2)
src/app/webbrowser/Browser.qml (+6/-9)
tests/autopilot/webbrowser_app/tests/test_findinpage.py (+12/-0)
Changed in webbrowser-app (Ubuntu): | |
status: | New → Confirmed |
importance: | Undecided → High |
assignee: | nobody → Ugo Riboni (uriboni) |
Changed in webbrowser-app (Ubuntu): | |
status: | Confirmed → In Progress |
Changed in canonical-devices-system-image: | |
importance: | Undecided → High |
status: | New → Confirmed |
status: | Confirmed → In Progress |
assignee: | nobody → Bill Filler (bfiller) |
milestone: | none → ww46-2015 |
Changed in canonical-devices-system-image: | |
status: | In Progress → Fix Committed |
Changed in canonical-devices-system-image: | |
status: | Fix Committed → Fix Released |
After a bit of investigation, I understand what’s going on: the Chrome instance is a focus scope that proxies focus requests to the address bar, and it’s itself contained in a FocusScope. Setting focus to true on chrome doesn’t imply that the active focus will change, it only guarantees that the next time the active focus is set on the enclosing focus scope, chrome will receive it.
So the current code that does "chrome.focus = true" in the onTriggered handler of the "find in page" action should really do "chrome. forceActiveFocu s()".