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

Side by Side Diff: chrome/browser/sync/test/integration/preferences_helper.cc

Issue 2014103002: Remove deprecated ListValue::Append(Value*) overload on Linux. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ADL fail Created 4 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/sync/test/integration/preferences_helper.h" 5 #include "chrome/browser/sync/test/integration/preferences_helper.h"
6 6
7 #include "base/strings/stringprintf.h" 7 #include "base/strings/stringprintf.h"
8 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/sync/test/integration/multi_client_status_change_checke r.h" 9 #include "chrome/browser/sync/test/integration/multi_client_status_change_checke r.h"
10 #include "chrome/browser/sync/test/integration/profile_sync_service_harness.h" 10 #include "chrome/browser/sync/test/integration/profile_sync_service_harness.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 69
70 void ChangeListPref(int index, 70 void ChangeListPref(int index,
71 const char* pref_name, 71 const char* pref_name,
72 const base::ListValue& new_value) { 72 const base::ListValue& new_value) {
73 { 73 {
74 ListPrefUpdate update(GetPrefs(index), pref_name); 74 ListPrefUpdate update(GetPrefs(index), pref_name);
75 base::ListValue* list = update.Get(); 75 base::ListValue* list = update.Get();
76 for (base::ListValue::const_iterator it = new_value.begin(); 76 for (base::ListValue::const_iterator it = new_value.begin();
77 it != new_value.end(); 77 it != new_value.end();
78 ++it) { 78 ++it) {
79 list->Append((*it)->DeepCopy()); 79 list->Append((*it)->CreateDeepCopy());
80 } 80 }
81 } 81 }
82 82
83 if (test()->use_verifier()) { 83 if (test()->use_verifier()) {
84 ListPrefUpdate update_verifier(GetVerifierPrefs(), pref_name); 84 ListPrefUpdate update_verifier(GetVerifierPrefs(), pref_name);
85 base::ListValue* list_verifier = update_verifier.Get(); 85 base::ListValue* list_verifier = update_verifier.Get();
86 for (base::ListValue::const_iterator it = new_value.begin(); 86 for (base::ListValue::const_iterator it = new_value.begin();
87 it != new_value.end(); 87 it != new_value.end();
88 ++it) { 88 ++it) {
89 list_verifier->Append((*it)->DeepCopy()); 89 list_verifier->Append((*it)->CreateDeepCopy());
90 } 90 }
91 } 91 }
92 } 92 }
93 93
94 bool BooleanPrefMatches(const char* pref_name) { 94 bool BooleanPrefMatches(const char* pref_name) {
95 bool reference_value; 95 bool reference_value;
96 if (test()->use_verifier()) { 96 if (test()->use_verifier()) {
97 reference_value = GetVerifierPrefs()->GetBoolean(pref_name); 97 reference_value = GetVerifierPrefs()->GetBoolean(pref_name);
98 } else { 98 } else {
99 reference_value = GetPrefs(0)->GetBoolean(pref_name); 99 reference_value = GetPrefs(0)->GetBoolean(pref_name);
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
378 return !checker.TimedOut(); 378 return !checker.TimedOut();
379 } 379 }
380 380
381 bool AwaitStringPrefMatches(const char* pref_name) { 381 bool AwaitStringPrefMatches(const char* pref_name) {
382 StringPrefMatchChecker checker(pref_name); 382 StringPrefMatchChecker checker(pref_name);
383 checker.Wait(); 383 checker.Wait();
384 return !checker.TimedOut(); 384 return !checker.TimedOut();
385 } 385 }
386 386
387 } // namespace preferences_helper 387 } // namespace preferences_helper
OLDNEW
« no previous file with comments | « chrome/browser/signin/signin_manager_unittest.cc ('k') | chrome/common/custom_handlers/protocol_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698