Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(47)

Issue 2563483006: Move gamepad_service out of content/ and into device/ (Closed)

Created:
4 years ago by ke.he
Modified:
4 years ago
Reviewers:
Tom Sepez, bajones, jam, blundell
CC:
chromium-reviews, mlamouri+watch-content_chromium.org, creis+watch_chromium.org, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, nasko+codewatch_chromium.org, jam, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, fuzzing_chromium.org, darin-cc_chromium.org, darin (slow to review)
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Move gamepad_service out of content/ and into device/ This patch is a subtask of "Decoupling Gamepad from //content". In this patch the GamepadService, GamepadServiceUnittest, GamepadMonitor and GamepadSharedBuffer are moved out of content/browser/gamepad or render_host, and into device/gamepad/. The file //content/common/gamepad_hardware_buffer.h is removed, we move the definition of GamepadHardwareBuffer into gamepad_shared_memory.h, and change its definition by using generic SharedMemorySeqLockBuffer<blink::WebGamepads>. In the unittest of GamepadProvider, we don't pass a MockSharedMemoryBuffer (which has no seqlock controls) anymore. GamepadProvider will create a SharedMemoryBuffer by default in its constructor, so we add the seqlock-read accordingly in its unittest. Based on a patch by bajones@chromium.org. BUG = 612330 Committed: https://crrev.com/bee6a64bd524847e541f6ef11c73c0328094b9d3 Cr-Commit-Position: refs/heads/master@{#437716}

Patch Set 1 : Move gamepad_service out of content/ and into device/ #

Total comments: 7

Patch Set 2 : addressed Blundell's review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+277 lines, -973 lines) Patch
M content/browser/BUILD.gn View 3 chunks +0 lines, -7 lines 0 comments Download
M content/browser/browser_main_loop.cc View 3 chunks +2 lines, -2 lines 0 comments Download
D content/browser/gamepad/OWNERS View 1 chunk +0 lines, -2 lines 0 comments Download
D content/browser/gamepad/gamepad_service.h View 1 chunk +0 lines, -143 lines 0 comments Download
D content/browser/gamepad/gamepad_service.cc View 1 chunk +0 lines, -197 lines 0 comments Download
D content/browser/gamepad/gamepad_service_test_helpers.h View 1 chunk +0 lines, -38 lines 0 comments Download
D content/browser/gamepad/gamepad_service_test_helpers.cc View 1 chunk +0 lines, -22 lines 0 comments Download
D content/browser/gamepad/gamepad_service_unittest.cc View 1 chunk +0 lines, -137 lines 0 comments Download
D content/browser/gamepad/gamepad_shared_buffer_impl.h View 1 chunk +0 lines, -35 lines 0 comments Download
D content/browser/gamepad/gamepad_shared_buffer_impl.cc View 1 chunk +0 lines, -46 lines 0 comments Download
D content/browser/renderer_host/gamepad_monitor.h View 1 chunk +0 lines, -44 lines 0 comments Download
D content/browser/renderer_host/gamepad_monitor.cc View 1 chunk +0 lines, -65 lines 0 comments Download
M content/browser/renderer_host/pepper/pepper_gamepad_host.h View 4 chunks +6 lines, -3 lines 0 comments Download
M content/browser/renderer_host/pepper/pepper_gamepad_host.cc View 2 chunks +3 lines, -3 lines 0 comments Download
M content/browser/renderer_host/pepper/pepper_gamepad_host_unittest.cc View 3 chunks +10 lines, -9 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 3 chunks +2 lines, -2 lines 0 comments Download
M content/common/BUILD.gn View 1 chunk +0 lines, -1 line 0 comments Download
D content/common/gamepad_hardware_buffer.h View 1 chunk +0 lines, -34 lines 0 comments Download
M content/renderer/gamepad_shared_memory_reader.h View 2 chunks +3 lines, -1 line 0 comments Download
M content/renderer/gamepad_shared_memory_reader.cc View 2 chunks +3 lines, -4 lines 0 comments Download
M content/test/BUILD.gn View 1 chunk +0 lines, -3 lines 0 comments Download
M device/BUILD.gn View 1 chunk +1 line, -0 lines 0 comments Download
M device/gamepad/BUILD.gn View 3 chunks +9 lines, -0 lines 0 comments Download
A + device/gamepad/gamepad_monitor.h View 2 chunks +13 lines, -11 lines 0 comments Download
A + device/gamepad/gamepad_monitor.cc View 2 chunks +7 lines, -10 lines 0 comments Download
M device/gamepad/gamepad_provider.h View 1 chunk +0 lines, -2 lines 0 comments Download
M device/gamepad/gamepad_provider.cc View 3 chunks +3 lines, -5 lines 0 comments Download
M device/gamepad/gamepad_provider_unittest.cc View 1 4 chunks +54 lines, -34 lines 0 comments Download
A + device/gamepad/gamepad_service.h View 5 chunks +15 lines, -14 lines 0 comments Download
A + device/gamepad/gamepad_service.cc View 10 chunks +36 lines, -43 lines 0 comments Download
A + device/gamepad/gamepad_service_unittest.cc View 1 6 chunks +8 lines, -12 lines 0 comments Download
M device/gamepad/gamepad_shared_buffer.h View 1 chunk +27 lines, -5 lines 0 comments Download
A device/gamepad/gamepad_shared_buffer.cc View 1 chunk +42 lines, -0 lines 0 comments Download
M device/gamepad/gamepad_test_helpers.h View 3 chunks +21 lines, -16 lines 0 comments Download
M device/gamepad/gamepad_test_helpers.cc View 1 chunk +10 lines, -21 lines 0 comments Download
M device/gamepad/public/interfaces/gamepad.mojom View 1 chunk +1 line, -1 line 0 comments Download
M ppapi/shared_impl/ppb_gamepad_shared.h View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 33 (21 generated)
ke.he
Hi, blundell@, This CL is almost a "copy" from CL (https://codereview.chromium.org/2466073002/), the owner is bajones@. ...
4 years ago (2016-12-09 07:44:55 UTC) #8
blundell
LGTM, thanks! Please add to the bottom of the CL description something like: "Based on ...
4 years ago (2016-12-09 13:35:22 UTC) #9
ke.he
blundell@, thanks very much. CL updated. jam@, Could PTAL on those files in content/ and ...
4 years ago (2016-12-09 15:15:23 UTC) #13
blundell
bajones@ should definitely review this as well :).
4 years ago (2016-12-09 15:17:45 UTC) #16
ke.he
On 2016/12/09 15:17:45, blundell wrote: > bajones@ should definitely review this as well :). Yeah, ...
4 years ago (2016-12-09 15:21:00 UTC) #17
Tom Sepez
RS LGTM on mojom
4 years ago (2016-12-09 17:15:55 UTC) #20
jam
lgtm
4 years ago (2016-12-09 17:40:51 UTC) #21
bajones
LGTM, and thanks for doing all the rebase/test fixing work here to move this forward!
4 years ago (2016-12-09 19:23:45 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2563483006/60001
4 years ago (2016-12-10 00:05:03 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2563483006/60001
4 years ago (2016-12-10 00:18:33 UTC) #28
commit-bot: I haz the power
Committed patchset #2 (id:60001)
4 years ago (2016-12-10 01:56:50 UTC) #31
commit-bot: I haz the power
4 years ago (2016-12-12 14:59:27 UTC) #33
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/bee6a64bd524847e541f6ef11c73c0328094b9d3
Cr-Commit-Position: refs/heads/master@{#437716}

Powered by Google App Engine
This is Rietveld 408576698