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

Side by Side Diff: chrome/browser/chromeos/arc/arc_downloads_watcher_service.cc

Issue 2357053002: Always use arc::InstanceHolder<T>::GetInstanceForMethod (Closed)
Patch Set: rebase, no code change Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "chrome/browser/chromeos/arc/arc_downloads_watcher_service.h" 5 #include "chrome/browser/chromeos/arc/arc_downloads_watcher_service.h"
6 6
7 #include <map> 7 #include <map>
8 #include <memory> 8 #include <memory>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 if (watcher_) { 281 if (watcher_) {
282 BrowserThread::DeleteSoon(BrowserThread::FILE, FROM_HERE, 282 BrowserThread::DeleteSoon(BrowserThread::FILE, FROM_HERE,
283 watcher_.release()); 283 watcher_.release());
284 } 284 }
285 } 285 }
286 286
287 void ArcDownloadsWatcherService::OnDownloadsChanged( 287 void ArcDownloadsWatcherService::OnDownloadsChanged(
288 mojo::Array<mojo::String> paths) { 288 mojo::Array<mojo::String> paths) {
289 DCHECK_CURRENTLY_ON(BrowserThread::UI); 289 DCHECK_CURRENTLY_ON(BrowserThread::UI);
290 290
291 auto* instance = arc_bridge_service()->file_system()->instance(); 291 auto* instance = arc_bridge_service()->file_system()->GetInstanceForMethod(
292 "RequestMediaScan");
292 if (!instance) 293 if (!instance)
293 return; 294 return;
294 instance->RequestMediaScan(std::move(paths)); 295 instance->RequestMediaScan(std::move(paths));
295 } 296 }
296 297
297 } // namespace arc 298 } // namespace arc
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/arc/arc_auth_service.cc ('k') | chrome/browser/chromeos/arc/arc_enterprise_reporting_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698