Last Comment Bug 664114 - Context Menu doesn't resize properly when switching the window orientation
: Context Menu doesn't resize properly when switching the window orientation
Status: VERIFIED FIXED
[regression][fennec 5.0b6]
: verified-beta
Product: Fennec Graveyard
Classification: Graveyard
Component: General (show other bugs)
: Firefox 5
: ARM Android
: -- normal (vote)
: Firefox 7
Assigned To: Mark Finkle (:mfinkle) (use needinfo?)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-14 05:05 PDT by Cristian Nicolae (:xti)
Modified: 2015-03-24 18:23 PDT (History)
17 users (show)
See Also:
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
screenshot (43.00 KB, image/png)
2011-06-14 05:20 PDT, Cristian Nicolae (:xti)
no flags Details
patch (10.94 KB, patch)
2011-06-14 12:48 PDT, Mark Finkle (:mfinkle) (use needinfo?)
wjohnston2000: review+
Details | Diff | Splinter Review
patch for beta (2.08 KB, patch)
2011-06-14 15:04 PDT, Mark Finkle (:mfinkle) (use needinfo?)
wjohnston2000: review+
mbrubeck: review+
mark.finkle: approval‑mozilla‑beta+
Details | Diff | Splinter Review

Description Cristian Nicolae (:xti) 2011-06-14 05:05:25 PDT
Build id : Mozilla/5.0 (Android;Linux armv7l;rv:5.0)Gecko/20110613
Firefox/5.0 Fennec/5.0
Device: Motorola Droid 2
OS: Android 2.2

Steps to reproduce:
1. Open Fennec app
2. Go to http://slickdeals.net/
3. Long tap on Tap and hold down on the Slickdeals banner image link
4. Switch device to landscape

Expected result:
Context Menu resize properly due to device orientation changes at step 4.

Actual result:
The Context Menu does not resize when switching the orientation.
Comment 1 Cristian Nicolae (:xti) 2011-06-14 05:20:09 PDT
Created attachment 539179 [details]
screenshot
Comment 2 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-14 06:51:30 PDT
What's wrong with the screen shot? It seems like the context menu has changed it's size, right?
Comment 3 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-14 06:52:25 PDT
Oh, I see what you mean. The height overflows.
Comment 4 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-14 12:48:28 PDT
Created attachment 539289 [details] [diff] [review]
patch

I found two problems: menu overflows and context hint (the url on first row) is white-on-white

Fixes in this patch include:
* Adds the color / background-color to the right elements (context-header gets the background and share-hint / context-hint get color)
* Fixes the overflow issue by adding display: -moz-box to the context-commands richlistbox

The match syncs the contextmenu and the menulist behaviors a bit too:
* Adds flex to the container for the context container
* Makes sizeToContent use the container padding to create the width for the popup
* Makes sure sizetoContent is called before we make the panels visible, in case the richlistitems are larger than the window. We need to resize before they are visible or the UI will pan.
Comment 5 Wesley Johnston (:wesj) 2011-06-14 14:39:51 PDT
Comment on attachment 539289 [details] [diff] [review]
patch

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

Looks good!

::: mobile/chrome/content/common-ui.js
@@ +1220,1 @@
>    },

Can we rename this._panel to this._container?
Comment 6 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-14 15:04:05 PDT
Created attachment 539333 [details] [diff] [review]
patch for beta

minimal fix needed to fix the overflow in mozilla-beta
Comment 7 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-14 15:12:13 PDT
Comment on attachment 539333 [details] [diff] [review]
patch for beta

minimal beta patch. fennec-only. no nays from IRC and beta triage meeting.
Comment 8 Philipp von Weitershausen [:philikon] 2011-06-15 02:15:17 PDT
Backed out in http://hg.mozilla.org/integration/mozilla-inbound/rev/d05a24569346 due to a persistent failure in dom/tests/mochitest/dom-level0/test_innerWidthHeight_script.html on Android opt.
Comment 9 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-15 06:27:17 PDT
(In reply to comment #8)
> Backed out in
> http://hg.mozilla.org/integration/mozilla-inbound/rev/d05a24569346 due to a
> persistent failure in
> dom/tests/mochitest/dom-level0/test_innerWidthHeight_script.html on Android
> opt.

Wes - can you think of any reason for this failure?
Comment 10 Aaron Train [:aaronmt] 2011-06-15 06:42:14 PDT
Verifying Fixed on the beta channel
http://hg.mozilla.org/releases/mozilla-beta/rev/6eb872ce9e29

Mozilla/5.0 (Android; Linux armv7l; rv:5.0) Gecko/20110614 Firefox/5.0 Fennec/5.0

Leaving open re-landing on mozilla-inbound.
Comment 11 Mark Finkle (:mfinkle) (use needinfo?) 2011-06-15 06:54:07 PDT
(In reply to comment #8)
> Backed out in
> http://hg.mozilla.org/integration/mozilla-inbound/rev/d05a24569346 due to a
> persistent failure in
> dom/tests/mochitest/dom-level0/test_innerWidthHeight_script.html on Android
> opt.

Philipp - I notice the test failed for your backout too. Could it be intermittent?
Comment 12 Phil Ringnalda (:philor) 2011-06-15 08:31:48 PDT
My guess would be the other patch in the same push, http://hg.mozilla.org/integration/mozilla-inbound/rev/b9ee105d755c

And note that you don't actually have just one test failure, you have that one, plus a timeout in browser_thumbnails.js that's being called intermittent but is actually permanent, and a timeout in twinopen.
Comment 13 Mounir Lamouri (:mounir) 2011-06-16 05:24:59 PDT
Pushed to m-c:
http://hg.mozilla.org/mozilla-central/rev/19e4a93ebff5
Comment 14 Anna (Waverley) 2011-06-21 06:47:10 PDT
VERIFIED FIXED on:

Mozilla /5.0 (Android;Linux armv7l;rv:7.0a1) Gecko/20110621 Firefox/7.0a1 Fennec/7.0a1 

Device: HTC Desire Z(Android 2.2)

Note: "Not fixed on aurora"

Note You need to log in before you can comment on or make changes to this bug.