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

Unified Diff: webkit/plugins/ppapi/ppapi_webplugin_impl.cc

Issue 16155009: Update webkit/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/plugins/ppapi/ppapi_plugin_instance.cc ('k') | webkit/plugins/ppapi/ppb_buffer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppapi_webplugin_impl.cc
diff --git a/webkit/plugins/ppapi/ppapi_webplugin_impl.cc b/webkit/plugins/ppapi/ppapi_webplugin_impl.cc
index 6980043c96d0dc9b69f744744710b0ce460d6771..a1efd3555efdb6ea0371f35c8e85710795bc4b19 100644
--- a/webkit/plugins/ppapi/ppapi_webplugin_impl.cc
+++ b/webkit/plugins/ppapi/ppapi_webplugin_impl.cc
@@ -90,7 +90,7 @@ bool WebPluginImpl::initialize(WebPluginContainer* container) {
instance_ = init_data_->module->CreateInstance(init_data_->delegate,
container,
init_data_->url);
- if (!instance_)
+ if (!instance_.get())
return false;
// Enable script objects for this plugin.
@@ -123,7 +123,7 @@ void WebPluginImpl::destroy() {
if (container_)
container_->clearScriptObjects();
- if (instance_) {
+ if (instance_.get()) {
::ppapi::PpapiGlobals::Get()->GetVarTracker()->ReleaseVar(instance_object_);
instance_object_ = PP_MakeUndefined();
instance_->Delete();
@@ -140,13 +140,13 @@ NPObject* WebPluginImpl::scriptableObject() {
instance_object_ = instance_->GetInstanceObject();
// GetInstanceObject talked to the plugin which may have removed the instance
// from the DOM, in which case instance_ would be NULL now.
- if (!instance_)
+ if (!instance_.get())
return NULL;
scoped_refptr<NPObjectVar> object(NPObjectVar::FromPPVar(instance_object_));
// If there's an InstanceObject, tell the Instance's MessageChannel to pass
// any non-postMessage calls to it.
- if (object) {
+ if (object.get()) {
instance_->message_channel().SetPassthroughObject(object->np_object());
}
NPObject* message_channel_np_object(instance_->message_channel().np_object());
« no previous file with comments | « webkit/plugins/ppapi/ppapi_plugin_instance.cc ('k') | webkit/plugins/ppapi/ppb_buffer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698