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

Side by Side Diff: sync/internal_api/sync_manager_impl.cc

Issue 251133005: sync: Include control types in node browser (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix NOTREACHED(). Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « chrome/browser/sync/profile_sync_service.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "sync/internal_api/sync_manager_impl.h" 5 #include "sync/internal_api/sync_manager_impl.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/base64.h" 9 #include "base/base64.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 940 matching lines...) Expand 10 before | Expand all | Expand 10 after
951 js_sync_encryption_handler_observer_.SetJsEventHandler(event_handler); 951 js_sync_encryption_handler_observer_.SetJsEventHandler(event_handler);
952 } 952 }
953 953
954 scoped_ptr<base::ListValue> SyncManagerImpl::GetAllNodesForType( 954 scoped_ptr<base::ListValue> SyncManagerImpl::GetAllNodesForType(
955 syncer::ModelType type) { 955 syncer::ModelType type) {
956 DirectoryTypeDebugInfoEmitterMap* emitter_map = 956 DirectoryTypeDebugInfoEmitterMap* emitter_map =
957 model_type_registry_->directory_type_debug_info_emitter_map(); 957 model_type_registry_->directory_type_debug_info_emitter_map();
958 DirectoryTypeDebugInfoEmitterMap::iterator it = emitter_map->find(type); 958 DirectoryTypeDebugInfoEmitterMap::iterator it = emitter_map->find(type);
959 959
960 if (it == emitter_map->end()) { 960 if (it == emitter_map->end()) {
961 NOTREACHED() << "Asked to return debug info for invalid type " 961 // This can happen in some cases. The UI thread makes requests of us
962 << ModelTypeToString(type); 962 // when it doesn't really know which types are enabled or disabled.
963 DLOG(WARNING) << "Asked to return debug info for invalid type "
964 << ModelTypeToString(type);
963 return scoped_ptr<base::ListValue>(); 965 return scoped_ptr<base::ListValue>();
964 } 966 }
965 967
966 return it->second->GetAllNodes(); 968 return it->second->GetAllNodes();
967 } 969 }
968 970
969 void SyncManagerImpl::OnInvalidatorStateChange(InvalidatorState state) { 971 void SyncManagerImpl::OnInvalidatorStateChange(InvalidatorState state) {
970 DCHECK(thread_checker_.CalledOnValidThread()); 972 DCHECK(thread_checker_.CalledOnValidThread());
971 973
972 const std::string& state_str = InvalidatorStateToString(state); 974 const std::string& state_str = InvalidatorStateToString(state);
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
1128 int SyncManagerImpl::GetDefaultNudgeDelay() { 1130 int SyncManagerImpl::GetDefaultNudgeDelay() {
1129 return kDefaultNudgeDelayMilliseconds; 1131 return kDefaultNudgeDelayMilliseconds;
1130 } 1132 }
1131 1133
1132 // static. 1134 // static.
1133 int SyncManagerImpl::GetPreferencesNudgeDelay() { 1135 int SyncManagerImpl::GetPreferencesNudgeDelay() {
1134 return kPreferencesNudgeDelayMilliseconds; 1136 return kPreferencesNudgeDelayMilliseconds;
1135 } 1137 }
1136 1138
1137 } // namespace syncer 1139 } // namespace syncer
OLDNEW
« no previous file with comments | « chrome/browser/sync/profile_sync_service.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698