Pepper_56_C++_interfaces
Pepper_56_C++_interfaces
 All Classes Namespaces Files Functions Typedefs Enumerations Macros Groups
mouse_lock.h
Go to the documentation of this file.
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
3 // found in the LICENSE file.
4 
5 #ifndef PPAPI_CPP_MOUSE_LOCK_H_
6 #define PPAPI_CPP_MOUSE_LOCK_H_
7 
8 #include "ppapi/c/pp_stdint.h"
10 
14 
15 namespace pp {
16 
17 class CompletionCallback;
18 class Instance;
19 
50 class MouseLock {
51  public:
56  explicit MouseLock(Instance* instance);
57 
59  virtual ~MouseLock();
60 
62  virtual void MouseLockLost() = 0;
63 
84  int32_t LockMouse(const CompletionCallback& cc);
85 
90  void UnlockMouse();
91 
92  private:
93  InstanceHandle associated_instance_;
94 };
95 
96 } // namespace pp
97 
98 #endif // PPAPI_CPP_MOUSE_LOCK_H_
Definition: completion_callback.h:26
int32_t LockMouse(const CompletionCallback &cc)
MouseLock(Instance *instance)
Definition: mouse_lock.h:50
void UnlockMouse()
virtual void MouseLockLost()=0
PPP_MouseLock functions exposed as virtual functions for you to override.
Definition: instance_handle.h:44
virtual ~MouseLock()
Destructor.
Definition: instance.h:42