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

Unified Diff: content/browser/gamepad/gamepad_shared_buffer_impl.h

Issue 2081583002: Migrating majority of gamepad from content/browser/ to device/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed Android and Unit tests Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/browser/gamepad/gamepad_shared_buffer_impl.h
diff --git a/content/browser/gamepad/gamepad_shared_buffer_impl.h b/content/browser/gamepad/gamepad_shared_buffer_impl.h
new file mode 100644
index 0000000000000000000000000000000000000000..4524cecb441c97358c62510cb01778c695cb6e32
--- /dev/null
+++ b/content/browser/gamepad/gamepad_shared_buffer_impl.h
@@ -0,0 +1,33 @@
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CONTENT_COMMON_GAMEPAD_SHARED_BUFFER_IMPL_H_
scottmg 2016/06/23 17:27:19 This doesn't match the filename.
+#define CONTENT_COMMON_GAMEPAD_SHARED_BUFFER_IMPL_H_
+
+#include "device/gamepad/gamepad_shared_buffer.h"
+#include "third_party/WebKit/public/platform/WebGamepads.h"
+
+namespace content {
+
+struct GamepadHardwareBuffer;
+
+class GamepadSharedBufferImpl : public device::GamepadSharedBuffer{
piman 2016/06/22 22:52:59 nit: space before {
+ public:
+ GamepadSharedBufferImpl();
+ ~GamepadSharedBufferImpl();
+
+ base::SharedMemory* shared_memory() override;
+ blink::WebGamepads* buffer() override;
+ GamepadHardwareBuffer* hardware_buffer();
+
+ void WriteBegin() override;
+ void WriteEnd() override;
+
+ private:
+ base::SharedMemory shared_memory_;
+};
+
+} // namespace content
+
+#endif // CONTENT_COMMON_GAMEPAD_SHARED_BUFFER_IMPL_H_

Powered by Google App Engine
This is Rietveld 408576698