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

Side by Side Diff: chrome/common/plugin_messages_internal.h

Issue 4142004: Let every "accelerated IO surface swapped" message have an identifier of the surface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments Created 10 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 #include "base/shared_memory.h" 5 #include "base/shared_memory.h"
6 #include "build/build_config.h" 6 #include "build/build_config.h"
7 #include "gfx/native_widget_types.h" 7 #include "gfx/native_widget_types.h"
8 #include "ipc/ipc_message_macros.h" 8 #include "ipc/ipc_message_macros.h"
9 #include "webkit/glue/webcursor.h" 9 #include "webkit/glue/webcursor.h"
10 10
(...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after
431 // IOSurface object of the given width and height. This information is then 431 // IOSurface object of the given width and height. This information is then
432 // forwarded on to the browser process. 432 // forwarded on to the browser process.
433 // 433 //
434 // NOTE: the original intent was to pass a mach port as the IOSurface 434 // NOTE: the original intent was to pass a mach port as the IOSurface
435 // identifier but it looks like that will be a lot of work. For now we pass an 435 // identifier but it looks like that will be a lot of work. For now we pass an
436 // ID from IOSurfaceGetID. 436 // ID from IOSurfaceGetID.
437 IPC_MESSAGE_ROUTED4(PluginHostMsg_AcceleratedSurfaceSetIOSurface, 437 IPC_MESSAGE_ROUTED4(PluginHostMsg_AcceleratedSurfaceSetIOSurface,
438 gfx::PluginWindowHandle /* window */, 438 gfx::PluginWindowHandle /* window */,
439 int32 /* width */, 439 int32 /* width */,
440 int32 /* height */, 440 int32 /* height */,
441 uint64 /* identifier for IOSurface */) 441 uint64 /* surface_id */)
442 442
443 443
444 // On the Mac, shared memory can't be allocated in the sandbox, so 444 // On the Mac, shared memory can't be allocated in the sandbox, so
445 // the TransportDIB used by the plug-in for rendering has to be allocated 445 // the TransportDIB used by the plug-in for rendering has to be allocated
446 // and managed by the browser. This is a synchronous message, use with care. 446 // and managed by the browser. This is a synchronous message, use with care.
447 IPC_SYNC_MESSAGE_ROUTED1_1(PluginHostMsg_AllocTransportDIB, 447 IPC_SYNC_MESSAGE_ROUTED1_1(PluginHostMsg_AllocTransportDIB,
448 size_t /* requested memory size */, 448 size_t /* requested memory size */,
449 TransportDIB::Handle /* output: DIB handle */) 449 TransportDIB::Handle /* output: DIB handle */)
450 450
451 // Since the browser keeps handles to the allocated transport DIBs, this 451 // Since the browser keeps handles to the allocated transport DIBs, this
452 // message is sent to tell the browser that it may release them when the 452 // message is sent to tell the browser that it may release them when the
453 // renderer is finished with them. 453 // renderer is finished with them.
454 IPC_MESSAGE_ROUTED1(PluginHostMsg_FreeTransportDIB, 454 IPC_MESSAGE_ROUTED1(PluginHostMsg_FreeTransportDIB,
455 TransportDIB::Id /* DIB id */) 455 TransportDIB::Id /* DIB id */)
456 456
457 // This message notifies the renderer process (and from there the 457 // This message notifies the renderer process (and from there the
458 // browser process) that the plug-in swapped the buffers associated 458 // browser process) that the plug-in swapped the buffers associated
459 // with the given "window", which should cause the browser to redraw 459 // with the given "window", which should cause the browser to redraw
460 // the various plug-ins' contents. 460 // the various plug-ins' contents.
461 IPC_MESSAGE_ROUTED1(PluginHostMsg_AcceleratedSurfaceBuffersSwapped, 461 IPC_MESSAGE_ROUTED2(PluginHostMsg_AcceleratedSurfaceBuffersSwapped,
462 gfx::PluginWindowHandle /* window */) 462 gfx::PluginWindowHandle /* window */,
463 uint64 /* surface_id */)
463 #endif 464 #endif
464 465
465 IPC_END_MESSAGES(PluginHost) 466 IPC_END_MESSAGES(PluginHost)
466 467
467 //----------------------------------------------------------------------------- 468 //-----------------------------------------------------------------------------
468 // NPObject messages 469 // NPObject messages
469 // These are messages used to marshall NPObjects. They are sent both from the 470 // These are messages used to marshall NPObjects. They are sent both from the
470 // plugin to the renderer and from the renderer to the plugin. 471 // plugin to the renderer and from the renderer to the plugin.
471 IPC_BEGIN_MESSAGES(NPObject) 472 IPC_BEGIN_MESSAGES(NPObject)
472 IPC_SYNC_MESSAGE_ROUTED0_0(NPObjectMsg_Release) 473 IPC_SYNC_MESSAGE_ROUTED0_0(NPObjectMsg_Release)
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
511 NPVariant_Param /* result_param */, 512 NPVariant_Param /* result_param */,
512 bool /* result */) 513 bool /* result */)
513 514
514 IPC_SYNC_MESSAGE_ROUTED2_2(NPObjectMsg_Evaluate, 515 IPC_SYNC_MESSAGE_ROUTED2_2(NPObjectMsg_Evaluate,
515 std::string /* script */, 516 std::string /* script */,
516 bool /* popups_allowed */, 517 bool /* popups_allowed */,
517 NPVariant_Param /* result_param */, 518 NPVariant_Param /* result_param */,
518 bool /* result */) 519 bool /* result */)
519 520
520 IPC_END_MESSAGES(NPObject) 521 IPC_END_MESSAGES(NPObject)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698