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

Side by Side Diff: content/common/browser_plugin/browser_plugin_messages.h

Issue 21297005: <webview>: Refactor Permission API to chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup_permissions
Patch Set: Fixed some bugs Created 7 years, 4 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
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 // Multiply-included message header, no traditional include guard. 5 // Multiply-included message header, no traditional include guard.
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/shared_memory.h" 10 #include "base/memory/shared_memory.h"
11 #include "base/process/process.h" 11 #include "base/process/process.h"
12 #include "base/values.h" 12 #include "base/values.h"
13 #include "cc/output/compositor_frame.h" 13 #include "cc/output/compositor_frame.h"
14 #include "cc/output/compositor_frame_ack.h" 14 #include "cc/output/compositor_frame_ack.h"
15 #include "content/common/browser_plugin/browser_plugin_message_enums.h"
16 #include "content/common/content_export.h" 15 #include "content/common/content_export.h"
17 #include "content/common/content_param_traits.h" 16 #include "content/common/content_param_traits.h"
18 #include "content/common/edit_command.h" 17 #include "content/common/edit_command.h"
18 #include "content/public/common/browser_plugin/browser_plugin_message_enums.h"
19 #include "content/public/common/common_param_traits.h" 19 #include "content/public/common/common_param_traits.h"
20 #include "content/public/common/drop_data.h" 20 #include "content/public/common/drop_data.h"
21 #include "ipc/ipc_channel_handle.h" 21 #include "ipc/ipc_channel_handle.h"
22 #include "ipc/ipc_message_macros.h" 22 #include "ipc/ipc_message_macros.h"
23 #include "ipc/ipc_message_utils.h" 23 #include "ipc/ipc_message_utils.h"
24 #include "third_party/WebKit/public/web/WebDragOperation.h" 24 #include "third_party/WebKit/public/web/WebDragOperation.h"
25 #include "third_party/WebKit/public/web/WebDragStatus.h" 25 #include "third_party/WebKit/public/web/WebDragStatus.h"
26 #include "ui/gfx/point.h" 26 #include "ui/gfx/point.h"
27 #include "ui/gfx/rect.h" 27 #include "ui/gfx/rect.h"
28 #include "ui/gfx/size.h" 28 #include "ui/gfx/size.h"
29 #include "webkit/common/cursors/webcursor.h" 29 #include "webkit/common/cursors/webcursor.h"
30 30
31 #undef IPC_MESSAGE_EXPORT 31 #undef IPC_MESSAGE_EXPORT
32 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT 32 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT
33 33
34 #define IPC_MESSAGE_START BrowserPluginMsgStart 34 #define IPC_MESSAGE_START BrowserPluginMsgStart
35 35
36 36
37 IPC_ENUM_TRAITS(BrowserPluginPermissionType)
38 IPC_ENUM_TRAITS(WebKit::WebDragStatus) 37 IPC_ENUM_TRAITS(WebKit::WebDragStatus)
39 38
40 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_AutoSize_Params) 39 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_AutoSize_Params)
41 IPC_STRUCT_MEMBER(bool, enable) 40 IPC_STRUCT_MEMBER(bool, enable)
42 IPC_STRUCT_MEMBER(gfx::Size, max_size) 41 IPC_STRUCT_MEMBER(gfx::Size, max_size)
43 IPC_STRUCT_MEMBER(gfx::Size, min_size) 42 IPC_STRUCT_MEMBER(gfx::Size, min_size)
44 IPC_STRUCT_END() 43 IPC_STRUCT_END()
45 44
46 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_ResizeGuest_Params) 45 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_ResizeGuest_Params)
47 // Indicates whether the parameters have been populated or not. 46 // Indicates whether the parameters have been populated or not.
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 IPC_MESSAGE_ROUTED3(BrowserPluginHostMsg_PluginAtPositionResponse, 241 IPC_MESSAGE_ROUTED3(BrowserPluginHostMsg_PluginAtPositionResponse,
243 int /* instance_id */, 242 int /* instance_id */,
244 int /* request_id */, 243 int /* request_id */,
245 gfx::Point /* position */) 244 gfx::Point /* position */)
246 245
247 // Sets the name of the guest window to the provided |name|. 246 // Sets the name of the guest window to the provided |name|.
248 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_SetName, 247 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_SetName,
249 int /* instance_id */, 248 int /* instance_id */,
250 std::string /* name */) 249 std::string /* name */)
251 250
252 // Tells the guest that its request for an API permission has been allowed or
253 // denied.
254 // Note that |allow| = true does not readily mean that the guest will be granted
255 // permission, since a security check in the embedder might follow. For example
256 // for media access permission, the guest will be granted permission only if its
257 // embedder also has access. For certain APIs, such as the Dialog API,
258 // additional information may be passed by the developer through |user_input|.
259 IPC_MESSAGE_ROUTED4(BrowserPluginHostMsg_RespondPermission,
260 int /* instance_id */,
261 int /* request_id */,
262 bool /* allow */,
263 std::string /* user_input */)
264
265 // Sends a PointerLock Lock ACK to the BrowserPluginGuest. 251 // Sends a PointerLock Lock ACK to the BrowserPluginGuest.
266 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_LockMouse_ACK, 252 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_LockMouse_ACK,
267 int /* instance_id */, 253 int /* instance_id */,
268 bool /* succeeded */) 254 bool /* succeeded */)
269 255
270 // Sends a PointerLock Unlock ACK to the BrowserPluginGuest. 256 // Sends a PointerLock Unlock ACK to the BrowserPluginGuest.
271 IPC_MESSAGE_ROUTED1(BrowserPluginHostMsg_UnlockMouse_ACK, int /* instance_id */) 257 IPC_MESSAGE_ROUTED1(BrowserPluginHostMsg_UnlockMouse_ACK, int /* instance_id */)
272 258
273 // Sent when plugin's position has changed without UpdateRect. 259 // Sent when plugin's position has changed without UpdateRect.
274 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_UpdateGeometry, 260 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_UpdateGeometry,
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
357 int /* instance_id */, 343 int /* instance_id */,
358 BrowserPluginMsg_BuffersSwapped_Params) 344 BrowserPluginMsg_BuffersSwapped_Params)
359 345
360 IPC_MESSAGE_CONTROL5(BrowserPluginMsg_CompositorFrameSwapped, 346 IPC_MESSAGE_CONTROL5(BrowserPluginMsg_CompositorFrameSwapped,
361 int /* instance_id */, 347 int /* instance_id */,
362 cc::CompositorFrame /* frame */, 348 cc::CompositorFrame /* frame */,
363 int /* route_id */, 349 int /* route_id */,
364 uint32 /* output_surface_id */, 350 uint32 /* output_surface_id */,
365 int /* renderer_host_id */) 351 int /* renderer_host_id */)
366 352
367 // When the guest requests permission, the browser process forwards this
368 // request to the embeddder through this message.
369 IPC_MESSAGE_CONTROL4(BrowserPluginMsg_RequestPermission,
370 int /* instance_id */,
371 BrowserPluginPermissionType /* permission_type */,
372 int /* request_id */,
373 base::DictionaryValue /* request_info */)
374
375 // Forwards a PointerLock Unlock request to the BrowserPlugin. 353 // Forwards a PointerLock Unlock request to the BrowserPlugin.
376 IPC_MESSAGE_CONTROL2(BrowserPluginMsg_SetMouseLock, 354 IPC_MESSAGE_CONTROL2(BrowserPluginMsg_SetMouseLock,
377 int /* instance_id */, 355 int /* instance_id */,
378 bool /* enable */) 356 bool /* enable */)
379 357
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698