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

Unified Diff: public/platform/WebGamepad.h

Issue 196833003: Removed Blink Gamepad transition cruft (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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
« no previous file with comments | « no previous file | public/platform/WebGamepads.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/platform/WebGamepad.h
diff --git a/public/platform/WebGamepad.h b/public/platform/WebGamepad.h
index db1fa1c012da5eaa2279c9f0454a9c2c530f236d..b2f32da02f57a3a4ef1a03469f14e541e29605d3 100644
--- a/public/platform/WebGamepad.h
+++ b/public/platform/WebGamepad.h
@@ -34,7 +34,6 @@ namespace blink {
#pragma pack(push, 1)
-#if defined(ENABLE_NEW_GAMEPAD_API)
class WebGamepadButton {
public:
WebGamepadButton()
@@ -50,7 +49,6 @@ public:
bool pressed;
float value;
};
-#endif
// This structure is intentionally POD and fixed size so that it can be shared
// memory between hardware polling threads and the rest of the browser. See
@@ -69,9 +67,7 @@ public:
, buttonsLength(0)
{
id[0] = 0;
-#if defined(ENABLE_NEW_GAMEPAD_API)
mapping[0] = 0;
-#endif
}
// Is there a gamepad connected at this index?
@@ -93,23 +89,15 @@ public:
// Number of valid entries in the buttons array.
unsigned buttonsLength;
-#if defined(ENABLE_NEW_GAMEPAD_API)
// Button states
WebGamepadButton buttons[buttonsLengthCap];
// Mapping type (for example "standard")
WebUChar mapping[mappingLengthCap];
-#else
- float buttons[buttonsLengthCap];
-#endif
};
#if BLINK_IMPLEMENTATION
-#if defined(ENABLE_NEW_GAMEPAD_API)
COMPILE_ASSERT(sizeof(WebGamepad) == 529, WebGamepad_has_wrong_size);
-#else
-COMPILE_ASSERT(sizeof(WebGamepad) == 465, WebGamepad_has_wrong_size);
-#endif
#endif
#pragma pack(pop)
« no previous file with comments | « no previous file | public/platform/WebGamepads.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698