New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 724964 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug
Team-Accessibility



Sign in to add a comment

Accessibility zoom does not override touch-action filtering

Reported by oehrstr...@gmail.com, May 22 2017

Issue description

Steps to reproduce the problem:
1. Google something on google.
2. Selct an AMP marked page
3. Try to zoom! Fail!

What is the expected behavior?
The browser should respect the accessibility setting and allow the user to zoom.

What went wrong?
It does not zoom. 

Did this work before? No 

Chrome version:   Channel: n/a
OS Version: 
Flash Version: 

Google will eventually be the recipient of a ADA class action lawsuit if this is not fixed.
 
Cc: acindhe@chromium.org
Components: -UI UI>Accessibility
Labels: triage-te
Labels: Needs-Bisect
oehrstroem@ could you please provide chrome version, on which device & OS version you have observed this issue. And also could you please try on latest chrome version. Thanks 
Chrome 58.0.3029.83
Android 7.1.2 Nexus 5X Build/NG2G470
Also fails Chrome Beta 59.0.3071.71
Also fails Chrome Dev 60.0.3107.3

I.e. two-finger zoom works on all other pages, but not AMP pages.
(Yes, I have enabled Force Enable Zoom, for those pesky pages that block zoom.)
Cc: tedc...@chromium.org
Hi Ted,

can you help get this routed to the right person.  Issue 704920  is likely related.

Thanks

Patrick
Owner: aelias@chromium.org
Status: Available (was: Unconfirmed)
@aelias - any thoughts on why zoom is disabled there?
Components: Internals>Input>Touch>Screen
Owner: bokan@chromium.org
Status: Assigned (was: Available)
Pinch zoom still works very occasionally and it also works if the gesture starts on the top "position: fixed" bar.  I guessed this was probably touch event listeners, but I removed all of them in devtools inspector to no visible effect.  bokan@, any idea what's happening here?
Cc: aelias@chromium.org
Labels: -triage-te -Needs-Bisect
Status: Started (was: Assigned)
Cc: dtapu...@chromium.org
Labels: -Pri-2 Pri-3
This is caused not by touch event handlers but the document (inside the AMP iframe) setting `touch-action: pan-y`. Removing that or adding pinch-zoom allows zooming. We could prevent filtering of pinch gestures if the accessibility option is enabled but I'm a little worried this might break content in a bad way (e.g. double handling pinch-zooms on maps). I'm inclined to leave this as-is and poke AMP to fix their CSS, WDYT?

I was able to zoom (repeatedly zooming in quickly) occasionally but this appears to be a bug in our filtering, I filed issue 730110 to track that.
Cc: rbyers@chromium.org
It's strange to have to ask web developers to add "pinch-zoom" property to touch-action when they already disabled pinch zoom in their viewport tag anyway.  And I predict every site using "pan-y" for similar use case as AMP in the future will run into the same pitfall.

How about making the "Force Enable Zoom" setting disable pinch gesture filtering for pan-x/pan-y, but not for "none"?  The idea is that "none" is for use cases like maps or drawing apps which fully absorb the gesture input to do something totally different, whereas pan-x/pan-y are for scrollers with sidepanels.

Note another motivating problem here is the report in  http://crbug.com/704920  that users are actually trapped in the zoomed-in state on AMP if they zoomed in on the google.com search results in the first place.  This can only happen with the "Force Enable Zoom" setting.
That's a good point, touch-action: none is probably the one that would break content meaningfully but I think we could override filtering in all the other cases. 
Labels: Hotlist-Input-Dev

Comment 15 by bokan@chromium.org, Jun 13 2017

Owner: chaopeng@chromium.org
Status: Assigned (was: Started)
Summary: Accessibility zoom does not override touch-action filtering (was: Accessibility zoom does not work for accelerated mobile pages)
Chao, please take a look. The relevant filtering occurs in LegacyInputRouterImpl::SendGestureEvent via touch_action_filter_.FilterGestureEvent. If the "Force enable zoom" accessibility feature is on, we shouldn't filter out pinch events at all except for touch-action:none.
FWIW I agree that "force enable zoom" should effectively upgrade any touch-action other than 'none' to include 'pinch-zoom'.  This should be really easy to do I think.
Just tried turn on "Force enable zoom" in accessibility. I can zoom google.com search result. bokan@ do you have a test page for this?
You need to zoom in on google.com search results (e.g. search for "white house"), then tap on an AMP news result.  Then you are still zoomed in but can't zoom out from the AMP frame.
For a synthetic test case you can use https://rbyers.github.io/touch-action.html and try pinch-zooming on the various boxes there.
Labels: triage-laura
Labels: -Pri-3 -triage-laura Pri-2

Comment 22 Deleted

Note that the fundamental tradeoff here is one of web-compat.  We may break some sites with this option enabled.  Eg. imagine a maps-style application that happens to be using touch-action:pan-y (instead of none) for some reason, but doesn't actually have a page big enough to scroll.  Now when you pinch-zoom, the maps javascript will zoom the map, but with this setting on the browser will also zoom into the page resulting in a confusing a blurry double-zoom effect.

This would be a serious issue if we were going to override touch-action:none (same reason why we can't have "force enable zoom" override TouchEvent.preventDefault).  But as long as it's just the others, I think the compat risk is probably small enough to be outweighed by the net user-benefit.
Project Member

Comment 24 by bugdroid1@chromium.org, Aug 25 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292

commit e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292
Author: chaopeng <chaopeng@chromium.org>
Date: Fri Aug 25 00:35:26 2017

Support force enable zoom override css: touch-action

This patch is for Support force enable zoom override css: touch-action.
When user turn on force enable zoom, we will add pinch-zoom to touch-action
except touch-action: none. The idea is that "none" is for use cases like 
maps or drawing apps which fully absorb the gesture input to do something 
totally different, whereas pan-x/pan-y are for scrollers with sidepanels.

Bug:  724964 
Change-Id: Ie729214f94b6d28bebac9179ad1c9fd768ebc5f3
Reviewed-on: https://chromium-review.googlesource.com/608528
Reviewed-by: Dave Tapuska <dtapuska@chromium.org>
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Reviewed-by: David Bokan <bokan@chromium.org>
Commit-Queue: Jianpeng Chao <chaopeng@chromium.org>
Cr-Commit-Position: refs/heads/master@{#497264}
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/input_router.h
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/input_router_impl.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/input_router_impl.h
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/legacy_input_router_impl.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/legacy_input_router_impl.h
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/touch_action_filter.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/touch_action_filter.h
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/input/touch_action_filter_unittest.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/render_view_host_impl.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/render_widget_host_impl.cc
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/render_widget_host_impl.h
[modify] https://crrev.com/e5f829bbdba5f46dc48161f2c8cc8ea2c8c5f292/content/browser/renderer_host/render_widget_host_unittest.cc

Status: Fixed (was: Assigned)

Sign in to add a comment