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

Unified Diff: base/values.cc

Issue 7867044: PART1: Initiated the SignedSettings refactoring. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased to ToT and cleaned up some tests. Created 9 years, 2 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: base/values.cc
diff --git a/base/values.cc b/base/values.cc
index 60b0d70f1ed07f7a92c1f6ca7f5815dae3c38fa6..d7b102112831c98e569a2f3f1d02692ab428d523 100644
--- a/base/values.cc
+++ b/base/values.cc
@@ -887,6 +887,15 @@ ListValue::const_iterator ListValue::Find(const Value& value) const {
return std::find_if(list_.begin(), list_.end(), ValueEquals(&value));
}
+int ListValue::Find(const Value& value) const {
pastarmovj 2011/10/05 09:47:16 This is not part of the CL but a rebase artefact.
+ for (ValueVector::const_iterator i(list_.begin()); i != list_.end(); ++i) {
+ if ((*i)->Equals(&value)) {
+ return i - list_.begin();
+ }
+ }
+ return -1;
+}
+
bool ListValue::GetAsList(ListValue** out_value) {
if (out_value)
*out_value = this;

Powered by Google App Engine
This is Rietveld 408576698