Closed Bug 1667497 Opened 4 years ago Closed 4 years ago

Tap on input field does not result in zooming on StackOverflow jobs page

Categories

(GeckoView :: IME, defect, P1)

Unspecified
All
defect

Tracking

(firefox83 fixed)

RESOLVED FIXED
83 Branch
Tracking Status
firefox83 --- fixed

People

(Reporter: botond, Assigned: agi)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [geckoview:m83])

Attachments

(2 files)

STR

  1. Navigate to https://stackoverflow.com/jobs/apply/416113?reset=False&ra=2fybyLHT9J7i&oqs=a%3D2fybyLHT9J7i%26so%3Dp%26sec%3DFalse%26pg%3D1%26offset%3D5%26total%3D5924%26srp%3DTrue%26so_medium%3DInternal%26so_source%3DJobSearchPreview%26_%3D1600791325104 in GVE.
  2. Request desktop site. Observe that the resulting form is zoomed out with the form fields and labels fairly small.
  3. Tap on the "Location" input field.

Expected results

The tap triggers zooming in on the input field (and shows the keyboard).

Actual results

The keyboard is shown but no zooming occurs.

I got a regression window with GVE and it pointed to bug 1648149.

Flags: needinfo?(agi)
Attached file zoom-to-input.html

Thanks Botond! Minimal testcase. Patch incoming.

Flags: needinfo?(agi)

The regression from bug 1648149 can be fixed with the following:

--- a/mobile/android/actors/GeckoViewContentChild.jsm
+++ b/mobile/android/actors/GeckoViewContentChild.jsm
@@ -159,7 +161,7 @@ class GeckoViewContentChild extends GeckoViewActorChild {
         const onResize = function() {
           gotResize = true;
           if (dwu.isMozAfterPaintPending) {
-            contentWindow.addEventListener(
+            contentWindow.windowRoot.addEventListener(
               "MozAfterPaint",
               () => zoomToFocusedInput(),
               { capture: true, once: true }

But I still see issues with the testcase in Comment 1 (most of the times the text field is not visible).

Botond said on matrix he would take a look, feel free to reassign.

Assignee: nobody → botond
Priority: -- → P1
Whiteboard: [geckoview:m83]

(In reply to Agi Sferro | :agi | ⏰ PST | he/him from comment #2)

But I still see issues with the testcase in Comment 1 (most of the times the text field is not visible).

Botond said on matrix he would take a look, feel free to reassign.

Thanks for finding this issue, Agi. I agree, it looks like a bug in zoomToFocusedInput.

That said, this is a pre-existing issue (it's been broken since before bug 1648149), and it does not come up in the original STR (which works fine with your fix to GeckoViewContentChild.jsm).

So, my suggestion would be to:

  • land your fix to GeckoViewContentChild.jsm in this bug
  • file another bug to track this pre-existing issue (which I will look into further)

Does that sound reasonable?

Flags: needinfo?(agi)
Blocks: 1669588

Sounds good! Opened Bug 1669588.

Flags: needinfo?(agi)
Pushed by asferro@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fcef5f74af97 Listen for MozAfterPaint on windowRoot. r=owlish
Status: NEW → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → 83 Branch
Assignee: botond → agi
Has Regression Range: --- → yes
Keywords: regression

Moving some input bugs to the new GeckoView::IME component.

Component: General → IME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: