Closed Bug 1890848 Opened 7 months ago Closed 4 months ago

[toolbar redesign] The nav bar should automatically appear when closing the keyboard.

Categories

(Fenix :: Toolbar, task, P1)

All
Android
task

Tracking

(firefox129 fixed)

RESOLVED FIXED
129 Branch
Tracking Status
firefox129 --- fixed

People

(Reporter: royang, Assigned: mavduevskiy)

References

Details

(Whiteboard: [fxdroid])

Attachments

(6 files)

No description provided.
Severity: -- → N/A
Whiteboard: [fxdroid]
Summary: The nav bar should automatically appear when closing the keyboard. → [toolbar redesign] The nav bar should automatically appear when closing the keyboard.
Duplicate of this bug: 1895605

Setting toolbar redesign's Beta experiment blockers to priority P2 until we finish fixing our Nightly blockers.

Priority: -- → P2
Assignee: nobody → mavduevskiy
Assignee: mavduevskiy → nobody
Assignee: nobody → mavduevskiy

Nightly blocker

Priority: P2 → P1

likely gets fixed by 1898059

The function is duplicated in Home and Browser fragments and being used to determine if the address bar is positioned at the bottom. Moving it into an extensions reduces code fragility, as well as allowing other components, not just fragments, to reliably check the address bar position.

Attachment #9405360 - Attachment description: Bug 1890848 - Refactor isToolbarAtBottom into an extension function → WIP: Bug 1890848 - Refactor isToolbarAtBottom into an extension function
Attachment #9405383 - Attachment description: Bug 1890848 – Show the navbar when keyboard is hidden → WIP: Bug 1890848 – Show the navbar when keyboard is hidden
Attachment #9405360 - Attachment description: WIP: Bug 1890848 - Refactor isToolbarAtBottom into an extension function → Bug 1890848 - Refactor isToolbarAtBottom into an extension function
Attachment #9405383 - Attachment description: WIP: Bug 1890848 – Show the navbar when keyboard is hidden → Bug 1890848 – Show the navbar when keyboard is hidden
Pushed by mavduevskiy@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b1bbdbf70ab0 Refactor isToolbarAtBottom into an extension function r=android-reviewers,gl https://hg.mozilla.org/integration/autoland/rev/5b84e9134dc9 – Show the navbar when keyboard is hidden r=android-reviewers,gmalekpour
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 129 Branch

found a use case missed:
opening a tab through tabs tray and closing keyboard

Status: RESOLVED → REOPENED
Resolution: FIXED → ---

A mechanism that prevents the navbar from being drawn in case the home page is opened with intent to focus addressbar automatically (which cases glitching), was setting visibility to the compose view, but BottomToolbarContainerIntegration was managing visibility using the container. Using the container looks more appropriate.

Restricting access to compose view, so that visibility of the container would be managed through container view only.

Attachment #9409620 - Attachment description: WIP: Bug 1890848 - part1, Show keyboard after keyboard is dismissed → Bug 1890848 - part1, Show keyboard after keyboard is dismissed
Attachment #9409621 - Attachment description: WIP: Bug 1890848 - part2, Refactor BottomToolbarContainerView → Bug 1890848 - part2, Refactor BottomToolbarContainerView
Attachment #9409620 - Attachment description: Bug 1890848 - part1, Show keyboard after keyboard is dismissed → Bug 1890848 - part1, Show navbar after keyboard is dismissed
Attachment #9409620 - Attachment description: Bug 1890848 - part1, Show navbar after keyboard is dismissed → WIP: Bug 1890848 - part1, Show navbar after keyboard is dismissed
Attachment #9409621 - Attachment description: Bug 1890848 - part2, Refactor BottomToolbarContainerView → WIP: Bug 1890848 - part2, Refactor BottomToolbarContainerView to restrict access to the compose view parameter
Attachment #9409620 - Attachment description: WIP: Bug 1890848 - part1, Show navbar after keyboard is dismissed → Bug 1890848 - part1, Show navbar after keyboard is dismissed
Attachment #9409621 - Attachment description: WIP: Bug 1890848 - part2, Refactor BottomToolbarContainerView to restrict access to the compose view parameter → Bug 1890848 - part2, Refactor BottomToolbarContainerView to restrict access to the compose view parameter
Pushed by mavduevskiy@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0937386f87e4 part1, Show navbar after keyboard is dismissed r=android-reviewers,tchoh https://hg.mozilla.org/integration/autoland/rev/67d1ccd7b83d part2, Refactor BottomToolbarContainerView to restrict access to the compose view parameter r=android-reviewers,skhan
Status: REOPENED → RESOLVED
Closed: 5 months ago4 months ago
Resolution: --- → FIXED
Attached video 1000067570.mp4

This bug reappeared. Attached video.

Flags: needinfo?(mavduevskiy)

hey, Aarjav!

What's the behaviour that you would expect in this case? The use case you recorded.

From engineering perspective, it works correctly and the issue lies in a different tech realm – it should be fixed here.

In short, it has to do with the way android OS is handling the hiding keyboard. When navigation in OS is set through gestures, not navigation bar, the hide keyboard button hides the keyboard but the focused element still holds the focus. You can see this behaviour across all android apps, except – ironically – Chrome. But other browsers I tested, Google app, gphotos and gmail treat hiding the keyboard just as hiding the keyboard, focused element retains focus.

And that's the bug you noticed – the keyboard is hidden, but the toolbar is still focused (you can see the cursor is still there), and it takes a second back gesture to actually close the toolbar in edit mode and go back to display mode.

The behaviour is different if you switch system navigation to button navigation. It will work as you expect.

Overriding system behaviour here isn't straightforward, but it's something we have as a todo thing.

Flags: needinfo?(mavduevskiy)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: