Closed
Bug 775211
Opened 13 years ago
Closed 13 years ago
Custom menu is a tad slower to expand on initial invoke in Jellybean (Android 4.1)
Categories
(Firefox for Android Graveyard :: General, defect)
Tracking
(firefox15+ fixed, firefox16+ verified, firefox17+ verified)
VERIFIED
FIXED
Firefox 17
People
(Reporter: aaronmt, Unassigned)
References
Details
(Whiteboard: [jellybean])
Attachments
(1 file)
2.05 KB,
patch
|
mbrubeck
:
review+
lsblakk
:
approval-mozilla-aurora+
lsblakk
:
approval-mozilla-beta+
|
Details | Diff | Splinter Review |
Load up a new profile of Fennec on Jellybean 4.1.x and open the custom menu - in comparison to ICS it 'inflates' a tad slower the first time.
Tested via:
--
Nightly (07/18)
Galaxy Nexus (Android 4.1.1)
Reporter | ||
Updated•13 years ago
|
status-firefox15:
--- → affected
status-firefox16:
--- → affected
status-firefox17:
--- → affected
Whiteboard: [jellybean]
Comment 1•13 years ago
|
||
The problem was depending on child's height -- which is 0 until it is shown for the first time -- which caused the problem.
Hence the ScrollView measured a 0, and then the actual height -- showing the flickering.
Instead, this does an AT_MOST call on preferred height of 75% of screen height. This fixes the problem.
Attachment #645548 -
Flags: review?(mbrubeck)
Comment 3•13 years ago
|
||
Moving the tracking flags over from bug 767668.
Comment 4•13 years ago
|
||
Comment on attachment 645548 [details] [diff] [review]
Patch
Nice!
> protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
>+ super.onMeasure(widthMeasureSpec, heightMeasureSpec);
>
> DisplayMetrics metrics = new DisplayMetrics();
> ((Activity) GeckoApp.mAppContext).getWindowManager().getDefaultDisplay().getMetrics(metrics);
>
> // heightPixels changes during rotation.
>+ int restrictedHeightSpec = MeasureSpec.makeMeasureSpec((int) (0.75 * metrics.heightPixels), MeasureSpec.AT_MOST);
>
> super.onMeasure(widthMeasureSpec, restrictedHeightSpec);
> }
We're calling super.onMeasure twice now. Is the first call still useful, or should it be removed?
Attachment #645548 -
Flags: review?(mbrubeck) → review+
Comment 5•13 years ago
|
||
The first call is still useful. I still removing it and it failed.
So (from my understanding), the first call makes the size to be 100% of its children (which may fill the entire screen). The second call restricts the height to 75%.
We do super.onMeasure() which takes care of setMeasuredDimension().
Comment 6•13 years ago
|
||
Comment 7•13 years ago
|
||
Comment on attachment 645548 [details] [diff] [review]
Patch
[Approval Request Comment]
Bug caused by (feature/regressing bug #): -
User impact if declined: The menu will take time to show in JB. HTC will have visual glitches.
Testing completed (on m-c, etc.): Landed in m-i on 07/24
Risk to taking this patch (and alternatives if risky): None.
String or UUID changes made by this patch: None.
Attachment #645548 -
Flags: approval-mozilla-beta?
Attachment #645548 -
Flags: approval-mozilla-aurora?
Comment 8•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 17
Comment 9•13 years ago
|
||
Comment on attachment 645548 [details] [diff] [review]
Patch
no risk, mobile only - approving.
Attachment #645548 -
Flags: approval-mozilla-beta?
Attachment #645548 -
Flags: approval-mozilla-beta+
Attachment #645548 -
Flags: approval-mozilla-aurora?
Attachment #645548 -
Flags: approval-mozilla-aurora+
Updated•13 years ago
|
Comment 10•13 years ago
|
||
Pushed to aurora:
https://hg.mozilla.org/releases/mozilla-aurora/rev/540cd72d8445
Comment 11•13 years ago
|
||
Pushed to beta:
https://hg.mozilla.org/releases/mozilla-beta/rev/686479fc0e26
Updated•13 years ago
|
Reporter | ||
Updated•13 years ago
|
Comment 12•13 years ago
|
||
I am still seeing bug 767668 (duplicate of this bug) in Beta. Did the beta update of 7/27 include Sriram's fixes?
Comment 13•13 years ago
|
||
(In reply to Daniel Asarnow from comment #12)
> I am still seeing bug 767668 (duplicate of this bug) in Beta. Did the beta
> update of 7/27 include Sriram's fixes?
No, it didn't. This fix will be included in the next beta update (probably later this week).
Assignee | ||
Updated•5 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•