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

Side by Side Diff: chrome/browser/chromeos/extensions/file_manager/event_router.cc

Issue 553393002: Get rid of FileManagerPrivateAPI class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address comments Created 6 years, 3 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/extensions/file_manager/event_router.h" 5 #include "chrome/browser/chromeos/extensions/file_manager/event_router.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/files/file_util.h" 8 #include "base/files/file_util.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/prefs/pref_change_registrar.h" 10 #include "base/prefs/pref_change_registrar.h"
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
365 const drive::JobInfo& info, const std::string& status) 365 const drive::JobInfo& info, const std::string& status)
366 : job_info(info), status(status) { 366 : job_info(info), status(status) {
367 } 367 }
368 368
369 EventRouter::EventRouter(Profile* profile) 369 EventRouter::EventRouter(Profile* profile)
370 : pref_change_registrar_(new PrefChangeRegistrar), 370 : pref_change_registrar_(new PrefChangeRegistrar),
371 profile_(profile), 371 profile_(profile),
372 device_event_router_(new DeviceEventRouterImpl(profile)), 372 device_event_router_(new DeviceEventRouterImpl(profile)),
373 weak_factory_(this) { 373 weak_factory_(this) {
374 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 374 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
375 ObserveEvents();
375 } 376 }
376 377
377 EventRouter::~EventRouter() { 378 EventRouter::~EventRouter() {
378 } 379 }
379 380
380 void EventRouter::Shutdown() { 381 void EventRouter::Shutdown() {
381 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 382 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
382 383
383 DLOG_IF(WARNING, !file_watchers_.empty()) 384 DLOG_IF(WARNING, !file_watchers_.empty())
384 << "Not all file watchers are " 385 << "Not all file watchers are "
(...skipping 545 matching lines...) Expand 10 before | Expand all | Expand 10 after
930 // Do nothing. 931 // Do nothing.
931 } 932 }
932 933
933 void EventRouter::OnFormatCompleted(const std::string& device_path, 934 void EventRouter::OnFormatCompleted(const std::string& device_path,
934 bool success) { 935 bool success) {
935 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 936 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
936 // Do nothing. 937 // Do nothing.
937 } 938 }
938 939
939 } // namespace file_manager 940 } // namespace file_manager
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698