From 4bc2d022d22a0bbd20e48cb7d91cbabc7972a11c Mon Sep 17 00:00:00 2001 From: "kinuko@chromium.org" Date: Mon, 27 May 2013 05:46:22 +0000 Subject: Revert 202364 "Track NPObject ownership by the originating plugi..." Suspected to have broken ClickToPlayPluginTest.NoCallbackAtLoad > Track NPObject ownership by the originating plugins' NPP identifier. [2/3] (Chrome) > > This CL updates Chrome to return plugin NPP identifiers for NPAPI, PPAPI and browser plugins, and to make the necessary calls into Blink to support object ownership tracking. > > This CL requires Blink CL crrev.com/14989014, and is itself required by Blink CL crrev.com/14019005. > > BUG=152006 > > Review URL: https://chromiumcodereview.appspot.com/15007012 TBR=wez@chromium.org Review URL: https://codereview.chromium.org/15757007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@202369 0039d316-1c4b-4281-b951-d872f2087c98 --- webkit/plugins/ppapi/ppapi_plugin_instance.cc | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'webkit/plugins/ppapi/ppapi_plugin_instance.cc') diff --git a/webkit/plugins/ppapi/ppapi_plugin_instance.cc b/webkit/plugins/ppapi/ppapi_plugin_instance.cc index 4f7f050..9368e29 100644 --- a/webkit/plugins/ppapi/ppapi_plugin_instance.cc +++ b/webkit/plugins/ppapi/ppapi_plugin_instance.cc @@ -437,16 +437,17 @@ PluginInstance::PluginInstance( selection_anchor_(0), pending_user_gesture_(0.0), document_loader_(NULL), - nacl_document_load_(false), - npp_(new NPP_t) { + nacl_document_load_(false) { pp_instance_ = HostGlobals::Get()->AddInstance(this); memset(¤t_print_settings_, 0, sizeof(current_print_settings_)); DCHECK(delegate); module_->InstanceCreated(this); delegate_->InstanceCreated(this); + message_channel_.reset(new MessageChannel(this)); view_data_.is_page_visible = delegate->IsPageVisible(); + resource_creation_ = delegate_->CreateResourceCreationAPI(this); // TODO(bbudge) remove this when the trusted NaCl plugin has been removed. @@ -633,8 +634,6 @@ static void SetGPUHistogram(const ::ppapi::Preferences& prefs, bool PluginInstance::Initialize(const std::vector& arg_names, const std::vector& arg_values, bool full_frame) { - message_channel_.reset(new MessageChannel(this)); - full_frame_ = full_frame; UpdateTouchEventRequest(); @@ -2546,10 +2545,6 @@ bool PluginInstance::IsValidInstanceOf(PluginModule* module) { module == original_module_.get(); } -NPP PluginInstance::instanceNPP() { - return npp_.get(); -} - void PluginInstance::DoSetCursor(WebCursorInfo* cursor) { cursor_.reset(cursor); if (fullscreen_container_) { -- cgit v1.1