Closed Bug 772743 Opened 12 years ago Closed 12 years ago

Add pref to prevent top level widget going fullscreen in b2g desktop client

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla16

People

(Reporter: cpearce, Assigned: cpearce)

References

Details

Attachments

(1 file)

For the b2g desktop client we'd like a pref to toggle that prevents the top-level widget from going fullscreen when content enters dom fullscreen mode. This is to stop the B2G desktop client window (and thus content) from taking up the entire screen of the host OS; the content should instead resize to completely fill the client window.

Without this, the app running in the b2g desktop client gets impression that the (emulated) device's screen spontaneously grows when entering fullscreen, which obviously doesn't happen on physical hardware!

cjones is vehement that he'd prefer a pref rather than just relying on #defines here...
Add pref to prevent the top level widget entering fullscreen. Set it to true for b2g desktop client.
Attachment #640919 - Flags: review?(mounir)
Comment on attachment 640919 [details] [diff] [review]
Bug 772743 - Add pref to not make the widget fullscreen when entering fullscreen. Set it to true for b2g desktop client.

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

r=me with the comment added.

::: dom/base/nsGlobalWindow.cpp
@@ +4477,5 @@
>    // Set this before so if widget sends an event indicating its
>    // gone full screen, the state trap above works.
>    mFullScreen = aFullScreen;
>  
> +  if (!Preferences::GetBool("full-screen-api.ignore-widgets", false)) {

Can you add a quick comment explaining why you are checking that pref here so reader will not have to go to b2g.js to understand (which might not be obvious because nothing says this is related to b2g).
Attachment #640919 - Flags: review?(mounir) → review+
Landed with comment added:
https://hg.mozilla.org/integration/mozilla-inbound/rev/e3f2d02b21b9
Target Milestone: --- → mozilla16
https://hg.mozilla.org/mozilla-central/rev/e3f2d02b21b9
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: