diff options
author | akalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-10 09:23:39 +0000 |
---|---|---|
committer | akalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-10 09:23:39 +0000 |
commit | ec5263a0914ca9f58586f3808b1ab45acd3b9400 (patch) | |
tree | 9e119d6b7578eb6ab348fd4334c5bd9c818f0bbe /base | |
parent | 46be25eca97a31cae1b48a59513591f32d0ce6b4 (diff) | |
download | chromium_src-ec5263a0914ca9f58586f3808b1ab45acd3b9400.zip chromium_src-ec5263a0914ca9f58586f3808b1ab45acd3b9400.tar.gz chromium_src-ec5263a0914ca9f58586f3808b1ab45acd3b9400.tar.bz2 |
[Sync] Remove more boilerplate from chrome://sync-internals js files
Add new JsEventDetails class which encapsulates a DictionaryValue.
Make JS events use that instead of JsArgList.
Automate listening to log events in sync_log.js.
Cleaned up javascript files a bit.
Add Swap() method to DictionaryValue.
BUG=
TEST=
Review URL: http://codereview.chromium.org/6951009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84767 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base')
-rw-r--r-- | base/values.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/base/values.h b/base/values.h index 49ac219..6fb3240 100644 --- a/base/values.h +++ b/base/values.h @@ -308,6 +308,11 @@ class BASE_API DictionaryValue : public Value { // replaced. void MergeDictionary(const DictionaryValue* dictionary); + // Swaps contents with the |other| dictionary. + void Swap(DictionaryValue* other) { + dictionary_.swap(other->dictionary_); + } + // This class provides an iterator for the keys in the dictionary. // It can't be used to modify the dictionary. // |