Google search engine field stops resizing if suggestions change during animation

VERIFIED FIXED in Firefox 18

Status

()

Firefox for Android
General
VERIFIED FIXED
5 years ago
2 years ago

People

(Reporter: xti, Assigned: bnicholson)

Tracking

19 Branch
Firefox 20
ARM
Android
Points:
---

Firefox Tracking Flags

(firefox18 verified, firefox19 verified, firefox20 verified)

Details

Attachments

(3 attachments)

(Reporter)

Description

5 years ago
Created attachment 683080 [details]
screenshot

Firefox 19.0a1 (2012-11-19)
Device: Galaxy S2
OS: Android 4.0.3

Steps to reproduce:
1. Tap on URL Bar and type at least one character
2. Enable the Google search engine suggestions
3. Type an url address 

Expected result:
Google search engine field margins are resized to fit exactly all suggestions.

Actual result:
A blank space remains under the last remaining suggestion (see screenshot)
Is this a recent regression?
(Assignee)

Comment 2

5 years ago
I've been noticing this too. My first guess is that typing during the animation will disrupt it and prevent a resize from happening, though I don't know what recent change would have caused this.
Assignee: nobody → bnicholson
Status: NEW → ASSIGNED
(Assignee)

Comment 3

5 years ago
Created attachment 685425 [details] [diff] [review]
Ensure suggestion view parameters are reset if view is removed during animation

ListView reinflates its views whenever they change, so the AnimatedHeightLayout can be removed from the list if the user enters something during the animation. Apparently, this aborts the animation, and onAnimationEnd() is never called. As a result, the height layout param is never reset to WRAP_CONTENT.

By overriding onDetachedFromWindow(), we can guarantee that the animation callback is executed.
Attachment #685425 - Flags: review?(lucasr.at.mozilla)
(Assignee)

Updated

5 years ago
status-firefox18: --- → affected
status-firefox19: --- → affected
status-firefox20: --- → affected
Comment on attachment 685425 [details] [diff] [review]
Ensure suggestion view parameters are reset if view is removed during animation

Review of attachment 685425 [details] [diff] [review]:
-----------------------------------------------------------------

Ugh, ugly bug in Android. View simply sets current animation to null when detached from window (doesn't cancel the animation at all).
Attachment #685425 - Flags: review?(lucasr.at.mozilla) → review+
(Assignee)

Comment 5

5 years ago
Created attachment 685721 [details]
screenshot 2

If a letter is typed while the row is expanding, this can also cause entries to be cut off as shown in this screenshot.
(Assignee)

Updated

5 years ago
Summary: Google search engine field is not resized if only one suggestion remains → Google search engine field stops resizing if suggestions change during animation
(Assignee)

Updated

5 years ago
Blocks: 769145
(Assignee)

Comment 7

5 years ago
Comment on attachment 685425 [details] [diff] [review]
Ensure suggestion view parameters are reset if view is removed during animation

[Approval Request Comment]
Bug caused by (feature/regressing bug #): bug 769145 (Fx18)
User impact if declined: search suggestions UI can look broken (see screenshots)
Testing completed (on m-c, etc.): m-i
Risk to taking this patch (and alternatives if risky): low risk
String or UUID changes made by this patch: none
Attachment #685425 - Flags: approval-mozilla-beta?
Attachment #685425 - Flags: approval-mozilla-aurora?
https://hg.mozilla.org/mozilla-central/rev/e4c4d25441c9
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 20

Updated

5 years ago
status-firefox20: affected → fixed
(Reporter)

Comment 9

5 years ago
(In reply to Brian Nicholson (:bnicholson) from comment #5)
> Created attachment 685721 [details]
> screenshot 2
> 
> If a letter is typed while the row is expanding, this can also cause entries
> to be cut off as shown in this screenshot.

Is this related to Bug 813055? I can reproduce the same issue as yours on the latest Nightly build
status-firefox20: fixed → affected
(Reporter)

Comment 10

5 years ago
The fix works wonderful on the latest Nightly build. The Google search engine field resizes dynamic and smooth. Closing bug as verified fixed on:

Firefox 20.0a1 (2012-11-28)
Device: Galaxy Nexus
OS: Android 4.1.1
Status: RESOLVED → VERIFIED
status-firefox20: affected → verified
(Assignee)

Updated

5 years ago
Duplicate of this bug: 813055

Updated

5 years ago
Attachment #685425 - Flags: approval-mozilla-beta?
Attachment #685425 - Flags: approval-mozilla-beta+
Attachment #685425 - Flags: approval-mozilla-aurora?
Attachment #685425 - Flags: approval-mozilla-aurora+
(Assignee)

Comment 13

5 years ago
http://hg.mozilla.org/releases/mozilla-beta/rev/d985d487de38
status-firefox18: affected → fixed
(Reporter)

Comment 14

5 years ago
I cannot reproduce this issue anymore on the latest Aurora build. 

--
Firefox 19.0a2 (2012-11-29)
Device: Galaxy Nexus
OS: Android 4.1.1
status-firefox18: fixed → affected
status-firefox19: fixed → verified
(Reporter)

Comment 15

5 years ago
Also it works fine on the latest Beta build too
status-firefox18: affected → verified
You need to log in before you can comment on or make changes to this bug.