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

Issue 644162 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
inactive
Closed: Oct 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 2
Type: Bug-Regression



Sign in to add a comment

W3C Gamepad API broken on Android

Reported by aicomman...@gmail.com, Sep 6 2016

Issue description

Steps to reproduce the problem:
1. Connect a Bluetooth gamepad to your Android device
2. Go to http://html5gamepad.com and press some buttons

What is the expected behavior?
Gamepad input should appear on the site.

What went wrong?
Gamepad input doesn't appear on the site.

Did this work before? Yes Confirmed working in 411370, confirmed broken in the next build 411386. Likely cause is: https://chromium.googlesource.com/chromium/src.git/+/667f05771b5c1275f87599076d222c0ed21ba22b 

Chrome version: 54.0.2840.6  Channel: dev
OS Version: 7.0
Flash Version: Shockwave Flash 22.0 r0

Android 7.0.0; Pixel C Build/NRD90M
 
Functionality returns with the attached patch. bajones@ I'm not sure if you believe more bugs like that might be lurking in the refactoring. If not, I can put that up for review or let you take care of the fix yourself.
android_data_fetcher.diff
472 bytes Download

Comment 2 by tkent@chromium.org, Sep 6 2016

Components: Blink>GamepadAPI
This bug has now escaped into Chrome Beta. Can this be assigned to someone familar with gamepad like bajones or aelias?

Comment 4 by aelias@chromium.org, Sep 18 2016

Cc: aelias@chromium.org bajones@chromium.org
Owner: bajones@chromium.org
Status: Assigned (was: Unconfirmed)
Sorry, the GamepadAPI label doesn't have a good triage rotation so no one saw this bug until you posted the code review.  Feel free to cc bajones@chromium.org and me directly next time you file a bug.

Comment 5 by aelias@chromium.org, Sep 18 2016

Cc: -bajones@chromium.org
Labels: M-54 ReleaseBlock-Stable
Does this mean all bluetooth gamepads effectively don't work at all on Android anymore (please confirm)?  If so, I think this qualifies for stable blocker.

Comment 6 by aelias@chromium.org, Sep 18 2016

For reference, the patch in #1 was uploaded as https://codereview.chromium.org/2350573002/.
Gamepads can still scroll the page, but the Gamepad API itself doesn't work at all on Android.
The same commit that caused this break is also to blame for a failed assert when disconnecting a gamepad on all platforms (except Android due to this bug). See issue 644170. 
Confirming, no bluetooth gamepads working on Android. At all. 
And seems like the patch by aelias@chromium.org (https://codereview.chromium.org/2350573002/) works! Thanks! Unblocked now.
Brandon, as this is a 54 stable blocker, I'd just like to double-check you're going to look into this soon?  The fix is already known and this just needs a unit test.
[Bulk edit]

This issue is listed as a release block stable for M54 Android.  We'll be cutting our stable candidate in just about two weeks, so time is running out to fix this bug - please prioritize working on it ASAP.

Are you sure this issue shouldn't block the release?  Remove the ReleaseBlock-Stable label.
Unsure if this issue should block the release, or know the issue should block the release but we won't be able to fix it in time?  CC me so that we can discuss.

Thanks!
Cc: -aelias@chromium.org bajones@chromium.org
Owner: aelias@chromium.org
Over to aelias@ since bajones@ is out on paternity.
Labels: Merge-Request-54
Merge request for https://codereview.chromium.org/2350573002/ (currently in CQ)
Project Member

Comment 15 by bugdroid1@chromium.org, Oct 4 2016

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

commit 4b5f513335e161aa156e0114b052e18a96e44871
Author: aicommander <aicommander@gmail.com>
Date: Tue Oct 04 21:48:14 2016

Fix gamepad connected status on Android

Commit 667f05771b5c1275f87599076d222c0ed21ba22b created a regression
in gamepad API functionality on Android by removing the assignment
that sets the gamepad.connected value. This CL adds the missing
assignment back.

BUG= 644162 

Review-Url: https://codereview.chromium.org/2350573002
Cr-Commit-Position: refs/heads/master@{#422947}

[modify] https://crrev.com/4b5f513335e161aa156e0114b052e18a96e44871/device/gamepad/gamepad_platform_data_fetcher_android.cc

Comment 16 by dimu@chromium.org, Oct 4 2016

Labels: -Merge-Request-54 Merge-Approved-54 Hotlist-Merge-Approved
Your change meets the bar and is auto-approved for M54 (branch: 2840)
Project Member

Comment 17 by bugdroid1@chromium.org, Oct 4 2016

Labels: -merge-approved-54 merge-merged-2840
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7f13318172fe5e10b45db45326106d84c3b8c1fc

commit 7f13318172fe5e10b45db45326106d84c3b8c1fc
Author: Alexandre Elias <aelias@chromium.org>
Date: Tue Oct 04 22:09:04 2016

Fix gamepad connected status on Android

Commit 667f05771b5c1275f87599076d222c0ed21ba22b created a regression
in gamepad API functionality on Android by removing the assignment
that sets the gamepad.connected value. This CL adds the missing
assignment back.

BUG= 644162 

Review-Url: https://codereview.chromium.org/2350573002
Cr-Commit-Position: refs/heads/master@{#422947}
(cherry picked from commit 4b5f513335e161aa156e0114b052e18a96e44871)

Review URL: https://codereview.chromium.org/2390233005 .

Cr-Commit-Position: refs/branch-heads/2840@{#640}
Cr-Branched-From: 1ae106dbab4bddd85132d5b75c670794311f4c57-refs/heads/master@{#414607}

[modify] https://crrev.com/7f13318172fe5e10b45db45326106d84c3b8c1fc/device/gamepad/gamepad_platform_data_fetcher_android.cc

Status: Fixed (was: Assigned)
Marking fixed, the unit test question can be resolved as part of  http://crbug.com/147549 
Project Member

Comment 19 by bugdroid1@chromium.org, Oct 27 2016

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

commit 7f13318172fe5e10b45db45326106d84c3b8c1fc
Author: Alexandre Elias <aelias@chromium.org>
Date: Tue Oct 04 22:09:04 2016

Fix gamepad connected status on Android

Commit 667f05771b5c1275f87599076d222c0ed21ba22b created a regression
in gamepad API functionality on Android by removing the assignment
that sets the gamepad.connected value. This CL adds the missing
assignment back.

BUG= 644162 

Review-Url: https://codereview.chromium.org/2350573002
Cr-Commit-Position: refs/heads/master@{#422947}
(cherry picked from commit 4b5f513335e161aa156e0114b052e18a96e44871)

Review URL: https://codereview.chromium.org/2390233005 .

Cr-Commit-Position: refs/branch-heads/2840@{#640}
Cr-Branched-From: 1ae106dbab4bddd85132d5b75c670794311f4c57-refs/heads/master@{#414607}

[modify] https://crrev.com/7f13318172fe5e10b45db45326106d84c3b8c1fc/device/gamepad/gamepad_platform_data_fetcher_android.cc

Sign in to add a comment