Closed Bug 906427 Opened 11 years ago Closed 11 years ago

Disallow pinch-zoom on subframes

Categories

(Core :: Graphics: Layers, defect)

26 Branch
All
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla26

People

(Reporter: kats, Assigned: kats)

Details

Attachments

(1 file)

With the multi-apzc code, pinch zooming is allowed in subframes, even though the RequestContentRepaint handler will not update gecko with this. This results in being able to zoom into iframes and have them render blurry. We should add a method on the GeckoContentController that tells the APZC whether or not to allow zooming on non-root APZCs for a given layers id.
What would determine whether or not we allow zooming for subframes?
In general we don't want the APZC to zoom something if the content controller cannot repaint it at the requested zoom. Also we don't want to zoom something if UX decided it should not be zoomable. When I first filed this bug I was really only thinking about web content in the B2G browser but if we're going to turn on APZC for all apps then I'll need to rethink this.
Attached patch Simple fixSplinter Review
This applies on top of the patches in bug 898443. Since I don't really have a good understanding yet of all ways in which we want to control this behaviour I decided to just go with the simplest thing and always push pinches up to the root APZC for a given layers id. For the B2G browser this means that pinches in the content area will always be done on the root content document rather than iframes.
Attachment #793141 - Flags: review?(bgirard)
Attachment #793141 - Flags: review?(bgirard) → review+
I just realized that this doesn't prevent double-tap on subframes, which will also trigger a subframe zoom. Not sure what the best way to handle that is.
Actually the GeckoContentController can (and should by default) direct the ZoomToRect call to the root layer APZC. We just need to ensure that it maintains that behaviour going forward. https://hg.mozilla.org/integration/b2g-inbound/rev/317c2317495d
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: