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

Unified Diff: ppapi/proxy/gamepad_resource.cc

Issue 11359063: Refactor the way singleton-style resources are exposed via PPB_Instance (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 1 month 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: ppapi/proxy/gamepad_resource.cc
diff --git a/ppapi/proxy/gamepad_resource.cc b/ppapi/proxy/gamepad_resource.cc
index 8a4943767cc30b9fff1c26141050a8a868dc0cad..8bbf8cc6c28cf3c124db5e186bcd2b22f8d1b7d6 100644
--- a/ppapi/proxy/gamepad_resource.cc
+++ b/ppapi/proxy/gamepad_resource.cc
@@ -58,6 +58,10 @@ GamepadResource::GamepadResource(Connection connection, PP_Instance instance)
GamepadResource::~GamepadResource() {
}
+thunk::PPB_Gamepad_API* GamepadResource::AsPPB_Gamepad_API() {
+ return this;
+}
+
void GamepadResource::Sample(PP_GamepadsSampleData* data) {
if (!buffer_) {
// Browser hasn't sent back our shared memory, give the plugin gamepad

Powered by Google App Engine
This is Rietveld 408576698