Commit a5171187 authored by dcheng's avatar dcheng Committed by Commit bot

Remove implicit conversions from scoped_refptr to T* in content/

This patch was generated by running the rewrite_scoped_refptr clang tool
on a Mac build.

BUG=110610

Review URL: https://codereview.chromium.org/590493002

Cr-Commit-Position: refs/heads/master@{#295847}
parent 4b070e30
......@@ -297,7 +297,9 @@ void SuspendObserverDelegate::StartObserver(
// Enumerate the devices in Device thread and post the observers start to be
// done on UI thread. The devices array is retained in |device_thread| and
// released in DoStartObserver().
base::PostTaskAndReplyWithResult(device_thread, FROM_HERE,
base::PostTaskAndReplyWithResult(
device_thread.get(),
FROM_HERE,
base::BindBlock(^{ return [[AVCaptureDeviceGlue devices] retain]; }),
base::Bind(&SuspendObserverDelegate::DoStartObserver, this));
}
......@@ -308,7 +310,9 @@ void SuspendObserverDelegate::OnDeviceChanged(
// Enumerate the devices in Device thread and post the consolidation of the
// new devices and the old ones to be done on UI thread. The devices array
// is retained in |device_thread| and released in DoOnDeviceChanged().
PostTaskAndReplyWithResult(device_thread, FROM_HERE,
PostTaskAndReplyWithResult(
device_thread.get(),
FROM_HERE,
base::BindBlock(^{ return [[AVCaptureDeviceGlue devices] retain]; }),
base::Bind(&SuspendObserverDelegate::DoOnDeviceChanged, this));
}
......
......@@ -534,7 +534,7 @@ class TestResourceDispatcherHostDelegate
void GotCookie(bool found_cookie) {
found_cookie_ = found_cookie;
if (runner_)
if (runner_.get())
runner_->QuitClosure().Run();
}
......
......@@ -50,7 +50,7 @@ scoped_refptr<CompositingIOSurfaceMac> CompositingIOSurfaceMac::Create() {
scoped_refptr<CompositingIOSurfaceContext> offscreen_context =
CompositingIOSurfaceContext::Get(
CompositingIOSurfaceContext::kOffscreenContextWindowNumber);
if (!offscreen_context) {
if (!offscreen_context.get()) {
LOG(ERROR) << "Failed to create context for offscreen operations";
return NULL;
}
......@@ -67,7 +67,7 @@ CompositingIOSurfaceMac::CompositingIOSurfaceMac(
gl_error_(GL_NO_ERROR),
eviction_queue_iterator_(eviction_queue_.Get().end()),
eviction_has_been_drawn_since_updated_(false) {
CHECK(offscreen_context_);
CHECK(offscreen_context_.get());
}
CompositingIOSurfaceMac::~CompositingIOSurfaceMac() {
......
......@@ -739,7 +739,7 @@ void RenderWidgetHostViewMac::UpdateDisplayLink() {
CGDirectDisplayID display_id = [screen_number unsignedIntValue];
display_link_ = DisplayLinkMac::GetForDisplay(display_id);
if (!display_link_) {
if (!display_link_.get()) {
// Note that on some headless systems, the display link will fail to be
// created, so this should not be a fatal error.
LOG(ERROR) << "Failed to create display link.";
......@@ -747,7 +747,7 @@ void RenderWidgetHostViewMac::UpdateDisplayLink() {
}
void RenderWidgetHostViewMac::SendVSyncParametersToRenderer() {
if (!render_widget_host_ || !display_link_)
if (!render_widget_host_ || !display_link_.get())
return;
if (!display_link_->GetVSyncParameters(&vsync_timebase_, &vsync_interval_)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment