Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | |
|
Ted C
2014/04/16 23:36:53
no (c)
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Is it?
I noti
kbalazs
2014/04/18 15:21:20
(c) is deprecated. It's there in a lot of files bu
| |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 // Define the data fetcher that GamepadProvider will use for android port. | |
| 6 // (GamepadPlatformDataFetcher). | |
| 7 | |
| 8 #ifndef CONTENT_BROWSER_GAMEPAD_GAMEPAD_PLATFORM_DATA_FETCHER_ANDROID_H_ | |
| 9 #define CONTENT_BROWSER_GAMEPAD_GAMEPAD_PLATFORM_DATA_FETCHER_ANDROID_H_ | |
| 10 | |
| 11 #include <jni.h> | |
| 12 | |
| 13 #include "base/android/jni_android.h" | |
| 14 #include "content/browser/gamepad/gamepad_data_fetcher.h" | |
| 15 #include "content/browser/gamepad/gamepad_provider.h" | |
| 16 #include "content/browser/gamepad/gamepad_standard_mappings.h" | |
| 17 | |
| 18 #include "third_party/WebKit/public/platform/WebGamepads.h" | |
|
Ted C
2014/04/16 23:36:53
no blank line above this.
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Done.
| |
| 19 | |
| 20 namespace content { | |
| 21 using blink::WebGamepad; | |
|
Ted C
2014/04/16 23:36:53
you are fully qualifying blink::WebGamepads, so I
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Removed it.
| |
| 22 using blink::WebGamepads; | |
| 23 | |
| 24 class GamepadPlatformDataFetcherAndroid : public GamepadDataFetcher { | |
| 25 public: | |
| 26 GamepadPlatformDataFetcherAndroid(); | |
| 27 ~GamepadPlatformDataFetcherAndroid(); | |
| 28 | |
| 29 // Method for sending pause hints to the JNI interface. Runs on | |
| 30 // polling_thread_. | |
|
Ted C
2014/04/16 23:36:53
polling_thread_ is a private class variable in gam
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Dropping the
| |
| 31 virtual void PauseHint(bool ispaused) OVERRIDE; | |
|
Ted C
2014/04/16 23:36:53
is_paused or just paused to match the overridden m
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Using paused
| |
| 32 | |
| 33 virtual void GetGamepadData(blink::WebGamepads* pads, | |
| 34 bool devices_changed_hint) OVERRIDE; | |
| 35 | |
| 36 // Registers the JNI methods for GamepadsReader. | |
| 37 static bool RegisterGamepadPlatformDataFetcherAndroid(JNIEnv* env); | |
| 38 | |
| 39 private: | |
| 40 // Data to fetch into. | |
| 41 blink::WebGamepads* gamepads_data_; | |
|
jdduke (slow)
2014/04/16 23:23:44
I think you can remove this variable now?
Ted C
2014/04/16 23:36:53
this doesn't look used in the implementation
SaurabhK
2014/04/18 14:51:57
On 2014/04/16 23:36:53, Ted C wrote:
Removed.
| |
| 42 | |
| 43 DISALLOW_COPY_AND_ASSIGN(GamepadPlatformDataFetcherAndroid); | |
| 44 }; | |
| 45 | |
| 46 } // namespace content | |
| 47 | |
| 48 #endif // CONTENT_BROWSER_GAMEPAD_GAMEPAD_PLATFORM_DATA_FETCHER_ANDROID_H_ | |
| OLD | NEW |