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

Unified Diff: ppapi/cpp/mouse_lock.cc

Issue 9699106: Check explicitly for PPB_MouseLock v1.0 in pp::MouseLock. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/cpp/mouse_lock.cc
diff --git a/ppapi/cpp/mouse_lock.cc b/ppapi/cpp/mouse_lock.cc
index 7724a0f1aac87884ad5a932073fef40504ca9337..7266fbde39190938c51279f3d58d9d3d0e061a95 100644
--- a/ppapi/cpp/mouse_lock.cc
+++ b/ppapi/cpp/mouse_lock.cc
@@ -30,8 +30,8 @@ const PPP_MouseLock ppp_mouse_lock = {
&MouseLockLost
};
-template <> const char* interface_name<PPB_MouseLock>() {
- return PPB_MOUSELOCK_INTERFACE;
+template <> const char* interface_name<PPB_MouseLock_1_0>() {
+ return PPB_MOUSELOCK_INTERFACE_1_0;
}
} // namespace
@@ -48,15 +48,15 @@ MouseLock::~MouseLock() {
}
int32_t MouseLock::LockMouse(const CompletionCallback& cc) {
- if (!has_interface<PPB_MouseLock>())
+ if (!has_interface<PPB_MouseLock_1_0>())
return cc.MayForce(PP_ERROR_NOINTERFACE);
- return get_interface<PPB_MouseLock>()->LockMouse(
+ return get_interface<PPB_MouseLock_1_0>()->LockMouse(
associated_instance_.pp_instance(), cc.pp_completion_callback());
}
void MouseLock::UnlockMouse() {
- if (has_interface<PPB_MouseLock>()) {
- get_interface<PPB_MouseLock>()->UnlockMouse(
+ if (has_interface<PPB_MouseLock_1_0>()) {
+ get_interface<PPB_MouseLock_1_0>()->UnlockMouse(
associated_instance_.pp_instance());
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698