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

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

Issue 722513003: Enable -Wunused-local-typedef (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 unified diff | Download patch
« no previous file with comments | « build/config/compiler/BUILD.gn ('k') | chrome/browser/ui/libgtk2ui/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 870 matching lines...) Expand 10 before | Expand all | Expand 10 after
881 base::Owned(extension_id), 881 base::Owned(extension_id),
882 got_error)); 882 got_error));
883 } 883 }
884 } 884 }
885 885
886 void EventRouter::DispatchDirectoryChangeEventWithEntryDefinition( 886 void EventRouter::DispatchDirectoryChangeEventWithEntryDefinition(
887 const linked_ptr<drive::FileChange> list, 887 const linked_ptr<drive::FileChange> list,
888 const std::string* extension_id, 888 const std::string* extension_id,
889 bool watcher_error, 889 bool watcher_error,
890 const EntryDefinition& entry_definition) { 890 const EntryDefinition& entry_definition) {
891 typedef std::map<base::FilePath, drive::FileChange::ChangeList> ChangeListMap;
892
893 // TODO(mtomasz): Add support for watching files in File System Provider API. 891 // TODO(mtomasz): Add support for watching files in File System Provider API.
894 if (entry_definition.error != base::File::FILE_OK || 892 if (entry_definition.error != base::File::FILE_OK ||
895 !entry_definition.is_directory) { 893 !entry_definition.is_directory) {
896 DVLOG(1) << "Unable to dispatch event because resolving the directory " 894 DVLOG(1) << "Unable to dispatch event because resolving the directory "
897 << "entry definition failed."; 895 << "entry definition failed.";
898 return; 896 return;
899 } 897 }
900 898
901 file_manager_private::FileWatchEvent event; 899 file_manager_private::FileWatchEvent event;
902 event.event_type = watcher_error 900 event.event_type = watcher_error
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
1035 void EventRouter::SetDispatchDirectoryChangeEventImplForTesting( 1033 void EventRouter::SetDispatchDirectoryChangeEventImplForTesting(
1036 const DispatchDirectoryChangeEventImplCallback& callback) { 1034 const DispatchDirectoryChangeEventImplCallback& callback) {
1037 dispatch_directory_change_event_impl_ = callback; 1035 dispatch_directory_change_event_impl_ = callback;
1038 } 1036 }
1039 1037
1040 base::WeakPtr<EventRouter> EventRouter::GetWeakPtr() { 1038 base::WeakPtr<EventRouter> EventRouter::GetWeakPtr() {
1041 return weak_factory_.GetWeakPtr(); 1039 return weak_factory_.GetWeakPtr();
1042 } 1040 }
1043 1041
1044 } // namespace file_manager 1042 } // namespace file_manager
OLDNEW
« no previous file with comments | « build/config/compiler/BUILD.gn ('k') | chrome/browser/ui/libgtk2ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698