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

Side by Side Diff: ppapi/thunk/ppb_instance_api.h

Issue 10081020: PPAPI: Make blocking completion callbacks work. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: export AssertLockHeld Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ppapi/thunk/ppb_host_resolver_private_thunk.cc ('k') | ppapi/thunk/ppb_layer_compositor_api.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_THUNK_INSTANCE_API_H_ 5 #ifndef PPAPI_THUNK_INSTANCE_API_H_
6 #define PPAPI_THUNK_INSTANCE_API_H_ 6 #define PPAPI_THUNK_INSTANCE_API_H_
7 7
8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h"
8 #include "ppapi/c/dev/pp_print_settings_dev.h" 10 #include "ppapi/c/dev/pp_print_settings_dev.h"
9 #include "ppapi/c/dev/ppb_console_dev.h" 11 #include "ppapi/c/dev/ppb_console_dev.h"
10 #include "ppapi/c/dev/ppb_text_input_dev.h" 12 #include "ppapi/c/dev/ppb_text_input_dev.h"
11 #include "ppapi/c/dev/ppb_url_util_dev.h" 13 #include "ppapi/c/dev/ppb_url_util_dev.h"
12 #include "ppapi/c/pp_bool.h" 14 #include "ppapi/c/pp_bool.h"
13 #include "ppapi/c/pp_completion_callback.h" 15 #include "ppapi/c/pp_completion_callback.h"
14 #include "ppapi/c/pp_size.h" 16 #include "ppapi/c/pp_size.h"
15 #include "ppapi/c/pp_time.h" 17 #include "ppapi/c/pp_time.h"
16 #include "ppapi/c/ppb_audio_config.h" 18 #include "ppapi/c/ppb_audio_config.h"
17 #include "ppapi/c/ppb_gamepad.h" 19 #include "ppapi/c/ppb_gamepad.h"
18 #include "ppapi/c/ppb_instance.h" 20 #include "ppapi/c/ppb_instance.h"
19 #include "ppapi/c/ppb_mouse_cursor.h" 21 #include "ppapi/c/ppb_mouse_cursor.h"
20 #include "ppapi/c/private/ppb_instance_private.h" 22 #include "ppapi/c/private/ppb_instance_private.h"
21 #include "ppapi/shared_impl/api_id.h" 23 #include "ppapi/shared_impl/api_id.h"
22 24
23 // Windows headers interfere with this file. 25 // Windows headers interfere with this file.
24 #ifdef PostMessage 26 #ifdef PostMessage
25 #undef PostMessage 27 #undef PostMessage
26 #endif 28 #endif
27 29
28 namespace ppapi { 30 namespace ppapi {
29 31
32 class TrackedCallback;
30 struct ViewData; 33 struct ViewData;
31 34
32 namespace thunk { 35 namespace thunk {
33 36
34 class PPB_Flash_API; 37 class PPB_Flash_API;
35 38
36 class PPB_Instance_API { 39 class PPB_Instance_API {
37 public: 40 public:
38 virtual ~PPB_Instance_API() {} 41 virtual ~PPB_Instance_API() {}
39 42
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 virtual void PostMessage(PP_Instance instance, PP_Var message) = 0; 105 virtual void PostMessage(PP_Instance instance, PP_Var message) = 0;
103 106
104 // Mouse cursor. 107 // Mouse cursor.
105 virtual PP_Bool SetCursor(PP_Instance instance, 108 virtual PP_Bool SetCursor(PP_Instance instance,
106 PP_MouseCursor_Type type, 109 PP_MouseCursor_Type type,
107 PP_Resource image, 110 PP_Resource image,
108 const PP_Point* hot_spot) = 0; 111 const PP_Point* hot_spot) = 0;
109 112
110 // MouseLock. 113 // MouseLock.
111 virtual int32_t LockMouse(PP_Instance instance, 114 virtual int32_t LockMouse(PP_Instance instance,
112 PP_CompletionCallback callback) = 0; 115 scoped_refptr<TrackedCallback> callback) = 0;
113 virtual void UnlockMouse(PP_Instance instance) = 0; 116 virtual void UnlockMouse(PP_Instance instance) = 0;
114 117
115 // Printing. 118 // Printing.
116 virtual PP_Bool GetDefaultPrintSettings( 119 virtual PP_Bool GetDefaultPrintSettings(
117 PP_Instance instance, 120 PP_Instance instance,
118 PP_PrintSettings_Dev* print_settings) = 0; 121 PP_PrintSettings_Dev* print_settings) = 0;
119 122
120 // TextInput. 123 // TextInput.
121 virtual void SetTextInputType(PP_Instance instance, 124 virtual void SetTextInputType(PP_Instance instance,
122 PP_TextInput_Type type) = 0; 125 PP_TextInput_Type type) = 0;
(...skipping 27 matching lines...) Expand all
150 PP_URLComponents_Dev* components) = 0; 153 PP_URLComponents_Dev* components) = 0;
151 #endif // !defined(OS_NACL) 154 #endif // !defined(OS_NACL)
152 155
153 static const ApiID kApiID = API_ID_PPB_INSTANCE; 156 static const ApiID kApiID = API_ID_PPB_INSTANCE;
154 }; 157 };
155 158
156 } // namespace thunk 159 } // namespace thunk
157 } // namespace ppapi 160 } // namespace ppapi
158 161
159 #endif // PPAPI_THUNK_INSTANCE_API_H_ 162 #endif // PPAPI_THUNK_INSTANCE_API_H_
OLDNEW
« no previous file with comments | « ppapi/thunk/ppb_host_resolver_private_thunk.cc ('k') | ppapi/thunk/ppb_layer_compositor_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698