Index: chrome/browser/ui/webui/sync_internals_message_handler.cc |
diff --git a/chrome/browser/ui/webui/sync_internals_message_handler.cc b/chrome/browser/ui/webui/sync_internals_message_handler.cc |
index ab914568b00e7837c47a77b98227550133c96c2f..ea7e1aeb499ce0a3d5b422d7728d8bfa0d416da0 100644 |
--- a/chrome/browser/ui/webui/sync_internals_message_handler.cc |
+++ b/chrome/browser/ui/webui/sync_internals_message_handler.cc |
@@ -34,9 +34,9 @@ namespace { |
class UtilAboutSyncDataExtractor : public AboutSyncDataExtractor { |
public: |
std::unique_ptr<base::DictionaryValue> ConstructAboutInformation( |
- sync_driver::SyncService* service, |
+ syncer::SyncService* service, |
SigninManagerBase* signin) override { |
- return sync_driver::sync_ui_util::ConstructAboutInformation( |
+ return syncer::sync_ui_util::ConstructAboutInformation( |
service, signin, chrome::GetChannel()); |
} |
}; |
@@ -70,27 +70,27 @@ void SyncInternalsMessageHandler::RegisterMessages() { |
DCHECK_CURRENTLY_ON(content::BrowserThread::UI); |
web_ui()->RegisterMessageCallback( |
- sync_driver::sync_ui_util::kRegisterForEvents, |
+ syncer::sync_ui_util::kRegisterForEvents, |
base::Bind(&SyncInternalsMessageHandler::HandleRegisterForEvents, |
base::Unretained(this))); |
web_ui()->RegisterMessageCallback( |
- sync_driver::sync_ui_util::kRegisterForPerTypeCounters, |
+ syncer::sync_ui_util::kRegisterForPerTypeCounters, |
base::Bind(&SyncInternalsMessageHandler::HandleRegisterForPerTypeCounters, |
base::Unretained(this))); |
web_ui()->RegisterMessageCallback( |
- sync_driver::sync_ui_util::kRequestUpdatedAboutInfo, |
+ syncer::sync_ui_util::kRequestUpdatedAboutInfo, |
base::Bind(&SyncInternalsMessageHandler::HandleRequestUpdatedAboutInfo, |
base::Unretained(this))); |
web_ui()->RegisterMessageCallback( |
- sync_driver::sync_ui_util::kRequestListOfTypes, |
+ syncer::sync_ui_util::kRequestListOfTypes, |
base::Bind(&SyncInternalsMessageHandler::HandleRequestListOfTypes, |
base::Unretained(this))); |
web_ui()->RegisterMessageCallback( |
- sync_driver::sync_ui_util::kGetAllNodes, |
+ syncer::sync_ui_util::kGetAllNodes, |
base::Bind(&SyncInternalsMessageHandler::HandleGetAllNodes, |
base::Unretained(this))); |
} |
@@ -144,10 +144,10 @@ void SyncInternalsMessageHandler::HandleRequestListOfTypes( |
it.Good(); it.Inc()) { |
type_list->AppendString(ModelTypeToString(it.Get())); |
} |
- event_details.Set(sync_driver::sync_ui_util::kTypes, type_list.release()); |
+ event_details.Set(syncer::sync_ui_util::kTypes, type_list.release()); |
web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kDispatchEvent, |
- base::StringValue(sync_driver::sync_ui_util::kOnReceivedListOfTypes), |
+ syncer::sync_ui_util::kDispatchEvent, |
+ base::StringValue(syncer::sync_ui_util::kOnReceivedListOfTypes), |
event_details); |
} |
@@ -171,7 +171,7 @@ void SyncInternalsMessageHandler::OnReceivedAllNodes( |
std::unique_ptr<base::ListValue> nodes) { |
base::FundamentalValue id(request_id); |
web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kGetAllNodesCallback, id, *nodes); |
+ syncer::sync_ui_util::kGetAllNodesCallback, id, *nodes); |
} |
void SyncInternalsMessageHandler::OnStateChanged() { |
@@ -183,29 +183,26 @@ void SyncInternalsMessageHandler::OnProtocolEvent( |
std::unique_ptr<base::DictionaryValue> value( |
syncer::ProtocolEvent::ToValue(event)); |
web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kDispatchEvent, |
- base::StringValue(sync_driver::sync_ui_util::kOnProtocolEvent), *value); |
+ syncer::sync_ui_util::kDispatchEvent, |
+ base::StringValue(syncer::sync_ui_util::kOnProtocolEvent), *value); |
} |
void SyncInternalsMessageHandler::OnCommitCountersUpdated( |
syncer::ModelType type, |
const syncer::CommitCounters& counters) { |
- EmitCounterUpdate(type, sync_driver::sync_ui_util::kCommit, |
- counters.ToValue()); |
+ EmitCounterUpdate(type, syncer::sync_ui_util::kCommit, counters.ToValue()); |
} |
void SyncInternalsMessageHandler::OnUpdateCountersUpdated( |
syncer::ModelType type, |
const syncer::UpdateCounters& counters) { |
- EmitCounterUpdate(type, sync_driver::sync_ui_util::kUpdate, |
- counters.ToValue()); |
+ EmitCounterUpdate(type, syncer::sync_ui_util::kUpdate, counters.ToValue()); |
} |
void SyncInternalsMessageHandler::OnStatusCountersUpdated( |
syncer::ModelType type, |
const syncer::StatusCounters& counters) { |
- EmitCounterUpdate(type, sync_driver::sync_ui_util::kStatus, |
- counters.ToValue()); |
+ EmitCounterUpdate(type, syncer::sync_ui_util::kStatus, counters.ToValue()); |
} |
void SyncInternalsMessageHandler::EmitCounterUpdate( |
@@ -213,14 +210,12 @@ void SyncInternalsMessageHandler::EmitCounterUpdate( |
const std::string& counter_type, |
std::unique_ptr<base::DictionaryValue> value) { |
std::unique_ptr<base::DictionaryValue> details(new base::DictionaryValue()); |
- details->SetString(sync_driver::sync_ui_util::kModelType, |
- ModelTypeToString(type)); |
- details->SetString(sync_driver::sync_ui_util::kCounterType, counter_type); |
- details->Set(sync_driver::sync_ui_util::kCounters, value.release()); |
+ details->SetString(syncer::sync_ui_util::kModelType, ModelTypeToString(type)); |
+ details->SetString(syncer::sync_ui_util::kCounterType, counter_type); |
+ details->Set(syncer::sync_ui_util::kCounters, value.release()); |
web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kDispatchEvent, |
- base::StringValue(sync_driver::sync_ui_util::kOnCountersUpdated), |
- *details); |
+ syncer::sync_ui_util::kDispatchEvent, |
+ base::StringValue(syncer::sync_ui_util::kOnCountersUpdated), *details); |
} |
void SyncInternalsMessageHandler::HandleJsEvent( |
@@ -228,9 +223,9 @@ void SyncInternalsMessageHandler::HandleJsEvent( |
const JsEventDetails& details) { |
DVLOG(1) << "Handling event: " << name |
<< " with details " << details.ToString(); |
- web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kDispatchEvent, base::StringValue(name), |
- details.Get()); |
+ web_ui()->CallJavascriptFunctionUnsafe(syncer::sync_ui_util::kDispatchEvent, |
+ base::StringValue(name), |
+ details.Get()); |
} |
void SyncInternalsMessageHandler::SendAboutInfo() { |
@@ -240,9 +235,8 @@ void SyncInternalsMessageHandler::SendAboutInfo() { |
about_sync_data_extractor_->ConstructAboutInformation(sync_service, |
signin); |
web_ui()->CallJavascriptFunctionUnsafe( |
- sync_driver::sync_ui_util::kDispatchEvent, |
- base::StringValue(sync_driver::sync_ui_util::kOnAboutInfoUpdated), |
- *value); |
+ syncer::sync_ui_util::kDispatchEvent, |
+ base::StringValue(syncer::sync_ui_util::kOnAboutInfoUpdated), *value); |
} |
// Gets the ProfileSyncService of the underlying original profile. |