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

Unified Diff: chrome/browser/sync/profile_sync_service_harness.cc

Issue 10696107: sync: Track validity of about:sync fields (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update Created 8 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/sync/profile_sync_service_harness.cc
diff --git a/chrome/browser/sync/profile_sync_service_harness.cc b/chrome/browser/sync/profile_sync_service_harness.cc
index 1bfa704a6732f9b00a39b8eea403f74da87bc110..9b4ffc58f056afc0e8cc75b02b97c601d6f50c24 100644
--- a/chrome/browser/sync/profile_sync_service_harness.cc
+++ b/chrome/browser/sync/profile_sync_service_harness.cc
@@ -22,9 +22,9 @@
#include "base/message_loop.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/signin/signin_manager.h"
+#include "chrome/browser/sync/about_sync_util.h"
#include "chrome/browser/sync/glue/data_type_controller.h"
#include "chrome/browser/sync/profile_sync_service_factory.h"
-#include "chrome/browser/sync/sync_ui_util.h"
#include "chrome/common/chrome_switches.h"
#include "sync/internal_api/public/sessions/sync_session_snapshot.h"
@@ -757,7 +757,9 @@ bool ProfileSyncServiceHarness::AwaitStatusChangeWithTimeout(
ProfileSyncService::Status ProfileSyncServiceHarness::GetStatus() {
DCHECK(service() != NULL) << "GetStatus(): service() is NULL.";
- return service()->QueryDetailedSyncStatus();
+ ProfileSyncService::Status result;
+ service()->QueryDetailedSyncStatus(&result);
+ return result;
}
// We use this function to share code between IsFullySynced and IsDataSynced
@@ -1104,10 +1106,10 @@ size_t ProfileSyncServiceHarness::GetNumDatatypes() const {
}
std::string ProfileSyncServiceHarness::GetServiceStatus() {
- DictionaryValue value;
- sync_ui_util::ConstructAboutInformation(service_, &value);
+ scoped_ptr<DictionaryValue> value(
+ sync_ui_util::ConstructAboutInformation(service_));
std::string service_status;
- base::JSONWriter::WriteWithOptions(&value,
+ base::JSONWriter::WriteWithOptions(value.get(),
base::JSONWriter::OPTIONS_PRETTY_PRINT,
&service_status);
return service_status;

Powered by Google App Engine
This is Rietveld 408576698