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

Side by Side Diff: ppapi/shared_impl/ppb_gamepad_shared.h

Issue 2563483006: Move gamepad_service out of content/ and into device/ (Closed)
Patch Set: Move gamepad_service out of content/ and into device/ Created 4 years 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_ 5 #ifndef PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_
6 #define PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_ 6 #define PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include "base/atomicops.h" 10 #include "base/atomicops.h"
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 static const size_t kItemsLengthCap = 4; 102 static const size_t kItemsLengthCap = 4;
103 103
104 // Number of valid entries in the items array. 104 // Number of valid entries in the items array.
105 unsigned length; 105 unsigned length;
106 106
107 // Gamepad data for N separate gamepad devices. 107 // Gamepad data for N separate gamepad devices.
108 WebKitGamepad items[kItemsLengthCap]; 108 WebKitGamepad items[kItemsLengthCap];
109 }; 109 };
110 110
111 // This is the structure store in shared memory. It must match 111 // This is the structure store in shared memory. It must match
112 // content/common/gamepad_hardware_buffer.h. The GamepadHost unit test has 112 // device::GamepadHardwareBuffer. The GamepadHost unit test has
113 // some compile asserts to validate this. 113 // some compile asserts to validate this.
114 struct ContentGamepadHardwareBuffer { 114 struct ContentGamepadHardwareBuffer {
115 base::subtle::Atomic32 sequence; 115 base::subtle::Atomic32 sequence;
116 WebKitGamepads buffer; 116 WebKitGamepads buffer;
117 }; 117 };
118 118
119 #pragma pack(pop) 119 #pragma pack(pop)
120 120
121 PPAPI_SHARED_EXPORT void ConvertWebKitGamepadData( 121 PPAPI_SHARED_EXPORT void ConvertWebKitGamepadData(
122 const WebKitGamepads& webkit_data, 122 const WebKitGamepads& webkit_data,
123 PP_GamepadsSampleData* output_data); 123 PP_GamepadsSampleData* output_data);
124 124
125 } // namespace ppapi 125 } // namespace ppapi
126 126
127 #endif // PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_ 127 #endif // PPAPI_SHARED_IMPL_PPB_GAMEPAD_SHARED_H_
OLDNEW
« device/gamepad/gamepad_shared_buffer.h ('K') | « device/gamepad/public/interfaces/gamepad.mojom ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698