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

Unified Diff: components/storage_monitor/portable_device_watcher_win.cc

Issue 717263004: Remove implicit conversions from scoped_refptr to T* in components/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | components/wifi/wifi_service_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/storage_monitor/portable_device_watcher_win.cc
diff --git a/components/storage_monitor/portable_device_watcher_win.cc b/components/storage_monitor/portable_device_watcher_win.cc
index 2cf4af696598bc004feba05a3f4765366987284d..3f90feeab4a97d1c44de6c9fc5f51dc489ef2b6e 100644
--- a/components/storage_monitor/portable_device_watcher_win.cc
+++ b/components/storage_monitor/portable_device_watcher_win.cc
@@ -423,8 +423,8 @@ bool EnumerateAttachedDevicesOnBlockingThread(
for (DWORD index = 0; index < pnp_device_count; ++index) {
PortableDeviceWatcherWin::DeviceDetails device_details;
- if (GetDeviceInfoOnBlockingThread(
- portable_device_mgr, pnp_device_ids[index], &device_details))
+ if (GetDeviceInfoOnBlockingThread(portable_device_mgr.get(),
+ pnp_device_ids[index], &device_details))
devices->push_back(device_details);
CoTaskMemFree(pnp_device_ids[index]);
}
@@ -446,7 +446,7 @@ bool HandleDeviceAttachedEventOnBlockingThread(
// Sometimes, portable device manager doesn't have the new device details.
// Refresh the manager device list to update its details.
portable_device_mgr->RefreshDeviceList();
- return GetDeviceInfoOnBlockingThread(portable_device_mgr, pnp_device_id,
+ return GetDeviceInfoOnBlockingThread(portable_device_mgr.get(), pnp_device_id,
device_details);
}
@@ -576,8 +576,7 @@ void PortableDeviceWatcherWin::EnumerateAttachedDevices() {
DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
Devices* devices = new Devices;
base::PostTaskAndReplyWithResult(
- media_task_runner_,
- FROM_HERE,
+ media_task_runner_.get(), FROM_HERE,
base::Bind(&EnumerateAttachedDevicesOnBlockingThread, devices),
base::Bind(&PortableDeviceWatcherWin::OnDidEnumerateAttachedDevices,
weak_ptr_factory_.GetWeakPtr(), base::Owned(devices)));
@@ -601,8 +600,7 @@ void PortableDeviceWatcherWin::HandleDeviceAttachEvent(
DCHECK(content::BrowserThread::CurrentlyOn(content::BrowserThread::UI));
DeviceDetails* device_details = new DeviceDetails;
base::PostTaskAndReplyWithResult(
- media_task_runner_,
- FROM_HERE,
+ media_task_runner_.get(), FROM_HERE,
base::Bind(&HandleDeviceAttachedEventOnBlockingThread, pnp_device_id,
device_details),
base::Bind(&PortableDeviceWatcherWin::OnDidHandleDeviceAttachEvent,
« no previous file with comments | « no previous file | components/wifi/wifi_service_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698