diff options
author | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-12 19:15:03 +0000 |
---|---|---|
committer | dmazzoni@chromium.org <dmazzoni@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-07-12 19:15:03 +0000 |
commit | f3a1c64a4d81c412273ed567536f23c2c14813a2 (patch) | |
tree | f0ced21805b18546e879413e4f808dd4f683c534 | |
parent | 2338319a9acbaecba44243740b3f01b5c408a78a (diff) | |
download | chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.zip chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.tar.gz chromium_src-f3a1c64a4d81c412273ed567536f23c2c14813a2.tar.bz2 |
Move base/values.h into the base namespace. This includes a cros DEPS roll
with a minor change to that code since libcros also uses base/values.h.
BUG=88666
TEST=none
Review URL: http://codereview.chromium.org/7259019
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@92208 0039d316-1c4b-4281-b951-d872f2087c98
281 files changed, 1799 insertions, 1266 deletions
diff --git a/base/json/json_reader.h b/base/json/json_reader.h index 4f83492..46e450c 100644 --- a/base/json/json_reader.h +++ b/base/json/json_reader.h @@ -43,10 +43,10 @@ #define FRIEND_TEST(test_case_name, test_name)\ friend class test_case_name##_##test_name##_Test -class Value; - namespace base { +class Value; + class BASE_API JSONReader { public: // A struct to hold a JS token. diff --git a/base/json/json_writer.h b/base/json/json_writer.h index c019e87..36331bb 100644 --- a/base/json/json_writer.h +++ b/base/json/json_writer.h @@ -11,10 +11,10 @@ #include "base/base_api.h" #include "base/basictypes.h" -class Value; - namespace base { +class Value; + class BASE_API JSONWriter { public: // Given a root node, generates a JSON string and puts it into |json|. diff --git a/base/value_conversions.h b/base/value_conversions.h index 75246d1..5ed7550c 100644 --- a/base/value_conversions.h +++ b/base/value_conversions.h @@ -11,11 +11,12 @@ #include "base/base_api.h" class FilePath; -class StringValue; -class Value; namespace base { +class StringValue; +class Value; + // The caller takes ownership of the returned value. BASE_API StringValue* CreateFilePathValue(const FilePath& in_value); BASE_API bool GetValueAsFilePath(const Value& value, FilePath* file_path); diff --git a/base/values.h b/base/values.h index a00a17c..21ddfce 100644 --- a/base/values.h +++ b/base/values.h @@ -32,6 +32,13 @@ #include "base/string16.h" #include "build/build_config.h" +// This file declares "using base::Value", etc. at the bottom, so that +// current code can use these classes without the base namespace. In +// new code, please always use base::Value, etc. or add your own +// "using" declaration. +// http://crbug.com/88666 +namespace base { + class BinaryValue; class DictionaryValue; class FundamentalValue; @@ -455,4 +462,17 @@ class BASE_API ValueSerializer { virtual Value* Deserialize(int* error_code, std::string* error_str) = 0; }; +} // namespace base + +// http://crbug.com/88666 +using base::BinaryValue; +using base::DictionaryValue; +using base::FundamentalValue; +using base::ListValue; +using base::StringValue; +using base::Value; +using base::ValueMap; +using base::ValueSerializer; +using base::ValueVector; + #endif // BASE_VALUES_H_ diff --git a/chrome/browser/about_flags.h b/chrome/browser/about_flags.h index 780e9fb..e690bef 100644 --- a/chrome/browser/about_flags.h +++ b/chrome/browser/about_flags.h @@ -11,9 +11,12 @@ #include "base/command_line.h" -class ListValue; class PrefService; +namespace base { +class ListValue; +} + namespace about_flags { // Enumeration of OSs. @@ -87,7 +90,7 @@ struct Experiment { void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line); // Get a list of all available experiments. The caller owns the result. -ListValue* GetFlagsExperimentsData(PrefService* prefs); +base::ListValue* GetFlagsExperimentsData(PrefService* prefs); // Returns true if one of the experiment flags has been flipped since startup. bool IsRestartNeededToCommitChanges(); diff --git a/chrome/browser/accessibility_events.h b/chrome/browser/accessibility_events.h index 072bd9e..5d7a012 100644 --- a/chrome/browser/accessibility_events.h +++ b/chrome/browser/accessibility_events.h @@ -9,9 +9,12 @@ #include <string> class AccessibilityControlInfo; -class DictionaryValue; class Profile; +namespace base { +class DictionaryValue; +} + // Use the NotificationService to post the given accessibility // notification type with AccessibilityControlInfo details to any // listeners. Will not send if the profile's pause level is nonzero @@ -27,7 +30,7 @@ class AccessibilityControlInfo { // Serialize this class as a DictionaryValue that can be converted to // a JavaScript object. - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; // Return the specific type of this control, which will be one of the // string constants defined in extension_accessibility_api_constants.h. @@ -86,7 +89,7 @@ class AccessibilityRadioButtonInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetChecked(bool checked) { checked_ = checked; } @@ -111,7 +114,7 @@ class AccessibilityCheckboxInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetChecked(bool checked) { checked_ = checked; } @@ -132,7 +135,7 @@ class AccessibilityTabInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetTab(int tab_index, std::string tab_name) { tab_index_ = tab_index; @@ -160,7 +163,7 @@ class AccessibilityComboBoxInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetValue(int item_index, const std::string& value) { item_index_ = item_index; @@ -190,7 +193,7 @@ class AccessibilityTextBoxInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetValue( const std::string& value, int selection_start, int selection_end) { @@ -223,7 +226,7 @@ class AccessibilityListBoxInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; void SetValue(int item_index, std::string value) { item_index_ = item_index; @@ -264,7 +267,7 @@ class AccessibilityMenuItemInfo : public AccessibilityControlInfo { virtual const char* type() const; - virtual void SerializeToDict(DictionaryValue* dict) const; + virtual void SerializeToDict(base::DictionaryValue* dict) const; int item_index() const { return item_index_; } int item_count() const { return item_count_; } diff --git a/chrome/browser/autocomplete/search_provider.h b/chrome/browser/autocomplete/search_provider.h index e0a747a..287a40d 100644 --- a/chrome/browser/autocomplete/search_provider.h +++ b/chrome/browser/autocomplete/search_provider.h @@ -29,7 +29,10 @@ #include "content/common/url_fetcher.h" class Profile; + +namespace base { class Value; +} // Autocomplete provider for searches and suggestions from a search engine. // @@ -199,7 +202,7 @@ class SearchProvider : public AutocompleteProvider, // Parses the results from the Suggest server and stores up to kMaxMatches of // them in server_results_. Returns whether parsing succeeded. - bool ParseSuggestResults(Value* root_val, + bool ParseSuggestResults(base::Value* root_val, bool is_keyword, const string16& input_text, SuggestResults* suggest_results); diff --git a/chrome/browser/automation/automation_provider.h b/chrome/browser/automation/automation_provider.h index 15a47c6..e907150 100644 --- a/chrome/browser/automation/automation_provider.h +++ b/chrome/browser/automation/automation_provider.h @@ -55,7 +55,6 @@ class AutomationTabTracker; class AutomationWindowTracker; class Browser; class CreditCard; -class DictionaryValue; class DownloadItem; class Extension; class ExtensionPortContainer; @@ -63,7 +62,6 @@ class ExtensionTestResultNotificationObserver; class ExternalTabContainer; class FilePath; class InitialLoadObserver; -class ListValue; class LoginHandler; class MetricEventDurationObserver; class NavigationController; @@ -73,6 +71,10 @@ class RenderViewHost; class TabContents; struct AutocompleteMatchData; +namespace base { +class DictionaryValue; +} + namespace gfx { class Point; } @@ -149,7 +151,8 @@ class AutomationProvider // Get the DictionaryValue equivalent for a download item. Caller owns the // DictionaryValue. - DictionaryValue* GetDictionaryFromDownloadItem(const DownloadItem* download); + base::DictionaryValue* GetDictionaryFromDownloadItem( + const DownloadItem* download); protected: friend struct BrowserThread::DeleteOnThread<BrowserThread::UI>; diff --git a/chrome/browser/automation/automation_provider_json.h b/chrome/browser/automation/automation_provider_json.h index 0e23f86..1ea31db 100644 --- a/chrome/browser/automation/automation_provider_json.h +++ b/chrome/browser/automation/automation_provider_json.h @@ -14,9 +14,12 @@ class AutomationProvider; class Browser; -class DictionaryValue; class TabContents; + +namespace base { +class DictionaryValue; class Value; +} namespace IPC { class Message; @@ -35,7 +38,7 @@ class AutomationJSONReply { // Send a success reply along with data contained in |value|. // An empty message will be sent if |value| is NULL. - void SendSuccess(const Value* value); + void SendSuccess(const base::Value* value); // Send an error reply along with error message |error_message|. void SendError(const std::string& error_message); @@ -48,7 +51,7 @@ class AutomationJSONReply { // Gets the browser specified by the given dictionary |args|. |args| should // contain a key 'windex' which refers to the index of the browser. Returns // true on success and sets |browser|. Otherwise, |error| will be set. -bool GetBrowserFromJSONArgs(DictionaryValue* args, +bool GetBrowserFromJSONArgs(base::DictionaryValue* args, Browser** browser, std::string* error) WARN_UNUSED_RESULT; @@ -56,7 +59,7 @@ bool GetBrowserFromJSONArgs(DictionaryValue* args, // contain a key 'windex' which refers to the index of the parent browser, // and a key 'tab_index' which refers to the index of the tab in that browser. // Returns true on success and sets |tab|. Otherwise, |error| will be set. -bool GetTabFromJSONArgs(DictionaryValue* args, +bool GetTabFromJSONArgs(base::DictionaryValue* args, TabContents** tab, std::string* error) WARN_UNUSED_RESULT; @@ -65,7 +68,7 @@ bool GetTabFromJSONArgs(DictionaryValue* args, // a key 'tab_index' which refers to the index of the tab in that browser. // Returns true on success and sets |browser| and |tab|. Otherwise, |error| // will be set. -bool GetBrowserAndTabFromJSONArgs(DictionaryValue* args, +bool GetBrowserAndTabFromJSONArgs(base::DictionaryValue* args, Browser** browser, TabContents** tab, std::string* error) WARN_UNUSED_RESULT; diff --git a/chrome/browser/automation/automation_provider_observers.h b/chrome/browser/automation/automation_provider_observers.h index 9dc6d22..b513405 100644 --- a/chrome/browser/automation/automation_provider_observers.h +++ b/chrome/browser/automation/automation_provider_observers.h @@ -84,7 +84,7 @@ class InitialLoadObserver : public NotificationObserver { // stop_time_ms values may be null if WaitForInitialLoads has not finished. // Only includes entries for the |tab_count| tabs we are monitoring. // There is no defined ordering of the return value. - DictionaryValue* GetTimingInformation() const; + base::DictionaryValue* GetTimingInformation() const; private: class TabTime; @@ -1250,7 +1250,7 @@ class NTPInfoObserver : public NotificationObserver { scoped_ptr<IPC::Message> reply_message_; CancelableRequestConsumer* consumer_; CancelableRequestProvider::Handle request_; - scoped_ptr<DictionaryValue> ntp_info_; + scoped_ptr<base::DictionaryValue> ntp_info_; history::TopSites* top_sites_; NotificationRegistrar registrar_; diff --git a/chrome/browser/automation/automation_util.h b/chrome/browser/automation/automation_util.h index cda8a5f..b15cf2a 100644 --- a/chrome/browser/automation/automation_util.h +++ b/chrome/browser/automation/automation_util.h @@ -12,10 +12,13 @@ class AutomationProvider; class Browser; -class DictionaryValue; class GURL; class TabContents; +namespace base { +class DictionaryValue; +} + namespace IPC { class Message; } @@ -54,19 +57,19 @@ void DeleteCookie(const GURL& url, // Gets the cookies for the given URL. Uses the JSON interface. // See |TestingAutomationProvider| for example input. void GetCookiesJSON(AutomationProvider* provider, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Deletes the cookie with the given name for the URL. Uses the JSON interface. // See |TestingAutomationProvider| for example input. void DeleteCookieJSON(AutomationProvider* provider, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Sets a cookie for the given URL. Uses the JSON interface. // See |TestingAutomationProvider| for example input. void SetCookieJSON(AutomationProvider* provider, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); } // namespace automation_util diff --git a/chrome/browser/automation/testing_automation_provider.h b/chrome/browser/automation/testing_automation_provider.h index d8b1497..05cebfd 100644 --- a/chrome/browser/automation/testing_automation_provider.h +++ b/chrome/browser/automation/testing_automation_provider.h @@ -21,9 +21,12 @@ #include "content/common/page_type.h" #include "third_party/WebKit/Source/WebKit/chromium/public/WebInputEvent.h" -class DictionaryValue; class TemplateURLService; +namespace base { +class DictionaryValue; +} + // This is an automation provider containing testing calls. class TestingAutomationProvider : public AutomationProvider, public BrowserList::Observer, @@ -351,20 +354,20 @@ class TestingAutomationProvider : public AutomationProvider, // Method ptr for json handlers. // Uses the JSON interface for input/output. - typedef void (TestingAutomationProvider::*JsonHandler)(DictionaryValue*, + typedef void (TestingAutomationProvider::*JsonHandler)(base::DictionaryValue*, IPC::Message*); // Method ptr for json handlers that take a browser argument. // Uses the JSON interface for input/output. typedef void (TestingAutomationProvider::*BrowserJsonHandler)( Browser* browser, - DictionaryValue*, + base::DictionaryValue*, IPC::Message*); // Set window dimensions. // Uses the JSON interface for input/output. void SetWindowDimensions(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about infobars in the given TabContents object. @@ -376,103 +379,103 @@ class TestingAutomationProvider : public AutomationProvider, // Perform actions on an infobar like dismiss, accept, cancel. // Uses the JSON interface for input/output. void PerformActionOnInfobar(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about the chromium/chrome in use. // This includes things like version, executable name, executable path. // Uses the JSON interface for input/output. void GetBrowserInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about the state of navigation in a given tab. // This includes ssl info. // Uses the JSON interface for input/output. void GetNavigationInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about downloads. This includes only ones that have been // registered by the history system. // Uses the JSON interface for input/output. void GetDownloadsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Wait for all downloads to complete. // Uses the JSON interface for input/output. void WaitForDownloadsToComplete(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Performs the given action on the specified download. // Uses the JSON interface for input/output. void PerformActionOnDownload(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about history. // Uses the JSON interface for input/output. void GetHistoryInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Add an item to the history service. // Uses the JSON interface for input/output. void AddHistoryItem(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Invoke loading of template url model. // Uses the JSON interface for input/output. void LoadSearchEngineInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get search engines list. // Assumes that the profile's template url model is loaded. // Uses the JSON interface for input/output. void GetSearchEngineInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Add or edit search engine. // Assumes that the profile's template url model is loaded. // Uses the JSON interface for input/output. void AddOrEditSearchEngine(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Perform a given action on an existing search engine. // Assumes that the profile's template url model is loaded. // Uses the JSON interface for input/output. void PerformActionOnSearchEngine(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about preferences stored in Local State. // Uses the JSON interface for input/output. void GetLocalStatePrefsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Set local state prefs. // Uses the JSON interface for input/output. void SetLocalStatePrefs(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about preferences. // Uses the JSON interface for input/output. void GetPrefsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Set prefs. // Uses the JSON interface for input/output. void SetPrefs(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Return load times of initial tabs. @@ -481,25 +484,25 @@ class TestingAutomationProvider : public AutomationProvider, // See declaration of InitialLoadObserver in automation_provider_observers.h // for example response. void GetInitialLoadTimes(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about plugins. // Uses the JSON interface for input/output. void GetPluginsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Enable a plugin. // Uses the JSON interface for input/output. void EnablePlugin(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Disable a plugin. // Uses the JSON interface for input/output. void DisablePlugin(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about omnibox. @@ -507,19 +510,19 @@ class TestingAutomationProvider : public AutomationProvider, // in the omnibox popup, the text in the omnibox. // Uses the JSON interface for input/output. void GetOmniboxInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Set text in the omnibox. This sets focus to the omnibox. // Uses the JSON interface for input/output. void SetOmniboxText(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Move omnibox popup selection up or down. // Uses the JSON interface for input/output. void OmniboxMovePopupSelection(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Accept the current string of text in the omnibox. @@ -527,25 +530,25 @@ class TestingAutomationProvider : public AutomationProvider, // Blocks until the page loads. // Uses the JSON interface for input/output. void OmniboxAcceptInput(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Generate dictionary info about instant tab. // Uses the JSON interface for input/output. void GetInstantInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Save the contents of a tab into a file. // Uses the JSON interface for input/output. void SaveTabContents(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Import the given settings from the given browser. // Uses the JSON interface for input/output. void ImportSettings(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Add a new entry to the password store based on the password information @@ -553,57 +556,57 @@ class TestingAutomationProvider : public AutomationProvider, // will never fill in the password). // Uses the JSON interface for input/output. void AddSavedPassword(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Removes the password matching the information provided. This method can // also be used to remove a blacklisted site. // Uses the JSON interface for input/output. void RemoveSavedPassword(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Return the saved username/password combinations. // Uses the JSON interface for input/output. void GetSavedPasswords(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Clear the specified browsing data. This call provides similar // functionality to RemoveBrowsingData but is synchronous. // Uses the JSON interface for input/output. void ClearBrowsingData(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about blocked popups in a tab. // Uses the JSON interface for input/output. void GetBlockedPopupsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Launch a blocked popup. // Uses the JSON interface for input/output. void UnblockAndLaunchBlockedPopup(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about theme. // Uses the JSON interface for input/output. void GetThemeInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get info about all intalled extensions. // Uses the JSON interface for input/output. void GetExtensionsInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Uninstalls the extension with the given id. // Uses the JSON interface for input/output. void UninstallExtensionById(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Set extension states: @@ -611,42 +614,42 @@ class TestingAutomationProvider : public AutomationProvider, // Allow/disallow extension in incognito mode. // Uses the JSON interface for input/output. void SetExtensionStateById(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Responds to the Find request and returns the match count. void FindInPage(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Returns information about translation for a given tab. Includes // information about the translate bar if it is showing. void GetTranslateInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Takes the specified action on the translate bar. // Uses the JSON interface for input/output. void SelectTranslateOption(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Get the profiles that are currently saved to the DB. // Uses the JSON interface for input/output. void GetAutofillProfile(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Fill in an AutofillProfile with the given profile information. // Uses the JSON interface for input/output. void FillAutofillProfile(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Causes the autofill popup to be displayed in an already-focused webpage // form field. Waits until the popup is displayed before returning. void AutofillTriggerSuggestions(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* message); // Highlights the previous or next autofill entry in an already-displayed @@ -655,7 +658,7 @@ class TestingAutomationProvider : public AutomationProvider, // to be displayed in the webpage form before returning. Use // AutofillTriggerSuggestions() to cause the autofill popup to be displayed. void AutofillHighlightSuggestion(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* message); // Causes a webpage form to be filled with autofill information from an @@ -663,43 +666,43 @@ class TestingAutomationProvider : public AutomationProvider, // AutofillHighlightSuggestion() as needed to highlight the desired profile // in the autofill popup. void AutofillAcceptSelection(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* message); // Signs in to sync using the given username and password. // Uses the JSON interface for input/output. void SignInToSync(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Returns info about sync. // Uses the JSON interface for input/output. void GetSyncInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Waits for the ongoing sync cycle to complete. // Uses the JSON interface for input/output. void AwaitSyncCycleCompletion(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Waits for sync to reinitialize (for example, after a browser restart). // Uses the JSON interface for input/output. void AwaitSyncRestart(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Enables sync for one or more sync datatypes. // Uses the JSON interface for input/output. void EnableSyncForDatatypes(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Disables sync for one or more sync datatypes. // Uses the JSON interface for input/output. void DisableSyncForDatatypes(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Translate DictionaryValues of autofill profiles and credit cards to the @@ -708,16 +711,16 @@ class TestingAutomationProvider : public AutomationProvider, // profiles/cards: the ListValue of profiles/credit cards to translate. // error_message: a pointer to the return string in case of error. static std::vector<AutofillProfile> GetAutofillProfilesFromList( - const ListValue& profiles, std::string* error_message); + const base::ListValue& profiles, std::string* error_message); static std::vector<CreditCard> GetCreditCardsFromList( - const ListValue& cards, std::string* error_message); + const base::ListValue& cards, std::string* error_message); // The opposite of the above: translates from the internal data structure // for profiles and credit cards to a ListValue of DictionaryValues. The // caller owns the returned object. - static ListValue* GetListFromAutofillProfiles( + static base::ListValue* GetListFromAutofillProfiles( const std::vector<AutofillProfile*>& autofill_profiles); - static ListValue* GetListFromCreditCards( + static base::ListValue* GetListFromCreditCards( const std::vector<CreditCard*>& credit_cards); // Return the map from the internal data representation to the string value @@ -730,63 +733,63 @@ class TestingAutomationProvider : public AutomationProvider, // Get a list of active HTML5 notifications. // Uses the JSON interface for input/output. void GetActiveNotifications(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Close an active HTML5 notification. // Uses the JSON interface for input/output. void CloseNotification(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Waits for the number of active HTML5 notifications to reach a given count. // Uses the JSON interface for input/output. void WaitForNotificationCount(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Gets info about the elements in the NTP. // Uses the JSON interface for input/output. void GetNTPInfo(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Moves a thumbnail in the NTP's Most Visited sites section to a different // index. // Uses the JSON interface for input/output. void MoveNTPMostVisitedThumbnail(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Removes a thumbnail from the NTP's Most Visited sites section. // Uses the JSON interface for input/output. void RemoveNTPMostVisitedThumbnail(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Unpins a thumbnail in the NTP's Most Visited sites section. // Uses the JSON interface for input/output. void UnpinNTPMostVisitedThumbnail(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Restores all thumbnails that have been removed (i.e., blacklisted) from the // NTP's Most Visited sites section. // Uses the JSON interface for input/output. void RestoreAllNTPMostVisitedThumbnails(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Kills the given renderer process and returns after the associated // RenderProcessHost receives notification of its closing. void KillRendererProcess(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Populates the fields of the event parameter with what is found in the // args parameter. Upon failure, returns false and puts the error message in // the error parameter, otherwise returns true. - bool BuildWebKeyEventFromArgs(DictionaryValue* args, + bool BuildWebKeyEventFromArgs(base::DictionaryValue* args, std::string* error, NativeWebKeyboardEvent* event); @@ -804,38 +807,38 @@ class TestingAutomationProvider : public AutomationProvider, // Determines whether each relevant section of the NTP is in thumbnail mode. void GetNTPThumbnailMode(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Puts or removes the specified section of the NTP into/from thumbnail mode. // If the section is put into thumbnail mode, all other relevant sections are // removed from thumbnail mode. void SetNTPThumbnailMode(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Determines whether each relevant section of the NTP is in menu mode. void GetNTPMenuMode(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Puts or removes the specified section of the NTP into/from menu mode. void SetNTPMenuMode(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Launches the specified app from the currently-selected tab. void LaunchApp(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Sets the launch type for the specified app. void SetAppLaunchType(Browser* browser, - DictionaryValue* args, + base::DictionaryValue* args, IPC::Message* reply_message); // Waits for all tabs to stop loading. - void WaitForAllTabsToStopLoading(DictionaryValue* args, + void WaitForAllTabsToStopLoading(base::DictionaryValue* args, IPC::Message* reply_message); // Gets the browser and tab index of the given tab. Uses the JSON interface. @@ -847,7 +850,8 @@ class TestingAutomationProvider : public AutomationProvider, // "tab_handle": 3 // optional // } // output: { "windex": 1, "tab_index": 5 } - void GetIndicesFromTab(DictionaryValue* args, IPC::Message* reply_message); + void GetIndicesFromTab(base::DictionaryValue* args, + IPC::Message* reply_message); // Navigates to the given URL. Uses the JSON interface. // Example: @@ -857,7 +861,7 @@ class TestingAutomationProvider : public AutomationProvider, // "navigation_count": 1 // number of navigations to wait for // } // output: { "result": AUTOMATION_MSG_NAVIGATION_SUCCESS } - void NavigateToURL(DictionaryValue* args, IPC::Message* reply_message); + void NavigateToURL(base::DictionaryValue* args, IPC::Message* reply_message); // Executes javascript in the specified frame. Uses the JSON interface. // Waits for a result from the |DOMAutomationController|. The javascript @@ -877,7 +881,7 @@ class TestingAutomationProvider : public AutomationProvider, // dropped. // TODO(kkania): Replace the non-JSON counterparts and drop the JSON suffix. void ExecuteJavascriptJSON( - DictionaryValue* args, IPC::Message* reply_message); + base::DictionaryValue* args, IPC::Message* reply_message); // Goes forward in the specified tab. Uses the JSON interface. // Example: @@ -885,7 +889,7 @@ class TestingAutomationProvider : public AutomationProvider, // output: { "did_go_forward": true, // optional // "result": AUTOMATION_MSG_NAVIGATION_SUCCESS // optional // } - void GoForward(DictionaryValue* args, IPC::Message* reply_message); + void GoForward(base::DictionaryValue* args, IPC::Message* reply_message); // Goes back in the specified tab. Uses the JSON interface. // Example: @@ -893,25 +897,26 @@ class TestingAutomationProvider : public AutomationProvider, // output: { "did_go_back": true, // optional // "result": AUTOMATION_MSG_NAVIGATION_SUCCESS // optional // } - void GoBack(DictionaryValue* args, IPC::Message* reply_message); + void GoBack(base::DictionaryValue* args, IPC::Message* reply_message); // Reload the specified tab. Uses the JSON interface. // Example: // input: { "windex": 1, "tab_index": 1 } // output: { "result": AUTOMATION_MSG_NAVIGATION_SUCCESS // optional } - void ReloadJSON(DictionaryValue* args, IPC::Message* reply_message); + void ReloadJSON(base::DictionaryValue* args, IPC::Message* reply_message); // Get the current url of the specified tab. Uses the JSON interface. // Example: // input: { "windex": 1, "tab_index": 1 } // output: { "url": "http://www.google.com" } - void GetTabURLJSON(DictionaryValue* args, IPC::Message* reply_message); + void GetTabURLJSON(base::DictionaryValue* args, IPC::Message* reply_message); // Get the current url of the specified tab. Uses the JSON interface. // Example: // input: { "windex": 1, "tab_index": 1 } // output: { "title": "Google" } - void GetTabTitleJSON(DictionaryValue* args, IPC::Message* reply_message); + void GetTabTitleJSON(base::DictionaryValue* args, + IPC::Message* reply_message); // Captures the entire page of the the specified tab, including the // non-visible portions of the page, and saves the PNG to a file. @@ -919,7 +924,7 @@ class TestingAutomationProvider : public AutomationProvider, // input: { "windex": 1, "tab_index": 1, "path":"/tmp/foo.png"} // output: none void CaptureEntirePageJSON( - DictionaryValue* args, IPC::Message* reply_message); + base::DictionaryValue* args, IPC::Message* reply_message); // Gets the cookies for the given URL. Uses the JSON interface. // "expiry" refers to the amount of seconds since the Unix epoch. If omitted, @@ -937,7 +942,7 @@ class TestingAutomationProvider : public AutomationProvider, // } // ] // } - void GetCookiesJSON(DictionaryValue* args, IPC::Message* reply_message); + void GetCookiesJSON(base::DictionaryValue* args, IPC::Message* reply_message); // Deletes the cookie with the given name for the URL. Uses the JSON // interface. @@ -947,7 +952,8 @@ class TestingAutomationProvider : public AutomationProvider, // "name": "my_cookie" // } // output: none - void DeleteCookieJSON(DictionaryValue* args, IPC::Message* reply_message); + void DeleteCookieJSON(base::DictionaryValue* args, + IPC::Message* reply_message); // Sets a cookie for the given URL. Uses the JSON interface. // "expiry" refers to the amount of seconds since the Unix epoch. If omitted, @@ -971,25 +977,25 @@ class TestingAutomationProvider : public AutomationProvider, // } // } // output: none - void SetCookieJSON(DictionaryValue* args, IPC::Message* reply_message); + void SetCookieJSON(base::DictionaryValue* args, IPC::Message* reply_message); // Gets the ID for every open tab. This ID is unique per session. // Example: // input: none // output: { "ids": [4124, 213, 1] } - void GetTabIds(DictionaryValue* args, IPC::Message* reply_message); + void GetTabIds(base::DictionaryValue* args, IPC::Message* reply_message); // Checks if the given tab ID refers to an open tab. // Example: // input: { "id": 41 } // output: { "is_valid": false } - void IsTabIdValid(DictionaryValue* args, IPC::Message* reply_message); + void IsTabIdValid(base::DictionaryValue* args, IPC::Message* reply_message); // Closes the specified tab. // Example: // input: { "windex": 1, "tab_index": 1 } // output: none - void CloseTabJSON(DictionaryValue* args, IPC::Message* reply_message); + void CloseTabJSON(base::DictionaryValue* args, IPC::Message* reply_message); // Sends the WebKit events for a mouse click at a given coordinate. // Example: @@ -1000,7 +1006,7 @@ class TestingAutomationProvider : public AutomationProvider, // "y": 100 // } // output: none - void WebkitMouseClick(DictionaryValue* args, + void WebkitMouseClick(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit event for a mouse move to a given coordinate. @@ -1011,7 +1017,7 @@ class TestingAutomationProvider : public AutomationProvider, // "y": 100 // } // output: none - void WebkitMouseMove(DictionaryValue* args, + void WebkitMouseMove(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit events for a mouse drag between two coordinates. @@ -1024,7 +1030,7 @@ class TestingAutomationProvider : public AutomationProvider, // "end_y": 100 // } // output: none - void WebkitMouseDrag(DictionaryValue* args, + void WebkitMouseDrag(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit events for a mouse button down at a given coordinate. @@ -1035,7 +1041,7 @@ class TestingAutomationProvider : public AutomationProvider, // "y": 100 // } // output: none - void WebkitMouseButtonDown(DictionaryValue* args, + void WebkitMouseButtonDown(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit events for a mouse button up at a given coordinate. @@ -1046,7 +1052,7 @@ class TestingAutomationProvider : public AutomationProvider, // "y": 100 // } // output: none - void WebkitMouseButtonUp(DictionaryValue* args, + void WebkitMouseButtonUp(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit events for a mouse double click at a given coordinate. @@ -1057,7 +1063,7 @@ class TestingAutomationProvider : public AutomationProvider, // "y": 100 // } // output: none - void WebkitMouseDoubleClick(DictionaryValue* args, + void WebkitMouseDoubleClick(base::DictionaryValue* args, IPC::Message* message); // Drag and drop file paths at a given coordinate. @@ -1071,7 +1077,7 @@ class TestingAutomationProvider : public AutomationProvider, // ], // } // output: none - void DragAndDropFilePaths(DictionaryValue* args, + void DragAndDropFilePaths(base::DictionaryValue* args, IPC::Message* message); // Sends the WebKit key event with the specified properties. @@ -1087,7 +1093,7 @@ class TestingAutomationProvider : public AutomationProvider, // "isSystemKey": false // } // output: none - void SendWebkitKeyEvent(DictionaryValue* args, + void SendWebkitKeyEvent(base::DictionaryValue* args, IPC::Message* message); // Sends the key event from the OS level to the browser window, @@ -1100,7 +1106,7 @@ class TestingAutomationProvider : public AutomationProvider, // "modifiers": automation::kShiftKeyMask, // } // output: none - void SendOSLevelKeyEventToTab(DictionaryValue* args, + void SendOSLevelKeyEventToTab(base::DictionaryValue* args, IPC::Message* message); // Method used as a Task that sends a success AutomationJSONReply. @@ -1111,7 +1117,7 @@ class TestingAutomationProvider : public AutomationProvider, // input: none // output: { "message": "This is an alert!" } void GetAppModalDialogMessage( - DictionaryValue* args, IPC::Message* reply_message); + base::DictionaryValue* args, IPC::Message* reply_message); // Accepts or dismisses the active JavaScript modal dialog. If optional // prompt text is given, it will be used as the result of the prompt dialog. @@ -1121,7 +1127,7 @@ class TestingAutomationProvider : public AutomationProvider, // } // output: none void AcceptOrDismissAppModalDialog( - DictionaryValue* args, IPC::Message* reply_message); + base::DictionaryValue* args, IPC::Message* reply_message); // Activates the given tab. // Example: @@ -1129,78 +1135,86 @@ class TestingAutomationProvider : public AutomationProvider, // "tab_index": 1, // } // output: none - void ActivateTabJSON(DictionaryValue* args, IPC::Message* message); + void ActivateTabJSON(base::DictionaryValue* args, IPC::Message* message); // Gets the version of ChromeDriver automation supported by this server. // Example: // input: none // output: { "version": 1 } - void GetChromeDriverAutomationVersion(DictionaryValue* args, + void GetChromeDriverAutomationVersion(base::DictionaryValue* args, IPC::Message* message); // Auto-updates installed extensions. // Uses the JSON interface for input/output. - void UpdateExtensionsNow(DictionaryValue* args, IPC::Message* reply_message); + void UpdateExtensionsNow(base::DictionaryValue* args, + IPC::Message* reply_message); #if defined(OS_CHROMEOS) - void GetLoginInfo(DictionaryValue* args, IPC::Message* reply_message); + void GetLoginInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void ShowCreateAccountUI(DictionaryValue* args, IPC::Message* reply_message); + void ShowCreateAccountUI(base::DictionaryValue* args, + IPC::Message* reply_message); - void LoginAsGuest(DictionaryValue* args, IPC::Message* reply_message); + void LoginAsGuest(base::DictionaryValue* args, IPC::Message* reply_message); - void Login(DictionaryValue* args, IPC::Message* reply_message); + void Login(base::DictionaryValue* args, IPC::Message* reply_message); - void LockScreen(DictionaryValue* args, IPC::Message* reply_message); + void LockScreen(base::DictionaryValue* args, IPC::Message* reply_message); - void UnlockScreen(DictionaryValue* args, IPC::Message* reply_message); + void UnlockScreen(base::DictionaryValue* args, IPC::Message* reply_message); - void SignoutInScreenLocker(DictionaryValue* args, + void SignoutInScreenLocker(base::DictionaryValue* args, IPC::Message* reply_message); - void GetBatteryInfo(DictionaryValue* args, IPC::Message* reply_message); + void GetBatteryInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void GetNetworkInfo(DictionaryValue* args, IPC::Message* reply_message); + void GetNetworkInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void NetworkScan(DictionaryValue* args, IPC::Message* reply_message); + void NetworkScan(base::DictionaryValue* args, IPC::Message* reply_message); - void GetProxySettings(DictionaryValue* args, IPC::Message* reply_message); + void GetProxySettings(base::DictionaryValue* args, + IPC::Message* reply_message); - void SetProxySettings(DictionaryValue* args, IPC::Message* reply_message); + void SetProxySettings(base::DictionaryValue* args, + IPC::Message* reply_message); - void ConnectToWifiNetwork(DictionaryValue* args, IPC::Message* reply_message); + void ConnectToWifiNetwork(base::DictionaryValue* args, + IPC::Message* reply_message); - void ConnectToHiddenWifiNetwork(DictionaryValue* args, + void ConnectToHiddenWifiNetwork(base::DictionaryValue* args, IPC::Message* reply_message); - void DisconnectFromWifiNetwork(DictionaryValue* args, + void DisconnectFromWifiNetwork(base::DictionaryValue* args, IPC::Message* reply_message); // VPN automation - void AddPrivateNetwork(DictionaryValue* args, IPC::Message* reply_message); + void AddPrivateNetwork(base::DictionaryValue* args, + IPC::Message* reply_message); - void GetPrivateNetworkInfo(DictionaryValue* args, + void GetPrivateNetworkInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void ConnectToPrivateNetwork(DictionaryValue* args, + void ConnectToPrivateNetwork(base::DictionaryValue* args, IPC::Message* reply_message); - void DisconnectFromPrivateNetwork(DictionaryValue* args, + void DisconnectFromPrivateNetwork(base::DictionaryValue* args, IPC::Message* reply_message); - void ForgetWifiNetwork(DictionaryValue* args, IPC::Message* reply_message); + void ForgetWifiNetwork(base::DictionaryValue* args, + IPC::Message* reply_message); - void GetUpdateInfo(DictionaryValue* args, IPC::Message* reply_message); + void GetUpdateInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void UpdateCheck(DictionaryValue* args, IPC::Message* reply_message); + void UpdateCheck(base::DictionaryValue* args, IPC::Message* reply_message); - void SetReleaseTrack(DictionaryValue* args, IPC::Message* reply_message); + void SetReleaseTrack(base::DictionaryValue* args, + IPC::Message* reply_message); - void GetVolumeInfo(DictionaryValue* args, IPC::Message* reply_message); + void GetVolumeInfo(base::DictionaryValue* args, IPC::Message* reply_message); - void SetVolume(DictionaryValue* args, IPC::Message* reply_message); + void SetVolume(base::DictionaryValue* args, IPC::Message* reply_message); - void SetMute(DictionaryValue* args, IPC::Message* reply_message); + void SetMute(base::DictionaryValue* args, IPC::Message* reply_message); #endif // defined(OS_CHROMEOS) void WaitForTabCountToBecome(int browser_handle, diff --git a/chrome/browser/background/background_contents_service.h b/chrome/browser/background/background_contents_service.h index 32e677a..88787f6 100644 --- a/chrome/browser/background/background_contents_service.h +++ b/chrome/browser/background/background_contents_service.h @@ -21,12 +21,15 @@ #include "webkit/glue/window_open_disposition.h" class CommandLine; -class DictionaryValue; class NotificationDelegate; class PrefService; class Profile; class TabContents; +namespace base { +class DictionaryValue; +} + namespace gfx { class Rect; } @@ -114,9 +117,10 @@ class BackgroundContentsService : private NotificationObserver, // Load a BackgroundContent; the settings are read from the provided // dictionary. - void LoadBackgroundContentsFromDictionary(Profile* profile, - const std::string& extension_id, - const DictionaryValue* contents); + void LoadBackgroundContentsFromDictionary( + Profile* profile, + const std::string& extension_id, + const base::DictionaryValue* contents); // Load the manifest-specified BackgroundContents for all apps for the // profile. diff --git a/chrome/browser/bookmarks/bookmark_codec.h b/chrome/browser/bookmarks/bookmark_codec.h index 2d29df8..fa2da5a 100644 --- a/chrome/browser/bookmarks/bookmark_codec.h +++ b/chrome/browser/bookmarks/bookmark_codec.h @@ -19,9 +19,12 @@ class BookmarkModel; class BookmarkNode; + +namespace base { class DictionaryValue; class ListValue; class Value; +} // BookmarkCodec is responsible for encoding/decoding bookmarks into JSON // values. BookmarkCodec is used by BookmarkService. @@ -39,13 +42,13 @@ class BookmarkCodec { // returned object. This is invoked to encode the contents of the bookmark bar // model and is currently a convenience to invoking Encode that takes the // bookmark bar node and other folder node. - Value* Encode(BookmarkModel* model); + base::Value* Encode(BookmarkModel* model); // Encodes the bookmark bar and other folders returning the JSON value. It's // up to the caller to delete the returned object. // This method is public for use by StarredURLDatabase in migrating the // bookmarks out of the database. - Value* Encode(const BookmarkNode* bookmark_bar_node, + base::Value* Encode(const BookmarkNode* bookmark_bar_node, const BookmarkNode* other_folder_node, const BookmarkNode* synced_folder_node); @@ -58,7 +61,7 @@ class BookmarkCodec { BookmarkNode* other_folder_node, BookmarkNode* synced_folder_node, int64* max_node_id, - const Value& value); + const base::Value& value); // Returns the checksum computed during last encoding/decoding call. const std::string& computed_checksum() const { return computed_checksum_; } @@ -96,16 +99,16 @@ class BookmarkCodec { private: // Encodes node and all its children into a Value object and returns it. // The caller takes ownership of the returned object. - Value* EncodeNode(const BookmarkNode* node); + base::Value* EncodeNode(const BookmarkNode* node); // Helper to perform decoding. bool DecodeHelper(BookmarkNode* bb_node, BookmarkNode* other_folder_node, BookmarkNode* synced_folder_node, - const Value& value); + const base::Value& value); // Decodes the children of the specified node. Returns true on success. - bool DecodeChildren(const ListValue& child_value_list, + bool DecodeChildren(const base::ListValue& child_value_list, BookmarkNode* parent); // Reassigns bookmark IDs for all nodes. @@ -120,7 +123,7 @@ class BookmarkCodec { // created appropriately by way of DecodeChildren. If node is NULL a new // node is created and added to parent (parent must then be non-NULL), // otherwise node is used. - bool DecodeNode(const DictionaryValue& value, + bool DecodeNode(const base::DictionaryValue& value, BookmarkNode* parent, BookmarkNode* node); diff --git a/chrome/browser/chromeos/cros/network_library.h b/chrome/browser/chromeos/cros/network_library.h index 778003f..505db4a 100644 --- a/chrome/browser/chromeos/cros/network_library.h +++ b/chrome/browser/chromeos/cros/network_library.h @@ -17,8 +17,10 @@ #include "base/timer.h" #include "third_party/cros/chromeos_network.h" +namespace base { class DictionaryValue; class Value; +} namespace chromeos { @@ -242,8 +244,8 @@ class NetworkDevice { bool support_network_scan() const { return support_network_scan_; } private: - bool ParseValue(int index, const Value* value); - void ParseInfo(const DictionaryValue* info); + bool ParseValue(int index, const base::Value* value); + void ParseInfo(const base::DictionaryValue* info); // General device info. std::string device_path_; @@ -364,8 +366,8 @@ class Network { Network(const std::string& service_path, ConnectionType type); // Parse name/value pairs from libcros. - virtual bool ParseValue(int index, const Value* value); - virtual void ParseInfo(const DictionaryValue* info); + virtual bool ParseValue(int index, const base::Value* value); + virtual void ParseInfo(const base::DictionaryValue* info); // Erase cached credentials, used when "Save password" is unchecked. virtual void EraseCredentials(); @@ -378,7 +380,7 @@ class Network { std::string* dest); virtual void SetBooleanProperty(const char* prop, bool b, bool* dest); virtual void SetIntegerProperty(const char* prop, int i, int* dest); - virtual void SetValueProperty(const char* prop, Value* val); + virtual void SetValueProperty(const char* prop, base::Value* val); virtual void ClearProperty(const char* prop); // This will clear the property if string is empty. Otherwise, it will set it. @@ -502,13 +504,13 @@ class VirtualNetwork : public Network { private: // Network overrides. - virtual bool ParseValue(int index, const Value* value); - virtual void ParseInfo(const DictionaryValue* info); + virtual bool ParseValue(int index, const base::Value* value); + virtual void ParseInfo(const base::DictionaryValue* info); virtual void EraseCredentials(); virtual void CalculateUniqueId(); // VirtualNetwork private methods. - bool ParseProviderValue(int index, const Value* value); + bool ParseProviderValue(int index, const base::Value* value); void set_server_hostname(const std::string& server_hostname) { server_hostname_ = server_hostname; @@ -559,7 +561,7 @@ class WirelessNetwork : public Network { int strength_; // Network overrides. - virtual bool ParseValue(int index, const Value* value); + virtual bool ParseValue(int index, const base::Value* value); private: void set_strength(int strength) { strength_ = strength; } @@ -592,7 +594,7 @@ class CellularNetwork : public WirelessNetwork { Apn(const std::string& apn, const std::string& network_id, const std::string& username, const std::string& password); ~Apn(); - void Set(const DictionaryValue& dict); + void Set(const base::DictionaryValue& dict); }; explicit CellularNetwork(const std::string& service_path); @@ -654,7 +656,7 @@ class CellularNetwork : public WirelessNetwork { protected: // WirelessNetwork overrides. - virtual bool ParseValue(int index, const Value* value); + virtual bool ParseValue(int index, const base::Value* value); ActivationState activation_state_; NetworkTechnology network_technology_; @@ -747,7 +749,7 @@ class WifiNetwork : public WirelessNetwork { virtual void CalculateUniqueId(); // WirelessNetwork overrides. - virtual bool ParseValue(int index, const Value* value); + virtual bool ParseValue(int index, const base::Value* value); void set_encryption(ConnectionSecurity encryption) { encryption_ = encryption; diff --git a/chrome/browser/chromeos/cros_settings.h b/chrome/browser/chromeos/cros_settings.h index 71b1969..a225313 100644 --- a/chrome/browser/chromeos/cros_settings.h +++ b/chrome/browser/chromeos/cros_settings.h @@ -18,9 +18,8 @@ namespace base { template <typename T> struct DefaultLazyInstanceTraits; -} - class Value; +} namespace chromeos { @@ -37,14 +36,14 @@ class CrosSettings : public base::NonThreadSafe { // Sets |in_value| to given |path| in cros settings. // Note that this takes ownership of |in_value|. - void Set(const std::string& path, Value* in_value); + void Set(const std::string& path, base::Value* in_value); // Fires system setting change notification. void FireObservers(const char* path); // Gets settings value of given |path| to |out_value|. // Note that the caller owns |out_value| returned. - bool Get(const std::string& path, Value** out_value) const; + bool Get(const std::string& path, base::Value** out_value) const; // Convenience forms of Set(). These methods will replace any existing // value at that path, even if it has a different type. diff --git a/chrome/browser/chromeos/cros_settings_provider.cc b/chrome/browser/chromeos/cros_settings_provider.cc index de59e3d..95b59c0b 100644 --- a/chrome/browser/chromeos/cros_settings_provider.cc +++ b/chrome/browser/chromeos/cros_settings_provider.cc @@ -7,6 +7,7 @@ #include "base/command_line.h" #include "base/logging.h" #include "base/string_util.h" +#include "base/values.h" #include "chrome/common/chrome_switches.h" namespace chromeos { diff --git a/chrome/browser/chromeos/cros_settings_provider.h b/chrome/browser/chromeos/cros_settings_provider.h index 0cb7fe1..ee88cf7 100644 --- a/chrome/browser/chromeos/cros_settings_provider.h +++ b/chrome/browser/chromeos/cros_settings_provider.h @@ -7,7 +7,9 @@ #include <string> +namespace base { class Value; +} namespace chromeos { @@ -17,18 +19,18 @@ class CrosSettingsProvider { // Sets |in_value| to given |path| in cros settings. // Note that this takes ownership of |in_value|. - void Set(const std::string& path, Value* in_value); + void Set(const std::string& path, base::Value* in_value); // Gets settings value of given |path| to |out_value|. // Note that |out_value| is owned by the caller, not this class. - virtual bool Get(const std::string& path, Value** out_value) const = 0; + virtual bool Get(const std::string& path, base::Value** out_value) const = 0; // Gets the namespace prefix provided by this provider virtual bool HandlesSetting(const std::string& path) = 0; private: // Does the real job for Set(). - virtual void DoSet(const std::string& path, Value* in_value) = 0; + virtual void DoSet(const std::string& path, base::Value* in_value) = 0; }; } // namespace chromeos diff --git a/chrome/browser/chromeos/customization_document.h b/chrome/browser/chromeos/customization_document.h index 0da9347..47ab6c9 100644 --- a/chrome/browser/chromeos/customization_document.h +++ b/chrome/browser/chromeos/customization_document.h @@ -17,13 +17,13 @@ #include "content/common/url_fetcher.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class FilePath; -class ListValue; class PrefService; namespace base { - class Time; +class DictionaryValue; +class ListValue; +class Time; } namespace chromeos { @@ -50,7 +50,7 @@ class CustomizationDocument { const std::string& dictionary_name, const std::string& entry_name) const; - scoped_ptr<DictionaryValue> root_; + scoped_ptr<base::DictionaryValue> root_; private: DISALLOW_COPY_AND_ASSIGN(CustomizationDocument); @@ -111,7 +111,7 @@ class ServicesCustomizationDocument : public CustomizationDocument, // OEM specific carrier deal. class CarrierDeal { public: - explicit CarrierDeal(DictionaryValue* deal_dict); + explicit CarrierDeal(base::DictionaryValue* deal_dict); ~CarrierDeal(); // Returns string with the specified |locale| and |id|. @@ -132,7 +132,7 @@ class ServicesCustomizationDocument : public CustomizationDocument, std::string top_up_url_; int notification_count_; base::Time expire_date_; - DictionaryValue* localized_strings_; + base::DictionaryValue* localized_strings_; DISALLOW_COPY_AND_ASSIGN(CarrierDeal); }; diff --git a/chrome/browser/chromeos/locale_change_guard.h b/chrome/browser/chromeos/locale_change_guard.h index bcab9af..ef60776 100644 --- a/chrome/browser/chromeos/locale_change_guard.h +++ b/chrome/browser/chromeos/locale_change_guard.h @@ -15,11 +15,14 @@ #include "content/common/notification_observer.h" #include "content/common/notification_registrar.h" -class ListValue; class NotificationDetails; class NotificationSource; class Profile; +namespace base { +class ListValue; +} + namespace chromeos { // Performs check whether locale has been changed automatically recently @@ -40,7 +43,7 @@ class LocaleChangeGuard : public NotificationObserver { private: class Delegate; - void RevertLocaleChange(const ListValue* list); + void RevertLocaleChange(const base::ListValue* list); void AcceptLocaleChange(); void Check(); diff --git a/chrome/browser/chromeos/login/enterprise_enrollment_view.h b/chrome/browser/chromeos/login/enterprise_enrollment_view.h index eb9c169..5688ccc 100644 --- a/chrome/browser/chromeos/login/enterprise_enrollment_view.h +++ b/chrome/browser/chromeos/login/enterprise_enrollment_view.h @@ -15,7 +15,9 @@ #include "chrome/common/net/gaia/google_service_auth_error.h" #include "views/view.h" +namespace base { class DictionaryValue; +} namespace views { class GridLayout; @@ -63,7 +65,7 @@ class EnterpriseEnrollmentView : public views::View, private: // Updates the gaia login box. - void UpdateGaiaLogin(const DictionaryValue& args); + void UpdateGaiaLogin(const base::DictionaryValue& args); // Display the given i18n string as error message. void ShowError(int message_id); diff --git a/chrome/browser/chromeos/metrics_cros_settings_provider.h b/chrome/browser/chromeos/metrics_cros_settings_provider.h index c4d8ab4..cdb918e 100644 --- a/chrome/browser/chromeos/metrics_cros_settings_provider.h +++ b/chrome/browser/chromeos/metrics_cros_settings_provider.h @@ -27,8 +27,8 @@ class MetricsCrosSettingsProvider : public CrosSettingsProvider { private: // CrosSettingsProvider implementation. - virtual void DoSet(const std::string& path, Value* value); - virtual bool Get(const std::string& path, Value** value) const; + virtual void DoSet(const std::string& path, base::Value* value); + virtual bool Get(const std::string& path, base::Value** value) const; virtual bool HandlesSetting(const std::string& path); DISALLOW_COPY_AND_ASSIGN(MetricsCrosSettingsProvider); diff --git a/chrome/browser/chromeos/network_message_observer.h b/chrome/browser/chromeos/network_message_observer.h index 17ee943..f42ac77 100644 --- a/chrome/browser/chromeos/network_message_observer.h +++ b/chrome/browser/chromeos/network_message_observer.h @@ -30,8 +30,8 @@ class NetworkMessageObserver : public NetworkLibrary::NetworkManagerObserver, static bool IsApplicableBackupPlan(const CellularDataPlan* plan, const CellularDataPlan* other_plan); private: - virtual void OpenMobileSetupPage(const ListValue* args); - virtual void OpenMoreInfoPage(const ListValue* args); + virtual void OpenMobileSetupPage(const base::ListValue* args); + virtual void OpenMoreInfoPage(const base::ListValue* args); virtual void InitNewPlan(const CellularDataPlan* plan); virtual void ShowNeedsPlanNotification(const CellularNetwork* cellular); virtual void ShowNoDataNotification(CellularDataPlanType plan_type); diff --git a/chrome/browser/chromeos/notifications/balloon_view_host.h b/chrome/browser/chromeos/notifications/balloon_view_host.h index c6f334f..a1fb534 100644 --- a/chrome/browser/chromeos/notifications/balloon_view_host.h +++ b/chrome/browser/chromeos/notifications/balloon_view_host.h @@ -15,12 +15,15 @@ #include "base/compiler_specific.h" #include "ui/gfx/native_widget_types.h" -class ListValue; class GURL; +namespace base { +class ListValue; +} + namespace chromeos { -typedef Callback1<const ListValue*>::Type MessageCallback; +typedef Callback1<const base::ListValue*>::Type MessageCallback; class BalloonViewHost : public ::BalloonViewHost { public: @@ -45,7 +48,7 @@ class BalloonViewHost : public ::BalloonViewHost { // Message handlers. virtual void OnWebUISend(const GURL& source_url, const std::string& name, - const ListValue& args); + const base::ListValue& args); DISALLOW_COPY_AND_ASSIGN(BalloonViewHost); }; diff --git a/chrome/browser/chromeos/offline/offline_load_page.h b/chrome/browser/chromeos/offline/offline_load_page.h index 08a8ba5..115efb0 100644 --- a/chrome/browser/chromeos/offline/offline_load_page.h +++ b/chrome/browser/chromeos/offline/offline_load_page.h @@ -12,10 +12,13 @@ #include "chrome/browser/chromeos/network_state_notifier.h" #include "chrome/browser/tab_contents/chrome_interstitial_page.h" -class DictionaryValue; class Extension; class TabContents; +namespace base { +class DictionaryValue; +} + namespace chromeos { // OfflineLoadPage class shows the interstitial page that is shown @@ -69,9 +72,9 @@ class OfflineLoadPage : public ChromeInterstitialPage { // normal site. void GetAppOfflineStrings(const Extension* app, const string16& faield_url, - DictionaryValue* strings) const; + base::DictionaryValue* strings) const; void GetNormalOfflineStrings(const string16& faield_url, - DictionaryValue* strings) const; + base::DictionaryValue* strings) const; // True if there is a mobile network is available but // has not been activated. diff --git a/chrome/browser/chromeos/user_cros_settings_provider.h b/chrome/browser/chromeos/user_cros_settings_provider.h index a382335..901218f 100644 --- a/chrome/browser/chromeos/user_cros_settings_provider.h +++ b/chrome/browser/chromeos/user_cros_settings_provider.h @@ -12,10 +12,13 @@ #include "chrome/browser/chromeos/cros_settings_provider.h" #include "chrome/browser/chromeos/login/signed_settings_helper.h" -class ListValue; class PrefService; class Task; +namespace base { +class ListValue; +} + namespace chromeos { // CrosSettingsProvider implementation that works with SignedSettings. @@ -48,7 +51,7 @@ class UserCrosSettingsProvider : public CrosSettingsProvider { static bool cached_allow_new_user(); static bool cached_data_roaming_enabled(); static bool cached_show_users_on_signin(); - static const ListValue* cached_whitelist(); + static const base::ListValue* cached_whitelist(); static std::string cached_owner(); // Returns true if given email is in user whitelist. @@ -57,7 +60,7 @@ class UserCrosSettingsProvider : public CrosSettingsProvider { static bool IsEmailInCachedWhitelist(const std::string& email); // CrosSettingsProvider implementation. - virtual bool Get(const std::string& path, Value** out_value) const; + virtual bool Get(const std::string& path, base::Value** out_value) const; virtual bool HandlesSetting(const std::string& path); void WhitelistUser(const std::string& email); @@ -68,7 +71,7 @@ class UserCrosSettingsProvider : public CrosSettingsProvider { private: // CrosSettingsProvider implementation. - virtual void DoSet(const std::string& path, Value* value); + virtual void DoSet(const std::string& path, base::Value* value); DISALLOW_COPY_AND_ASSIGN(UserCrosSettingsProvider); }; diff --git a/chrome/browser/content_settings/content_settings_origin_identifier_value_map.h b/chrome/browser/content_settings/content_settings_origin_identifier_value_map.h index eaf3b89..92be692 100644 --- a/chrome/browser/content_settings/content_settings_origin_identifier_value_map.h +++ b/chrome/browser/content_settings/content_settings_origin_identifier_value_map.h @@ -15,7 +15,10 @@ #include "chrome/common/content_settings_types.h" class GURL; + +namespace base { class Value; +} namespace content_settings { @@ -28,14 +31,14 @@ class OriginIdentifierValueMap { const ContentSettingsPattern& secondary_pattern, ContentSettingsType content_type, ResourceIdentifier identifier, - Value* value); + base::Value* value); ~Entry(); ContentSettingsPattern primary_pattern; ContentSettingsPattern secondary_pattern; ContentSettingsType content_type; ResourceIdentifier identifier; - linked_ptr<Value> value; + linked_ptr<base::Value> value; }; typedef std::list<Entry> EntryList; @@ -70,7 +73,7 @@ class OriginIdentifierValueMap { // Returns a weak pointer to the value for the given |primary_pattern|, // |secondary_pattern|, |content_type|, |resource_identifier| tuple. If // no value is stored for the passed parameter |NULL| is returned. - Value* GetValue( + base::Value* GetValue( const GURL& primary_url, const GURL& secondary_url, ContentSettingsType content_type, @@ -84,7 +87,7 @@ class OriginIdentifierValueMap { const ContentSettingsPattern& secondary_pattern, ContentSettingsType content_type, const ResourceIdentifier& resource_identifier, - Value* value); + base::Value* value); // Deletes the map entry for the given |primary_pattern|, // |secondary_pattern|, |content_type|, |resource_identifier| tuple. diff --git a/chrome/browser/content_settings/content_settings_policy_provider.h b/chrome/browser/content_settings/content_settings_policy_provider.h index f634da7..b9261fe 100644 --- a/chrome/browser/content_settings/content_settings_policy_provider.h +++ b/chrome/browser/content_settings/content_settings_policy_provider.h @@ -20,7 +20,6 @@ #include "content/common/notification_registrar.h" class ContentSettingsDetails; -class DictionaryValue; class HostContentSettingsMap; class PrefService; diff --git a/chrome/browser/content_settings/content_settings_pref_provider.h b/chrome/browser/content_settings/content_settings_pref_provider.h index c30e404..e7d5386 100644 --- a/chrome/browser/content_settings/content_settings_pref_provider.h +++ b/chrome/browser/content_settings/content_settings_pref_provider.h @@ -22,10 +22,13 @@ #include "content/common/notification_registrar.h" class ContentSettingsDetails; -class DictionaryValue; class HostContentSettingsMap; class PrefService; +namespace base { +class DictionaryValue; +} + namespace content_settings { // Content settings provider that provides default content settings based on @@ -62,7 +65,7 @@ class PrefDefaultProvider : public DefaultProviderInterface, void NotifyObservers(const ContentSettingsDetails& details); // Sets the fields of |settings| based on the values in |dictionary|. - void GetSettingsFromDictionary(const DictionaryValue* dictionary, + void GetSettingsFromDictionary(const base::DictionaryValue* dictionary, ContentSettings* settings); // Forces the default settings to be explicitly set instead of themselves @@ -187,7 +190,7 @@ class PrefProvider : public ProviderInterface, void SyncObsoletePref(); static void CanonicalizeContentSettingsExceptions( - DictionaryValue* all_settings_dictionary); + base::DictionaryValue* all_settings_dictionary); void NotifyObservers(const ContentSettingsDetails& details); diff --git a/chrome/browser/content_settings/host_content_settings_map.h b/chrome/browser/content_settings/host_content_settings_map.h index 10fda10..ec454a0 100644 --- a/chrome/browser/content_settings/host_content_settings_map.h +++ b/chrome/browser/content_settings/host_content_settings_map.h @@ -31,7 +31,6 @@ class ProviderInterface; } // namespace content_settings class ContentSettingsDetails; -class DictionaryValue; class ExtensionService; class GURL; class PrefService; diff --git a/chrome/browser/download/download_util.h b/chrome/browser/download/download_util.h index 20a5693..90f669a 100644 --- a/chrome/browser/download/download_util.h +++ b/chrome/browser/download/download_util.h @@ -22,7 +22,6 @@ class BaseDownloadItemModel; class CrxInstaller; -class DictionaryValue; class DownloadItem; class DownloadManager; class GURL; @@ -34,6 +33,7 @@ struct DownloadCreateInfo; struct DownloadSaveInfo; namespace base { +class DictionaryValue; class TimeTicks; } @@ -227,7 +227,7 @@ void DragDownload(const DownloadItem* download, // Creates a representation of a download in a format that the downloads // HTML page can understand. -DictionaryValue* CreateDownloadItemValue(DownloadItem* download, int id); +base::DictionaryValue* CreateDownloadItemValue(DownloadItem* download, int id); // Get the localized status text for an in-progress download. string16 GetProgressStatusText(DownloadItem* download); diff --git a/chrome/browser/enumerate_modules_model_win.h b/chrome/browser/enumerate_modules_model_win.h index f0cdd6d..d9c0de4 100644 --- a/chrome/browser/enumerate_modules_model_win.h +++ b/chrome/browser/enumerate_modules_model_win.h @@ -19,7 +19,10 @@ class EnumerateModulesModel; class FilePath; + +namespace base { class ListValue; +} // A helper class that implements the enumerate module functionality on the File // thread. @@ -261,7 +264,7 @@ class EnumerateModulesModel { void ScanNow(); // Gets the whole module list as a ListValue. - ListValue* GetModuleList() const; + base::ListValue* GetModuleList() const; private: friend struct DefaultSingletonTraits<EnumerateModulesModel>; diff --git a/chrome/browser/extensions/crx_installer.h b/chrome/browser/extensions/crx_installer.h index 0589d1e..171105b 100644 --- a/chrome/browser/extensions/crx_installer.h +++ b/chrome/browser/extensions/crx_installer.h @@ -59,7 +59,7 @@ class CrxInstaller WhitelistEntry(); ~WhitelistEntry(); - scoped_ptr<DictionaryValue> parsed_manifest; + scoped_ptr<base::DictionaryValue> parsed_manifest; std::string localized_name; }; @@ -168,7 +168,7 @@ class CrxInstaller virtual void OnUnpackFailure(const std::string& error_message); virtual void OnUnpackSuccess(const FilePath& temp_dir, const FilePath& extension_dir, - const DictionaryValue* original_manifest, + const base::DictionaryValue* original_manifest, const Extension* extension); // Returns true if we can skip confirmation because the install was @@ -237,7 +237,7 @@ class CrxInstaller // A parsed copy of the unmodified original manifest, before any // transformations like localization have taken place. - scoped_ptr<DictionaryValue> original_manifest_; + scoped_ptr<base::DictionaryValue> original_manifest_; // If non-empty, contains the current version of the extension we're // installing (for upgrades). diff --git a/chrome/browser/extensions/extension_bookmark_helpers.h b/chrome/browser/extensions/extension_bookmark_helpers.h index 5b0a381..beb7600 100644 --- a/chrome/browser/extensions/extension_bookmark_helpers.h +++ b/chrome/browser/extensions/extension_bookmark_helpers.h @@ -12,21 +12,24 @@ class BookmarkModel; class BookmarkNode; + +namespace base { class DictionaryValue; class ListValue; +} // Helper functions. namespace extension_bookmark_helpers { -DictionaryValue* GetNodeDictionary(const BookmarkNode* node, - bool recurse, - bool only_folders); +base::DictionaryValue* GetNodeDictionary(const BookmarkNode* node, + bool recurse, + bool only_folders); // Add a JSON representation of |node| to the JSON |list|. -void AddNode(const BookmarkNode* node, ListValue* list, bool recurse); +void AddNode(const BookmarkNode* node, base::ListValue* list, bool recurse); void AddNodeFoldersOnly(const BookmarkNode* node, - ListValue* list, + base::ListValue* list, bool recurse); bool RemoveNode(BookmarkModel* model, diff --git a/chrome/browser/extensions/extension_bookmark_manager_api.h b/chrome/browser/extensions/extension_bookmark_manager_api.h index f2bff9b..0f02d59 100644 --- a/chrome/browser/extensions/extension_bookmark_manager_api.h +++ b/chrome/browser/extensions/extension_bookmark_manager_api.h @@ -12,10 +12,13 @@ #include "chrome/browser/ui/bookmarks/bookmark_tab_helper.h" struct BookmarkNodeData; -class ListValue; class Profile; class TabContentsWrapper; +namespace base { +class ListValue; +} + // Class that handles the chrome.experimental.bookmarkManager events. class ExtensionBookmarkManagerEventRouter : public BookmarkTabHelper::BookmarkDrag { @@ -39,7 +42,7 @@ class ExtensionBookmarkManagerEventRouter private: // Helper to actually dispatch an event to extension listeners. - void DispatchEvent(const char* event_name, const ListValue* args); + void DispatchEvent(const char* event_name, const base::ListValue* args); void DispatchDragEvent(const BookmarkNodeData& data, const char* event_name); diff --git a/chrome/browser/extensions/extension_bookmarks_module.h b/chrome/browser/extensions/extension_bookmarks_module.h index 0aecb29..fe9546d 100644 --- a/chrome/browser/extensions/extension_bookmarks_module.h +++ b/chrome/browser/extensions/extension_bookmarks_module.h @@ -20,6 +20,10 @@ class FilePath; +namespace base { +class ListValue; +} + // Observes BookmarkModel and then routes the notifications as events to // the extension system. class ExtensionBookmarkEventRouter : public BookmarkModelObserver { @@ -143,7 +147,7 @@ class RemoveBookmarkFunction : public BookmarksFunction { public: // Returns true on successful parse and sets invalid_id to true if conversion // from id string to int64 failed. - static bool ExtractIds(const ListValue* args, std::list<int64>* ids, + static bool ExtractIds(const base::ListValue* args, std::list<int64>* ids, bool* invalid_id); // BookmarksFunction: virtual bool RunImpl() OVERRIDE; @@ -171,7 +175,7 @@ class CreateBookmarkFunction : public BookmarksFunction { class MoveBookmarkFunction : public BookmarksFunction { public: - static bool ExtractIds(const ListValue* args, std::list<int64>* ids, + static bool ExtractIds(const base::ListValue* args, std::list<int64>* ids, bool* invalid_id); virtual void GetQuotaLimitHeuristics( std::list<QuotaLimitHeuristic*>* heuristics) const; @@ -184,7 +188,7 @@ class MoveBookmarkFunction : public BookmarksFunction { class UpdateBookmarkFunction : public BookmarksFunction { public: - static bool ExtractIds(const ListValue* args, std::list<int64>* ids, + static bool ExtractIds(const base::ListValue* args, std::list<int64>* ids, bool* invalid_id); virtual void GetQuotaLimitHeuristics( std::list<QuotaLimitHeuristic*>* heuristics) const; diff --git a/chrome/browser/extensions/extension_browser_actions_api.h b/chrome/browser/extensions/extension_browser_actions_api.h index ad7b706..127ad4a 100644 --- a/chrome/browser/extensions/extension_browser_actions_api.h +++ b/chrome/browser/extensions/extension_browser_actions_api.h @@ -9,9 +9,12 @@ #include "chrome/browser/extensions/extension_function.h" #include "chrome/common/extensions/extension_action.h" -class DictionaryValue; class ExtensionAction; +namespace base { +class DictionaryValue; +} + // Base class for chrome.browserAction.* APIs. class BrowserActionFunction : public SyncExtensionFunction { protected: @@ -25,7 +28,7 @@ class BrowserActionFunction : public SyncExtensionFunction { // All the browser action APIs take a single argument called details that is // a dictionary. - DictionaryValue* details_; + base::DictionaryValue* details_; // The tab id the browser action function should apply to, if any, or // kDefaultTabId if none was specified. diff --git a/chrome/browser/extensions/extension_content_settings_store.h b/chrome/browser/extensions/extension_content_settings_store.h index cdba784..f9a7765 100644 --- a/chrome/browser/extensions/extension_content_settings_store.h +++ b/chrome/browser/extensions/extension_content_settings_store.h @@ -20,8 +20,9 @@ #include "chrome/common/content_settings.h" #include "googleurl/src/gurl.h" -class DictionaryValue; +namespace base { class ListValue; +} // This class is the backend for extension-defined content settings. It is used // by the content_settings::ExtensionProvider to integrate its settings into the @@ -82,13 +83,13 @@ class ExtensionContentSettingsStore // Serializes all content settings set by the extension with ID |extension_id| // and returns them as a ListValue. The caller takes ownership of the returned // value. - ListValue* GetSettingsForExtension(const std::string& extension_id, - ExtensionPrefsScope scope) const; + base::ListValue* GetSettingsForExtension(const std::string& extension_id, + ExtensionPrefsScope scope) const; // Deserializes content settings rules from |list| and applies them as set by // the extension with ID |extension_id|. void SetExtensionContentSettingsFromList(const std::string& extension_id, - const ListValue* list, + const base::ListValue* list, ExtensionPrefsScope scope); // ////////////////////////////////////////////////////////////////////////// diff --git a/chrome/browser/extensions/extension_context_menu_api.h b/chrome/browser/extensions/extension_context_menu_api.h index a7b1694..64c8ea6 100644 --- a/chrome/browser/extensions/extension_context_menu_api.h +++ b/chrome/browser/extensions/extension_context_menu_api.h @@ -10,16 +10,19 @@ #include "chrome/browser/extensions/extension_menu_manager.h" #include "chrome/common/extensions/url_pattern_set.h" -class DictionaryValue; class ExtensionMenuItem; +namespace base { +class DictionaryValue; +} + class ExtensionContextMenuFunction : public SyncExtensionFunction { public: virtual ~ExtensionContextMenuFunction() {} protected: // Helper function to read and parse a list of menu item contexts. - bool ParseContexts(const DictionaryValue& properties, + bool ParseContexts(const base::DictionaryValue& properties, const char* key, ExtensionMenuItem::ContextList* result); @@ -27,25 +30,25 @@ class ExtensionContextMenuFunction : public SyncExtensionFunction { // error, returns false and puts an error message into error_. If the key is // not present, |result| is set to |default_value| and the return value is // true. - bool ParseType(const DictionaryValue& properties, + bool ParseType(const base::DictionaryValue& properties, const ExtensionMenuItem::Type& default_value, ExtensionMenuItem::Type* result); // Helper to read and parse the "checked" property. bool ParseChecked(ExtensionMenuItem::Type type, - const DictionaryValue& properties, + const base::DictionaryValue& properties, bool default_value, bool* checked); // Helper to read in a set of url patterns from a property with the given key // name. - bool ParseURLPatterns(const DictionaryValue& properties, + bool ParseURLPatterns(const base::DictionaryValue& properties, const char* key, URLPatternSet* result); // Reads in any document and targetUrl patterns from |properties| and sets // them on |item|. - bool SetURLPatterns(const DictionaryValue& properties, + bool SetURLPatterns(const base::DictionaryValue& properties, ExtensionMenuItem* item); // If the parentId key was specified in properties, this will try looking up @@ -54,7 +57,7 @@ class ExtensionContextMenuFunction : public SyncExtensionFunction { // parentId key is not in properties, this will return true and leave |result| // unset. Also, it is considered an error if the item found has a type other // than NORMAL. - bool GetParent(const DictionaryValue& properties, + bool GetParent(const base::DictionaryValue& properties, const ExtensionMenuManager& manager, ExtensionMenuItem** result); }; diff --git a/chrome/browser/extensions/extension_cookies_api.h b/chrome/browser/extensions/extension_cookies_api.h index fbeaf83..63a6aef 100644 --- a/chrome/browser/extensions/extension_cookies_api.h +++ b/chrome/browser/extensions/extension_cookies_api.h @@ -20,7 +20,9 @@ #include "googleurl/src/gurl.h" #include "net/base/cookie_monster.h" +namespace base { class DictionaryValue; +} namespace net { class URLRequestContextGetter; @@ -74,7 +76,7 @@ class CookiesFunction : public AsyncExtensionFunction { // URL is invalid or isn't found in the dictionary. If check_host_permissions // is true, the URL is also checked against the extension's host permissions, // and if there is no permission for the URL, this function returns false. - bool ParseUrl(const DictionaryValue* details, GURL* url, + bool ParseUrl(const base::DictionaryValue* details, GURL* url, bool check_host_permissions); // Checks the given details dictionary for a 'storeId' value, and retrieves @@ -84,7 +86,7 @@ class CookiesFunction : public AsyncExtensionFunction { // assigns the internal error_ value if that occurs. // At least one of the output parameters store and store_id should be // non-NULL. - bool ParseStoreContext(const DictionaryValue* details, + bool ParseStoreContext(const base::DictionaryValue* details, net::URLRequestContextGetter** context, std::string* store_id); }; @@ -119,7 +121,7 @@ class GetAllCookiesFunction : public CookiesFunction { void GetAllCookiesOnIOThread(); void RespondOnUIThread(); - DictionaryValue* details_; + base::DictionaryValue* details_; GURL url_; std::string store_id_; scoped_refptr<net::URLRequestContextGetter> store_context_; diff --git a/chrome/browser/extensions/extension_cookies_helpers.h b/chrome/browser/extensions/extension_cookies_helpers.h index 18bbf8d..43ba424 100644 --- a/chrome/browser/extensions/extension_cookies_helpers.h +++ b/chrome/browser/extensions/extension_cookies_helpers.h @@ -16,11 +16,14 @@ #include "net/base/cookie_monster.h" class Browser; -class DictionaryValue; class Extension; -class ListValue; class Profile; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace extension_cookies_helpers { // Returns either the original profile or the incognito profile, based on the @@ -36,15 +39,15 @@ const char* GetStoreIdFromProfile(Profile* profile); // Constructs a Cookie object as defined by the cookies API. This function // allocates a new DictionaryValue object; the caller is responsible for // freeing it. -DictionaryValue* CreateCookieValue( +base::DictionaryValue* CreateCookieValue( const net::CookieMonster::CanonicalCookie& cookie, const std::string& store_id); // Constructs a CookieStore object as defined by the cookies API. This function // allocates a new DictionaryValue object; the caller is responsible for // freeing it. -DictionaryValue* CreateCookieStoreValue(Profile* profile, - ListValue* tab_ids); +base::DictionaryValue* CreateCookieStoreValue(Profile* profile, + base::ListValue* tab_ids); // Retrieves all cookies from the given cookie store corresponding to the given // URL. If the URL is empty, all cookies in the cookie store are retrieved. @@ -65,13 +68,13 @@ GURL GetURLFromCanonicalCookie( void AppendMatchingCookiesToList( const net::CookieList& all_cookies, const std::string& store_id, - const GURL& url, const DictionaryValue* details, + const GURL& url, const base::DictionaryValue* details, const Extension* extension, - ListValue* match_list); + base::ListValue* match_list); // Appends the IDs of all tabs belonging to the given browser to the // given list. -void AppendToTabIdList(Browser* browser, ListValue* tab_ids); +void AppendToTabIdList(Browser* browser, base::ListValue* tab_ids); // A class representing the cookie filter parameters passed into // cookies.getAll(). @@ -84,7 +87,7 @@ class MatchFilter { // Takes the details dictionary argument given by the user as input. // This class does not take ownership of the lifetime of the DictionaryValue // object. - explicit MatchFilter(const DictionaryValue* details); + explicit MatchFilter(const base::DictionaryValue* details); // Returns true if the given cookie matches the properties in the match // filter. @@ -110,7 +113,7 @@ class MatchFilter { // 'foo.bar.com', '.foo.bar.com', and 'baz.foo.bar.com'. bool MatchesDomain(const std::string& domain); - const DictionaryValue* details_; + const base::DictionaryValue* details_; }; } // namespace extension_cookies_helpers diff --git a/chrome/browser/extensions/extension_debugger_api.h b/chrome/browser/extensions/extension_debugger_api.h index 6d1642e..a4a1fa9 100644 --- a/chrome/browser/extensions/extension_debugger_api.h +++ b/chrome/browser/extensions/extension_debugger_api.h @@ -15,10 +15,13 @@ // Base debugger function. -class DictionaryValue; class ExtensionDevToolsClientHost; class TabContents; +namespace base { +class DictionaryValue; +} + class DebuggerFunction : public AsyncExtensionFunction { protected: DebuggerFunction(); @@ -56,7 +59,7 @@ class SendRequestDebuggerFunction : public DebuggerFunction { virtual ~SendRequestDebuggerFunction(); virtual bool RunImpl(); - void SendResponseBody(DictionaryValue* dictionary); + void SendResponseBody(base::DictionaryValue* dictionary); DECLARE_EXTENSION_FUNCTION_NAME("experimental.debugger.sendRequest") }; diff --git a/chrome/browser/extensions/extension_file_browser_private_api.h b/chrome/browser/extensions/extension_file_browser_private_api.h index f283014..065b9e2 100644 --- a/chrome/browser/extensions/extension_file_browser_private_api.h +++ b/chrome/browser/extensions/extension_file_browser_private_api.h @@ -104,7 +104,7 @@ class ExecuteTasksFileBrowserFunction : public AsyncExtensionFunction { // Initates execution of context menu tasks identified with |task_id| for // each element of |files_list|. bool InitiateFileTaskExecution(const std::string& task_id, - ListValue* files_list); + base::ListValue* files_list); void RequestFileEntryOnFileThread(const GURL& source_url, const std::string& task_id, const std::vector<GURL>& file_urls); diff --git a/chrome/browser/extensions/extension_function.h b/chrome/browser/extensions/extension_function.h index bffffdb7..4b2226e 100644 --- a/chrome/browser/extensions/extension_function.h +++ b/chrome/browser/extensions/extension_function.h @@ -27,10 +27,13 @@ class ExtensionFunction; class ExtensionFunctionDispatcher; class UIThreadExtensionFunction; class IOThreadExtensionFunction; -class ListValue; class QuotaLimitHeuristic; class RenderViewHost; + +namespace base { +class ListValue; class Value; +} #define EXTENSION_FUNCTION_VALIDATE(test) do { \ if (!(test)) { \ @@ -81,7 +84,7 @@ class ExtensionFunction std::list<QuotaLimitHeuristic*>* heuristics) const {} // Specifies the raw arguments to the function, as a JSON value. - virtual void SetArgs(const ListValue* args); + virtual void SetArgs(const base::ListValue* args); // Retrieves the results of the function as a JSON-encoded string (may // be empty). @@ -176,11 +179,11 @@ class ExtensionFunction bool user_gesture_; // The arguments to the API. Only non-null if argument were specified. - scoped_ptr<ListValue> args_; + scoped_ptr<base::ListValue> args_; // The result of the API. This should be populated by the derived class before // SendResponse() is called. - scoped_ptr<Value> result_; + scoped_ptr<base::Value> result_; // Any detailed error from the API. This should be populated by the derived // class before Run() returns. diff --git a/chrome/browser/extensions/extension_function_dispatcher.h b/chrome/browser/extensions/extension_function_dispatcher.h index 5ebd6a2..1ce2f81 100644 --- a/chrome/browser/extensions/extension_function_dispatcher.h +++ b/chrome/browser/extensions/extension_function_dispatcher.h @@ -19,7 +19,6 @@ class Browser; class ChromeRenderMessageFilter; class Extension; class ExtensionFunction; -class ListValue; class Profile; class RenderViewHost; class TabContents; diff --git a/chrome/browser/extensions/extension_history_api.h b/chrome/browser/extensions/extension_history_api.h index d547a46..af57c6b 100644 --- a/chrome/browser/extensions/extension_history_api.h +++ b/chrome/browser/extensions/extension_history_api.h @@ -51,8 +51,8 @@ class HistoryFunction : public AsyncExtensionFunction { virtual void Run(); virtual bool RunImpl() = 0; - bool GetUrlFromValue(Value* value, GURL* url); - bool GetTimeFromValue(Value* value, base::Time* time); + bool GetUrlFromValue(base::Value* value, GURL* url); + bool GetTimeFromValue(base::Value* value, base::Time* time); }; // Base class for history funciton APIs which require async interaction with diff --git a/chrome/browser/extensions/extension_input_ui_api.h b/chrome/browser/extensions/extension_input_ui_api.h index fa6ec5d..592024d 100644 --- a/chrome/browser/extensions/extension_input_ui_api.h +++ b/chrome/browser/extensions/extension_input_ui_api.h @@ -13,7 +13,6 @@ #include "chrome/browser/chromeos/input_method/ibus_ui_controller.h" #include "chrome/browser/extensions/extension_function.h" -class ListValue; class Profile; class ExtensionInputUiEventRouter diff --git a/chrome/browser/extensions/extension_omnibox_api.h b/chrome/browser/extensions/extension_omnibox_api.h index b7b0b02..611bb5d 100644 --- a/chrome/browser/extensions/extension_omnibox_api.h +++ b/chrome/browser/extensions/extension_omnibox_api.h @@ -14,6 +14,10 @@ #include "chrome/browser/extensions/extension_function.h" #include "webkit/glue/window_open_disposition.h" +namespace base { +class ListValue; +} + // Event router class for events related to the omnibox API. class ExtensionOmniboxEventRouter { public: @@ -61,7 +65,7 @@ struct ExtensionOmniboxSuggestion { // Converts a list of style ranges from the extension into the format expected // by the autocomplete system. - bool ReadStylesFromValue(const ListValue& value); + bool ReadStylesFromValue(const base::ListValue& value); // The text that gets put in the edit box. string16 content; diff --git a/chrome/browser/extensions/extension_pref_value_map.h b/chrome/browser/extensions/extension_pref_value_map.h index 4112b17..54538e4 100644 --- a/chrome/browser/extensions/extension_pref_value_map.h +++ b/chrome/browser/extensions/extension_pref_value_map.h @@ -72,7 +72,7 @@ class ExtensionPrefValueMap { void SetExtensionPref(const std::string& ext_id, const std::string& key, ExtensionPrefsScope scope, - Value* value); + base::Value* value); // Remove the extension preference value for |key| of extension |ext_id|. // Precondition: the extension must be registered. @@ -122,9 +122,9 @@ class ExtensionPrefValueMap { void RemoveObserver(Observer* observer); - const Value* GetEffectivePrefValue(const std::string& key, - bool incognito, - bool* from_incognito) const; + const base::Value* GetEffectivePrefValue(const std::string& key, + bool incognito, + bool* from_incognito) const; private: struct ExtensionEntry; diff --git a/chrome/browser/extensions/extension_preference_api.h b/chrome/browser/extensions/extension_preference_api.h index 804d062..5ac4b78 100644 --- a/chrome/browser/extensions/extension_preference_api.h +++ b/chrome/browser/extensions/extension_preference_api.h @@ -12,6 +12,10 @@ #include "chrome/browser/prefs/pref_change_registrar.h" #include "content/common/notification_observer.h" +namespace base { +class Value; +} + class ExtensionPreferenceEventRouter : public NotificationObserver { public: explicit ExtensionPreferenceEventRouter(Profile* profile); @@ -39,8 +43,6 @@ class ExtensionPreferenceEventRouter : public NotificationObserver { DISALLOW_COPY_AND_ASSIGN(ExtensionPreferenceEventRouter); }; -class Value; - class PrefTransformerInterface { public: virtual ~PrefTransformerInterface() {} @@ -51,15 +53,17 @@ class PrefTransformerInterface { // |error| and returns NULL otherwise. |bad_message| is passed to simulate // the behavior of EXTENSION_FUNCTION_VALIDATE. It is never NULL. // The ownership of the returned value is passed to the caller. - virtual Value* ExtensionToBrowserPref(const Value* extension_pref, - std::string* error, - bool* bad_message) = 0; + virtual base::Value* ExtensionToBrowserPref( + const base::Value* extension_pref, + std::string* error, + bool* bad_message) = 0; // Converts the representation of the preference as stored in the browser // into a representation that is used by the extension. // Returns the extension representation in case of success or NULL otherwise. // The ownership of the returned value is passed to the caller. - virtual Value* BrowserToExtensionPref(const Value* browser_pref) = 0; + virtual base::Value* BrowserToExtensionPref( + const base::Value* browser_pref) = 0; }; class GetPreferenceFunction : public SyncExtensionFunction { diff --git a/chrome/browser/extensions/extension_prefs.h b/chrome/browser/extensions/extension_prefs.h index 65a68c2..a5fbbb1 100644 --- a/chrome/browser/extensions/extension_prefs.h +++ b/chrome/browser/extensions/extension_prefs.h @@ -76,7 +76,7 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Returns a copy of the Extensions prefs. // TODO(erikkay) Remove this so that external consumers don't need to be // aware of the internal structure of the preferences. - DictionaryValue* CopyCurrentExtensions(); + base::DictionaryValue* CopyCurrentExtensions(); // Returns true if the specified external extension was uninstalled by the // user. @@ -297,7 +297,7 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { void SetExtensionControlledPref(const std::string& extension_id, const std::string& pref_key, ExtensionPrefsScope scope, - Value* value); + base::Value* value); void RemoveExtensionControlledPref(const std::string& extension_id, const std::string& pref_key, @@ -353,19 +353,19 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Converts internal relative paths to be absolute. Used for export to // consumers who expect full paths. - void MakePathsAbsolute(DictionaryValue* dict); + void MakePathsAbsolute(base::DictionaryValue* dict); // Sets the pref |key| for extension |id| to |value|. void UpdateExtensionPref(const std::string& id, const std::string& key, - Value* value); + base::Value* value); // Deletes the pref dictionary for extension |id|. void DeleteExtensionPrefs(const std::string& id); // Reads a boolean pref from |ext| with key |pref_key|. // Return false if the value is false or |pref_key| does not exist. - static bool ReadBooleanFromPref(const DictionaryValue* ext, + static bool ReadBooleanFromPref(const base::DictionaryValue* ext, const std::string& pref_key); // Reads a boolean pref |pref_key| from extension with id |extension_id|. @@ -374,7 +374,7 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Reads an integer pref from |ext| with key |pref_key|. // Return false if the value does not exist. - static bool ReadIntegerFromPref(const DictionaryValue* ext, + static bool ReadIntegerFromPref(const base::DictionaryValue* ext, const std::string& pref_key, int* out_value); @@ -386,7 +386,7 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Reads a list pref |pref_key| from extension with id |extension_id|. bool ReadExtensionPrefList(const std::string& extension_id, const std::string& pref_key, - const ListValue** out_value); + const base::ListValue** out_value); // Interprets the list pref, |pref_key| in |extension_id|'s preferences, as a // URLPatternSet. The |valid_schemes| specify how to parse the URLPatterns. @@ -403,12 +403,12 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Returns a dictionary for extension |id|'s prefs or NULL if it doesn't // exist. - const DictionaryValue* GetExtensionPref(const std::string& id) const; + const base::DictionaryValue* GetExtensionPref(const std::string& id) const; // Returns the dictionary of preferences controlled by the specified extension // or creates a new one. All entries in the dictionary contain non-expanded // paths. - const DictionaryValue* GetExtensionControlledPrefs( + const base::DictionaryValue* GetExtensionControlledPrefs( const std::string& id, bool incognito) const; @@ -420,7 +420,7 @@ class ExtensionPrefs : public ExtensionContentSettingsStore::Observer { // Checks if kPrefBlacklist is set to true in the DictionaryValue. // Return false if the value is false or kPrefBlacklist does not exist. // This is used to decide if an extension is blacklisted. - static bool IsBlacklistBitSet(DictionaryValue* ext); + static bool IsBlacklistBitSet(base::DictionaryValue* ext); // Fix missing preference entries in the extensions that are were introduced // in a later Chrome version. diff --git a/chrome/browser/extensions/extension_proxy_api.h b/chrome/browser/extensions/extension_proxy_api.h index 8a8fb4d..5d6720f 100644 --- a/chrome/browser/extensions/extension_proxy_api.h +++ b/chrome/browser/extensions/extension_proxy_api.h @@ -16,9 +16,12 @@ #include "chrome/browser/prefs/proxy_prefs.h" #include "chrome/browser/profiles/profile.h" -class Value; class ExtensionEventRouterForwarder; +namespace base { +class Value; +} + // Class to convert between the representation of proxy settings used // in the Proxy Settings API and the representation used in the PrefStores. // This plugs into the ExtensionPreferenceAPI to get and set proxy settings. @@ -28,10 +31,11 @@ class ProxyPrefTransformer : public PrefTransformerInterface { virtual ~ProxyPrefTransformer(); // Implementation of PrefTransformerInterface. - virtual Value* ExtensionToBrowserPref(const Value* extension_pref, - std::string* error, - bool* bad_message) OVERRIDE; - virtual Value* BrowserToExtensionPref(const Value* browser_pref) OVERRIDE; + virtual base::Value* ExtensionToBrowserPref(const base::Value* extension_pref, + std::string* error, + bool* bad_message) OVERRIDE; + virtual base::Value* BrowserToExtensionPref( + const base::Value* browser_pref) OVERRIDE; private: DISALLOW_COPY_AND_ASSIGN(ProxyPrefTransformer); diff --git a/chrome/browser/extensions/extension_proxy_api_helpers.h b/chrome/browser/extensions/extension_proxy_api_helpers.h index 1907a3d..f658aab 100644 --- a/chrome/browser/extensions/extension_proxy_api_helpers.h +++ b/chrome/browser/extensions/extension_proxy_api_helpers.h @@ -13,9 +13,12 @@ #include "chrome/browser/prefs/proxy_prefs.h" #include "net/proxy/proxy_config.h" +class ProxyConfigDictionary; + +namespace base { class DictionaryValue; class ListValue; -class ProxyConfigDictionary; +} namespace extension_proxy_api_helpers { @@ -46,27 +49,28 @@ bool CreatePACScriptFromDataURL( // // The parameter |bad_message| is passed to simulate the behavior of // EXTENSION_FUNCTION_VALIDATE. It is never NULL. -bool GetProxyModeFromExtensionPref(const DictionaryValue* proxy_config, +bool GetProxyModeFromExtensionPref(const base::DictionaryValue* proxy_config, ProxyPrefs::ProxyMode* out, std::string* error, bool* bad_message); -bool GetPacMandatoryFromExtensionPref(const DictionaryValue* proxy_config, +bool GetPacMandatoryFromExtensionPref(const base::DictionaryValue* proxy_config, bool* out, std::string* error, bool* bad_message); -bool GetPacUrlFromExtensionPref(const DictionaryValue* proxy_config, +bool GetPacUrlFromExtensionPref(const base::DictionaryValue* proxy_config, std::string* out, std::string* error, bool* bad_message); -bool GetPacDataFromExtensionPref(const DictionaryValue* proxy_config, +bool GetPacDataFromExtensionPref(const base::DictionaryValue* proxy_config, std::string* out, std::string* error, bool* bad_message); -bool GetProxyRulesStringFromExtensionPref(const DictionaryValue* proxy_config, - std::string* out, - std::string* error, - bool* bad_message); -bool GetBypassListFromExtensionPref(const DictionaryValue* proxy_config, +bool GetProxyRulesStringFromExtensionPref( + const base::DictionaryValue* proxy_config, + std::string* out, + std::string* error, + bool* bad_message); +bool GetBypassListFromExtensionPref(const base::DictionaryValue* proxy_config, std::string* out, std::string* error, bool* bad_message); @@ -74,20 +78,21 @@ bool GetBypassListFromExtensionPref(const DictionaryValue* proxy_config, // Creates and returns a ProxyConfig dictionary (as defined in the extension // API) from the given parameters. Ownership is passed to the caller. // Depending on the value of |mode_enum|, several of the strings may be empty. -DictionaryValue* CreateProxyConfigDict(ProxyPrefs::ProxyMode mode_enum, - bool pac_mandatory, - const std::string& pac_url, - const std::string& pac_data, - const std::string& proxy_rules_string, - const std::string& bypass_list, - std::string* error); +base::DictionaryValue* CreateProxyConfigDict( + ProxyPrefs::ProxyMode mode_enum, + bool pac_mandatory, + const std::string& pac_url, + const std::string& pac_data, + const std::string& proxy_rules_string, + const std::string& bypass_list, + std::string* error); // Converts a ProxyServer dictionary instance (as defined in the extension API) // |proxy_server| to a net::ProxyServer. // |default_scheme| is the default scheme that is filled in, in case the // caller did not pass one. // Returns true if successful and sets |error| otherwise. -bool GetProxyServer(const DictionaryValue* proxy_server, +bool GetProxyServer(const base::DictionaryValue* proxy_server, net::ProxyServer::Scheme default_scheme, net::ProxyServer* out, std::string* error, @@ -95,7 +100,7 @@ bool GetProxyServer(const DictionaryValue* proxy_server, // Joins a list of URLs (stored as StringValues) in |list| with |joiner| // to |out|. Returns true if successful and sets |error| otherwise. -bool JoinUrlList(ListValue* list, +bool JoinUrlList(base::ListValue* list, const std::string& joiner, std::string* out, std::string* error, @@ -107,23 +112,24 @@ bool JoinUrlList(ListValue* list, // Creates and returns a ProxyRules dictionary as defined in the extension API // with the values of a ProxyConfigDictionary configured for fixed proxy // servers. Returns NULL in case of failures. Ownership is passed to the caller. -DictionaryValue* CreateProxyRulesDict( +base::DictionaryValue* CreateProxyRulesDict( const ProxyConfigDictionary& proxy_config); // Creates and returns a ProxyServer dictionary as defined in the extension API // with values from a net::ProxyServer object. Never returns NULL. Ownership is // passed to the caller. -DictionaryValue* CreateProxyServerDict(const net::ProxyServer& proxy); +base::DictionaryValue* CreateProxyServerDict(const net::ProxyServer& proxy); // Creates and returns a PacScript dictionary as defined in the extension API // with the values of a ProxyconfigDictionary configured for pac scripts. // Returns NULL in case of failures. Ownership is passed to the caller. -DictionaryValue* CreatePacScriptDict(const ProxyConfigDictionary& proxy_config); +base::DictionaryValue* CreatePacScriptDict( + const ProxyConfigDictionary& proxy_config); // Tokenizes the |in| at delimiters |delims| and returns a new ListValue with // StringValues created from the tokens. Ownership is passed to the caller. -ListValue* TokenizeToStringList(const std::string& in, - const std::string& delims); +base::ListValue* TokenizeToStringList(const std::string& in, + const std::string& delims); } // namespace extension_proxy_api_helpers diff --git a/chrome/browser/extensions/extension_sidebar_api.h b/chrome/browser/extensions/extension_sidebar_api.h index 7ad2a33..02363f2 100644 --- a/chrome/browser/extensions/extension_sidebar_api.h +++ b/chrome/browser/extensions/extension_sidebar_api.h @@ -8,11 +8,14 @@ #include <string> #include "chrome/browser/extensions/extension_function.h" -class DictionaryValue; class Profile; class RenderViewHost; class TabContents; +namespace base { +class DictionaryValue; +} + namespace extension_sidebar_constants { extern const char kActiveState[]; extern const char kHiddenState[]; @@ -38,14 +41,14 @@ class SidebarFunction : public SyncExtensionFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details) = 0; + const base::DictionaryValue& details) = 0; }; class CollapseSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.collapse"); }; @@ -53,7 +56,7 @@ class ExpandSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.expand"); }; @@ -61,7 +64,7 @@ class GetStateSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.getState"); }; @@ -69,7 +72,7 @@ class HideSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.hide"); }; @@ -77,7 +80,7 @@ class NavigateSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.navigate"); }; @@ -85,7 +88,7 @@ class SetBadgeTextSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.setBadgeText"); }; @@ -93,7 +96,7 @@ class SetIconSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.setIcon"); }; @@ -101,7 +104,7 @@ class SetTitleSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.setTitle"); }; @@ -109,9 +112,8 @@ class ShowSidebarFunction : public SidebarFunction { private: virtual bool RunImpl(TabContents* tab, const std::string& content_id, - const DictionaryValue& details); + const base::DictionaryValue& details); DECLARE_EXTENSION_FUNCTION_NAME("experimental.sidebar.show"); }; #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_SIDEBAR_API_H_ - diff --git a/chrome/browser/extensions/extension_tabs_module.h b/chrome/browser/extensions/extension_tabs_module.h index f02f9ed..b6faaab 100644 --- a/chrome/browser/extensions/extension_tabs_module.h +++ b/chrome/browser/extensions/extension_tabs_module.h @@ -15,28 +15,31 @@ class BackingStore; class Browser; -class DictionaryValue; -class ListValue; class SkBitmap; class TabContents; class TabContentsWrapper; class TabStripModel; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace ExtensionTabUtil { int GetWindowId(const Browser* browser); int GetTabId(const TabContents* tab_contents); std::string GetTabStatusText(bool is_loading); int GetWindowIdOfTab(const TabContents* tab_contents); -ListValue* CreateTabList(const Browser* browser); -DictionaryValue* CreateTabValue(const TabContents* tab_contents); -DictionaryValue* CreateTabValue(const TabContents* tab_contents, - TabStripModel* tab_strip, - int tab_index); +base::ListValue* CreateTabList(const Browser* browser); +base::DictionaryValue* CreateTabValue(const TabContents* tab_contents); +base::DictionaryValue* CreateTabValue(const TabContents* tab_contents, + TabStripModel* tab_strip, + int tab_index); // Create a tab value, overriding its kSelectedKey to the provided boolean. -DictionaryValue* CreateTabValueActive(const TabContents* tab_contents, - bool active); -DictionaryValue* CreateWindowValue(const Browser* browser, - bool populate_tabs); +base::DictionaryValue* CreateTabValueActive(const TabContents* tab_contents, + bool active); +base::DictionaryValue* CreateWindowValue(const Browser* browser, + bool populate_tabs); // Gets the |tab_strip_model| and |tab_index| for the given |tab_contents|. bool GetTabStripModel(const TabContents* tab_contents, TabStripModel** tab_strip_model, diff --git a/chrome/browser/extensions/extension_tts_api_controller.h b/chrome/browser/extensions/extension_tts_api_controller.h index 8ffe065..51fe516 100644 --- a/chrome/browser/extensions/extension_tts_api_controller.h +++ b/chrome/browser/extensions/extension_tts_api_controller.h @@ -13,13 +13,15 @@ #include "base/scoped_ptr.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class Extension; class ExtensionTtsPlatformImpl; -class ListValue; class Profile; -class Value; +namespace base { +class DictionaryValue; +class ListValue; +class Value; +} // Events sent back from the TTS engine indicating the progress. enum TtsEventType { @@ -67,8 +69,8 @@ class Utterance { void set_text(const std::string& text) { text_ = text; } const std::string& text() const { return text_; } - void set_options(const Value* options); - const Value* options() const { return options_.get(); } + void set_options(const base::Value* options); + const base::Value* options() const { return options_.get(); } void set_src_extension_id(const std::string& src_extension_id) { src_extension_id_ = src_extension_id; @@ -151,7 +153,7 @@ class Utterance { // The full options arg passed to tts.speak, which may include fields // other than the ones we explicitly parse, below. - scoped_ptr<Value> options_; + scoped_ptr<base::Value> options_; // The extension ID of the extension that called speak() and should // receive events. @@ -212,7 +214,7 @@ class ExtensionTtsController { // Return a list of all available voices, including the native voice, // if supported, and all voices registered by extensions. - ListValue* GetVoices(Profile* profile); + base::ListValue* GetVoices(Profile* profile); // For unit testing. void SetPlatformImpl(ExtensionTtsPlatformImpl* platform_impl); diff --git a/chrome/browser/extensions/extension_tts_engine_api.h b/chrome/browser/extensions/extension_tts_engine_api.h index 7c14937..35e2c69 100644 --- a/chrome/browser/extensions/extension_tts_engine_api.h +++ b/chrome/browser/extensions/extension_tts_engine_api.h @@ -11,8 +11,12 @@ class Extension; class Utterance; +namespace base { +class ListValue; +} + // Return a list of all available voices registered by extensions. -void GetExtensionVoices(Profile* profile, ListValue* result_voices); +void GetExtensionVoices(Profile* profile, base::ListValue* result_voices); // Find the first extension with a tts_voices in its // manifest that matches the speech parameters of this utterance. diff --git a/chrome/browser/extensions/extension_web_ui.h b/chrome/browser/extensions/extension_web_ui.h index cecd955..6eeb830 100644 --- a/chrome/browser/extensions/extension_web_ui.h +++ b/chrome/browser/extensions/extension_web_ui.h @@ -15,12 +15,16 @@ #include "chrome/common/extensions/extension.h" class GURL; -class ListValue; class PrefService; class Profile; class RenderViewHost; class TabContents; +namespace base { +class ListValue; +class Value; +} + // This class implements WebUI for extensions and allows extensions to put UI in // the main tab contents area. For example, each extension can specify an // "options_page", and that page is displayed in the tab contents area and is @@ -49,7 +53,7 @@ class ExtensionWebUI : public ChromeWebUI { const Extension::URLOverrideMap& overrides); static void UnregisterChromeURLOverride(const std::string& page, Profile* profile, - Value* override); + base::Value* override); // Called from BrowserPrefs static void RegisterUserPrefs(PrefService* prefs); @@ -64,8 +68,8 @@ class ExtensionWebUI : public ChromeWebUI { // ensure that something takes its place. static void UnregisterAndReplaceOverride(const std::string& page, Profile* profile, - ListValue* list, - Value* override); + base::ListValue* list, + base::Value* override); // TODO(aa): This seems out of place. Why is it not with the event routers for // the other extension APIs? diff --git a/chrome/browser/extensions/extension_webrequest_api.h b/chrome/browser/extensions/extension_webrequest_api.h index 96746c4..15d1d7e 100644 --- a/chrome/browser/extensions/extension_webrequest_api.h +++ b/chrome/browser/extensions/extension_webrequest_api.h @@ -20,11 +20,14 @@ #include "net/base/completion_callback.h" #include "webkit/glue/resource_type.h" -class DictionaryValue; class ExtensionInfoMap; class GURL; + +namespace base { +class DictionaryValue; class ListValue; class StringValue; +} namespace net { class HostPortPair; @@ -63,7 +66,7 @@ class ExtensionWebRequestEventRouter { // Returns false if there was an error initializing. If it is a user error, // an error message is provided, otherwise the error is internal (and // unexpected). - bool InitFromValue(const DictionaryValue& value, std::string* error); + bool InitFromValue(const base::DictionaryValue& value, std::string* error); }; // Internal representation of the extraInfoSpec parameter on webRequest @@ -78,7 +81,8 @@ class ExtensionWebRequestEventRouter { BLOCKING = 1<<4, }; - static bool InitFromValue(const ListValue& value, int* extra_info_spec); + static bool InitFromValue(const base::ListValue& value, + int* extra_info_spec); }; // Contains an extension's response to a blocking event. @@ -215,7 +219,7 @@ class ExtensionWebRequestEventRouter { ProfileId profile_id, net::URLRequest* request, const std::vector<const EventListener*>& listeners, - const ListValue& args); + const base::ListValue& args); // Returns a list of event listeners that care about the given event, based // on their filter parameters. |extra_info_spec| will contain the combined diff --git a/chrome/browser/extensions/extension_webstore_private_api.h b/chrome/browser/extensions/extension_webstore_private_api.h index 59ee0a1..19eec7a 100644 --- a/chrome/browser/extensions/extension_webstore_private_api.h +++ b/chrome/browser/extensions/extension_webstore_private_api.h @@ -84,7 +84,8 @@ class BeginInstallWithManifestFunction : public AsyncExtensionFunction, // Called when we've successfully parsed the manifest and icon data in the // utility process. Ownership of parsed_manifest is transferred. - void OnParseSuccess(const SkBitmap& icon, DictionaryValue* parsed_manifest); + void OnParseSuccess(const SkBitmap& icon, + base::DictionaryValue* parsed_manifest); // Called to indicate a parse failure. The |result_code| parameter should // indicate whether the problem was with the manifest or icon data. @@ -109,7 +110,7 @@ class BeginInstallWithManifestFunction : public AsyncExtensionFunction, std::string localized_name_; // The results of parsing manifest_ and icon_data_ go into these two. - scoped_ptr<DictionaryValue> parsed_manifest_; + scoped_ptr<base::DictionaryValue> parsed_manifest_; SkBitmap icon_; // A dummy Extension object we create for the purposes of using diff --git a/chrome/browser/extensions/extensions_ui.h b/chrome/browser/extensions/extensions_ui.h index 2b20716..7039d5f 100644 --- a/chrome/browser/extensions/extensions_ui.h +++ b/chrome/browser/extensions/extensions_ui.h @@ -20,15 +20,18 @@ #include "content/common/notification_registrar.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class Extension; class ExtensionService; class FilePath; -class ListValue; class PrefService; class RenderProcessHost; class UserScript; +namespace base { +class DictionaryValue; +class ListValue; +} + // Information about a page running in an extension, for example a toolstrip, // a background page, or a tab contents. struct ExtensionPage { @@ -74,7 +77,7 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, // Extension Detail JSON Struct for page. (static for ease of testing). // Note: service can be NULL in unit tests. - static DictionaryValue* CreateExtensionDetailValue( + static base::DictionaryValue* CreateExtensionDetailValue( ExtensionService* service, const Extension* extension, const std::vector<ExtensionPage>& pages, @@ -93,52 +96,52 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, private: // Callback for "requestExtensionsData" message. - void HandleRequestExtensionsData(const ListValue* args); + void HandleRequestExtensionsData(const base::ListValue* args); // Callback for "toggleDeveloperMode" message. - void HandleToggleDeveloperMode(const ListValue* args); + void HandleToggleDeveloperMode(const base::ListValue* args); // Callback for "inspect" message. - void HandleInspectMessage(const ListValue* args); + void HandleInspectMessage(const base::ListValue* args); // Callback for "reload" message. - void HandleReloadMessage(const ListValue* args); + void HandleReloadMessage(const base::ListValue* args); // Callback for "enable" message. - void HandleEnableMessage(const ListValue* args); + void HandleEnableMessage(const base::ListValue* args); // Callback for "enableIncognito" message. - void HandleEnableIncognitoMessage(const ListValue* args); + void HandleEnableIncognitoMessage(const base::ListValue* args); // Callback for "allowFileAcces" message. - void HandleAllowFileAccessMessage(const ListValue* args); + void HandleAllowFileAccessMessage(const base::ListValue* args); // Callback for "uninstall" message. - void HandleUninstallMessage(const ListValue* args); + void HandleUninstallMessage(const base::ListValue* args); // Callback for "options" message. - void HandleOptionsMessage(const ListValue* args); + void HandleOptionsMessage(const base::ListValue* args); // Callback for "showButton" message. - void HandleShowButtonMessage(const ListValue* args); + void HandleShowButtonMessage(const base::ListValue* args); // Callback for "load" message. - void HandleLoadMessage(const ListValue* args); + void HandleLoadMessage(const base::ListValue* args); // Callback for "pack" message. - void HandlePackMessage(const ListValue* args); + void HandlePackMessage(const base::ListValue* args); // Callback for "autoupdate" message. - void HandleAutoUpdateMessage(const ListValue* args); + void HandleAutoUpdateMessage(const base::ListValue* args); // Utility for calling javascript window.alert in the page. void ShowAlert(const std::string& message); // Callback for "selectFilePath" message. - void HandleSelectFilePathMessage(const ListValue* args); + void HandleSelectFilePathMessage(const base::ListValue* args); // Utility for callbacks that get an extension ID as the sole argument. - const Extension* GetExtension(const ListValue* args); + const Extension* GetExtension(const base::ListValue* args); // Forces a UI update if appropriate after a notification is received. void MaybeUpdateAfterNotification(); diff --git a/chrome/browser/extensions/external_extension_loader.h b/chrome/browser/extensions/external_extension_loader.h index fb2185c..c47f5d22 100644 --- a/chrome/browser/extensions/external_extension_loader.h +++ b/chrome/browser/extensions/external_extension_loader.h @@ -10,9 +10,12 @@ #include "base/memory/ref_counted.h" #include "base/memory/scoped_ptr.h" -class DictionaryValue; class ExternalExtensionProviderImpl; +namespace base { +class DictionaryValue; +} + // Base class for gathering a list of external extensions. Subclasses // implement loading from registry, JSON file, policy. // Instances are owned by ExternalExtensionProviderImpl objects. @@ -62,7 +65,7 @@ class ExternalExtensionLoader // this task should invoke |LoadFinished| with a PostTask. This scheme of // posting tasks will avoid concurrent access and imply the necessary memory // barriers. - scoped_ptr<DictionaryValue> prefs_; + scoped_ptr<base::DictionaryValue> prefs_; private: friend class base::RefCountedThreadSafe<ExternalExtensionLoader>; diff --git a/chrome/browser/extensions/external_extension_provider_impl.h b/chrome/browser/extensions/external_extension_provider_impl.h index 6e0cd12..8190996 100644 --- a/chrome/browser/extensions/external_extension_provider_impl.h +++ b/chrome/browser/extensions/external_extension_provider_impl.h @@ -11,12 +11,15 @@ #include "base/memory/ref_counted.h" #include "chrome/browser/extensions/external_extension_loader.h" -class DictionaryValue; class ExternalExtensionLoader; class Profile; -class ValueSerializer; class Version; +namespace base { +class DictionaryValue; +class ValueSerializer; +} + // A specialization of the ExternalExtensionProvider that uses an instance // of ExternalExtensionLoader to provide external extensions. This class // can be seen as a bridge between the extension system and an @@ -47,7 +50,7 @@ class ExternalExtensionProviderImpl // Sets underlying prefs and notifies provider. Only to be called by the // owned ExternalExtensionLoader instance. - void SetPrefs(DictionaryValue* prefs); + void SetPrefs(base::DictionaryValue* prefs); // ExternalExtensionProvider implementation: virtual void VisitRegisteredExtension() const; @@ -83,7 +86,7 @@ class ExternalExtensionProviderImpl VisitorInterface* service_; // weak // Dictionary of the external extensions that are provided by this provider. - scoped_ptr<DictionaryValue> prefs_; + scoped_ptr<base::DictionaryValue> prefs_; // Indicates that the extensions provided by this provider are loaded // entirely. diff --git a/chrome/browser/extensions/external_policy_extension_loader.h b/chrome/browser/extensions/external_policy_extension_loader.h index d346daca..ce4721b 100644 --- a/chrome/browser/extensions/external_policy_extension_loader.h +++ b/chrome/browser/extensions/external_policy_extension_loader.h @@ -12,7 +12,6 @@ #include "content/common/notification_observer.h" #include "content/common/notification_registrar.h" -class ListValue; class MockExternalPolicyExtensionProviderVisitor; class Profile; diff --git a/chrome/browser/extensions/sandboxed_extension_unpacker.h b/chrome/browser/extensions/sandboxed_extension_unpacker.h index 4bb7e74..6204876 100644 --- a/chrome/browser/extensions/sandboxed_extension_unpacker.h +++ b/chrome/browser/extensions/sandboxed_extension_unpacker.h @@ -13,10 +13,13 @@ #include "base/scoped_temp_dir.h" #include "content/browser/utility_process_host.h" -class DictionaryValue; class Extension; class ResourceDispatcherHost; +namespace base { +class DictionaryValue; +} + class SandboxedExtensionUnpackerClient : public base::RefCountedThreadSafe<SandboxedExtensionUnpackerClient> { public: @@ -32,7 +35,7 @@ class SandboxedExtensionUnpackerClient // for deleting this memory. virtual void OnUnpackSuccess(const FilePath& temp_dir, const FilePath& extension_root, - const DictionaryValue* original_manifest, + const base::DictionaryValue* original_manifest, const Extension* extension) = 0; virtual void OnUnpackFailure(const std::string& error) = 0; @@ -192,15 +195,16 @@ class SandboxedExtensionUnpacker : public UtilityProcessHost::Client { virtual void OnProcessCrashed(int exit_code); // IPC message handlers. - void OnUnpackExtensionSucceeded(const DictionaryValue& manifest); + void OnUnpackExtensionSucceeded(const base::DictionaryValue& manifest); void OnUnpackExtensionFailed(const std::string& error_message); void ReportFailure(FailureReason reason, const std::string& message); - void ReportSuccess(const DictionaryValue& original_manifest); + void ReportSuccess(const base::DictionaryValue& original_manifest); // Overwrites original manifest with safe result from utility process. // Returns NULL on error. Caller owns the returned object. - DictionaryValue* RewriteManifestFile(const DictionaryValue& manifest); + base::DictionaryValue* RewriteManifestFile( + const base::DictionaryValue& manifest); // Overwrites original files with safe results from utility process. // Reports error and returns false if it fails. diff --git a/chrome/browser/extensions/sandboxed_extension_unpacker_unittest.cc b/chrome/browser/extensions/sandboxed_extension_unpacker_unittest.cc index 165f571..ff34297 100644 --- a/chrome/browser/extensions/sandboxed_extension_unpacker_unittest.cc +++ b/chrome/browser/extensions/sandboxed_extension_unpacker_unittest.cc @@ -8,6 +8,7 @@ #include "base/scoped_temp_dir.h" #include "base/scoped_temp_dir.h" #include "base/string_util.h" +#include "base/values.h" #include "chrome/browser/extensions/sandboxed_extension_unpacker.h" #include "chrome/common/chrome_paths.h" #include "chrome/common/extensions/extension.h" diff --git a/chrome/browser/extensions/test_extension_prefs.h b/chrome/browser/extensions/test_extension_prefs.h index e781ee4..8262b7f 100644 --- a/chrome/browser/extensions/test_extension_prefs.h +++ b/chrome/browser/extensions/test_extension_prefs.h @@ -12,11 +12,14 @@ #include "base/scoped_temp_dir.h" #include "chrome/common/extensions/extension.h" -class DictionaryValue; class ExtensionPrefs; class ExtensionPrefValueMap; class PrefService; +namespace base { +class DictionaryValue; +} + // This is a test class intended to make it easier to work with ExtensionPrefs // in tests. class TestExtensionPrefs { @@ -39,7 +42,7 @@ class TestExtensionPrefs { // Similar to AddExtension, but takes a dictionary with manifest values. scoped_refptr<Extension> AddExtensionWithManifest( - const DictionaryValue& manifest, Extension::Location location); + const base::DictionaryValue& manifest, Extension::Location location); // Similar to AddExtension, this adds a new test Extension. This is useful for // cases when you don't need the Extension object, but just the id it was diff --git a/chrome/browser/external_protocol/external_protocol_handler.h b/chrome/browser/external_protocol/external_protocol_handler.h index 72bcbcf..002b0c8 100644 --- a/chrome/browser/external_protocol/external_protocol_handler.h +++ b/chrome/browser/external_protocol/external_protocol_handler.h @@ -8,10 +8,13 @@ #include <string> -class DictionaryValue; class GURL; class PrefService; +namespace base { +class DictionaryValue; +} + class ExternalProtocolHandler { public: enum BlockState { @@ -66,7 +69,7 @@ class ExternalProtocolHandler { // Prepopulates the dictionary with known protocols to deny or allow, if // preferences for them do not already exist. - static void PrepopulateDictionary(DictionaryValue* win_pref); + static void PrepopulateDictionary(base::DictionaryValue* win_pref); // Allows LaunchUrl to proceed with launching an external protocol handler. // This is typically triggered by a user gesture, but is also called for diff --git a/chrome/browser/geolocation/geolocation_content_settings_map.h b/chrome/browser/geolocation/geolocation_content_settings_map.h index 0aa1309..640ae96 100644 --- a/chrome/browser/geolocation/geolocation_content_settings_map.h +++ b/chrome/browser/geolocation/geolocation_content_settings_map.h @@ -24,10 +24,13 @@ #include "googleurl/src/gurl.h" class ContentSettingsDetails; -class DictionaryValue; class PrefService; class Profile; +namespace base { +class DictionaryValue; +} + class GeolocationContentSettingsMap : public base::RefCountedThreadSafe<GeolocationContentSettingsMap>, public NotificationObserver { @@ -109,7 +112,7 @@ class GeolocationContentSettingsMap // Sets the fields of |one_origin_settings| based on the values in // |dictionary|. static void GetOneOriginSettingsFromDictionary( - const DictionaryValue* dictionary, + const base::DictionaryValue* dictionary, OneOriginSettings* one_origin_settings); // The profile we're associated with. diff --git a/chrome/browser/history/top_sites.h b/chrome/browser/history/top_sites.h index c69a61c..fc99b28 100644 --- a/chrome/browser/history/top_sites.h +++ b/chrome/browser/history/top_sites.h @@ -25,11 +25,14 @@ #include "content/browser/cancelable_request.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class FilePath; class SkBitmap; class Profile; +namespace base { +class DictionaryValue; +} + namespace history { class TopSitesCache; @@ -361,12 +364,12 @@ class TopSites // storing all URLs, but filtering on access. It is a dictionary, // key is the URL, value is a dummy value. This is owned by the // PrefService. - const DictionaryValue* blacklist_; + const base::DictionaryValue* blacklist_; // This is a dictionary for the pinned URLs for the the most visited part of // the new tab page. Key is the URL, value is index where it is pinned at (may // be the same as key). This is owned by the PrefService. - const DictionaryValue* pinned_urls_; + const base::DictionaryValue* pinned_urls_; // See description above HistoryLoadState. HistoryLoadState history_state_; diff --git a/chrome/browser/importer/external_process_importer_bridge.h b/chrome/browser/importer/external_process_importer_bridge.h index 2aaa244..80c2724 100644 --- a/chrome/browser/importer/external_process_importer_bridge.h +++ b/chrome/browser/importer/external_process_importer_bridge.h @@ -14,10 +14,13 @@ #include "chrome/browser/importer/importer_bridge.h" #include "chrome/browser/importer/profile_writer.h" -class DictionaryValue; class GURL; class ProfileImportThread; +namespace base { +class DictionaryValue; +} + // When the importer is run in an external process, the bridge is effectively // split in half by the IPC infrastructure. The external bridge receives data // and notifications from the importer, and sends it across IPC. The @@ -26,7 +29,7 @@ class ProfileImportThread; class ExternalProcessImporterBridge : public ImporterBridge { public: ExternalProcessImporterBridge(ProfileImportThread* profile_import_thread, - const DictionaryValue& localized_strings); + const base::DictionaryValue& localized_strings); // Begin ImporterBridge implementation: virtual void AddBookmarks( @@ -68,7 +71,7 @@ class ExternalProcessImporterBridge : public ImporterBridge { // Holds strings needed by the external importer because the resource // bundle isn't available to the external process. - scoped_ptr<DictionaryValue> localized_strings_; + scoped_ptr<base::DictionaryValue> localized_strings_; DISALLOW_COPY_AND_ASSIGN(ExternalProcessImporterBridge); }; diff --git a/chrome/browser/importer/firefox_importer_utils.h b/chrome/browser/importer/firefox_importer_utils.h index 95391ce..da756220 100644 --- a/chrome/browser/importer/firefox_importer_utils.h +++ b/chrome/browser/importer/firefox_importer_utils.h @@ -12,11 +12,14 @@ #include "base/basictypes.h" #include "build/build_config.h" -class DictionaryValue; class FilePath; class GURL; class TemplateURL; +namespace base { +class DictionaryValue; +} + #if defined(OS_WIN) // Detects which version of Firefox is installed from registry. Returns its // major version, and drops the minor version. Returns 0 if failed. If there are @@ -62,7 +65,7 @@ FilePath GetProfilesINI(); // Path=Profiles/abcdefeg.default // We set "[value]" in path "<Section>.<Key>". For example, the path // "Genenral.StartWithLastProfile" has the value "1". -void ParseProfileINI(const FilePath& file, DictionaryValue* root); +void ParseProfileINI(const FilePath& file, base::DictionaryValue* root); // Returns true if we want to add the URL to the history. We filter out the URL // with a unsupported scheme. @@ -93,7 +96,7 @@ bool IsDefaultHomepage(const GURL& homepage, const FilePath& app_path); // |prefs| is not filled). // Note: for strings, only valid UTF-8 string values are supported. If a // key/pair is not valid UTF-8, it is ignored and will not appear in |prefs|. -bool ParsePrefFile(const FilePath& pref_file, DictionaryValue* prefs); +bool ParsePrefFile(const FilePath& pref_file, base::DictionaryValue* prefs); // Parses the value of a particular firefox preference from a string that is the // contents of the prefs file. diff --git a/chrome/browser/io_thread.h b/chrome/browser/io_thread.h index 21cd6ee..6bdd01b 100644 --- a/chrome/browser/io_thread.h +++ b/chrome/browser/io_thread.h @@ -21,12 +21,15 @@ class ChromeNetLog; class ChromeURLRequestContextGetter; class ExtensionEventRouterForwarder; -class ListValue; class MediaInternals; class PrefProxyConfigTracker; class PrefService; class SystemURLRequestContextGetter; +namespace base { +class ListValue; +} + namespace chrome_browser_net { class ConnectInterceptor; class Predictor; @@ -111,7 +114,7 @@ class IOThread : public BrowserProcessSubThread { base::TimeDelta max_dns_queue_delay, size_t max_speculative_parallel_resolves, const chrome_common_net::UrlList& startup_urls, - ListValue* referral_list, + base::ListValue* referral_list, bool preconnect_enabled); // Registers |url_request_context_getter| into the IO thread. During @@ -165,7 +168,7 @@ class IOThread : public BrowserProcessSubThread { base::TimeDelta max_dns_queue_delay, size_t max_speculative_parallel_resolves, const chrome_common_net::UrlList& startup_urls, - ListValue* referral_list, + base::ListValue* referral_list, bool preconnect_enabled); void ChangedToOnTheRecordOnIOThread(); diff --git a/chrome/browser/metrics/metrics_log.h b/chrome/browser/metrics/metrics_log.h index 374889d..36f2ec5 100644 --- a/chrome/browser/metrics/metrics_log.h +++ b/chrome/browser/metrics/metrics_log.h @@ -14,10 +14,13 @@ #include "content/common/page_transition_types.h" struct AutocompleteLog; -class DictionaryValue; class GURL; class PrefService; +namespace base { +class DictionaryValue; +} + namespace webkit { namespace npapi { struct WebPluginInfo; @@ -42,7 +45,7 @@ class MetricsLog : public MetricsLogBase { // dictionary giving the metrics for the profile. void RecordEnvironment( const std::vector<webkit::npapi::WebPluginInfo>& plugin_list, - const DictionaryValue* profile_metrics); + const base::DictionaryValue* profile_metrics); // Records the input text, available choices, and selected entry when the // user uses the Omnibox to open a URL. @@ -96,12 +99,13 @@ class MetricsLog : public MetricsLogBase { // Writes all profile metrics. This invokes WriteProfileMetrics for each key // in all_profiles_metrics that starts with kProfilePrefix. - void WriteAllProfilesMetrics(const DictionaryValue& all_profiles_metrics); + void WriteAllProfilesMetrics( + const base::DictionaryValue& all_profiles_metrics); // Writes metrics for the profile identified by key. This writes all // key/value pairs in profile_metrics. void WriteProfileMetrics(const std::string& key, - const DictionaryValue& profile_metrics); + const base::DictionaryValue& profile_metrics); DISALLOW_COPY_AND_ASSIGN(MetricsLog); }; diff --git a/chrome/browser/metrics/metrics_service.h b/chrome/browser/metrics/metrics_service.h index dd4118f..24e143b 100644 --- a/chrome/browser/metrics/metrics_service.h +++ b/chrome/browser/metrics/metrics_service.h @@ -28,14 +28,17 @@ class BookmarkModel; class BookmarkNode; -class DictionaryValue; -class ListValue; class HistogramSynchronizer; class MetricsLogBase; class MetricsReportingScheduler; class PrefService; class TemplateURLService; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace webkit { namespace npapi { struct WebPluginInfo; @@ -237,12 +240,12 @@ class MetricsService : public NotificationObserver, void RecallUnsentLogs(); // Decode and verify written pref log data. static MetricsService::LogRecallStatus RecallUnsentLogsHelper( - const ListValue& list, + const base::ListValue& list, std::vector<std::string>* local_list); // Encode and write list size and checksum for perf log data. static void StoreUnsentLogsHelper(const std::vector<std::string>& local_list, const size_t kMaxLocalListSize, - ListValue* list); + base::ListValue* list); // Convert |pending_log_| to XML in |compressed_log_|, and compress it for // transmission. void PreparePendingLogText(); @@ -406,7 +409,7 @@ class MetricsService : public NotificationObserver, // Dictionary containing all the profile specific metrics. This is set // at creation time from the prefs. - scoped_ptr<DictionaryValue> profile_dictionary_; + scoped_ptr<base::DictionaryValue> profile_dictionary_; // The scheduler for determining when uploads should happen. scoped_ptr<MetricsReportingScheduler> scheduler_; diff --git a/chrome/browser/net/predictor.h b/chrome/browser/net/predictor.h index edc03e1..f1f0bcb 100644 --- a/chrome/browser/net/predictor.h +++ b/chrome/browser/net/predictor.h @@ -33,7 +33,9 @@ #include "chrome/common/net/predictor_common.h" #include "net/base/host_port_pair.h" +namespace base { class ListValue; +} namespace net { class HostResolver; @@ -113,14 +115,14 @@ class Predictor : public base::RefCountedThreadSafe<Predictor> { // Construct a ListValue object that contains all the data in the referrers_ // so that it can be persisted in a pref. - void SerializeReferrers(ListValue* referral_list); + void SerializeReferrers(base::ListValue* referral_list); // Process a ListValue that contains all the data from a previous reference // list, as constructed by SerializeReferrers(), and add all the identified // values into the current referrer list. - void DeserializeReferrers(const ListValue& referral_list); + void DeserializeReferrers(const base::ListValue& referral_list); - void DeserializeReferrersThenDelete(ListValue* referral_list); + void DeserializeReferrersThenDelete(base::ListValue* referral_list); // For unit test code only. size_t max_concurrent_dns_lookups() const { diff --git a/chrome/browser/net/predictor_api.h b/chrome/browser/net/predictor_api.h index 37d39e6..951ca37 100644 --- a/chrome/browser/net/predictor_api.h +++ b/chrome/browser/net/predictor_api.h @@ -32,7 +32,7 @@ namespace chrome_browser_net { void FinalizePredictorInitialization( Predictor* global_predictor, const std::vector<GURL>& urls_to_prefetch, - ListValue* referral_list); + base::ListValue* referral_list); // Free all resources allocated by FinalizePredictorInitialization. After that // you must not call any function from this file. diff --git a/chrome/browser/net/referrer.h b/chrome/browser/net/referrer.h index 22ab43c..ff6a26f 100644 --- a/chrome/browser/net/referrer.h +++ b/chrome/browser/net/referrer.h @@ -24,7 +24,9 @@ #include "googleurl/src/gurl.h" #include "net/base/host_port_pair.h" +namespace base { class Value; +} namespace chrome_browser_net { @@ -115,8 +117,8 @@ class Referrer : public SubresourceMap { bool Trim(double reduce_rate, double threshold); // Provide methods for persisting, and restoring contents into a Value class. - Value* Serialize() const; - void Deserialize(const Value& referrers); + base::Value* Serialize() const; + void Deserialize(const base::Value& referrers); private: // Helper function for pruning list. Metric for usefulness is "large accrued diff --git a/chrome/browser/net/service_providers_win.h b/chrome/browser/net/service_providers_win.h index 39687cd..dc1a450 100644 --- a/chrome/browser/net/service_providers_win.h +++ b/chrome/browser/net/service_providers_win.h @@ -8,8 +8,6 @@ #include <vector> -class Value; - struct WinsockNamespaceProvider { std::wstring name; int version; @@ -38,4 +36,3 @@ void GetWinsockLayeredServiceProviders( WinsockLayeredServiceProviderList* service_list); #endif // CHROME_BROWSER_NET_SERVICE_PROVIDERS_WIN_H_ - diff --git a/chrome/browser/notifications/notifications_prefs_cache.h b/chrome/browser/notifications/notifications_prefs_cache.h index 5983657..de65a3e 100644 --- a/chrome/browser/notifications/notifications_prefs_cache.h +++ b/chrome/browser/notifications/notifications_prefs_cache.h @@ -14,7 +14,9 @@ #include "googleurl/src/gurl.h" #include "third_party/WebKit/Source/WebKit/chromium/public/WebNotificationPresenter.h" +namespace base { class ListValue; +} // Class which caches notification preferences. // Construction occurs on the UI thread when the contents @@ -45,7 +47,7 @@ class NotificationsPrefsCache void SetCacheDeniedOrigins(const std::vector<GURL>& denied); void SetCacheDefaultContentSetting(ContentSetting setting); - static void ListValueToGurlVector(const ListValue& origin_list, + static void ListValueToGurlVector(const base::ListValue& origin_list, std::vector<GURL>* origin_vector); // Exposed for testing. diff --git a/chrome/browser/plugin_updater.h b/chrome/browser/plugin_updater.h index 694c3b1..dc9cfaf 100644 --- a/chrome/browser/plugin_updater.h +++ b/chrome/browser/plugin_updater.h @@ -15,12 +15,15 @@ #include "chrome/browser/prefs/pref_change_registrar.h" #include "content/common/notification_observer.h" -class DictionaryValue; -class ListValue; class NotificationDetails; class NotificationSource; class Profile; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace webkit { namespace npapi { class PluginGroup; @@ -32,7 +35,7 @@ class PluginUpdater : public NotificationObserver { public: // Get a list of all the plugin groups. The caller should take ownership // of the returned ListValue. - static ListValue* GetPluginGroupsData(); + static base::ListValue* GetPluginGroupsData(); // Enable or disable a plugin group. void EnablePluginGroup(bool enable, const string16& group_name); @@ -80,18 +83,19 @@ class PluginUpdater : public NotificationObserver { // Used for the post task to notify that plugin enabled status changed. static void OnNotifyPluginStatusChanged(); - static DictionaryValue* CreatePluginFileSummary( + static base::DictionaryValue* CreatePluginFileSummary( const webkit::npapi::WebPluginInfo& plugin); // Force plugins to be enabled or disabled due to policy. // |disabled_list| contains the list of StringValues of the names of the // policy-disabled plugins, |exceptions_list| the policy-allowed plugins, // and |enabled_list| the policy-enabled plugins. - void UpdatePluginsStateFromPolicy(const ListValue* disabled_list, - const ListValue* exceptions_list, - const ListValue* enabled_list); + void UpdatePluginsStateFromPolicy(const base::ListValue* disabled_list, + const base::ListValue* exceptions_list, + const base::ListValue* enabled_list); - void ListValueToStringSet(const ListValue* src, std::set<string16>* dest); + void ListValueToStringSet(const base::ListValue* src, + std::set<string16>* dest); // Needed to allow singleton instantiation using private constructor. friend struct DefaultSingletonTraits<PluginUpdater>; diff --git a/chrome/browser/policy/configuration_policy_store_interface.h b/chrome/browser/policy/configuration_policy_store_interface.h index 1d3bf43..2043834 100644 --- a/chrome/browser/policy/configuration_policy_store_interface.h +++ b/chrome/browser/policy/configuration_policy_store_interface.h @@ -9,7 +9,9 @@ #include "base/basictypes.h" #include "policy/configuration_policy_type.h" +namespace base { class Value; +} namespace policy { @@ -40,7 +42,7 @@ class ConfigurationPolicyStoreInterface { // A |ConfigurationPolicyProvider| specifies the value of a policy // setting through a call to |Apply|. The configuration policy pref // store takes over the ownership of |value|. - virtual void Apply(ConfigurationPolicyType policy, Value* value) = 0; + virtual void Apply(ConfigurationPolicyType policy, base::Value* value) = 0; protected: ConfigurationPolicyStoreInterface() {} diff --git a/chrome/browser/prefs/command_line_pref_store.h b/chrome/browser/prefs/command_line_pref_store.h index 6a654e7..7bc3cc8 100644 --- a/chrome/browser/prefs/command_line_pref_store.h +++ b/chrome/browser/prefs/command_line_pref_store.h @@ -12,8 +12,6 @@ #include "base/values.h" #include "chrome/browser/prefs/value_map_pref_store.h" -class DictionaryValue; - // This PrefStore keeps track of preferences set by command-line switches, // such as proxy settings. class CommandLinePrefStore : public ValueMapPrefStore { diff --git a/chrome/browser/prefs/overlay_persistent_pref_store.h b/chrome/browser/prefs/overlay_persistent_pref_store.h index 57ffe8d..47ce6afb 100644 --- a/chrome/browser/prefs/overlay_persistent_pref_store.h +++ b/chrome/browser/prefs/overlay_persistent_pref_store.h @@ -34,12 +34,13 @@ class OverlayPersistentPrefStore : public PersistentPrefStore, virtual void RemoveObserver(PrefStore::Observer* observer); virtual bool IsInitializationComplete() const; virtual ReadResult GetValue(const std::string& key, - const Value** result) const; + const base::Value** result) const; // Methods of PersistentPrefStore. - virtual ReadResult GetMutableValue(const std::string& key, Value** result); - virtual void SetValue(const std::string& key, Value* value); - virtual void SetValueSilently(const std::string& key, Value* value); + virtual ReadResult GetMutableValue(const std::string& key, + base::Value** result); + virtual void SetValue(const std::string& key, base::Value* value); + virtual void SetValueSilently(const std::string& key, base::Value* value); virtual void RemoveValue(const std::string& key); virtual bool ReadOnly() const; virtual PrefReadError ReadPrefs(); diff --git a/chrome/browser/prefs/pref_member.h b/chrome/browser/prefs/pref_member.h index b5d9618..6c035ff 100644 --- a/chrome/browser/prefs/pref_member.h +++ b/chrome/browser/prefs/pref_member.h @@ -47,7 +47,7 @@ class PrefMemberBase : public NotificationObserver { // Update the value, either by calling |UpdateValueInternal| directly // or by dispatching to the right thread. // Takes ownership of |value|. - virtual void UpdateValue(Value* value, bool is_managed) const; + virtual void UpdateValue(base::Value* value, bool is_managed) const; void MoveToThread(BrowserThread::ID thread_id); @@ -67,7 +67,7 @@ class PrefMemberBase : public NotificationObserver { private: // This method actually updates the value. It should only be called from // the thread the PrefMember is on. - virtual bool UpdateValueInternal(const Value& value) const = 0; + virtual bool UpdateValueInternal(const base::Value& value) const = 0; bool IsOnCorrectThread() const; @@ -217,7 +217,7 @@ class PrefMember : public subtle::PrefMemberBase { protected: virtual ~Internal() {} - virtual bool UpdateValueInternal(const Value& value) const; + virtual bool UpdateValueInternal(const base::Value& value) const; // We cache the value of the pref so we don't have to keep walking the pref // tree. diff --git a/chrome/browser/prefs/pref_model_associator.h b/chrome/browser/prefs/pref_model_associator.h index e03217b..1503153 100644 --- a/chrome/browser/prefs/pref_model_associator.h +++ b/chrome/browser/prefs/pref_model_associator.h @@ -21,7 +21,9 @@ namespace sync_pb { class PreferenceSpecifics; } +namespace base { class Value; +} // Contains all preference sync related logic. // TODO(sync): Merge this into PrefService once we separate the profile @@ -66,17 +68,18 @@ class PrefModelAssociator // value always takes precedence. Note that only certain preferences will // actually be merged, all others will return a copy of the server value. See // the method's implementation for details. - static Value* MergePreference(const PrefService::Preference& local_pref, - const Value& server_value); + static base::Value* MergePreference( + const PrefService::Preference& local_pref, + const base::Value& server_value); // Fills |sync_data| with a sync representation of the preference data // provided. static bool CreatePrefSyncData(const std::string& name, - const Value& value, + const base::Value& value, SyncData* sync_data); // Extract preference value and name from sync specifics. - Value* ReadPreferenceSpecifics( + base::Value* ReadPreferenceSpecifics( const sync_pb::PreferenceSpecifics& specifics, std::string* name); @@ -104,9 +107,10 @@ class PrefModelAssociator // preference has been updated. void SendUpdateNotificationsIfNecessary(const std::string& pref_name); - static Value* MergeListValues(const Value& from_value, const Value& to_value); - static Value* MergeDictionaryValues(const Value& from_value, - const Value& to_value); + static base::Value* MergeListValues( + const base::Value& from_value, const base::Value& to_value); + static base::Value* MergeDictionaryValues(const base::Value& from_value, + const base::Value& to_value); // Do we have an active association between the preferences and sync models? // Set when start syncing, reset in StopSyncing. While this is not set, we diff --git a/chrome/browser/prefs/pref_service.h b/chrome/browser/prefs/pref_service.h index ca1bbfc..b283bcd 100644 --- a/chrome/browser/prefs/pref_service.h +++ b/chrome/browser/prefs/pref_service.h @@ -56,7 +56,7 @@ class PrefService : public base::NonThreadSafe { // your own; use the PrefService::Register*Pref methods instead. Preference(const PrefService* service, const char* name, - Value::ValueType type); + base::Value::ValueType type); ~Preference() {} // Returns the name of the Preference (i.e., the key, e.g., @@ -64,11 +64,11 @@ class PrefService : public base::NonThreadSafe { const std::string name() const { return name_; } // Returns the registered type of the preference. - Value::ValueType GetType() const; + base::Value::ValueType GetType() const; // Returns the value of the Preference, falling back to the registered // default value if no other has been set. - const Value* GetValue() const; + const base::Value* GetValue() const; // Returns true if the Preference is managed, i.e. set by an admin policy. // Since managed prefs have the highest priority, this also indicates @@ -115,7 +115,7 @@ class PrefService : public base::NonThreadSafe { std::string name_; - Value::ValueType type_; + base::Value::ValueType type_; // Reference to the PrefService in which this pref was created. const PrefService* pref_service_; @@ -178,8 +178,10 @@ class PrefService : public base::NonThreadSafe { void RegisterListPref(const char* path); void RegisterDictionaryPref(const char* path); // These take ownership of the default_value: - void RegisterListPref(const char* path, ListValue* default_value); - void RegisterDictionaryPref(const char* path, DictionaryValue* default_value); + void RegisterListPref(const char* path, + base::ListValue* default_value); + void RegisterDictionaryPref(const char* path, + base::DictionaryValue* default_value); // These variants use a default value from the locale dll instead. void RegisterLocalizedBooleanPref(const char* path, int locale_default_message_id); @@ -213,10 +215,10 @@ class PrefService : public base::NonThreadSafe { void RegisterDictionaryPref(const char* path, PrefSyncStatus sync_status); // These take ownership of the default_value: void RegisterListPref(const char* path, - ListValue* default_value, + base::ListValue* default_value, PrefSyncStatus sync_status); void RegisterDictionaryPref(const char* path, - DictionaryValue* default_value, + base::DictionaryValue* default_value, PrefSyncStatus sync_status); // These variants use a default value from the locale dll instead. void RegisterLocalizedBooleanPref(const char* path, @@ -247,8 +249,8 @@ class PrefService : public base::NonThreadSafe { // Returns the branch if it exists, or the registered default value otherwise. // Note that |path| must point to a registered preference. In that case, these // functions will never return NULL. - const DictionaryValue* GetDictionary(const char* path) const; - const ListValue* GetList(const char* path) const; + const base::DictionaryValue* GetDictionary(const char* path) const; + const base::ListValue* GetList(const char* path) const; // Removes a user pref and restores the pref to its default value. void ClearPref(const char* path); @@ -258,7 +260,7 @@ class PrefService : public base::NonThreadSafe { // To set the value of dictionary or list values in the pref tree use // Set(), but to modify the value of a dictionary or list use either // ListPrefUpdate or DictionaryPrefUpdate from scoped_user_pref_update.h. - void Set(const char* path, const Value& value); + void Set(const char* path, const base::Value& value); void SetBoolean(const char* path, bool value); void SetInteger(const char* path, int value); void SetDouble(const char* path, double value); @@ -279,7 +281,7 @@ class PrefService : public base::NonThreadSafe { // Returns a dictionary with effective preference values. The ownership // is passed to the caller. - DictionaryValue* GetPreferenceValues() const; + base::DictionaryValue* GetPreferenceValues() const; // A helper method to quickly look up a preference. Returns NULL if the // preference is not registered. @@ -354,12 +356,12 @@ class PrefService : public base::NonThreadSafe { // RegisterPreference must not be called twice for the same path. // This method takes ownership of |default_value|. void RegisterPreference(const char* path, - Value* default_value, + base::Value* default_value, PrefSyncStatus sync_status); // Sets the value for this pref path in the user pref store and informs the // PrefNotifier of the change. - void SetUserPrefValue(const char* path, Value* new_value); + void SetUserPrefValue(const char* path, base::Value* new_value); // Load preferences from storage, attempting to diagnose and handle errors. // This should only be called from the constructor. @@ -372,7 +374,8 @@ class PrefService : public base::NonThreadSafe { // |type| may only be Values::TYPE_DICTIONARY or Values::TYPE_LIST and // |path| must point to a registered preference of type |type|. // Ownership of the returned value remains at the user pref store. - Value* GetMutableUserPref(const char* path, Value::ValueType type); + base::Value* GetMutableUserPref(const char* path, + base::Value::ValueType type); // The PrefValueStore provides prioritized preference values. It is created // and owned by this PrefService. Subclasses may access it for unit testing. diff --git a/chrome/browser/prefs/pref_value_map.h b/chrome/browser/prefs/pref_value_map.h index d4b9f4e..100aa34 100644 --- a/chrome/browser/prefs/pref_value_map.h +++ b/chrome/browser/prefs/pref_value_map.h @@ -12,13 +12,15 @@ #include "base/basictypes.h" +namespace base { class Value; +} // A generic string to value map used by the PrefStore implementations. class PrefValueMap { public: - typedef std::map<std::string, Value*>::iterator iterator; - typedef std::map<std::string, Value*>::const_iterator const_iterator; + typedef std::map<std::string, base::Value*>::iterator iterator; + typedef std::map<std::string, base::Value*>::const_iterator const_iterator; PrefValueMap(); virtual ~PrefValueMap(); @@ -26,12 +28,12 @@ class PrefValueMap { // Gets the value for |key| and stores it in |value|. Ownership remains with // the map. Returns true if a value is present. If not, |value| is not // touched. - bool GetValue(const std::string& key, const Value** value) const; - bool GetValue(const std::string& key, Value** value); + bool GetValue(const std::string& key, const base::Value** value) const; + bool GetValue(const std::string& key, base::Value** value); // Sets a new |value| for |key|. Takes ownership of |value|, which must be // non-NULL. Returns true if the value changed. - bool SetValue(const std::string& key, Value* value); + bool SetValue(const std::string& key, base::Value* value); // Removes the value for |key| from the map. Returns true if a value was // removed. @@ -63,7 +65,7 @@ class PrefValueMap { std::vector<std::string>* differing_keys) const; private: - typedef std::map<std::string, Value*> Map; + typedef std::map<std::string, base::Value*> Map; Map prefs_; diff --git a/chrome/browser/prefs/proxy_config_dictionary.h b/chrome/browser/prefs/proxy_config_dictionary.h index 3eeac12..06a33a1 100644 --- a/chrome/browser/prefs/proxy_config_dictionary.h +++ b/chrome/browser/prefs/proxy_config_dictionary.h @@ -12,7 +12,9 @@ #include "base/memory/scoped_ptr.h" #include "chrome/browser/prefs/proxy_prefs.h" +namespace base { class DictionaryValue; +} // Factory and wrapper for proxy config dictionaries that are stored // in the user preferences. The dictionary has the following structure: @@ -26,7 +28,7 @@ class DictionaryValue; class ProxyConfigDictionary { public: // Creates a deep copy of |dict| and leaves ownership to caller. - explicit ProxyConfigDictionary(const DictionaryValue* dict); + explicit ProxyConfigDictionary(const base::DictionaryValue* dict); ~ProxyConfigDictionary(); bool GetMode(ProxyPrefs::ProxyMode* out) const; @@ -36,22 +38,23 @@ class ProxyConfigDictionary { bool GetBypassList(std::string* out) const; bool HasBypassList() const; - static DictionaryValue* CreateDirect(); - static DictionaryValue* CreateAutoDetect(); - static DictionaryValue* CreatePacScript(const std::string& pac_url, + static base::DictionaryValue* CreateDirect(); + static base::DictionaryValue* CreateAutoDetect(); + static base::DictionaryValue* CreatePacScript(const std::string& pac_url, bool pac_mandatory); - static DictionaryValue* CreateFixedServers( + static base::DictionaryValue* CreateFixedServers( const std::string& proxy_server, const std::string& bypass_list); - static DictionaryValue* CreateSystem(); + static base::DictionaryValue* CreateSystem(); private: - static DictionaryValue* CreateDictionary(ProxyPrefs::ProxyMode mode, - const std::string& pac_url, - bool pac_mandatory, - const std::string& proxy_server, - const std::string& bypass_list); + static base::DictionaryValue* CreateDictionary( + ProxyPrefs::ProxyMode mode, + const std::string& pac_url, + bool pac_mandatory, + const std::string& proxy_server, + const std::string& bypass_list); - scoped_ptr<DictionaryValue> dict_; + scoped_ptr<base::DictionaryValue> dict_; DISALLOW_COPY_AND_ASSIGN(ProxyConfigDictionary); }; diff --git a/chrome/browser/prefs/scoped_user_pref_update.h b/chrome/browser/prefs/scoped_user_pref_update.h index 19add5c..65365f3 100644 --- a/chrome/browser/prefs/scoped_user_pref_update.h +++ b/chrome/browser/prefs/scoped_user_pref_update.h @@ -17,9 +17,12 @@ #include "base/values.h" #include "chrome/browser/prefs/pref_service.h" +class PrefService; + +namespace base { class DictionaryValue; class ListValue; -class PrefService; +} namespace subtle { @@ -37,7 +40,7 @@ class ScopedUserPrefUpdateBase : public base::NonThreadSafe { virtual ~ScopedUserPrefUpdateBase(); // Sets |value_| to |service_|->GetMutableUserPref and returns it. - Value* Get(Value::ValueType type); + base::Value* Get(Value::ValueType type); private: // If |value_| is not null, triggers a notification of PrefObservers and @@ -49,7 +52,7 @@ class ScopedUserPrefUpdateBase : public base::NonThreadSafe { // Path of the preference being updated. std::string path_; // Cache of value from user pref store (set between Get() and Notify() calls). - Value* value_; + base::Value* value_; DISALLOW_COPY_AND_ASSIGN(ScopedUserPrefUpdateBase); }; @@ -96,8 +99,8 @@ class ScopedUserPrefUpdate : public subtle::ScopedUserPrefUpdateBase { DISALLOW_COPY_AND_ASSIGN(ScopedUserPrefUpdate); }; -typedef ScopedUserPrefUpdate<DictionaryValue, Value::TYPE_DICTIONARY> +typedef ScopedUserPrefUpdate<base::DictionaryValue, Value::TYPE_DICTIONARY> DictionaryPrefUpdate; -typedef ScopedUserPrefUpdate<ListValue, Value::TYPE_LIST> ListPrefUpdate; +typedef ScopedUserPrefUpdate<base::ListValue, Value::TYPE_LIST> ListPrefUpdate; #endif // CHROME_BROWSER_PREFS_SCOPED_USER_PREF_UPDATE_H_ diff --git a/chrome/browser/prefs/testing_pref_store.h b/chrome/browser/prefs/testing_pref_store.h index ff6dc00..106b836 100644 --- a/chrome/browser/prefs/testing_pref_store.h +++ b/chrome/browser/prefs/testing_pref_store.h @@ -12,8 +12,6 @@ #include "chrome/browser/prefs/pref_value_map.h" #include "chrome/common/persistent_pref_store.h" -class DictionaryValue; - // |TestingPrefStore| is a preference store implementation that allows tests to // explicitly manipulate the contents of the store, triggering notifications // where appropriate. @@ -24,16 +22,17 @@ class TestingPrefStore : public PersistentPrefStore { // Overriden from PrefStore. virtual ReadResult GetValue(const std::string& key, - const Value** result) const; + const base::Value** result) const; virtual void AddObserver(PrefStore::Observer* observer); virtual void RemoveObserver(PrefStore::Observer* observer); virtual bool IsInitializationComplete() const; // PersistentPrefStore overrides: - virtual ReadResult GetMutableValue(const std::string& key, Value** result); + virtual ReadResult GetMutableValue(const std::string& key, + base::Value** result); virtual void ReportValueChanged(const std::string& key); - virtual void SetValue(const std::string& key, Value* value); - virtual void SetValueSilently(const std::string& key, Value* value); + virtual void SetValue(const std::string& key, base::Value* value); + virtual void SetValueSilently(const std::string& key, base::Value* value); virtual void RemoveValue(const std::string& key); virtual bool ReadOnly() const; virtual PersistentPrefStore::PrefReadError ReadPrefs(); diff --git a/chrome/browser/prefs/value_map_pref_store.h b/chrome/browser/prefs/value_map_pref_store.h index c713156..1898055 100644 --- a/chrome/browser/prefs/value_map_pref_store.h +++ b/chrome/browser/prefs/value_map_pref_store.h @@ -15,15 +15,15 @@ // storing the preference values. class ValueMapPrefStore : public PrefStore { public: - typedef std::map<std::string, Value*>::iterator iterator; - typedef std::map<std::string, Value*>::const_iterator const_iterator; + typedef std::map<std::string, base::Value*>::iterator iterator; + typedef std::map<std::string, base::Value*>::const_iterator const_iterator; ValueMapPrefStore(); virtual ~ValueMapPrefStore(); // PrefStore overrides: virtual ReadResult GetValue(const std::string& key, - const Value** value) const; + const base::Value** value) const; virtual void AddObserver(PrefStore::Observer* observer); virtual void RemoveObserver(PrefStore::Observer* observer); @@ -35,7 +35,7 @@ class ValueMapPrefStore : public PrefStore { protected: // Store a |value| for |key| in the store. Also generates an notification if // the value changed. Assumes ownership of |value|, which must be non-NULL. - void SetValue(const std::string& key, Value* value); + void SetValue(const std::string& key, base::Value* value); // Remove the value for |key| from the store. Sends a notification if there // was a value to be removed. diff --git a/chrome/browser/prerender/prerender_contents.h b/chrome/browser/prerender/prerender_contents.h index 600fb5c..97a6fce 100644 --- a/chrome/browser/prerender/prerender_contents.h +++ b/chrome/browser/prerender/prerender_contents.h @@ -164,7 +164,7 @@ class PrerenderContents : public NotificationObserver, int32 starting_page_id() { return starting_page_id_; } - Value* GetAsValue() const; + base::Value* GetAsValue() const; protected: PrerenderContents(PrerenderManager* prerender_manager, diff --git a/chrome/browser/prerender/prerender_history.h b/chrome/browser/prerender/prerender_history.h index f969557..c917a4a 100644 --- a/chrome/browser/prerender/prerender_history.h +++ b/chrome/browser/prerender/prerender_history.h @@ -14,7 +14,9 @@ #include "chrome/browser/prerender/prerender_origin.h" #include "googleurl/src/gurl.h" +namespace base { class Value; +} namespace prerender { @@ -64,7 +66,7 @@ class PrerenderHistory : public base::NonThreadSafe { void Clear(); // Retrieves the entries as a value which can be displayed. - Value* GetEntriesAsValue() const; + base::Value* GetEntriesAsValue() const; private: std::list<Entry> entries_; diff --git a/chrome/browser/prerender/prerender_manager.h b/chrome/browser/prerender/prerender_manager.h index 4831a40..bc88482 100644 --- a/chrome/browser/prerender/prerender_manager.h +++ b/chrome/browser/prerender/prerender_manager.h @@ -169,7 +169,7 @@ class PrerenderManager : public base::SupportsWeakPtr<PrerenderManager>, // Returns a Value object containing the active pages being prerendered, and // a history of pages which were prerendered. The caller is responsible for // deleting the return value. - Value* GetAsValue() const; + base::Value* GetAsValue() const; // Clears the data indicated by which bits of clear_flags are set. // @@ -308,7 +308,7 @@ class PrerenderManager : public base::SupportsWeakPtr<PrerenderManager>, // Returns a new Value representing the pages currently being prerendered. The // caller is responsible for delete'ing the return value. - Value* GetActivePrerendersAsValue() const; + base::Value* GetActivePrerendersAsValue() const; // Destroys all pending prerenders using FinalStatus. Also deletes them as // well as any swapped out TabContents queued for destruction. diff --git a/chrome/browser/printing/cloud_print/cloud_print_setup_flow.h b/chrome/browser/printing/cloud_print/cloud_print_setup_flow.h index b955eec..d532c60 100644 --- a/chrome/browser/printing/cloud_print/cloud_print_setup_flow.h +++ b/chrome/browser/printing/cloud_print/cloud_print_setup_flow.h @@ -25,6 +25,10 @@ class ServiceProcessControl; class GoogleServiceAuthError; class Browser; +namespace base { +class DictionaryValue; +} + // This class is responsible for showing a cloud print setup dialog // and perform operations to fill the content of the dialog and handle // user actions in the dialog. @@ -109,7 +113,7 @@ class CloudPrintSetupFlow : public HtmlDialogUIDelegate, void OnUserClickedPrintTestPage(); // The following methods control which iframe is visible. - void ShowGaiaLogin(const DictionaryValue& args); + void ShowGaiaLogin(const base::DictionaryValue& args); void ShowGaiaSuccessAndSettingUp(); void ShowGaiaFailed(const GoogleServiceAuthError& error); void ShowSetupDone(); diff --git a/chrome/browser/printing/print_dialog_cloud_internal.h b/chrome/browser/printing/print_dialog_cloud_internal.h index 23f8e2b..bfb8060 100644 --- a/chrome/browser/printing/print_dialog_cloud_internal.h +++ b/chrome/browser/printing/print_dialog_cloud_internal.h @@ -18,9 +18,14 @@ #include "content/common/notification_registrar.h" class GURL; -class StringValue; class CloudPrintHtmlDialogDelegateTest; +namespace base { +class ListValue; +class StringValue; +class Value; +} + namespace internal_cloud_print_helpers { // Small class to virtualize a few functions to aid with unit testing. @@ -33,10 +38,10 @@ class CloudPrintDataSenderHelper { // facilitate unit testing. virtual void CallJavascriptFunction(const std::wstring& function_name); virtual void CallJavascriptFunction(const std::wstring& function_name, - const Value& arg); + const base::Value& arg); virtual void CallJavascriptFunction(const std::wstring& function_name, - const Value& arg1, - const Value& arg2); + const base::Value& arg1, + const base::Value& arg2); private: WebUI* web_ui_; @@ -73,7 +78,7 @@ class CloudPrintDataSender base::Lock lock_; CloudPrintDataSenderHelper* volatile helper_; - scoped_ptr<StringValue> print_data_; + scoped_ptr<base::StringValue> print_data_; string16 print_job_title_; std::string file_type_; @@ -106,9 +111,9 @@ class CloudPrintFlowHandler : public WebUIMessageHandler, const NotificationDetails& details); // Callbacks from the page. - void HandleShowDebugger(const ListValue* args); - void HandleSendPrintData(const ListValue* args); - void HandleSetPageParameters(const ListValue* args); + void HandleShowDebugger(const base::ListValue* args); + void HandleSendPrintData(const base::ListValue* args); + void HandleSetPageParameters(const base::ListValue* args); virtual void SetDialogDelegate(CloudPrintHtmlDialogDelegate *delegate); void StoreDialogClientSize() const; diff --git a/chrome/browser/printing/print_dialog_gtk.h b/chrome/browser/printing/print_dialog_gtk.h index 47b38ad..af082d6 100644 --- a/chrome/browser/printing/print_dialog_gtk.h +++ b/chrome/browser/printing/print_dialog_gtk.h @@ -39,7 +39,7 @@ class PrintDialogGtk // printing::PrintDialogGtkInterface implementation. virtual void UseDefaultSettings(); - virtual bool UpdateSettings(const DictionaryValue& settings, + virtual bool UpdateSettings(const base::DictionaryValue& settings, const printing::PageRanges& ranges); virtual void ShowDialog( PrintingContextCairo::PrintSettingsCallback* callback); diff --git a/chrome/browser/printing/print_job_worker.h b/chrome/browser/printing/print_job_worker.h index 41195c6..44c0fb5 100644 --- a/chrome/browser/printing/print_job_worker.h +++ b/chrome/browser/printing/print_job_worker.h @@ -14,7 +14,9 @@ #include "printing/printing_context.h" #include "ui/gfx/native_widget_types.h" +namespace base { class DictionaryValue; +} namespace printing { @@ -46,7 +48,7 @@ class PrintJobWorker : public base::Thread { // Set the new print settings. This function takes ownership of // |new_settings|. - void SetSettings(const DictionaryValue* const new_settings); + void SetSettings(const base::DictionaryValue* const new_settings); // Starts the printing loop. Every pages are printed as soon as the data is // available. Makes sure the new_document is the right one. @@ -100,7 +102,7 @@ class PrintJobWorker : public base::Thread { // Called on the UI thread to update the print settings. This function takes // the ownership of |new_settings|. - void UpdatePrintSettings(const DictionaryValue* const new_settings); + void UpdatePrintSettings(const base::DictionaryValue* const new_settings); // Reports settings back to owner_. void GetSettingsDone(PrintingContext::Result result); diff --git a/chrome/browser/printing/printer_query.h b/chrome/browser/printing/printer_query.h index c360e6e..c2df681 100644 --- a/chrome/browser/printing/printer_query.h +++ b/chrome/browser/printing/printer_query.h @@ -11,10 +11,10 @@ #include "ui/gfx/native_widget_types.h" class CancelableTask; -class DictionaryValue; class MessageLoop; namespace base { +class DictionaryValue; class Thread; } @@ -53,7 +53,7 @@ class PrinterQuery : public PrintJobWorkerOwner { CancelableTask* callback); // Updates the current settings with |new_settings| dictionary values. - void SetSettings(const DictionaryValue& new_settings, + void SetSettings(const base::DictionaryValue& new_settings, CancelableTask* callback); // Stops the worker thread since the client is done with this object. diff --git a/chrome/browser/printing/printing_message_filter.h b/chrome/browser/printing/printing_message_filter.h index 829aba8..a611394 100644 --- a/chrome/browser/printing/printing_message_filter.h +++ b/chrome/browser/printing/printing_message_filter.h @@ -12,9 +12,12 @@ #include "base/shared_memory.h" #endif -class DictionaryValue; struct PrintHostMsg_ScriptedPrint_Params; +namespace base { +class DictionaryValue; +} + namespace printing { class PrinterQuery; class PrintJobManager; @@ -68,7 +71,7 @@ class PrintingMessageFilter : public BrowserMessageFilter { IPC::Message* reply_msg); void OnUpdatePrintSettings(int document_cookie, - const DictionaryValue& job_settings, + const base::DictionaryValue& job_settings, IPC::Message* reply_msg); void OnUpdatePrintSettingsReply( scoped_refptr<printing::PrinterQuery> printer_query, diff --git a/chrome/browser/profiles/profile_info_cache.h b/chrome/browser/profiles/profile_info_cache.h index f4ed02b..8b7b8f8 100644 --- a/chrome/browser/profiles/profile_info_cache.h +++ b/chrome/browser/profiles/profile_info_cache.h @@ -17,7 +17,10 @@ namespace gfx { class Image; } +namespace base { class DictionaryValue; +} + class PrefService; @@ -65,11 +68,11 @@ class ProfileInfoCache { static void RegisterPrefs(PrefService* prefs); private: - const DictionaryValue* GetInfoForProfileAtIndex(size_t index) const; + const base::DictionaryValue* GetInfoForProfileAtIndex(size_t index) const; // Saves the profile info to a cache and takes ownership of |info|. // Currently the only information that is cached is the profiles name and // avatar icon. - void SetInfoForProfileAtIndex(size_t index, DictionaryValue* info); + void SetInfoForProfileAtIndex(size_t index, base::DictionaryValue* info); std::string CacheKeyFromProfilePath(const FilePath& profile_path) const; std::vector<std::string>::iterator FindPositionForProfile( std::string search_key, diff --git a/chrome/browser/safe_browsing/safe_browsing_blocking_page.h b/chrome/browser/safe_browsing/safe_browsing_blocking_page.h index e0a47f9..c10ea86 100644 --- a/chrome/browser/safe_browsing/safe_browsing_blocking_page.h +++ b/chrome/browser/safe_browsing/safe_browsing_blocking_page.h @@ -36,12 +36,15 @@ #include "chrome/browser/tab_contents/chrome_interstitial_page.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class MessageLoop; class SafeBrowsingBlockingPageFactory; class MalwareDetails; class TabContents; +namespace base { +class DictionaryValue; +} + class SafeBrowsingBlockingPage : public ChromeInterstitialPage { public: typedef std::vector<SafeBrowsingService::UnsafeResource> UnsafeResourceList; @@ -96,13 +99,13 @@ class SafeBrowsingBlockingPage : public ChromeInterstitialPage { // Fills the passed dictionary with the strings passed to JS Template when // creating the HTML. - void PopulateMultipleThreatStringDictionary(DictionaryValue* strings); - void PopulateMalwareStringDictionary(DictionaryValue* strings); - void PopulatePhishingStringDictionary(DictionaryValue* strings); + void PopulateMultipleThreatStringDictionary(base::DictionaryValue* strings); + void PopulateMalwareStringDictionary(base::DictionaryValue* strings); + void PopulatePhishingStringDictionary(base::DictionaryValue* strings); // A helper method used by the Populate methods above used to populate common // fields. - void PopulateStringDictionary(DictionaryValue* strings, + void PopulateStringDictionary(base::DictionaryValue* strings, const string16& title, const string16& headline, const string16& description1, diff --git a/chrome/browser/ssl/ssl_blocking_page.h b/chrome/browser/ssl/ssl_blocking_page.h index 7768995..6f0deda 100644 --- a/chrome/browser/ssl/ssl_blocking_page.h +++ b/chrome/browser/ssl/ssl_blocking_page.h @@ -13,9 +13,12 @@ #include "base/string16.h" #include "chrome/browser/tab_contents/chrome_interstitial_page.h" -class DictionaryValue; class SSLCertErrorHandler; +namespace base { +class DictionaryValue; +} + // This class is responsible for showing/hiding the interstitial page that is // shown when a certificate error happens. // It deletes itself when the interstitial page is closed. @@ -30,7 +33,7 @@ class SSLBlockingPage : public ChromeInterstitialPage { // vector so that they can be used to resource the ssl_roadblock.html/ // ssl_error.html files. // Note: there can be up to 5 strings in |extra_info|. - static void SetExtraInfo(DictionaryValue* strings, + static void SetExtraInfo(base::DictionaryValue* strings, const std::vector<string16>& extra_info); protected: diff --git a/chrome/browser/sync/engine/syncapi.h b/chrome/browser/sync/engine/syncapi.h index f19a9c8..ffe369d 100644 --- a/chrome/browser/sync/engine/syncapi.h +++ b/chrome/browser/sync/engine/syncapi.h @@ -55,9 +55,12 @@ #include "chrome/common/net/gaia/google_service_auth_error.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class FilePath; +namespace base { +class DictionaryValue; +} + namespace browser_sync { class JsBackend; class ModelSafeWorkerRegistrar; @@ -284,11 +287,11 @@ class BaseNode { // Dumps a summary of node info into a DictionaryValue and returns it. // Transfers ownership of the DictionaryValue to the caller. - DictionaryValue* GetSummaryAsValue() const; + base::DictionaryValue* GetSummaryAsValue() const; // Dumps all node details into a DictionaryValue and returns it. // Transfers ownership of the DictionaryValue to the caller. - DictionaryValue* GetDetailsAsValue() const; + base::DictionaryValue* GetDetailsAsValue() const; protected: BaseNode(); @@ -637,7 +640,7 @@ class SyncManager { virtual ~ExtraPasswordChangeRecordData(); // Transfers ownership of the DictionaryValue to the caller. - virtual DictionaryValue* ToValue() const; + virtual base::DictionaryValue* ToValue() const; const sync_pb::PasswordSpecificsData& unencrypted() const; private: @@ -658,7 +661,7 @@ class SyncManager { ~ChangeRecord(); // Transfers ownership of the DictionaryValue to the caller. - DictionaryValue* ToValue(const BaseTransaction* trans) const; + base::DictionaryValue* ToValue(const BaseTransaction* trans) const; int64 id; Action action; diff --git a/chrome/browser/sync/js_test_util.h b/chrome/browser/sync/js_test_util.h index 2571e8b..e9a6ca3 100644 --- a/chrome/browser/sync/js_test_util.h +++ b/chrome/browser/sync/js_test_util.h @@ -15,8 +15,10 @@ #include "chrome/browser/sync/js_event_router.h" #include "testing/gmock/include/gmock/gmock.h" +namespace base { class DictionaryValue; class ListValue; +} namespace browser_sync { @@ -34,7 +36,7 @@ void PrintTo(const JsEventDetails& details, ::std::ostream* os); // Like HasArgs() but takes a ListValue instead. ::testing::Matcher<const JsArgList&> HasArgsAsList( - const ListValue& expected_args); + const base::ListValue& expected_args); // A gmock matcher for JsEventDetails. Use like: // @@ -44,7 +46,7 @@ void PrintTo(const JsEventDetails& details, ::std::ostream* os); // Like HasDetails() but takes a DictionaryValue instead. ::testing::Matcher<const JsEventDetails&> HasDetailsAsDictionary( - const DictionaryValue& expected_details); + const base::DictionaryValue& expected_details); // Mocks. diff --git a/chrome/browser/sync/protocol/proto_value_conversions.h b/chrome/browser/sync/protocol/proto_value_conversions.h index 1c6869a..16b2bab 100644 --- a/chrome/browser/sync/protocol/proto_value_conversions.h +++ b/chrome/browser/sync/protocol/proto_value_conversions.h @@ -8,7 +8,9 @@ #define CHROME_BROWSER_SYNC_PROTOCOL_PROTO_VALUE_CONVERSIONS_H_ #pragma once +namespace base { class DictionaryValue; +} namespace sync_pb { class AppSpecifics; @@ -48,73 +50,73 @@ namespace browser_sync { // caller. // TODO(akalin): Perhaps extend this to decrypt? -DictionaryValue* EncryptedDataToValue( +base::DictionaryValue* EncryptedDataToValue( const sync_pb::EncryptedData& encrypted_data); // Sub-protocols of SessionSpecifics. -DictionaryValue* SessionHeaderToValue( +base::DictionaryValue* SessionHeaderToValue( const sync_pb::SessionHeader& session_header); -DictionaryValue* SessionTabToValue( +base::DictionaryValue* SessionTabToValue( const sync_pb::SessionTab& session_tab); -DictionaryValue* SessionWindowToValue( +base::DictionaryValue* SessionWindowToValue( const sync_pb::SessionWindow& session_window); -DictionaryValue* TabNavigationToValue( +base::DictionaryValue* TabNavigationToValue( const sync_pb::TabNavigation& tab_navigation); // Sub-protocol of PasswordSpecifics. -DictionaryValue* PasswordSpecificsDataToValue( +base::DictionaryValue* PasswordSpecificsDataToValue( const sync_pb::PasswordSpecificsData& password_specifics_data); // Main *SpecificsToValue functions. -DictionaryValue* AppSpecificsToValue( +base::DictionaryValue* AppSpecificsToValue( const sync_pb::AppSpecifics& app_specifics); -DictionaryValue* AutofillSpecificsToValue( +base::DictionaryValue* AutofillSpecificsToValue( const sync_pb::AutofillSpecifics& autofill_specifics); -DictionaryValue* AutofillCreditCardSpecificsToValue( +base::DictionaryValue* AutofillCreditCardSpecificsToValue( const sync_pb::AutofillCreditCardSpecifics& autofill_credit_card_specifics); -DictionaryValue* AutofillProfileSpecificsToValue( +base::DictionaryValue* AutofillProfileSpecificsToValue( const sync_pb::AutofillProfileSpecifics& autofill_profile_specifics); -DictionaryValue* BookmarkSpecificsToValue( +base::DictionaryValue* BookmarkSpecificsToValue( const sync_pb::BookmarkSpecifics& bookmark_specifics); -DictionaryValue* ExtensionSpecificsToValue( +base::DictionaryValue* ExtensionSpecificsToValue( const sync_pb::ExtensionSpecifics& extension_specifics); -DictionaryValue* NigoriSpecificsToValue( +base::DictionaryValue* NigoriSpecificsToValue( const sync_pb::NigoriSpecifics& nigori_specifics); -DictionaryValue* PasswordSpecificsToValue( +base::DictionaryValue* PasswordSpecificsToValue( const sync_pb::PasswordSpecifics& password_specifics); -DictionaryValue* PreferenceSpecificsToValue( +base::DictionaryValue* PreferenceSpecificsToValue( const sync_pb::PreferenceSpecifics& password_specifics); -DictionaryValue* SearchEngineSpecificsToValue( +base::DictionaryValue* SearchEngineSpecificsToValue( const sync_pb::SearchEngineSpecifics& search_engine_specifics); -DictionaryValue* SessionSpecificsToValue( +base::DictionaryValue* SessionSpecificsToValue( const sync_pb::SessionSpecifics& session_specifics); -DictionaryValue* ThemeSpecificsToValue( +base::DictionaryValue* ThemeSpecificsToValue( const sync_pb::ThemeSpecifics& theme_specifics); -DictionaryValue* TypedUrlSpecificsToValue( +base::DictionaryValue* TypedUrlSpecificsToValue( const sync_pb::TypedUrlSpecifics& typed_url_specifics); // Any present extensions are mapped to sub-dictionary values with the // key equal to the extension name. -DictionaryValue* EntitySpecificsToValue( +base::DictionaryValue* EntitySpecificsToValue( const sync_pb::EntitySpecifics& entity_specifics); } // namespace browser_sync diff --git a/chrome/browser/sync/sessions/session_state.h b/chrome/browser/sync/sessions/session_state.h index f618fe9..85d683b 100644 --- a/chrome/browser/sync/sessions/session_state.h +++ b/chrome/browser/sync/sessions/session_state.h @@ -27,7 +27,9 @@ #include "chrome/browser/sync/syncable/model_type_payload_map.h" #include "chrome/browser/sync/syncable/syncable.h" +namespace base { class DictionaryValue; +} namespace syncable { class DirectoryManager; @@ -50,7 +52,7 @@ struct SyncSourceInfo { ~SyncSourceInfo(); // Caller takes ownership of the returned dictionary. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; sync_pb::GetUpdatesCallerInfo::GetUpdatesSource updates_source; syncable::ModelTypePayloadMap types; @@ -62,7 +64,7 @@ struct SyncerStatus { ~SyncerStatus(); // Caller takes ownership of the returned dictionary. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; // True when we get such an INVALID_STORE error from the server. bool invalid_store; @@ -91,7 +93,7 @@ struct ErrorCounters { ErrorCounters(); // Caller takes ownership of the returned dictionary. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; int num_conflicting_commits; @@ -106,7 +108,7 @@ struct ErrorCounters { }; // Caller takes ownership of the returned dictionary. -DictionaryValue* DownloadProgressMarkersToValue( +base::DictionaryValue* DownloadProgressMarkersToValue( const std::string (&download_progress_markers)[syncable::MODEL_TYPE_COUNT]); @@ -132,7 +134,7 @@ struct SyncSessionSnapshot { ~SyncSessionSnapshot(); // Caller takes ownership of the returned dictionary. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; std::string ToString() const; diff --git a/chrome/browser/sync/sync_setup_flow_handler.h b/chrome/browser/sync/sync_setup_flow_handler.h index b807d91..a7c2ae3 100644 --- a/chrome/browser/sync/sync_setup_flow_handler.h +++ b/chrome/browser/sync/sync_setup_flow_handler.h @@ -8,17 +8,20 @@ #include <string> -class DictionaryValue; class SyncSetupFlow; +namespace base { +class DictionaryValue; +} + class SyncSetupFlowHandler { public: // These functions control which part of the HTML is visible. - virtual void ShowGaiaLogin(const DictionaryValue& args) = 0; + virtual void ShowGaiaLogin(const base::DictionaryValue& args) = 0; virtual void ShowGaiaSuccessAndClose() = 0; virtual void ShowGaiaSuccessAndSettingUp() = 0; - virtual void ShowConfigure(const DictionaryValue& args) = 0; - virtual void ShowPassphraseEntry(const DictionaryValue& args) = 0; + virtual void ShowConfigure(const base::DictionaryValue& args) = 0; + virtual void ShowPassphraseEntry(const base::DictionaryValue& args) = 0; virtual void ShowSettingUp() = 0; virtual void ShowSetupDone(const std::wstring& user) = 0; virtual void SetFlow(SyncSetupFlow* flow) = 0; diff --git a/chrome/browser/sync/sync_ui_util.h b/chrome/browser/sync/sync_ui_util.h index 68738bc..136450c 100644 --- a/chrome/browser/sync/sync_ui_util.h +++ b/chrome/browser/sync/sync_ui_util.h @@ -14,8 +14,11 @@ class Browser; class Profile; + +namespace base { class ListValue; class DictionaryValue; +} // Utility functions to gather current sync status information from the sync // service and constructs messages suitable for showing in UI. @@ -58,7 +61,7 @@ void OpenSyncMyBookmarksDialog(Profile* profile, Browser* browser, ProfileSyncService::SyncEventCodes code); -void AddBoolSyncDetail(ListValue* details, +void AddBoolSyncDetail(base::ListValue* details, const std::string& stat_name, bool stat_value); @@ -66,7 +69,7 @@ void AddBoolSyncDetail(ListValue* details, void ConstructAboutInformation(ProfileSyncService* service, DictionaryValue* strings); -void AddIntSyncDetail(ListValue* details, +void AddIntSyncDetail(base::ListValue* details, const std::string& stat_name, int64 stat_value); } // namespace sync_ui_util diff --git a/chrome/browser/sync/syncable/model_type.h b/chrome/browser/sync/syncable/model_type.h index ed84384..d8582a3 100644 --- a/chrome/browser/sync/syncable/model_type.h +++ b/chrome/browser/sync/syncable/model_type.h @@ -17,8 +17,10 @@ #include "base/logging.h" #include "base/time.h" +namespace base { class ListValue; class StringValue; +} namespace sync_pb { class EntitySpecifics; @@ -116,7 +118,7 @@ std::string ModelTypeToString(ModelType model_type); // Handles all model types, and not just real ones. // // Caller takes ownership of returned value. -StringValue* ModelTypeToValue(ModelType model_type); +base::StringValue* ModelTypeToValue(ModelType model_type); std::string ModelTypeSetToString(const ModelTypeSet& model_types); @@ -135,10 +137,10 @@ bool ModelTypeBitSetFromString( ModelTypeBitSet ModelTypeBitSetFromSet(const ModelTypeSet& set); // Caller takes ownership of returned list. -ListValue* ModelTypeBitSetToValue(const ModelTypeBitSet& model_types); +base::ListValue* ModelTypeBitSetToValue(const ModelTypeBitSet& model_types); // Caller takes ownership of returned list. -ListValue* ModelTypeSetToValue(const ModelTypeSet& model_types); +base::ListValue* ModelTypeSetToValue(const ModelTypeSet& model_types); // Returns a string corresponding to the syncable tag for this datatype. std::string ModelTypeToRootTag(ModelType type); diff --git a/chrome/browser/sync/syncable/model_type_payload_map.h b/chrome/browser/sync/syncable/model_type_payload_map.h index f70a641..5a4d375 100644 --- a/chrome/browser/sync/syncable/model_type_payload_map.h +++ b/chrome/browser/sync/syncable/model_type_payload_map.h @@ -14,7 +14,9 @@ #include "chrome/browser/sync/engine/model_safe_worker.h" #include "chrome/browser/sync/syncable/model_type.h" +namespace base { class DictionaryValue; +} namespace syncable { @@ -40,7 +42,7 @@ std::string ModelTypePayloadMapToString( const ModelTypePayloadMap& model_type_payloads); // Caller takes ownership of the returned dictionary. -DictionaryValue* ModelTypePayloadMapToValue( +base::DictionaryValue* ModelTypePayloadMapToValue( const ModelTypePayloadMap& model_type_payloads); // Coalesce |update| into |original|, overwriting only when |update| has diff --git a/chrome/browser/sync/syncable/syncable.h b/chrome/browser/sync/syncable/syncable.h index 7c145d0..571374d 100644 --- a/chrome/browser/sync/syncable/syncable.h +++ b/chrome/browser/sync/syncable/syncable.h @@ -33,9 +33,13 @@ #include "chrome/browser/sync/util/dbgq.h" #include "chrome/common/deprecated/event_sys.h" -class DictionaryValue; struct PurgeInfo; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace sync_api { class ReadTransaction; class WriteNode; @@ -344,7 +348,7 @@ struct EntryKernel { // Dumps all kernel info into a DictionaryValue and returns it. // Transfers ownership of the DictionaryValue to the caller. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; private: // Tracks whether this entry needs to be saved to the database. @@ -434,7 +438,7 @@ class Entry { // Dumps all entry info into a DictionaryValue and returns it. // Transfers ownership of the DictionaryValue to the caller. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; protected: // Don't allow creation on heap, except by sync API wrappers. friend class sync_api::ReadNode; @@ -567,7 +571,7 @@ typedef std::set<EntryKernelMutation, EntryKernelMutationLessByMetaHandle> EntryKernelMutationSet; // Caller owns the return value. -ListValue* EntryKernelMutationSetToValue( +base::ListValue* EntryKernelMutationSetToValue( const EntryKernelMutationSet& mutations); // How syncable indices & Indexers work. diff --git a/chrome/browser/sync/syncable/syncable_id.h b/chrome/browser/sync/syncable/syncable_id.h index 33ed3b8..9630103 100644 --- a/chrome/browser/sync/syncable/syncable_id.h +++ b/chrome/browser/sync/syncable/syncable_id.h @@ -13,7 +13,9 @@ #include "base/hash_tables.h" +namespace base { class StringValue; +} namespace syncable { struct EntryKernel; @@ -95,7 +97,7 @@ class Id { // Dumps the ID as a value and returns it. Transfers ownership of // the StringValue to the caller. - StringValue* ToValue() const; + base::StringValue* ToValue() const; // Three functions are used to work with our proto buffers. std::string GetServerId() const; diff --git a/chrome/browser/themes/browser_theme_pack.h b/chrome/browser/themes/browser_theme_pack.h index 280c469..c208751 100644 --- a/chrome/browser/themes/browser_theme_pack.h +++ b/chrome/browser/themes/browser_theme_pack.h @@ -16,7 +16,6 @@ #include "content/browser/browser_thread.h" #include "ui/gfx/color_utils.h" -class DictionaryValue; class FilePath; class RefCountedMemory; namespace ui { @@ -25,6 +24,9 @@ class DataPack; namespace gfx { class Image; } +namespace base { +class DictionaryValue; +} // An optimized representation of a theme, backed by a mmapped DataPack. // @@ -117,22 +119,22 @@ class BrowserThemePack : public base::RefCountedThreadSafe< // Transforms the JSON tint values into their final versions in the |tints_| // array. - void BuildTintsFromJSON(DictionaryValue* tints_value); + void BuildTintsFromJSON(base::DictionaryValue* tints_value); // Transforms the JSON color values into their final versions in the // |colors_| array and also fills in unspecified colors based on tint values. - void BuildColorsFromJSON(DictionaryValue* color_value); + void BuildColorsFromJSON(base::DictionaryValue* color_value); // Implementation details of BuildColorsFromJSON(). - void ReadColorsFromJSON(DictionaryValue* colors_value, + void ReadColorsFromJSON(base::DictionaryValue* colors_value, std::map<int, SkColor>* temp_colors); void GenerateMissingColors(std::map<int, SkColor>* temp_colors); // Transforms the JSON display properties into |display_properties_|. - void BuildDisplayPropertiesFromJSON(DictionaryValue* display_value); + void BuildDisplayPropertiesFromJSON(base::DictionaryValue* display_value); // Parses the image names out of an extension. - void ParseImageNamesFromJSON(DictionaryValue* images_value, + void ParseImageNamesFromJSON(base::DictionaryValue* images_value, const FilePath& images_path, FilePathMap* file_paths) const; diff --git a/chrome/browser/translate/translate_prefs.h b/chrome/browser/translate/translate_prefs.h index 5b94df3..f6bf18e 100644 --- a/chrome/browser/translate/translate_prefs.h +++ b/chrome/browser/translate/translate_prefs.h @@ -10,9 +10,12 @@ #include "googleurl/src/gurl.h" +class PrefService; + +namespace base { class DictionaryValue; class ListValue; -class PrefService; +} class TranslatePrefs { public: @@ -64,17 +67,17 @@ class TranslatePrefs { bool IsValueBlacklisted(const char* pref_id, const std::string& value); void BlacklistValue(const char* pref_id, const std::string& value); void RemoveValueFromBlacklist(const char* pref_id, const std::string& value); - bool IsValueInList(const ListValue* list, const std::string& value); + bool IsValueInList(const base::ListValue* list, const std::string& value); bool IsLanguageWhitelisted(const std::string& original_language, std::string* target_language); // Retrieves the dictionary mapping the number of times translation has been // denied for a language, creating it if necessary. - DictionaryValue* GetTranslationDeniedCountDictionary(); + base::DictionaryValue* GetTranslationDeniedCountDictionary(); // Retrieves the dictionary mapping the number of times translation has been // accepted for a language, creating it if necessary. - DictionaryValue* GetTranslationAcceptedCountDictionary(); + base::DictionaryValue* GetTranslationAcceptedCountDictionary(); PrefService* prefs_; // Weak. }; diff --git a/chrome/browser/ui/webui/chrome_url_data_manager.h b/chrome/browser/ui/webui/chrome_url_data_manager.h index bed84d7..9bf894b 100644 --- a/chrome/browser/ui/webui/chrome_url_data_manager.h +++ b/chrome/browser/ui/webui/chrome_url_data_manager.h @@ -13,12 +13,15 @@ #include "content/browser/browser_thread.h" class ChromeURLDataManagerBackend; -class DictionaryValue; class FilePath; class MessageLoop; class Profile; class RefCountedMemory; +namespace base { +class DictionaryValue; +} + // To serve dynamic data off of chrome: URLs, implement the // ChromeURLDataManager::DataSource interface and register your handler // with AddDataSource. DataSources must be added on the UI thread (they are also @@ -102,7 +105,8 @@ class ChromeURLDataManager { // TODO: nuke this and convert all callers to not replace. virtual bool ShouldReplaceExistingSource() const; - static void SetFontAndTextDirection(DictionaryValue* localized_strings); + static void SetFontAndTextDirection( + base::DictionaryValue* localized_strings); protected: virtual ~DataSource(); diff --git a/chrome/browser/ui/webui/chromeos/login/eula_screen_handler.h b/chrome/browser/ui/webui/chromeos/login/eula_screen_handler.h index 2d947de..3dd3c20 100644 --- a/chrome/browser/ui/webui/chromeos/login/eula_screen_handler.h +++ b/chrome/browser/ui/webui/chromeos/login/eula_screen_handler.h @@ -12,7 +12,10 @@ #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" #include "content/browser/webui/web_ui.h" +namespace base { +class DictionaryValue; class ListValue; +} namespace chromeos { @@ -35,7 +38,7 @@ class EulaScreenHandler : public EulaScreenActor, virtual void OnPasswordFetched(const std::string& tpm_password); // OobeMessageHandler implementation: - virtual void GetLocalizedStrings(DictionaryValue* localized_strings); + virtual void GetLocalizedStrings(base::DictionaryValue* localized_strings); virtual void Initialize(); // WebUIMessageHandler implementation: @@ -43,9 +46,9 @@ class EulaScreenHandler : public EulaScreenActor, private: // JS messages handlers. - void HandleOnExit(const ListValue* args); - void HandleOnLearnMore(const ListValue* args); - void HandleOnTpmPopupOpened(const ListValue* args); + void HandleOnExit(const base::ListValue* args); + void HandleOnLearnMore(const base::ListValue* args); + void HandleOnTpmPopupOpened(const base::ListValue* args); Delegate* delegate_; diff --git a/chrome/browser/ui/webui/chromeos/login/login_ui.h b/chrome/browser/ui/webui/chromeos/login/login_ui.h index 877b0810..0c18e5e 100644 --- a/chrome/browser/ui/webui/chromeos/login/login_ui.h +++ b/chrome/browser/ui/webui/chromeos/login/login_ui.h @@ -92,9 +92,9 @@ class LoginUIHandler : public WebUIMessageHandler, HelpAppLauncher::HelpTopic help_topic_id) OVERRIDE; // Callbacks from javascript. - void HandleAuthenticateUser(const ListValue* args); - void HandleLaunchIncognito(const ListValue* args); - void HandleShutdownSystem(const ListValue* args); + void HandleAuthenticateUser(const base::ListValue* args); + void HandleLaunchIncognito(const base::ListValue* args); + void HandleShutdownSystem(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(LoginUIHandler); }; diff --git a/chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h b/chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h index 8986fc2..f438e09 100644 --- a/chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h +++ b/chrome/browser/ui/webui/chromeos/login/login_ui_helpers.h @@ -10,10 +10,13 @@ #include "base/string_piece.h" -class DictionaryValue; class FilePath; class RefCountedBytes; +namespace base { +class DictionaryValue; +} + namespace chromeos { // This class is used for encapsulating the statics and other other messy @@ -28,7 +31,7 @@ class HTMLOperationsInterface { virtual base::StringPiece GetLoginHTML(); virtual std::string GetFullHTML(base::StringPiece login_html, - DictionaryValue* localized_strings); + base::DictionaryValue* localized_strings); virtual RefCountedBytes* CreateHTMLBytes(std::string full_html); private: diff --git a/chrome/browser/ui/webui/chromeos/login/network_screen_handler.h b/chrome/browser/ui/webui/chromeos/login/network_screen_handler.h index 96f06f1..511bc92 100644 --- a/chrome/browser/ui/webui/chromeos/login/network_screen_handler.h +++ b/chrome/browser/ui/webui/chromeos/login/network_screen_handler.h @@ -11,7 +11,9 @@ #include "content/browser/webui/web_ui.h" #include "ui/gfx/point.h" +namespace base { class ListValue; +} namespace views { class Widget; @@ -39,7 +41,7 @@ class NetworkScreenHandler : public NetworkScreenActor, virtual void EnableContinue(bool enabled); // OobeMessageHandler implementation: - virtual void GetLocalizedStrings(DictionaryValue* localized_strings); + virtual void GetLocalizedStrings(base::DictionaryValue* localized_strings); virtual void Initialize(); // WebUIMessageHandler implementation: @@ -47,24 +49,24 @@ class NetworkScreenHandler : public NetworkScreenActor, private: // Handles change of the network control position. - void HandleNetworkControlPosition(const ListValue* args); + void HandleNetworkControlPosition(const base::ListValue* args); // Handles moving off the screen. - void HandleOnExit(const ListValue* args); + void HandleOnExit(const base::ListValue* args); // Handles change of the language. - void HandleOnLanguageChanged(const ListValue* args); + void HandleOnLanguageChanged(const base::ListValue* args); // Handles change of the input method. - void HandleOnInputMethodChanged(const ListValue* args); + void HandleOnInputMethodChanged(const base::ListValue* args); // Returns available languages. Caller gets the ownership. Note, it does // depend on the current locale. - static ListValue* GetLanguageList(); + static base::ListValue* GetLanguageList(); // Returns available input methods. Caller gets the ownership. Note, it does // depend on the current locale. - static ListValue* GetInputMethods(); + static base::ListValue* GetInputMethods(); // Creates network window or updates it's bounds. void CreateOrUpdateNetworkWindow(); diff --git a/chrome/browser/ui/webui/chromeos/login/oobe_ui.h b/chrome/browser/ui/webui/chromeos/login/oobe_ui.h index 0af6ba7..feb60ba 100644 --- a/chrome/browser/ui/webui/chromeos/login/oobe_ui.h +++ b/chrome/browser/ui/webui/chromeos/login/oobe_ui.h @@ -9,7 +9,9 @@ #include "chrome/browser/chromeos/login/oobe_display.h" #include "chrome/browser/ui/webui/chrome_web_ui.h" +namespace base { class DictionaryValue; +} namespace chromeos { class SigninScreenHandler; @@ -24,7 +26,8 @@ class OobeMessageHandler : public WebUIMessageHandler { virtual ~OobeMessageHandler(); // Gets localized strings to be used on the page. - virtual void GetLocalizedStrings(DictionaryValue* localized_strings) = 0; + virtual void GetLocalizedStrings( + base::DictionaryValue* localized_strings) = 0; // This method is called when page is ready. It propagates to inherited class // via virtual Initialize() method (see below). @@ -65,7 +68,7 @@ class OobeUI : public OobeDisplay, virtual ViewScreenDelegate* GetHTMLPageScreenActor(); // Collects localized strings from the owned handlers. - void GetLocalizedStrings(DictionaryValue* localized_strings); + void GetLocalizedStrings(base::DictionaryValue* localized_strings); // Initializes the handlers. void InitializeHandlers(); diff --git a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h index 3eb5e3d..819396d 100644 --- a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h +++ b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h @@ -10,7 +10,10 @@ #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" #include "content/browser/webui/web_ui.h" +namespace base { +class DictionaryValue; class ListValue; +} namespace chromeos { @@ -25,7 +28,8 @@ class SigninScreenHandler : public OobeMessageHandler, private: // OobeMessageHandler implementation: - virtual void GetLocalizedStrings(DictionaryValue* localized_strings) OVERRIDE; + virtual void GetLocalizedStrings( + base::DictionaryValue* localized_strings) OVERRIDE; virtual void Initialize() OVERRIDE; // WebUIMessageHandler implementation: @@ -38,7 +42,7 @@ class SigninScreenHandler : public OobeMessageHandler, HelpAppLauncher::HelpTopic help_topic_id) OVERRIDE; // Handles authenticate user request from javascript. - void HandleAuthenticateUser(const ListValue* args); + void HandleAuthenticateUser(const base::ListValue* args); // A delegate that glues this handler with backend LoginDisplay. LoginUIHandlerDelegate* delegate_; diff --git a/chrome/browser/ui/webui/chromeos/login/update_screen_handler.h b/chrome/browser/ui/webui/chromeos/login/update_screen_handler.h index 9d21d5d..4afec0d 100644 --- a/chrome/browser/ui/webui/chromeos/login/update_screen_handler.h +++ b/chrome/browser/ui/webui/chromeos/login/update_screen_handler.h @@ -17,7 +17,7 @@ class UpdateScreenHandler : public UpdateScreenActor, virtual ~UpdateScreenHandler(); // OobeMessageHandler implementation: - virtual void GetLocalizedStrings(DictionaryValue* localized_strings); + virtual void GetLocalizedStrings(base::DictionaryValue* localized_strings); virtual void Initialize(); // UpdateScreenActor implementation: diff --git a/chrome/browser/ui/webui/collected_cookies_ui_delegate.h b/chrome/browser/ui/webui/collected_cookies_ui_delegate.h index 493a2db..12d5228 100644 --- a/chrome/browser/ui/webui/collected_cookies_ui_delegate.h +++ b/chrome/browser/ui/webui/collected_cookies_ui_delegate.h @@ -66,12 +66,12 @@ class CollectedCookiesUIDelegate : public HtmlDialogUIDelegate, const NotificationDetails& details); // JS callback to bind cookies tree models with JS trees. - void BindCookiesTreeModel(const ListValue* args); + void BindCookiesTreeModel(const base::ListValue* args); // JS callback to block/allow cookies from given site. - void Block(const ListValue* args); - void Allow(const ListValue* args); - void AllowThisSession(const ListValue* args); + void Block(const base::ListValue* args); + void Allow(const base::ListValue* args); + void AllowThisSession(const base::ListValue* args); NotificationRegistrar registrar_; TabContents* tab_contents_; diff --git a/chrome/browser/ui/webui/constrained_html_ui.h b/chrome/browser/ui/webui/constrained_html_ui.h index 54e62d6..58c2058 100644 --- a/chrome/browser/ui/webui/constrained_html_ui.h +++ b/chrome/browser/ui/webui/constrained_html_ui.h @@ -57,7 +57,7 @@ class ConstrainedHtmlUI : public ChromeWebUI { ConstrainedHtmlUIDelegate* GetConstrainedDelegate(); // JS Message Handler - void OnDialogClose(const ListValue* args); + void OnDialogClose(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(ConstrainedHtmlUI); }; diff --git a/chrome/browser/ui/webui/cookies_tree_model_adapter.h b/chrome/browser/ui/webui/cookies_tree_model_adapter.h index 2a5e4e0..971981c 100644 --- a/chrome/browser/ui/webui/cookies_tree_model_adapter.h +++ b/chrome/browser/ui/webui/cookies_tree_model_adapter.h @@ -9,9 +9,12 @@ #include "base/compiler_specific.h" #include "chrome/browser/cookies_tree_model.h" +class WebUI; + +namespace base { class ListValue; class Value; -class WebUI; +} // CookiesTreeModelAdapter binds a CookiesTreeModel with a JS tree. It observes // tree model changes and forwards them to JS tree. It also provides a @@ -45,7 +48,7 @@ class CookiesTreeModelAdapter : public CookiesTreeModel::Observer { // JS callback that gets the tree node using the tree path info in |args| and // call SendChildren to pass back children nodes data to WebUI. - void RequestChildren(const ListValue* args); + void RequestChildren(const base::ListValue* args); // Get children nodes data and pass it to 'CookiesTree.loadChildren' to // update the WebUI. @@ -53,7 +56,7 @@ class CookiesTreeModelAdapter : public CookiesTreeModel::Observer { // Helper function to get a Value* representing id of |node|. // Caller needs to free the returned Value. - Value* GetTreeNodeId(CookieTreeNode* node); + base::Value* GetTreeNodeId(CookieTreeNode* node); // Hosting WebUI of the js tree. WebUI* web_ui_; diff --git a/chrome/browser/ui/webui/cookies_tree_model_util.h b/chrome/browser/ui/webui/cookies_tree_model_util.h index 6e4c1b3..2b27b65 100644 --- a/chrome/browser/ui/webui/cookies_tree_model_util.h +++ b/chrome/browser/ui/webui/cookies_tree_model_util.h @@ -9,8 +9,11 @@ #include <string> class CookieTreeNode; + +namespace base { class DictionaryValue; class ListValue; +} namespace cookies_tree_model_util { @@ -19,11 +22,11 @@ std::string GetTreeNodeId(CookieTreeNode* node); // Populate given |dict| with cookie tree node properties. void GetCookieTreeNodeDictionary(const CookieTreeNode& node, - DictionaryValue* dict); + base::DictionaryValue* dict); // Append the children nodes of |parent| in specified range to |nodes| list. void GetChildNodeList(CookieTreeNode* parent, int start, int count, - ListValue* nodes); + base::ListValue* nodes); // Gets tree node from |path| under |root|. Return NULL if |path| is not valid. CookieTreeNode* GetTreeNodeFromPath(CookieTreeNode* root, diff --git a/chrome/browser/ui/webui/downloads_dom_handler.h b/chrome/browser/ui/webui/downloads_dom_handler.h index 7da060e..c50ae3d 100644 --- a/chrome/browser/ui/webui/downloads_dom_handler.h +++ b/chrome/browser/ui/webui/downloads_dom_handler.h @@ -13,7 +13,9 @@ #include "chrome/browser/download/download_manager.h" #include "content/browser/webui/web_ui.h" +namespace base { class ListValue; +} // The handler for Javascript messages related to the "downloads" view, // also observes changes to the download manager. @@ -37,37 +39,37 @@ class DownloadsDOMHandler : public WebUIMessageHandler, virtual void ModelChanged(); // Callback for the "getDownloads" message. - void HandleGetDownloads(const ListValue* args); + void HandleGetDownloads(const base::ListValue* args); // Callback for the "openFile" message - opens the file in the shell. - void HandleOpenFile(const ListValue* args); + void HandleOpenFile(const base::ListValue* args); // Callback for the "drag" message - initiates a file object drag. - void HandleDrag(const ListValue* args); + void HandleDrag(const base::ListValue* args); // Callback for the "saveDangerous" message - specifies that the user // wishes to save a dangerous file. - void HandleSaveDangerous(const ListValue* args); + void HandleSaveDangerous(const base::ListValue* args); // Callback for the "discardDangerous" message - specifies that the user // wishes to discard (remove) a dangerous file. - void HandleDiscardDangerous(const ListValue* args); + void HandleDiscardDangerous(const base::ListValue* args); // Callback for the "show" message - shows the file in explorer. - void HandleShow(const ListValue* args); + void HandleShow(const base::ListValue* args); // Callback for the "pause" message - pauses the file download. - void HandlePause(const ListValue* args); + void HandlePause(const base::ListValue* args); // Callback for the "remove" message - removes the file download from shelf // and list. - void HandleRemove(const ListValue* args); + void HandleRemove(const base::ListValue* args); // Callback for the "cancel" message - cancels the download. - void HandleCancel(const ListValue* args); + void HandleCancel(const base::ListValue* args); // Callback for the "clearAll" message - clears all the downloads. - void HandleClearAll(const ListValue* args); + void HandleClearAll(const base::ListValue* args); private: // Send the current list of downloads to the page. @@ -80,7 +82,7 @@ class DownloadsDOMHandler : public WebUIMessageHandler, DownloadItem* GetDownloadById(int id); // Return the download that is referred to in a given value. - DownloadItem* GetDownloadByValue(const ListValue* args); + DownloadItem* GetDownloadByValue(const base::ListValue* args); // Current search text. std::wstring search_text_; diff --git a/chrome/browser/ui/webui/history2_ui.h b/chrome/browser/ui/webui/history2_ui.h index 4ad6e90..cdc8c26 100644 --- a/chrome/browser/ui/webui/history2_ui.h +++ b/chrome/browser/ui/webui/history2_ui.h @@ -50,16 +50,16 @@ class BrowsingHistoryHandler2 : public WebUIMessageHandler, virtual void RegisterMessages(); // Callback for the "getHistory" message. - void HandleGetHistory(const ListValue* args); + void HandleGetHistory(const base::ListValue* args); // Callback for the "searchHistory" message. - void HandleSearchHistory(const ListValue* args); + void HandleSearchHistory(const base::ListValue* args); // Callback for the "removeURLsOnOneDay" message. - void HandleRemoveURLsOnOneDay(const ListValue* args); + void HandleRemoveURLsOnOneDay(const base::ListValue* args); // Handle for "clearBrowsingData" message. - void HandleClearBrowsingData(const ListValue* args); + void HandleClearBrowsingData(const base::ListValue* args); // NotificationObserver implementation. virtual void Observe(int type, @@ -75,7 +75,7 @@ class BrowsingHistoryHandler2 : public WebUIMessageHandler, void RemoveComplete(); // Extract the arguments from the call to HandleSearchHistory. - void ExtractSearchHistoryArguments(const ListValue* args, + void ExtractSearchHistoryArguments(const base::ListValue* args, int* month, string16* query); diff --git a/chrome/browser/ui/webui/history_ui.h b/chrome/browser/ui/webui/history_ui.h index 78a85b7..4f8197f 100644 --- a/chrome/browser/ui/webui/history_ui.h +++ b/chrome/browser/ui/webui/history_ui.h @@ -29,16 +29,16 @@ class BrowsingHistoryHandler : public WebUIMessageHandler, virtual void RegisterMessages(); // Callback for the "getHistory" message. - void HandleGetHistory(const ListValue* args); + void HandleGetHistory(const base::ListValue* args); // Callback for the "searchHistory" message. - void HandleSearchHistory(const ListValue* args); + void HandleSearchHistory(const base::ListValue* args); // Callback for the "removeURLsOnOneDay" message. - void HandleRemoveURLsOnOneDay(const ListValue* args); + void HandleRemoveURLsOnOneDay(const base::ListValue* args); // Handle for "clearBrowsingData" message. - void HandleClearBrowsingData(const ListValue* args); + void HandleClearBrowsingData(const base::ListValue* args); // NotificationObserver implementation. virtual void Observe(int type, @@ -54,7 +54,7 @@ class BrowsingHistoryHandler : public WebUIMessageHandler, void RemoveComplete(); // Extract the arguments from the call to HandleSearchHistory. - void ExtractSearchHistoryArguments(const ListValue* args, + void ExtractSearchHistoryArguments(const base::ListValue* args, int* month, string16* query); diff --git a/chrome/browser/ui/webui/html_dialog_ui.h b/chrome/browser/ui/webui/html_dialog_ui.h index c4a78f6..eb34963 100644 --- a/chrome/browser/ui/webui/html_dialog_ui.h +++ b/chrome/browser/ui/webui/html_dialog_ui.h @@ -19,6 +19,10 @@ class Size; struct ContextMenuParams; +namespace base { +class ListValue; +} + // Implement this class to receive notifications. class HtmlDialogUIDelegate { public: @@ -106,7 +110,7 @@ class HtmlDialogUI : public ChromeWebUI { virtual void RenderViewCreated(RenderViewHost* render_view_host); // JS message handler. - void OnDialogClosed(const ListValue* args); + void OnDialogClosed(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(HtmlDialogUI); }; diff --git a/chrome/browser/ui/webui/media_internals/media_internals_handler.cc b/chrome/browser/ui/webui/media_internals/media_internals_handler.cc index 45bf9c3..8411c08 100644 --- a/chrome/browser/ui/webui/media_internals/media_internals_handler.cc +++ b/chrome/browser/ui/webui/media_internals/media_internals_handler.cc @@ -4,6 +4,7 @@ #include "chrome/browser/ui/webui/media_internals/media_internals_handler.h" +#include "base/values.h" #include "chrome/browser/browser_process.h" #include "chrome/browser/ui/webui/media_internals/media_internals_proxy.h" #include "content/browser/browser_thread.h" diff --git a/chrome/browser/ui/webui/media_internals/media_internals_handler.h b/chrome/browser/ui/webui/media_internals/media_internals_handler.h index dc9fe7c..ed5fd3f 100644 --- a/chrome/browser/ui/webui/media_internals/media_internals_handler.h +++ b/chrome/browser/ui/webui/media_internals/media_internals_handler.h @@ -10,6 +10,10 @@ class MediaInternalsProxy; +namespace base { +class ListValue; +} + // This class handles messages to and from MediaInternalsUI. // It does all its work on the IO thread through the proxy below. class MediaInternalsMessageHandler : public WebUIMessageHandler { @@ -22,7 +26,7 @@ class MediaInternalsMessageHandler : public WebUIMessageHandler { virtual void RegisterMessages(); // Javascript message handlers. - void OnGetEverything(const ListValue* list); + void OnGetEverything(const base::ListValue* list); // MediaInternals message handlers. void OnUpdate(const string16& update); diff --git a/chrome/browser/ui/webui/net_internals_ui.h b/chrome/browser/ui/webui/net_internals_ui.h index 6a70c4e..f75160c 100644 --- a/chrome/browser/ui/webui/net_internals_ui.h +++ b/chrome/browser/ui/webui/net_internals_ui.h @@ -8,7 +8,9 @@ #include "chrome/browser/ui/webui/chrome_web_ui.h" +namespace base { class Value; +} class NetInternalsUI : public ChromeWebUI { public: @@ -16,7 +18,7 @@ class NetInternalsUI : public ChromeWebUI { // Returns a Value containing constants NetInternals needs to load a log file. // Safe to call on any thread. Caller takes ownership of the returned Value. - static Value* GetConstants(); + static base::Value* GetConstants(); private: DISALLOW_COPY_AND_ASSIGN(NetInternalsUI); diff --git a/chrome/browser/ui/webui/new_profile_handler.h b/chrome/browser/ui/webui/new_profile_handler.h index 1a69950..f4518c0 100644 --- a/chrome/browser/ui/webui/new_profile_handler.h +++ b/chrome/browser/ui/webui/new_profile_handler.h @@ -10,6 +10,10 @@ class RefCountedMemory; +namespace base { +class ListValue; +} + // The handler for Javascript messages related to the "new profile" page. class NewProfileHandler : public WebUIMessageHandler { public: @@ -19,13 +23,13 @@ class NewProfileHandler : public WebUIMessageHandler { virtual void RegisterMessages(); // Callback for the "create" message - finishes creating a profile. - void HandleCreate(const ListValue* args); + void HandleCreate(const base::ListValue* args); // Callback for the "cancel" message - cancels creating a profile. - void HandleCancel(const ListValue* args); + void HandleCancel(const base::ListValue* args); // Callback for the "requestProfileInfo" message - sends profile info. - void HandleRequestProfileInfo(const ListValue* args); + void HandleRequestProfileInfo(const base::ListValue* args); private: // Send the default avatar images to the page. diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.h b/chrome/browser/ui/webui/ntp/app_launcher_handler.h index 5299609..0d1c8c6 100644 --- a/chrome/browser/ui/webui/ntp/app_launcher_handler.h +++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.h @@ -41,7 +41,7 @@ class AppLauncherHandler : public WebUIMessageHandler, static void CreateAppInfo(const Extension* extension, const AppNotification* notification, ExtensionService* service, - DictionaryValue* value); + base::DictionaryValue* value); // Callback for pings related to launching apps on the NTP. static bool HandlePing(Profile* profile, const std::string& path); @@ -56,45 +56,45 @@ class AppLauncherHandler : public WebUIMessageHandler, const NotificationDetails& details); // Populate the given dictionary with all installed app info. - void FillAppDictionary(DictionaryValue* value); + void FillAppDictionary(base::DictionaryValue* value); // Create a dictionary value for the given extension. May return NULL, e.g. if // the given extension is not an app. If non-NULL, the caller assumes // ownership of the pointer. - DictionaryValue* GetAppInfo(const Extension* extension); + base::DictionaryValue* GetAppInfo(const Extension* extension); // Populate the given dictionary with the web store promo content. - void FillPromoDictionary(DictionaryValue* value); + void FillPromoDictionary(base::DictionaryValue* value); // Callback for the "getApps" message. - void HandleGetApps(const ListValue* args); + void HandleGetApps(const base::ListValue* args); // Callback for the "launchApp" message. - void HandleLaunchApp(const ListValue* args); + void HandleLaunchApp(const base::ListValue* args); // Callback for the "setLaunchType" message. - void HandleSetLaunchType(const ListValue* args); + void HandleSetLaunchType(const base::ListValue* args); // Callback for the "uninstallApp" message. - void HandleUninstallApp(const ListValue* args); + void HandleUninstallApp(const base::ListValue* args); // Callback for the "hideAppPromo" message. - void HandleHideAppsPromo(const ListValue* args); + void HandleHideAppsPromo(const base::ListValue* args); // Callback for the "createAppShortcut" message. - void HandleCreateAppShortcut(const ListValue* args); + void HandleCreateAppShortcut(const base::ListValue* args); // Callback for the "reorderApps" message. - void HandleReorderApps(const ListValue* args); + void HandleReorderApps(const base::ListValue* args); // Callback for the "setPageIndex" message. - void HandleSetPageIndex(const ListValue* args); + void HandleSetPageIndex(const base::ListValue* args); // Callback for the "promoSeen" message. - void HandlePromoSeen(const ListValue* args); + void HandlePromoSeen(const base::ListValue* args); // Callback for the "saveAppPageName" message. - void HandleSaveAppPageName(const ListValue* args); + void HandleSaveAppPageName(const base::ListValue* args); // Register app launcher preferences. static void RegisterUserPrefs(PrefService* pref_service); diff --git a/chrome/browser/ui/webui/ntp/favicon_webui_handler.h b/chrome/browser/ui/webui/ntp/favicon_webui_handler.h index 557cb96..30c40f0 100644 --- a/chrome/browser/ui/webui/ntp/favicon_webui_handler.h +++ b/chrome/browser/ui/webui/ntp/favicon_webui_handler.h @@ -14,9 +14,12 @@ #include "content/browser/webui/web_ui.h" class GURL; -class ListValue; class Profile; +namespace base { +class ListValue; +} + class FaviconWebUIHandler : public WebUIMessageHandler { public: FaviconWebUIHandler(); @@ -25,7 +28,7 @@ class FaviconWebUIHandler : public WebUIMessageHandler { // WebUIMessageHandler virtual void RegisterMessages(); - void HandleGetFaviconDominantColor(const ListValue* args); + void HandleGetFaviconDominantColor(const base::ListValue* args); private: // Called when favicon data is available from the history backend. diff --git a/chrome/browser/ui/webui/ntp/most_visited_handler.h b/chrome/browser/ui/webui/ntp/most_visited_handler.h index 4e037b8..bad04c3 100644 --- a/chrome/browser/ui/webui/ntp/most_visited_handler.h +++ b/chrome/browser/ui/webui/ntp/most_visited_handler.h @@ -16,10 +16,13 @@ #include "content/common/notification_registrar.h" class GURL; -class ListValue; class PageUsageData; class PrefService; + +namespace base { +class ListValue; class Value; +} // The handler for Javascript messages related to the "most visited" view. // @@ -43,22 +46,22 @@ class MostVisitedHandler : public WebUIMessageHandler, virtual void RegisterMessages(); // Callback for the "getMostVisited" message. - void HandleGetMostVisited(const ListValue* args); + void HandleGetMostVisited(const base::ListValue* args); // Callback for the "blacklistURLFromMostVisited" message. - void HandleBlacklistURL(const ListValue* args); + void HandleBlacklistURL(const base::ListValue* args); // Callback for the "removeURLsFromMostVisitedBlacklist" message. - void HandleRemoveURLsFromBlacklist(const ListValue* args); + void HandleRemoveURLsFromBlacklist(const base::ListValue* args); // Callback for the "clearMostVisitedURLsBlacklist" message. - void HandleClearBlacklist(const ListValue* args); + void HandleClearBlacklist(const base::ListValue* args); // Callback for the "addPinnedURL" message. - void HandleAddPinnedURL(const ListValue* args); + void HandleAddPinnedURL(const base::ListValue* args); // Callback for the "removePinnedURL" message. - void HandleRemovePinnedURL(const ListValue* args); + void HandleRemovePinnedURL(const base::ListValue* args); // NotificationObserver implementation. virtual void Observe(int type, @@ -125,7 +128,7 @@ class MostVisitedHandler : public WebUIMessageHandler, bool got_first_most_visited_request_; // Keep the results of the db query here. - scoped_ptr<ListValue> pages_value_; + scoped_ptr<base::ListValue> pages_value_; DISALLOW_COPY_AND_ASSIGN(MostVisitedHandler); }; diff --git a/chrome/browser/ui/webui/ntp/new_tab_page_sync_handler.h b/chrome/browser/ui/webui/ntp/new_tab_page_sync_handler.h index 90198bb..debb24f 100644 --- a/chrome/browser/ui/webui/ntp/new_tab_page_sync_handler.h +++ b/chrome/browser/ui/webui/ntp/new_tab_page_sync_handler.h @@ -12,7 +12,9 @@ #include "chrome/browser/sync/sync_ui_util.h" #include "content/browser/webui/web_ui.h" +namespace base { class ListValue; +} // Sends sync-state changes to the New Tab Page for UI updating and forwards // link clicks on the page to the sync service. @@ -27,9 +29,9 @@ class NewTabPageSyncHandler : public WebUIMessageHandler, virtual void RegisterMessages(); // Callback for "GetSyncMessage". - void HandleGetSyncMessage(const ListValue* args); + void HandleGetSyncMessage(const base::ListValue* args); // Callback for "SyncLinkClicked". - void HandleSyncLinkClicked(const ListValue* args); + void HandleSyncLinkClicked(const base::ListValue* args); // ProfileSyncServiceObserver virtual void OnStateChanged(); diff --git a/chrome/browser/ui/webui/ntp/new_tab_ui.h b/chrome/browser/ui/webui/ntp/new_tab_ui.h index cc27f6a..ddb5f05 100644 --- a/chrome/browser/ui/webui/ntp/new_tab_ui.h +++ b/chrome/browser/ui/webui/ntp/new_tab_ui.h @@ -43,7 +43,7 @@ class NewTabUI : public ChromeWebUI, // Adds "url", "title", and "direction" keys on incoming dictionary, setting // title as the url as a fallback on empty title. - static void SetURLTitleAndDirection(DictionaryValue* dictionary, + static void SetURLTitleAndDirection(base::DictionaryValue* dictionary, const string16& title, const GURL& gurl); @@ -51,7 +51,7 @@ class NewTabUI : public ChromeWebUI, // by the NTP and adds them to the given list value. static void AddRecentlyClosedEntries( const TabRestoreService::Entries& entries, - ListValue* entry_list_value); + base::ListValue* entry_list_value); // The current preference version. static int current_pref_version() { return current_pref_version_; } diff --git a/chrome/browser/ui/webui/ntp/shown_sections_handler.h b/chrome/browser/ui/webui/ntp/shown_sections_handler.h index 9571f792..fb23f98 100644 --- a/chrome/browser/ui/webui/ntp/shown_sections_handler.h +++ b/chrome/browser/ui/webui/ntp/shown_sections_handler.h @@ -11,9 +11,12 @@ #include "content/common/notification_observer.h" class Extension; -class Value; class PrefService; +namespace base { +class Value; +} + // Use for the shown sections bitmask. // Currently, only the THUMB and APPS sections can be toggled by the user. Other // sections are shown automatically if they have data, and hidden otherwise. @@ -55,10 +58,10 @@ class ShownSectionsHandler : public WebUIMessageHandler, const NotificationDetails& details); // Callback for "getShownSections" message. - void HandleGetShownSections(const ListValue* args); + void HandleGetShownSections(const base::ListValue* args); // Callback for "setShownSections" message. - void HandleSetShownSections(const ListValue* args); + void HandleSetShownSections(const base::ListValue* args); static void RegisterUserPrefs(PrefService* pref_service); diff --git a/chrome/browser/ui/webui/options/about_page_handler.h b/chrome/browser/ui/webui/options/about_page_handler.h index 73dc0b3..9982658 100644 --- a/chrome/browser/ui/webui/options/about_page_handler.h +++ b/chrome/browser/ui/webui/options/about_page_handler.h @@ -21,23 +21,23 @@ class AboutPageHandler : public OptionsPageUIHandler { virtual ~AboutPageHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void RegisterMessages(); private: // The function is called from JavaScript when the about page is ready. - void PageReady(const ListValue* args); + void PageReady(const base::ListValue* args); // The function is called from JavaScript to set the release track like // "beta-channel" and "dev-channel". - void SetReleaseTrack(const ListValue* args); + void SetReleaseTrack(const base::ListValue* args); #if defined(OS_CHROMEOS) // Initiates update check. - void CheckNow(const ListValue* args); + void CheckNow(const base::ListValue* args); // Restarts the system. - void RestartNow(const ListValue* args); + void RestartNow(const base::ListValue* args); // Callback from chromeos::VersionLoader giving the version. void OnOSVersion(chromeos::VersionLoader::Handle handle, diff --git a/chrome/browser/ui/webui/options/autofill_options_handler.h b/chrome/browser/ui/webui/options/autofill_options_handler.h index a9a9f74..56991f2 100644 --- a/chrome/browser/ui/webui/options/autofill_options_handler.h +++ b/chrome/browser/ui/webui/options/autofill_options_handler.h @@ -11,8 +11,10 @@ #include "chrome/browser/autofill/personal_data_manager.h" #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; class ListValue; +} class AutofillOptionsHandler : public OptionsPageUIHandler, public PersonalDataManager::Observer { @@ -21,7 +23,7 @@ class AutofillOptionsHandler : public OptionsPageUIHandler, virtual ~AutofillOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); virtual void RegisterMessages(); @@ -30,50 +32,50 @@ class AutofillOptionsHandler : public OptionsPageUIHandler, private: // Loads the strings for the address and credit card overlays. - void SetAddressOverlayStrings(DictionaryValue* localized_strings); - void SetCreditCardOverlayStrings(DictionaryValue* localized_strings); + void SetAddressOverlayStrings(base::DictionaryValue* localized_strings); + void SetCreditCardOverlayStrings(base::DictionaryValue* localized_strings); // Loads Autofill addresses and credit cards using the PersonalDataManager. void LoadAutofillData(); // Removes an address from the PersonalDataManager. // |args| - A string, the GUID of the address to remove. - void RemoveAddress(const ListValue* args); + void RemoveAddress(const base::ListValue* args); // Removes a credit card from the PersonalDataManager. // |args| - A string, the GUID of the credit card to remove. - void RemoveCreditCard(const ListValue* args); + void RemoveCreditCard(const base::ListValue* args); // Requests profile data for a specific address. Calls into WebUI with the // loaded profile data to open the address editor. // |args| - A string, the GUID of the address to load. - void LoadAddressEditor(const ListValue* args); + void LoadAddressEditor(const base::ListValue* args); // Requests profile data for a specific credit card. Calls into WebUI with the // loaded profile data to open the credit card editor. // |args| - A string, the GUID of the credit card to load. - void LoadCreditCardEditor(const ListValue* args); + void LoadCreditCardEditor(const base::ListValue* args); // Adds or updates an address, depending on the GUID of the profile. If the // GUID is empty, a new address is added to the WebDatabase; otherwise, the // address with the matching GUID is updated. Called from WebUI. // |args| - an array containing the GUID of the address followed by the // address data. - void SetAddress(const ListValue* args); + void SetAddress(const base::ListValue* args); // Adds or updates a credit card, depending on the GUID of the profile. If the // GUID is empty, a new credit card is added to the WebDatabase; otherwise, // the credit card with the matching GUID is updated. Called from WebUI. // |args| - an array containing the GUID of the credit card followed by the // credit card data. - void SetCreditCard(const ListValue* args); + void SetCreditCard(const base::ListValue* args); // Validates a list of phone/fax numbers. The resulting validated list of // numbers is then sent back to the WebUI. // |args| - an array containing the index of the modified or added number, the // array of numbers, and the country code string set on the profile. - void ValidatePhoneNumbers(const ListValue* args); - void ValidateFaxNumbers(const ListValue* args); + void ValidatePhoneNumbers(const base::ListValue* args); + void ValidateFaxNumbers(const base::ListValue* args); // The personal data manager, used to load Autofill profiles and credit cards. // Unowned pointer, may not be NULL. diff --git a/chrome/browser/ui/webui/options/certificate_manager_handler.h b/chrome/browser/ui/webui/options/certificate_manager_handler.h index f363be2..6ffa8e0 100644 --- a/chrome/browser/ui/webui/options/certificate_manager_handler.h +++ b/chrome/browser/ui/webui/options/certificate_manager_handler.h @@ -26,7 +26,7 @@ class CertificateManagerHandler : public OptionsPageUIHandler, virtual ~CertificateManagerHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void RegisterMessages(); // CertificateManagerModel::Observer implementation. @@ -38,20 +38,20 @@ class CertificateManagerHandler : public OptionsPageUIHandler, private: // View certificate. - void View(const ListValue* args); + void View(const base::ListValue* args); // Edit server certificate trust values. - void EditServer(const ListValue* args); + void EditServer(const base::ListValue* args); // Edit certificate authority trust values. The sequence goes like: // 1. user clicks edit button -> CertificateEditCaTrustOverlay.show -> // GetCATrust -> CertificateEditCaTrustOverlay.populateTrust // 2. user clicks ok -> EditCATrust -> CertificateEditCaTrustOverlay.dismiss - void GetCATrust(const ListValue* args); - void EditCATrust(const ListValue* args); + void GetCATrust(const base::ListValue* args); + void EditCATrust(const base::ListValue* args); // Cleanup state stored during import or export process. - void CancelImportExportProcess(const ListValue* args); + void CancelImportExportProcess(const base::ListValue* args); void ImportExportCleanup(); // Export to PKCS #12 file. The sequence goes like: @@ -65,10 +65,10 @@ class CertificateManagerHandler : public OptionsPageUIHandler, // 4. slots unlocked -> ExportPersonalSlotsUnlocked -> exports to memory // buffer -> starts async write operation // 5. write finishes (or fails) -> ExportPersonalFileWritten - void ExportPersonal(const ListValue* args); - void ExportAllPersonal(const ListValue* args); + void ExportPersonal(const base::ListValue* args); + void ExportAllPersonal(const base::ListValue* args); void ExportPersonalFileSelected(const FilePath& path); - void ExportPersonalPasswordSelected(const ListValue* args); + void ExportPersonalPasswordSelected(const base::ListValue* args); void ExportPersonalSlotsUnlocked(); void ExportPersonalFileWritten(int write_errno, int bytes_written); @@ -85,9 +85,9 @@ class CertificateManagerHandler : public OptionsPageUIHandler, // 6a. if import succeeds -> ImportExportCleanup // 6b. if import fails -> show error, ImportExportCleanup // TODO(mattm): allow retrying with different password - void StartImportPersonal(const ListValue* args); + void StartImportPersonal(const base::ListValue* args); void ImportPersonalFileSelected(const FilePath& path); - void ImportPersonalPasswordSelected(const ListValue* args); + void ImportPersonalPasswordSelected(const base::ListValue* args); void ImportPersonalFileRead(int read_errno, std::string data); void ImportPersonalSlotUnlocked(); @@ -97,7 +97,7 @@ class CertificateManagerHandler : public OptionsPageUIHandler, // 3. read completes -> ImportServerFileRead -> parse certs -> attempt import // 4a. if import succeeds -> ImportExportCleanup // 4b. if import fails -> show error, ImportExportCleanup - void ImportServer(const ListValue* args); + void ImportServer(const base::ListValue* args); void ImportServerFileSelected(const FilePath& path); void ImportServerFileRead(int read_errno, std::string data); @@ -109,19 +109,19 @@ class CertificateManagerHandler : public OptionsPageUIHandler, // 4. user clicks ok -> ImportCATrustSelected -> attempt import // 5a. if import succeeds -> ImportExportCleanup // 5b. if import fails -> show error, ImportExportCleanup - void ImportCA(const ListValue* args); + void ImportCA(const base::ListValue* args); void ImportCAFileSelected(const FilePath& path); void ImportCAFileRead(int read_errno, std::string data); - void ImportCATrustSelected(const ListValue* args); + void ImportCATrustSelected(const base::ListValue* args); // Export a certificate. - void Export(const ListValue* args); + void Export(const base::ListValue* args); // Delete certificate and private key (if any). - void Delete(const ListValue* args); + void Delete(const base::ListValue* args); // Populate the trees in all the tabs. - void Populate(const ListValue* args); + void Populate(const base::ListValue* args); // Populate the given tab's tree. void PopulateTree(const std::string& tab_name, net::CertType type); @@ -138,7 +138,7 @@ class CertificateManagerHandler : public OptionsPageUIHandler, #if defined(OS_CHROMEOS) // Check whether Tpm token is ready and notifiy JS side. - void CheckTpmTokenReady(const ListValue* args); + void CheckTpmTokenReady(const base::ListValue* args); #endif gfx::NativeWindow GetParentWindow() const; diff --git a/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h b/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h index 862acf5..4708c9b 100644 --- a/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/accounts_options_handler.h @@ -22,17 +22,17 @@ class AccountsOptionsHandler : public CrosOptionsPageUIHandler { virtual void RegisterMessages(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); private: UserCrosSettingsProvider* users_settings() const; // Javascript callbacks to whitelist/unwhitelist user. - void WhitelistUser(const ListValue* args); - void UnwhitelistUser(const ListValue* args); + void WhitelistUser(const base::ListValue* args); + void UnwhitelistUser(const base::ListValue* args); // Javascript callback to auto add existing users to white list. - void WhitelistExistingUsers(const ListValue* args); + void WhitelistExistingUsers(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(AccountsOptionsHandler); }; diff --git a/chrome/browser/ui/webui/options/chromeos/change_picture_options_handler.h b/chrome/browser/ui/webui/options/chromeos/change_picture_options_handler.h index bf71207..3f1e231 100644 --- a/chrome/browser/ui/webui/options/chromeos/change_picture_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/change_picture_options_handler.h @@ -9,8 +9,10 @@ #include "chrome/browser/ui/webui/options/options_ui.h" #include "ui/gfx/native_widget_types.h" +namespace base { class DictionaryValue; class ListValue; +} namespace chromeos { @@ -22,23 +24,23 @@ class ChangePictureOptionsHandler : public OptionsPageUIHandler, virtual ~ChangePictureOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // WebUIMessageHandler implementation. virtual void RegisterMessages(); private: // Opens a file selection dialog to choose user image from file. - void ChooseFile(const ListValue* args); + void ChooseFile(const base::ListValue* args); // Opens the camera capture dialog. - void TakePhoto(const ListValue* args); + void TakePhoto(const base::ListValue* args); // Gets the list of available user images and sends it to the page. - void GetAvailableImages(const ListValue* args); + void GetAvailableImages(const base::ListValue* args); // Selects one of the available images as user's. - void SelectImage(const ListValue* args); + void SelectImage(const base::ListValue* args); // SelectFileDialog::Delegate implementation. virtual void FileSelected(const FilePath& path, int index, void* params); diff --git a/chrome/browser/ui/webui/options/chromeos/cros_language_options_handler.h b/chrome/browser/ui/webui/options/chromeos/cros_language_options_handler.h index 0501514..fda593c 100644 --- a/chrome/browser/ui/webui/options/chromeos/cros_language_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/cros_language_options_handler.h @@ -19,7 +19,7 @@ class CrosLanguageOptionsHandler : public LanguageOptionsHandlerCommon { virtual ~CrosLanguageOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // DOMMessageHandler implementation. virtual void RegisterMessages(); @@ -33,14 +33,14 @@ class CrosLanguageOptionsHandler : public LanguageOptionsHandlerCommon { // // Note that true in languageCodeSet does not mean anything. We just use // the dictionary as a set. - static ListValue* GetInputMethodList( + static base::ListValue* GetInputMethodList( const input_method::InputMethodDescriptors& descriptors); // Gets the list of languages from the given input descriptors. // The return value will look like: // [{'code': 'fi', 'displayName': 'Finnish', 'nativeDisplayName': 'suomi'}, // ...] - static ListValue* GetLanguageList( + static base::ListValue* GetLanguageList( const input_method::InputMethodDescriptors& descriptors); private: @@ -49,19 +49,19 @@ class CrosLanguageOptionsHandler : public LanguageOptionsHandlerCommon { virtual void SetApplicationLocale(const std::string& language_code); // Called when the sign-out button is clicked. - void RestartCallback(const ListValue* args); + void RestartCallback(const base::ListValue* args); // Called when the input method is disabled. // |args| will contain the input method ID as string (ex. "mozc"). - void InputMethodDisableCallback(const ListValue* args); + void InputMethodDisableCallback(const base::ListValue* args); // Called when the input method is enabled. // |args| will contain the input method ID as string (ex. "mozc"). - void InputMethodEnableCallback(const ListValue* args); + void InputMethodEnableCallback(const base::ListValue* args); // Called when the input method options page is opened. // |args| will contain the input method ID as string (ex. "mozc"). - void InputMethodOptionsOpenCallback(const ListValue* args); + void InputMethodOptionsOpenCallback(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(CrosLanguageOptionsHandler); }; diff --git a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.h b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.h index ff86de2..cf0fb22 100644 --- a/chrome/browser/ui/webui/options/chromeos/internet_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/internet_options_handler.h @@ -28,7 +28,7 @@ class InternetOptionsHandler virtual ~InternetOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); // WebUIMessageHandler implementation. @@ -58,7 +58,7 @@ class InternetOptionsHandler // 'forget' // Handle{Wifi,Cellular}ButtonClick handles button click on a wireless // network item and a cellular network item respectively. - void ButtonClickCallback(const ListValue* args); + void ButtonClickCallback(const base::ListValue* args); void HandleWifiButtonClick(const std::string& service_path, const std::string& command); void HandleCellularButtonClick(const std::string& service_path, @@ -69,61 +69,61 @@ class InternetOptionsHandler // Initiates cellular plan data refresh. The results from libcros will be // passed through CellularDataPlanChanged() callback method. // |args| will be [ service_path ] - void RefreshCellularPlanCallback(const ListValue* args); + void RefreshCellularPlanCallback(const base::ListValue* args); void SetActivationButtonVisibility( const chromeos::CellularNetwork* cellular, - DictionaryValue* dictionary); - - void SetAutoConnectCallback(const ListValue* args); - void SetSharedCallback(const ListValue* args); - void SetIPConfigCallback(const ListValue* args); - void EnableWifiCallback(const ListValue* args); - void DisableWifiCallback(const ListValue* args); - void EnableCellularCallback(const ListValue* args); - void DisableCellularCallback(const ListValue* args); - void BuyDataPlanCallback(const ListValue* args); - void SetApnCallback(const ListValue* args); - void SetSimCardLockCallback(const ListValue* args); - void ChangePinCallback(const ListValue* args); - void ShareNetworkCallback(const ListValue* args); + base::DictionaryValue* dictionary); + + void SetAutoConnectCallback(const base::ListValue* args); + void SetSharedCallback(const base::ListValue* args); + void SetIPConfigCallback(const base::ListValue* args); + void EnableWifiCallback(const base::ListValue* args); + void DisableWifiCallback(const base::ListValue* args); + void EnableCellularCallback(const base::ListValue* args); + void DisableCellularCallback(const base::ListValue* args); + void BuyDataPlanCallback(const base::ListValue* args); + void SetApnCallback(const base::ListValue* args); + void SetSimCardLockCallback(const base::ListValue* args); + void ChangePinCallback(const base::ListValue* args); + void ShareNetworkCallback(const base::ListValue* args); // Populates the ui with the details of the given device path. This forces // an overlay to be displayed in the UI. void PopulateDictionaryDetails(const chromeos::Network* network); void PopulateWifiDetails(const chromeos::WifiNetwork* wifi, - DictionaryValue* dictionary); + base::DictionaryValue* dictionary); void PopulateCellularDetails(const chromeos::CellularNetwork* cellular, - DictionaryValue* dictionary); + base::DictionaryValue* dictionary); void PopulateVPNDetails(const chromeos::VirtualNetwork* vpn, - DictionaryValue* dictionary); + base::DictionaryValue* dictionary); // Converts CellularDataPlan structure into dictionary for JS. Formats plan // settings into human readable texts. - DictionaryValue* CellularDataPlanToDictionary( + base::DictionaryValue* CellularDataPlanToDictionary( const chromeos::CellularDataPlan* plan); // Creates the map of a network. - ListValue* GetNetwork(const std::string& service_path, - const SkBitmap& icon, - const std::string& name, - bool connecting, - bool connected, - bool connectable, - chromeos::ConnectionType connection_type, - bool remembered, - bool shared, - chromeos::ActivationState activation_state, - bool restricted_ip); + base::ListValue* GetNetwork(const std::string& service_path, + const SkBitmap& icon, + const std::string& name, + bool connecting, + bool connected, + bool connectable, + chromeos::ConnectionType connection_type, + bool remembered, + bool shared, + chromeos::ActivationState activation_state, + bool restricted_ip); // Creates the map of wired networks. - ListValue* GetWiredList(); + base::ListValue* GetWiredList(); // Creates the map of wireless networks. - ListValue* GetWirelessList(); + base::ListValue* GetWirelessList(); // Creates the map of virtual networks. - ListValue* GetVPNList(); + base::ListValue* GetVPNList(); // Creates the map of remembered networks. - ListValue* GetRememberedList(); + base::ListValue* GetRememberedList(); // Fills network information into JS dictionary for displaying network lists. - void FillNetworkInfo(DictionaryValue* dictionary); + void FillNetworkInfo(base::DictionaryValue* dictionary); // Refreshes the display of network information. void RefreshNetworkData(); // Adds observers for wireless networks, if any, so that we can dynamically diff --git a/chrome/browser/ui/webui/options/chromeos/language_chewing_handler.h b/chrome/browser/ui/webui/options/chromeos/language_chewing_handler.h index 979a0fa..2b32f43 100644 --- a/chrome/browser/ui/webui/options/chromeos/language_chewing_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/language_chewing_handler.h @@ -10,7 +10,9 @@ #include "base/compiler_specific.h" #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; +} namespace chromeos { @@ -21,7 +23,8 @@ class LanguageChewingHandler : public OptionsPageUIHandler { virtual ~LanguageChewingHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings) OVERRIDE; + virtual void GetLocalizedValues( + base::DictionaryValue* localized_strings) OVERRIDE; private: DISALLOW_COPY_AND_ASSIGN(LanguageChewingHandler); diff --git a/chrome/browser/ui/webui/options/chromeos/language_hangul_handler.h b/chrome/browser/ui/webui/options/chromeos/language_hangul_handler.h index 28c7a6c..9fd58fd 100644 --- a/chrome/browser/ui/webui/options/chromeos/language_hangul_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/language_hangul_handler.h @@ -8,8 +8,10 @@ #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; class ListValue; +} namespace chromeos { @@ -20,11 +22,11 @@ class LanguageHangulHandler : public OptionsPageUIHandler { virtual ~LanguageHangulHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); private: // Returns the list of hangul keyboards. - static ListValue* GetKeyboardLayoutList(); + static base::ListValue* GetKeyboardLayoutList(); DISALLOW_COPY_AND_ASSIGN(LanguageHangulHandler); }; diff --git a/chrome/browser/ui/webui/options/chromeos/language_mozc_handler.h b/chrome/browser/ui/webui/options/chromeos/language_mozc_handler.h index e1a5419..a9a74a5 100644 --- a/chrome/browser/ui/webui/options/chromeos/language_mozc_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/language_mozc_handler.h @@ -8,7 +8,9 @@ #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; +} namespace chromeos { @@ -19,7 +21,7 @@ class LanguageMozcHandler : public OptionsPageUIHandler { virtual ~LanguageMozcHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); private: DISALLOW_COPY_AND_ASSIGN(LanguageMozcHandler); diff --git a/chrome/browser/ui/webui/options/chromeos/language_options_util.h b/chrome/browser/ui/webui/options/chromeos/language_options_util.h index 49e10da..ba2bb9a 100644 --- a/chrome/browser/ui/webui/options/chromeos/language_options_util.h +++ b/chrome/browser/ui/webui/options/chromeos/language_options_util.h @@ -13,7 +13,9 @@ #include "chrome/browser/chromeos/language_preferences.h" #include "ui/base/l10n/l10n_util.h" +namespace base { class ListValue; +} namespace chromeos { @@ -52,7 +54,7 @@ Value* CreateValue(int in_value); // Creates a multiple choice list from the given preference. template <typename T> -ListValue* CreateMultipleChoiceList( +base::ListValue* CreateMultipleChoiceList( const language_prefs::LanguageMultipleChoicePreference<T>& preference) { int list_length = 0; for (size_t i = 0; @@ -64,12 +66,12 @@ ListValue* CreateMultipleChoiceList( } DCHECK_GT(list_length, 0); - ListValue* list_value = new ListValue(); + base::ListValue* list_value = new base::ListValue(); for (int i = 0; i < list_length; ++i) { - ListValue* option = new ListValue(); + base::ListValue* option = new base::ListValue(); option->Append(CreateValue( preference.values_and_ids[i].ibus_config_value)); - option->Append(Value::CreateStringValue(l10n_util::GetStringUTF16( + option->Append(base::Value::CreateStringValue(l10n_util::GetStringUTF16( preference.values_and_ids[i].item_message_id))); list_value->Append(option); } diff --git a/chrome/browser/ui/webui/options/chromeos/language_pinyin_handler.h b/chrome/browser/ui/webui/options/chromeos/language_pinyin_handler.h index 270ef2c..bd86aaa 100644 --- a/chrome/browser/ui/webui/options/chromeos/language_pinyin_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/language_pinyin_handler.h @@ -8,7 +8,9 @@ #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; +} namespace chromeos { @@ -19,7 +21,7 @@ class LanguagePinyinHandler : public OptionsPageUIHandler { virtual ~LanguagePinyinHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); private: DISALLOW_COPY_AND_ASSIGN(LanguagePinyinHandler); diff --git a/chrome/browser/ui/webui/options/chromeos/proxy_handler.h b/chrome/browser/ui/webui/options/chromeos/proxy_handler.h index 73ce560..c13bf31 100644 --- a/chrome/browser/ui/webui/options/chromeos/proxy_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/proxy_handler.h @@ -16,7 +16,7 @@ class ProxyHandler : public CrosOptionsPageUIHandler { virtual ~ProxyHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); private: diff --git a/chrome/browser/ui/webui/options/chromeos/stats_options_handler.h b/chrome/browser/ui/webui/options/chromeos/stats_options_handler.h index af2963d..564e4d0 100644 --- a/chrome/browser/ui/webui/options/chromeos/stats_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/stats_options_handler.h @@ -21,7 +21,7 @@ class StatsOptionsHandler : public CrosOptionsPageUIHandler { StatsOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); // WebUIMessageHandler implementation. @@ -29,7 +29,7 @@ class StatsOptionsHandler : public CrosOptionsPageUIHandler { private: MetricsCrosSettingsProvider* provider() const; - void HandleMetricsReportingCheckbox(const ListValue* args); + void HandleMetricsReportingCheckbox(const base::ListValue* args); void SetupMetricsReportingCheckbox(bool user_changed); DISALLOW_COPY_AND_ASSIGN(StatsOptionsHandler); diff --git a/chrome/browser/ui/webui/options/chromeos/system_options_handler.h b/chrome/browser/ui/webui/options/chromeos/system_options_handler.h index 463e56b..61d451c 100644 --- a/chrome/browser/ui/webui/options/chromeos/system_options_handler.h +++ b/chrome/browser/ui/webui/options/chromeos/system_options_handler.h @@ -8,7 +8,9 @@ #include "chrome/browser/ui/webui/options/chromeos/cros_options_page_ui_handler.h" +namespace base { class DictionaryValue; +} // ChromeOS system options page UI handler. class SystemOptionsHandler : public chromeos::CrosOptionsPageUIHandler { @@ -17,7 +19,7 @@ class SystemOptionsHandler : public chromeos::CrosOptionsPageUIHandler { virtual ~SystemOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); virtual void RegisterMessages(); @@ -25,7 +27,7 @@ class SystemOptionsHandler : public chromeos::CrosOptionsPageUIHandler { // Called when the accessibility checkbox value is changed. // |args| will contain the checkbox checked state as a string // ("true" or "false"). - void AccessibilityChangeCallback(const ListValue* args); + void AccessibilityChangeCallback(const base::ListValue* args); private: DISALLOW_COPY_AND_ASSIGN(SystemOptionsHandler); diff --git a/chrome/browser/ui/webui/options/chromeos/system_settings_provider.h b/chrome/browser/ui/webui/options/chromeos/system_settings_provider.h index afc7fa9..f6311d4 100644 --- a/chrome/browser/ui/webui/options/chromeos/system_settings_provider.h +++ b/chrome/browser/ui/webui/options/chromeos/system_settings_provider.h @@ -12,8 +12,10 @@ #include "chrome/browser/chromeos/system/timezone_settings.h" #include "third_party/icu/public/i18n/unicode/timezone.h" +namespace base { class Value; class ListValue; +} namespace chromeos { @@ -24,18 +26,18 @@ class SystemSettingsProvider : public CrosSettingsProvider, virtual ~SystemSettingsProvider(); // CrosSettingsProvider overrides. - virtual bool Get(const std::string& path, Value** out_value) const; + virtual bool Get(const std::string& path, base::Value** out_value) const; virtual bool HandlesSetting(const std::string& path); // Overridden from TimezoneSettings::Observer: virtual void TimezoneChanged(const icu::TimeZone& timezone); // Creates the map of timezones used by the options page. - ListValue* GetTimezoneList(); + base::ListValue* GetTimezoneList(); private: // CrosSettingsProvider overrides. - virtual void DoSet(const std::string& path, Value* in_value); + virtual void DoSet(const std::string& path, base::Value* in_value); // Gets timezone name. static string16 GetTimezoneName(const icu::TimeZone& timezone); diff --git a/chrome/browser/ui/webui/options/cookies_view_handler.h b/chrome/browser/ui/webui/options/cookies_view_handler.h index 7b88bdd..456bb350 100644 --- a/chrome/browser/ui/webui/options/cookies_view_handler.h +++ b/chrome/browser/ui/webui/options/cookies_view_handler.h @@ -18,7 +18,7 @@ class CookiesViewHandler : public OptionsPageUIHandler, virtual ~CookiesViewHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void RegisterMessages(); // CookiesTreeModel::Observer implementation. @@ -40,17 +40,17 @@ class CookiesViewHandler : public OptionsPageUIHandler, void EnsureCookiesTreeModelCreated(); // Updates search filter for cookies tree model. - void UpdateSearchResults(const ListValue* args); + void UpdateSearchResults(const base::ListValue* args); // Remove all sites data. - void RemoveAll(const ListValue* args); + void RemoveAll(const base::ListValue* args); // Remove selected sites data. - void Remove(const ListValue* args); + void Remove(const base::ListValue* args); // Get the tree node using the tree path info in |args| and call // SendChildren to pass back children nodes data to WebUI. - void LoadChildren(const ListValue* args); + void LoadChildren(const base::ListValue* args); // Get children nodes data and pass it to 'CookiesView.loadChildren' to // update the WebUI. diff --git a/chrome/browser/ui/webui/options/extension_settings_handler.h b/chrome/browser/ui/webui/options/extension_settings_handler.h index c30e320..5ec4a14 100644 --- a/chrome/browser/ui/webui/options/extension_settings_handler.h +++ b/chrome/browser/ui/webui/options/extension_settings_handler.h @@ -20,15 +20,18 @@ #include "content/common/notification_registrar.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class Extension; class ExtensionService; class FilePath; -class ListValue; class PrefService; class RenderProcessHost; class UserScript; +namespace base { +class DictionaryValue; +class ListValue; +} + // Information about a page running in an extension, for example a toolstrip, // a background page, or a tab contents. struct ExtensionPage { @@ -84,7 +87,7 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, // Load |icons|. Will call handler->OnIconsLoaded when complete. IconLoader // takes ownership of both arguments. void LoadIcons(std::vector<ExtensionResource>* icons, - DictionaryValue* json); + base::DictionaryValue* json); // Cancel the load. IconLoader won't try to call back to the handler after // this. @@ -94,10 +97,10 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, // Load the icons and call ReportResultOnUIThread when done. This method // takes ownership of both arguments. void LoadIconsOnFileThread(std::vector<ExtensionResource>* icons, - DictionaryValue* json); + base::DictionaryValue* json); // Report back to the handler. This method takes ownership of |json|. - void ReportResultOnUIThread(DictionaryValue* json); + void ReportResultOnUIThread(base::DictionaryValue* json); // The handler we will report back to. ExtensionsDOMHandler* handler_; @@ -111,7 +114,7 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, // Extension Detail JSON Struct for page. (static for ease of testing). // Note: service can be NULL in unit tests. - static DictionaryValue* CreateExtensionDetailValue( + static base::DictionaryValue* CreateExtensionDetailValue( ExtensionService* service, const Extension* extension, const std::vector<ExtensionPage>& pages, @@ -119,7 +122,7 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, bool terminated); // ContentScript JSON Struct for page. (static for ease of testing). - static DictionaryValue* CreateContentScriptDetailValue( + static base::DictionaryValue* CreateContentScriptDetailValue( const UserScript& script, const FilePath& extension_path); @@ -135,52 +138,52 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, private: // Callback for "requestExtensionsData" message. - void HandleRequestExtensionsData(const ListValue* args); + void HandleRequestExtensionsData(const base::ListValue* args); // Callback for "toggleDeveloperMode" message. - void HandleToggleDeveloperMode(const ListValue* args); + void HandleToggleDeveloperMode(const base::ListValue* args); // Callback for "inspect" message. - void HandleInspectMessage(const ListValue* args); + void HandleInspectMessage(const base::ListValue* args); // Callback for "reload" message. - void HandleReloadMessage(const ListValue* args); + void HandleReloadMessage(const base::ListValue* args); // Callback for "enable" message. - void HandleEnableMessage(const ListValue* args); + void HandleEnableMessage(const base::ListValue* args); // Callback for "enableIncognito" message. - void HandleEnableIncognitoMessage(const ListValue* args); + void HandleEnableIncognitoMessage(const base::ListValue* args); // Callback for "allowFileAcces" message. - void HandleAllowFileAccessMessage(const ListValue* args); + void HandleAllowFileAccessMessage(const base::ListValue* args); // Callback for "uninstall" message. - void HandleUninstallMessage(const ListValue* args); + void HandleUninstallMessage(const base::ListValue* args); // Callback for "options" message. - void HandleOptionsMessage(const ListValue* args); + void HandleOptionsMessage(const base::ListValue* args); // Callback for "showButton" message. - void HandleShowButtonMessage(const ListValue* args); + void HandleShowButtonMessage(const base::ListValue* args); // Callback for "load" message. - void HandleLoadMessage(const ListValue* args); + void HandleLoadMessage(const base::ListValue* args); // Callback for "pack" message. - void HandlePackMessage(const ListValue* args); + void HandlePackMessage(const base::ListValue* args); // Callback for "autoupdate" message. - void HandleAutoUpdateMessage(const ListValue* args); + void HandleAutoUpdateMessage(const base::ListValue* args); // Utility for calling javascript window.alert in the page. void ShowAlert(const std::string& message); // Callback for "selectFilePath" message. - void HandleSelectFilePathMessage(const ListValue* args); + void HandleSelectFilePathMessage(const base::ListValue* args); // Utility for callbacks that get an extension ID as the sole argument. - const Extension* GetExtension(const ListValue* args); + const Extension* GetExtension(const base::ListValue* args); // Forces a UI update if appropriate after a notification is received. void MaybeUpdateAfterNotification(); @@ -213,11 +216,11 @@ class ExtensionsDOMHandler : public WebUIMessageHandler, // Takes ownership of |icons|. // Called on the file thread. void LoadExtensionIcons(std::vector<ExtensionResource>* icons, - DictionaryValue* json_data); + base::DictionaryValue* json_data); // Takes ownership of |json_data| and tells HTML about it. // Called on the UI thread. - void OnIconsLoaded(DictionaryValue* json_data); + void OnIconsLoaded(base::DictionaryValue* json_data); // Returns the ExtensionUninstallDialog object for this class, creating it if // needed. diff --git a/chrome/browser/ui/webui/options/font_settings_utils.h b/chrome/browser/ui/webui/options/font_settings_utils.h index 2a36bad..ce133b4 100644 --- a/chrome/browser/ui/webui/options/font_settings_utils.h +++ b/chrome/browser/ui/webui/options/font_settings_utils.h @@ -8,7 +8,6 @@ #include "base/basictypes.h" -class ListValue; class PrefService; // Chrome advanced options utility methods. diff --git a/chrome/browser/ui/webui/options/handler_options_handler.h b/chrome/browser/ui/webui/options/handler_options_handler.h index 69baf75..f7cb567 100644 --- a/chrome/browser/ui/webui/options/handler_options_handler.h +++ b/chrome/browser/ui/webui/options/handler_options_handler.h @@ -12,7 +12,9 @@ #include "chrome/browser/ui/webui/options/options_ui.h" #include "content/common/notification_registrar.h" +namespace base { class DictionaryValue; +} class HandlerOptionsHandler : public OptionsPageUIHandler { public: @@ -20,7 +22,7 @@ class HandlerOptionsHandler : public OptionsPageUIHandler { virtual ~HandlerOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); virtual void RegisterMessages(); @@ -46,7 +48,7 @@ class HandlerOptionsHandler : public OptionsPageUIHandler { // Returns a JSON object describing the set of protocol handlers for the // given protocol. - DictionaryValue* GetHandlersForProtocol(const std::string& protocol); + base::DictionaryValue* GetHandlersForProtocol(const std::string& protocol); // Called when the JS PasswordManager object is initialized. void UpdateHandlerList(); diff --git a/chrome/browser/ui/webui/options/import_data_handler.h b/chrome/browser/ui/webui/options/import_data_handler.h index 6f28fa3..3e18a10 100644 --- a/chrome/browser/ui/webui/options/import_data_handler.h +++ b/chrome/browser/ui/webui/options/import_data_handler.h @@ -25,14 +25,14 @@ class ImportDataHandler : public OptionsPageUIHandler, virtual ~ImportDataHandler(); // OptionsPageUIHandler: - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); // WebUIMessageHandler: virtual void RegisterMessages(); private: - void ImportData(const ListValue* args); + void ImportData(const base::ListValue* args); // ImporterList::Observer: virtual void OnSourceProfilesLoaded() OVERRIDE; diff --git a/chrome/browser/ui/webui/options/language_options_handler.h b/chrome/browser/ui/webui/options/language_options_handler.h index 46ac1d4..908ef38 100644 --- a/chrome/browser/ui/webui/options/language_options_handler.h +++ b/chrome/browser/ui/webui/options/language_options_handler.h @@ -16,7 +16,7 @@ class LanguageOptionsHandler : public LanguageOptionsHandlerCommon { virtual ~LanguageOptionsHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // WebUIMessageHandler implementation. virtual void RegisterMessages(); @@ -27,7 +27,7 @@ class LanguageOptionsHandler : public LanguageOptionsHandlerCommon { // The return value will look like: // [{'code': 'fi', 'displayName': 'Finnish', 'nativeDisplayName': 'suomi'}, // ...] - static ListValue* GetLanguageList(); + static base::ListValue* GetLanguageList(); private: // LanguageOptionsHandlerCommon implementation. @@ -35,7 +35,7 @@ class LanguageOptionsHandler : public LanguageOptionsHandlerCommon { virtual void SetApplicationLocale(const std::string& language_code); // Called when the restart button is clicked. - void RestartCallback(const ListValue* args); + void RestartCallback(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(LanguageOptionsHandler); }; diff --git a/chrome/browser/ui/webui/options/language_options_handler_common.h b/chrome/browser/ui/webui/options/language_options_handler_common.h index a81a47f..b3c3e7b 100644 --- a/chrome/browser/ui/webui/options/language_options_handler_common.h +++ b/chrome/browser/ui/webui/options/language_options_handler_common.h @@ -8,8 +8,10 @@ #include "chrome/browser/ui/webui/options/options_ui.h" +namespace base { class DictionaryValue; class ListValue; +} // The base class for language options page UI handlers. This class has code // common to the Chrome OS and non-Chrome OS implementation of the handler. @@ -19,7 +21,7 @@ class LanguageOptionsHandlerCommon : public OptionsPageUIHandler { virtual ~LanguageOptionsHandlerCommon(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // DOMMessageHandler implementation. virtual void RegisterMessages(); @@ -32,7 +34,7 @@ class LanguageOptionsHandlerCommon : public OptionsPageUIHandler { // // Note that true in values does not mean anything. We just use the // dictionary as a set. - static DictionaryValue* GetUILanguageCodeSet(); + static base::DictionaryValue* GetUILanguageCodeSet(); // Gets the set of language codes that can be used for spellchecking. // The return value will look like: @@ -40,7 +42,7 @@ class LanguageOptionsHandlerCommon : public OptionsPageUIHandler { // // Note that true in values does not mean anything. We just use the // dictionary as a set. - static DictionaryValue* GetSpellCheckLanguageCodeSet(); + static base::DictionaryValue* GetSpellCheckLanguageCodeSet(); private: // Returns the name of the product (ex. "Chrome" or "Chrome OS"). @@ -50,15 +52,15 @@ class LanguageOptionsHandlerCommon : public OptionsPageUIHandler { virtual void SetApplicationLocale(const std::string& language_code) = 0; // Called when the language options is opened. - void LanguageOptionsOpenCallback(const ListValue* args); + void LanguageOptionsOpenCallback(const base::ListValue* args); // Called when the UI language is changed. // |args| will contain the language code as string (ex. "fr"). - void UiLanguageChangeCallback(const ListValue* args); + void UiLanguageChangeCallback(const base::ListValue* args); // Called when the spell check language is changed. // |args| will contain the language code as string (ex. "fr"). - void SpellCheckLanguageChangeCallback(const ListValue* args); + void SpellCheckLanguageChangeCallback(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(LanguageOptionsHandlerCommon); }; diff --git a/chrome/browser/ui/webui/options/options_ui.h b/chrome/browser/ui/webui/options/options_ui.h index 1ebbfa9..d4a27f8 100644 --- a/chrome/browser/ui/webui/options/options_ui.h +++ b/chrome/browser/ui/webui/options/options_ui.h @@ -31,7 +31,7 @@ class OptionsPageUIHandler : public WebUIMessageHandler, virtual bool IsEnabled(); // Collects localized strings for options page. - virtual void GetLocalizedValues(DictionaryValue* localized_strings) = 0; + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings) = 0; // Initialize the page. Called once the DOM is available for manipulation. // This will be called only once. @@ -58,12 +58,12 @@ class OptionsPageUIHandler : public WebUIMessageHandler, int id; }; // A helper for simplifying the process of registering strings in WebUI. - static void RegisterStrings(DictionaryValue* localized_strings, + static void RegisterStrings(base::DictionaryValue* localized_strings, const OptionsStringResource* resources, size_t length); // Registers string resources for a page's header and tab title. - static void RegisterTitle(DictionaryValue* localized_strings, + static void RegisterTitle(base::DictionaryValue* localized_strings, const std::string& variable_name, int title_id); @@ -98,7 +98,7 @@ class OptionsUI : public ChromeWebUI, private: // Adds OptionsPageUiHandler to the handlers list if handler is enabled. - void AddOptionsPageUIHandler(DictionaryValue* localized_strings, + void AddOptionsPageUIHandler(base::DictionaryValue* localized_strings, OptionsPageUIHandler* handler); bool initialized_handlers_; diff --git a/chrome/browser/ui/webui/options/search_engine_manager_handler.h b/chrome/browser/ui/webui/options/search_engine_manager_handler.h index 285d3c3..0e76065 100644 --- a/chrome/browser/ui/webui/options/search_engine_manager_handler.h +++ b/chrome/browser/ui/webui/options/search_engine_manager_handler.h @@ -21,7 +21,7 @@ class SearchEngineManagerHandler : public OptionsPageUIHandler, virtual void Initialize(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // ui::TableModelObserver implementation. virtual void OnModelChanged(); @@ -42,30 +42,30 @@ class SearchEngineManagerHandler : public OptionsPageUIHandler, scoped_ptr<EditSearchEngineController> edit_controller_; // Removes the search engine at the given index. Called from WebUI. - void RemoveSearchEngine(const ListValue* args); + void RemoveSearchEngine(const base::ListValue* args); // Sets the search engine at the given index to be default. Called from WebUI. - void SetDefaultSearchEngine(const ListValue* args); + void SetDefaultSearchEngine(const base::ListValue* args); // Starts an edit session for the search engine at the given index. If the // index is -1, starts editing a new search engine instead of an existing one. // Called from WebUI. - void EditSearchEngine(const ListValue* args); + void EditSearchEngine(const base::ListValue* args); // Validates the given search engine values, and reports the results back // to WebUI. Called from WebUI. - void CheckSearchEngineInfoValidity(const ListValue* args); + void CheckSearchEngineInfoValidity(const base::ListValue* args); // Called when an edit is cancelled. // Called from WebUI. - void EditCancelled(const ListValue* args); + void EditCancelled(const base::ListValue* args); // Called when an edit is finished and should be saved. // Called from WebUI. - void EditCompleted(const ListValue* args); + void EditCompleted(const base::ListValue* args); // Returns a dictionary to pass to WebUI representing the given search engine. - DictionaryValue* CreateDictionaryForEngine(int index, bool is_default); + base::DictionaryValue* CreateDictionaryForEngine(int index, bool is_default); DISALLOW_COPY_AND_ASSIGN(SearchEngineManagerHandler); }; diff --git a/chrome/browser/ui/webui/options/stop_syncing_handler.h b/chrome/browser/ui/webui/options/stop_syncing_handler.h index 095f76c..251255f 100644 --- a/chrome/browser/ui/webui/options/stop_syncing_handler.h +++ b/chrome/browser/ui/webui/options/stop_syncing_handler.h @@ -14,13 +14,13 @@ class StopSyncingHandler : public OptionsPageUIHandler { virtual ~StopSyncingHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); // WebUIMessageHandler implementation. virtual void RegisterMessages(); private: - void StopSyncing(const ListValue* args); + void StopSyncing(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(StopSyncingHandler); }; diff --git a/chrome/browser/ui/webui/options/sync_setup_handler.h b/chrome/browser/ui/webui/options/sync_setup_handler.h index 8b9419d..50f9888 100644 --- a/chrome/browser/ui/webui/options/sync_setup_handler.h +++ b/chrome/browser/ui/webui/options/sync_setup_handler.h @@ -17,16 +17,16 @@ class SyncSetupHandler : public OptionsPageUIHandler, virtual ~SyncSetupHandler(); // OptionsPageUIHandler implementation. - virtual void GetLocalizedValues(DictionaryValue* localized_strings); + virtual void GetLocalizedValues(base::DictionaryValue* localized_strings); virtual void Initialize(); virtual void RegisterMessages(); // SyncSetupFlowHandler implementation. - virtual void ShowGaiaLogin(const DictionaryValue& args); + virtual void ShowGaiaLogin(const base::DictionaryValue& args); virtual void ShowGaiaSuccessAndClose(); virtual void ShowGaiaSuccessAndSettingUp(); - virtual void ShowConfigure(const DictionaryValue& args); - virtual void ShowPassphraseEntry(const DictionaryValue& args); + virtual void ShowConfigure(const base::DictionaryValue& args); + virtual void ShowPassphraseEntry(const base::DictionaryValue& args); virtual void ShowSettingUp(); virtual void ShowSetupDone(const std::wstring& user); virtual void SetFlow(SyncSetupFlow* flow); @@ -47,14 +47,14 @@ class SyncSetupHandler : public OptionsPageUIHandler, // Callbacks from the page. Protected in order to be called by the // SyncSetupWizardTest. - void OnDidClosePage(const ListValue* args); - void HandleSubmitAuth(const ListValue* args); - void HandleConfigure(const ListValue* args); - void HandlePassphraseEntry(const ListValue* args); - void HandlePassphraseCancel(const ListValue* args); - void HandleAttachHandler(const ListValue* args); - void HandleShowErrorUI(const ListValue* args); - void HandleShowSetupUI(const ListValue* args); + void OnDidClosePage(const base::ListValue* args); + void HandleSubmitAuth(const base::ListValue* args); + void HandleConfigure(const base::ListValue* args); + void HandlePassphraseEntry(const base::ListValue* args); + void HandlePassphraseCancel(const base::ListValue* args); + void HandleAttachHandler(const base::ListValue* args); + void HandleShowErrorUI(const base::ListValue* args); + void HandleShowSetupUI(const base::ListValue* args); SyncSetupFlow* flow() { return flow_; } diff --git a/chrome/browser/ui/webui/print_preview_handler.h b/chrome/browser/ui/webui/print_preview_handler.h index 651a70f..510b81a 100644 --- a/chrome/browser/ui/webui/print_preview_handler.h +++ b/chrome/browser/ui/webui/print_preview_handler.h @@ -13,9 +13,12 @@ #include "content/browser/webui/web_ui.h" class FilePath; -class FundamentalValue; class PrintSystemTaskProxy; + +namespace base { +class FundamentalValue; class StringValue; +} namespace printing { class PrintBackend; @@ -54,52 +57,52 @@ class PrintPreviewHandler : public WebUIMessageHandler, TabContents* preview_tab(); // Get the default printer. |args| is unused. - void HandleGetDefaultPrinter(const ListValue* args); + void HandleGetDefaultPrinter(const base::ListValue* args); // Get the list of printers. |args| is unused. - void HandleGetPrinters(const ListValue* args); + void HandleGetPrinters(const base::ListValue* args); // Ask the initiator renderer to generate a preview. // First element of |args| is a job settings JSON string. - void HandleGetPreview(const ListValue* args); + void HandleGetPreview(const base::ListValue* args); // Get the job settings from Web UI and initiate printing. // First element of |args| is a job settings JSON string. - void HandlePrint(const ListValue* args); + void HandlePrint(const base::ListValue* args); // Handles the request to hide the preview tab for printing. // |args| is unused. - void HandleHidePreview(const ListValue* args); + void HandleHidePreview(const base::ListValue* args); // Handles the request to cancel the pending print request. // |args| is unused. - void HandleCancelPendingPrintRequest(const ListValue* args); + void HandleCancelPendingPrintRequest(const base::ListValue* args); // Get the printer capabilities. // First element of |args| is the printer name. - void HandleGetPrinterCapabilities(const ListValue* args); + void HandleGetPrinterCapabilities(const base::ListValue* args); // Ask the initiator renderer to show the native print system dialog. // |args| is unused. - void HandleShowSystemDialog(const ListValue* args); + void HandleShowSystemDialog(const base::ListValue* args); // Ask the browser to show the native printer management dialog. // |args| is unused. - void HandleManagePrinters(const ListValue* args); + void HandleManagePrinters(const base::ListValue* args); // Ask the browser to close the preview tab. // |args| is unused. - void HandleClosePreviewTab(const ListValue* args); + void HandleClosePreviewTab(const base::ListValue* args); // Send the printer capabilities to the Web UI. // |settings_info| contains printer capabilities information. - void SendPrinterCapabilities(const DictionaryValue& settings_info); + void SendPrinterCapabilities(const base::DictionaryValue& settings_info); // Send the default printer to the Web UI. - void SendDefaultPrinter(const StringValue& default_printer); + void SendDefaultPrinter(const base::StringValue& default_printer); // Send the list of printers to the Web UI. - void SendPrinterList(const ListValue& printers); + void SendPrinterList(const base::ListValue& printers); // Helper function to get the initiator tab for the print preview tab. TabContents* GetInitiatorTab(); diff --git a/chrome/browser/ui/webui/sync_internals_ui.h b/chrome/browser/ui/webui/sync_internals_ui.h index 4c6ca5a..31157a4 100644 --- a/chrome/browser/ui/webui/sync_internals_ui.h +++ b/chrome/browser/ui/webui/sync_internals_ui.h @@ -39,7 +39,7 @@ class SyncInternalsUI : public ChromeWebUI, // getAboutInfo() be handled by the sync service. virtual void OnWebUISend(const GURL& source_url, const std::string& name, - const ListValue& args) OVERRIDE; + const base::ListValue& args) OVERRIDE; // browser_sync::JsEventHandler implementation. virtual void HandleJsEvent( diff --git a/chrome/browser/ui/webui/task_manager_handler.h b/chrome/browser/ui/webui/task_manager_handler.h index e6b4901..14278b3 100644 --- a/chrome/browser/ui/webui/task_manager_handler.h +++ b/chrome/browser/ui/webui/task_manager_handler.h @@ -10,7 +10,9 @@ #include "content/browser/webui/web_ui.h" #include "chrome/browser/task_manager/task_manager.h" +namespace base { class ListValue; +} class TaskManagerHandler : public WebUIMessageHandler, public TaskManagerModelObserver { @@ -34,11 +36,11 @@ class TaskManagerHandler : public WebUIMessageHandler, virtual void RegisterMessages() OVERRIDE; // Callback for the "killProcess" message. - void HandleKillProcess(const ListValue* args); + void HandleKillProcess(const base::ListValue* args); - void EnableTaskManager(const ListValue* indexes); - void DisableTaskManager(const ListValue* indexes); - void OpenAboutMemory(const ListValue* indexes); + void EnableTaskManager(const base::ListValue* indexes); + void DisableTaskManager(const base::ListValue* indexes); + void OpenAboutMemory(const base::ListValue* indexes); private: // Models diff --git a/chrome/browser/ui/webui/textfields_ui.h b/chrome/browser/ui/webui/textfields_ui.h index bb39b08..d00ae2b 100644 --- a/chrome/browser/ui/webui/textfields_ui.h +++ b/chrome/browser/ui/webui/textfields_ui.h @@ -46,7 +46,7 @@ class TextfieldsDOMHandler : public WebUIMessageHandler { // Handles the "textfieldValue" call from the JavaScript. This call // synchonizes the value inside the JavaScript textfield with the copy in the // DOM object. - virtual void HandleTextfieldValue(const ListValue* args); + virtual void HandleTextfieldValue(const base::ListValue* args); protected: virtual void RegisterMessages(); diff --git a/chrome/browser/ui/webui/web_ui_browsertest.h b/chrome/browser/ui/webui/web_ui_browsertest.h index 635b0c0..fca2962 100644 --- a/chrome/browser/ui/webui/web_ui_browsertest.h +++ b/chrome/browser/ui/webui/web_ui_browsertest.h @@ -13,9 +13,12 @@ #include "chrome/test/in_process_browser_test.h" #include "chrome/test/test_navigation_observer.h" -class Value; class WebUIMessageHandler; +namespace base { +class Value; +} + // This macro simplifies the declaration of simple javascript unit tests. // Use: // WEB_UI_UNITTEST_F(MyWebUIPageTest, myJavascriptUnittest); @@ -34,7 +37,7 @@ class WebUIBrowserTest : public InProcessBrowserTest, public TestNavigationObserver::JsInjectionReadyObserver { public: - typedef std::vector<const Value*> ConstValueVector; + typedef std::vector<const base::Value*> ConstValueVector; virtual ~WebUIBrowserTest(); // Add a custom helper JS library for your test. @@ -46,10 +49,10 @@ class WebUIBrowserTest // Note that calls to functions in test_api.js are not supported. bool RunJavascriptFunction(const std::string& function_name); bool RunJavascriptFunction(const std::string& function_name, - const Value& arg); + const base::Value& arg); bool RunJavascriptFunction(const std::string& function_name, - const Value& arg1, - const Value& arg2); + const base::Value& arg1, + const base::Value& arg2); bool RunJavascriptFunction(const std::string& function_name, const ConstValueVector& function_arguments); @@ -60,10 +63,10 @@ class WebUIBrowserTest // Runs a test that may include calls to functions in test_api.js. bool RunJavascriptTest(const std::string& test_name); bool RunJavascriptTest(const std::string& test_name, - const Value& arg); + const base::Value& arg); bool RunJavascriptTest(const std::string& test_name, - const Value& arg1, - const Value& arg2); + const base::Value& arg1, + const base::Value& arg2); bool RunJavascriptTest(const std::string& test_name, const ConstValueVector& test_arguments); diff --git a/chrome/browser/web_resource/gpu_blacklist_updater.h b/chrome/browser/web_resource/gpu_blacklist_updater.h index 3872fac..bd1d550 100644 --- a/chrome/browser/web_resource/gpu_blacklist_updater.h +++ b/chrome/browser/web_resource/gpu_blacklist_updater.h @@ -18,15 +18,14 @@ class GpuBlacklistUpdater : public WebResourceService { private: virtual ~GpuBlacklistUpdater(); - virtual void Unpack(const DictionaryValue& parsed_json); + virtual void Unpack(const base::DictionaryValue& parsed_json); void InitializeGpuBlacklist(); void UpdateGpuBlacklist( - const DictionaryValue& gpu_blacklist_cache, bool preliminary); + const base::DictionaryValue& gpu_blacklist_cache, bool preliminary); DISALLOW_COPY_AND_ASSIGN(GpuBlacklistUpdater); }; #endif // CHROME_BROWSER_WEB_RESOURCE_GPU_BLACKLIST_UPDATER_H_ - diff --git a/chrome/browser/web_resource/promo_resource_service.h b/chrome/browser/web_resource/promo_resource_service.h index fcb7676..5407cd4 100644 --- a/chrome/browser/web_resource/promo_resource_service.h +++ b/chrome/browser/web_resource/promo_resource_service.h @@ -90,7 +90,7 @@ class PromoResourceService // Overrides the current Chrome release channel for testing purposes. void set_channel(chrome::VersionInfo::Channel channel) { channel_ = channel; } - virtual void Unpack(const DictionaryValue& parsed_json); + virtual void Unpack(const base::DictionaryValue& parsed_json); // Unpack the web resource as a custom promo signal. Expects a start and end // signal, with the promo to be shown in the tooltip of the start signal @@ -132,7 +132,7 @@ class PromoResourceService // For example, "7:24" would indicate that all builds should see the promo, // and each group should see it for 24 hours. // - void UnpackPromoSignal(const DictionaryValue& parsed_json); + void UnpackPromoSignal(const base::DictionaryValue& parsed_json); // Unpack the promo resource as a custom logo signal. Expects a start and end // signal. Delivery will be in json in the form of: @@ -160,7 +160,7 @@ class PromoResourceService // } // } // - void UnpackLogoSignal(const DictionaryValue& parsed_json); + void UnpackLogoSignal(const base::DictionaryValue& parsed_json); // Unpack the web store promo. Expects JSON delivery in the following format: // { @@ -190,11 +190,11 @@ class PromoResourceService // the logo image. In the example above, the URL is empty so the // default webstore logo will be used. // answer_id: the promo's id - void UnpackWebStoreSignal(const DictionaryValue& parsed_json); + void UnpackWebStoreSignal(const base::DictionaryValue& parsed_json); // Gets mutable dictionary attached to user's preferences, so that we // can write resource data back to user's pref file. - DictionaryValue* web_resource_cache_; + base::DictionaryValue* web_resource_cache_; // Overrides the current Chrome release channel for testing purposes. chrome::VersionInfo::Channel channel_; diff --git a/chrome/browser/web_resource/web_resource_service.h b/chrome/browser/web_resource/web_resource_service.h index 1f08a9d..22509a8 100644 --- a/chrome/browser/web_resource/web_resource_service.h +++ b/chrome/browser/web_resource/web_resource_service.h @@ -11,10 +11,13 @@ #include "content/browser/utility_process_host.h" #include "content/common/content_notification_types.h" -class DictionaryValue; class PrefService; class ResourceDispatcherHost; +namespace base { +class DictionaryValue; +} + // A WebResourceService fetches data from a web resource server and store // locally as user preference. class WebResourceService : public UtilityProcessHost::Client { @@ -40,7 +43,7 @@ class WebResourceService : public UtilityProcessHost::Client { protected: virtual ~WebResourceService(); - virtual void Unpack(const DictionaryValue& parsed_json) = 0; + virtual void Unpack(const base::DictionaryValue& parsed_json) = 0; // If delay_ms is positive, schedule notification with the delay. // If delay_ms is 0, notify immediately by calling WebResourceStateChange(). @@ -61,7 +64,7 @@ class WebResourceService : public UtilityProcessHost::Client { void EndFetch(); // Puts parsed json data in the right places, and writes to prefs file. - void OnWebResourceUnpacked(const DictionaryValue& parsed_json); + void OnWebResourceUnpacked(const base::DictionaryValue& parsed_json); // Notify listeners that the state of a web resource has changed. void WebResourceStateChange(); diff --git a/chrome/common/extensions/extension.h b/chrome/common/extensions/extension.h index 08809aa..c1543da 100644 --- a/chrome/common/extensions/extension.h +++ b/chrome/common/extensions/extension.h @@ -25,15 +25,18 @@ #include "googleurl/src/gurl.h" #include "ui/gfx/size.h" -class DictionaryValue; class ExtensionAction; class ExtensionResource; class ExtensionSidebarDefaults; class FileBrowserHandler; -class ListValue; class SkBitmap; class Version; +namespace base { +class DictionaryValue; +class ListValue; +} + // Represents a Chrome extension. class Extension : public base::RefCountedThreadSafe<Extension> { public: @@ -176,18 +179,19 @@ class Extension : public base::RefCountedThreadSafe<Extension> { static scoped_refptr<Extension> Create(const FilePath& path, Location location, - const DictionaryValue& value, + const base::DictionaryValue& value, int flags, std::string* error); // In a few special circumstances, we want to create an Extension and give it // an explicit id. Most consumers should just use the plain Create() method. - static scoped_refptr<Extension> CreateWithId(const FilePath& path, - Location location, - const DictionaryValue& value, - int flags, - const std::string& explicit_id, - std::string* error); + static scoped_refptr<Extension> CreateWithId( + const FilePath& path, + Location location, + const base::DictionaryValue& value, + int flags, + const std::string& explicit_id, + std::string* error); // Return the update url used by gallery/webstore extensions. static GURL GalleryUpdateUrl(bool secure); @@ -487,7 +491,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { } const GURL& update_url() const { return update_url_; } const ExtensionIconSet& icons() const { return icons_; } - const DictionaryValue* manifest_value() const { + const base::DictionaryValue* manifest_value() const { return manifest_value_.get(); } const std::string default_locale() const { return default_locale_; } @@ -520,10 +524,10 @@ class Extension : public base::RefCountedThreadSafe<Extension> { // Theme-related. bool is_theme() const { return is_theme_; } - DictionaryValue* GetThemeImages() const { return theme_images_.get(); } - DictionaryValue* GetThemeColors() const {return theme_colors_.get(); } - DictionaryValue* GetThemeTints() const { return theme_tints_.get(); } - DictionaryValue* GetThemeDisplayProperties() const { + base::DictionaryValue* GetThemeImages() const { return theme_images_.get(); } + base::DictionaryValue* GetThemeColors() const {return theme_colors_.get(); } + base::DictionaryValue* GetThemeTints() const { return theme_tints_.get(); } + base::DictionaryValue* GetThemeDisplayProperties() const { return theme_display_properties_.get(); } @@ -563,7 +567,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { ~Extension(); // Initialize the extension from a parsed manifest. - bool InitFromValue(const DictionaryValue& value, int flags, + bool InitFromValue(const base::DictionaryValue& value, int flags, std::string* error); // Helper function for implementing HasCachedImage/GetCachedImage. A return @@ -574,7 +578,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { // Helper method that loads a UserScript object from a // dictionary in the content_script list of the manifest. - bool LoadUserScriptHelper(const DictionaryValue* content_script, + bool LoadUserScriptHelper(const base::DictionaryValue* content_script, int definition_index, int flags, std::string* error, @@ -582,7 +586,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { // Helper method that loads either the include_globs or exclude_globs list // from an entry in the content_script lists of the manifest. - bool LoadGlobsHelper(const DictionaryValue* content_script, + bool LoadGlobsHelper(const base::DictionaryValue* content_script, int content_script_index, const char* globs_property_name, std::string* error, @@ -590,35 +594,39 @@ class Extension : public base::RefCountedThreadSafe<Extension> { UserScript *instance); // Helpers to load various chunks of the manifest. - bool LoadIsApp(const DictionaryValue* manifest, std::string* error); - bool LoadExtent(const DictionaryValue* manifest, + bool LoadIsApp(const base::DictionaryValue* manifest, std::string* error); + bool LoadExtent(const base::DictionaryValue* manifest, const char* key, URLPatternSet* extent, const char* list_error, const char* value_error, URLPattern::ParseOption parse_strictness, std::string* error); - bool LoadLaunchContainer(const DictionaryValue* manifest, std::string* error); - bool LoadLaunchURL(const DictionaryValue* manifest, std::string* error); - bool LoadAppIsolation(const DictionaryValue* manifest, std::string* error); - bool EnsureNotHybridApp(const DictionaryValue* manifest, std::string* error); + bool LoadLaunchContainer(const base::DictionaryValue* manifest, + std::string* error); + bool LoadLaunchURL(const base::DictionaryValue* manifest, + std::string* error); + bool LoadAppIsolation(const base::DictionaryValue* manifest, + std::string* error); + bool EnsureNotHybridApp(const base::DictionaryValue* manifest, + std::string* error); // Helper method to load an ExtensionAction from the page_action or // browser_action entries in the manifest. ExtensionAction* LoadExtensionActionHelper( - const DictionaryValue* extension_action, std::string* error); + const base::DictionaryValue* extension_action, std::string* error); // Helper method to load an FileBrowserHandlerList from the manifest. FileBrowserHandlerList* LoadFileBrowserHandlers( - const ListValue* extension_actions, std::string* error); + const base::ListValue* extension_actions, std::string* error); // Helper method to load an FileBrowserHandler from manifest. FileBrowserHandler* LoadFileBrowserHandler( - const DictionaryValue* file_browser_handlers, std::string* error); + const base::DictionaryValue* file_browser_handlers, std::string* error); // Helper method to load an ExtensionSidebarDefaults from the sidebar manifest // entry. ExtensionSidebarDefaults* LoadExtensionSidebarDefaults( - const DictionaryValue* sidebar, std::string* error); + const base::DictionaryValue* sidebar, std::string* error); // Returns true if the extension has more than one "UI surface". For example, // an extension that has a browser action and a page action. @@ -626,7 +634,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { // Figures out if a source contains keys not associated with themes - we // don't want to allow scripts and such to be bundled with themes. - bool ContainsNonThemeKeys(const DictionaryValue& source) const; + bool ContainsNonThemeKeys(const base::DictionaryValue& source) const; // Only allow the experimental API permission if the command line // flag is present. @@ -729,16 +737,16 @@ class Extension : public base::RefCountedThreadSafe<Extension> { std::string public_key_; // A map of resource id's to relative file paths. - scoped_ptr<DictionaryValue> theme_images_; + scoped_ptr<base::DictionaryValue> theme_images_; // A map of color names to colors. - scoped_ptr<DictionaryValue> theme_colors_; + scoped_ptr<base::DictionaryValue> theme_colors_; // A map of color names to colors. - scoped_ptr<DictionaryValue> theme_tints_; + scoped_ptr<base::DictionaryValue> theme_tints_; // A map of display properties. - scoped_ptr<DictionaryValue> theme_display_properties_; + scoped_ptr<base::DictionaryValue> theme_display_properties_; // Whether the extension is a theme. bool is_theme_; @@ -751,7 +759,7 @@ class Extension : public base::RefCountedThreadSafe<Extension> { GURL update_url_; // A copy of the manifest that this extension was created from. - scoped_ptr<DictionaryValue> manifest_value_; + scoped_ptr<base::DictionaryValue> manifest_value_; // A map of chrome:// hostnames (newtab, downloads, etc.) to Extension URLs // which override the handling of those URLs. (see ExtensionOverrideUI). @@ -811,13 +819,13 @@ typedef std::set<std::string> ExtensionIdSet; // Handy struct to pass core extension info around. struct ExtensionInfo { - ExtensionInfo(const DictionaryValue* manifest, + ExtensionInfo(const base::DictionaryValue* manifest, const std::string& id, const FilePath& path, Extension::Location location); ~ExtensionInfo(); - scoped_ptr<DictionaryValue> extension_manifest; + scoped_ptr<base::DictionaryValue> extension_manifest; std::string extension_id; FilePath extension_path; Extension::Location extension_location; diff --git a/chrome/common/extensions/extension_l10n_util.h b/chrome/common/extensions/extension_l10n_util.h index 57aa68f..5aee097 100644 --- a/chrome/common/extensions/extension_l10n_util.h +++ b/chrome/common/extensions/extension_l10n_util.h @@ -12,7 +12,6 @@ #include <string> #include <vector> -class DictionaryValue; class Extension; class ExtensionMessageBundle; class FilePath; @@ -20,6 +19,10 @@ class GURL; class ResourceDispatcherHostRequestInfo; struct ExtensionInfo; +namespace base { +class DictionaryValue; +} + namespace extension_l10n_util { // Set the locale for this process to a fixed value, rather than using the @@ -29,7 +32,7 @@ void SetProcessLocale(const std::string& locale); // Returns default locale in form "en-US" or "sr" or empty string if // "default_locale" section was not defined in the manifest.json file. -std::string GetDefaultLocaleFromManifest(const DictionaryValue& manifest, +std::string GetDefaultLocaleFromManifest(const base::DictionaryValue& manifest, std::string* error); // Returns true iff the extension was localized, and the current locale @@ -39,13 +42,13 @@ bool ShouldRelocalizeManifest(const ExtensionInfo& info); // Localize extension name, description, browser_action and other fields // in the manifest. bool LocalizeManifest(const ExtensionMessageBundle& messages, - DictionaryValue* manifest, + base::DictionaryValue* manifest, std::string* error); // Load message catalogs, localize manifest and attach message bundle to the // extension. bool LocalizeExtension(const FilePath& extension_path, - DictionaryValue* manifest, + base::DictionaryValue* manifest, std::string* error); // Adds locale_name to the extension if it's in chrome_locales, and diff --git a/chrome/common/extensions/extension_message_bundle.h b/chrome/common/extensions/extension_message_bundle.h index 8f3078e..fad4b84 100644 --- a/chrome/common/extensions/extension_message_bundle.h +++ b/chrome/common/extensions/extension_message_bundle.h @@ -12,14 +12,16 @@ #include "base/memory/linked_ptr.h" +namespace base { class DictionaryValue; +} // Contains localized extension messages for one locale. Any messages that the // locale does not provide are pulled from the default locale. class ExtensionMessageBundle { public: typedef std::map<std::string, std::string> SubstitutionMap; - typedef std::vector<linked_ptr<DictionaryValue> > CatalogVector; + typedef std::vector<linked_ptr<base::DictionaryValue> > CatalogVector; // JSON keys of interest for messages file. static const char* kContentKey; @@ -123,12 +125,12 @@ class ExtensionMessageBundle { // They replace all $PLACEHOLDERS$ with their value, and return just key/value // of the message. bool GetMessageValue(const std::string& key, - const DictionaryValue& catalog, + const base::DictionaryValue& catalog, std::string* value, std::string* error) const; // Get all placeholders for a given message from JSON subtree. - bool GetPlaceholders(const DictionaryValue& name_tree, + bool GetPlaceholders(const base::DictionaryValue& name_tree, const std::string& name_key, SubstitutionMap* placeholders, std::string* error) const; diff --git a/chrome/common/extensions/extension_permission_set.h b/chrome/common/extensions/extension_permission_set.h index 14f58a90..5cd331a 100644 --- a/chrome/common/extensions/extension_permission_set.h +++ b/chrome/common/extensions/extension_permission_set.h @@ -17,10 +17,8 @@ #include "base/string16.h" #include "chrome/common/extensions/url_pattern_set.h" -class DictionaryValue; class Extension; class ExtensionPrefs; -class ListValue; // When prompting the user to install or approve permissions, we display // messages describing the effects of the permissions rather than listing the diff --git a/chrome/common/extensions/extension_unpacker.h b/chrome/common/extensions/extension_unpacker.h index 0282718..2526a9e 100644 --- a/chrome/common/extensions/extension_unpacker.h +++ b/chrome/common/extensions/extension_unpacker.h @@ -13,9 +13,12 @@ #include "base/memory/scoped_ptr.h" #include "base/tuple.h" -class DictionaryValue; class SkBitmap; +namespace base { +class DictionaryValue; +} + // This class unpacks an extension. It is designed to be used in a sandboxed // child process. We unpack and parse various bits of the extension, then // report back to the browser process, who then transcodes the pre-parsed bits @@ -51,19 +54,19 @@ class ExtensionUnpacker { // |extension_path| is the path to the extension we unpacked that wrote the // data. Returns true on success. static bool ReadMessageCatalogsFromFile(const FilePath& extension_path, - DictionaryValue* catalogs); + base::DictionaryValue* catalogs); const std::string& error_message() { return error_message_; } - DictionaryValue* parsed_manifest() { + base::DictionaryValue* parsed_manifest() { return parsed_manifest_.get(); } const DecodedImages& decoded_images() { return decoded_images_; } - DictionaryValue* parsed_catalogs() { return parsed_catalogs_.get(); } + base::DictionaryValue* parsed_catalogs() { return parsed_catalogs_.get(); } private: // Parse the manifest.json file inside the extension (not in the header). // Caller takes ownership of return value. - DictionaryValue* ReadManifest(); + base::DictionaryValue* ReadManifest(); // Parse all _locales/*/messages.json files inside the extension. bool ReadAllMessageCatalogs(const std::string& default_locale); @@ -86,7 +89,7 @@ class ExtensionUnpacker { FilePath temp_install_dir_; // The parsed version of the manifest JSON contained in the extension. - scoped_ptr<DictionaryValue> parsed_manifest_; + scoped_ptr<base::DictionaryValue> parsed_manifest_; // A list of decoded images and the paths where those images came from. Paths // are relative to the manifest file. @@ -94,7 +97,7 @@ class ExtensionUnpacker { // Dictionary of relative paths and catalogs per path. Paths are in the form // of _locales/locale, without messages.json base part. - scoped_ptr<DictionaryValue> parsed_catalogs_; + scoped_ptr<base::DictionaryValue> parsed_catalogs_; // The last error message that was set. Empty if there were no errors. std::string error_message_; diff --git a/chrome/common/json_pref_store.h b/chrome/common/json_pref_store.h index 8291a02..b94030d 100644 --- a/chrome/common/json_pref_store.h +++ b/chrome/common/json_pref_store.h @@ -16,12 +16,12 @@ #include "chrome/common/persistent_pref_store.h" namespace base { +class DictionaryValue; class MessageLoopProxy; +class Value; } -class DictionaryValue; class FilePath; -class Value; // A writable PrefStore implementation that is used for user preferences. class JsonPrefStore : public PersistentPrefStore, @@ -35,15 +35,16 @@ class JsonPrefStore : public PersistentPrefStore, // PrefStore overrides: virtual ReadResult GetValue(const std::string& key, - const Value** result) const; + const base::Value** result) const; virtual void AddObserver(PrefStore::Observer* observer); virtual void RemoveObserver(PrefStore::Observer* observer); virtual bool IsInitializationComplete() const; // PersistentPrefStore overrides: - virtual ReadResult GetMutableValue(const std::string& key, Value** result); - virtual void SetValue(const std::string& key, Value* value); - virtual void SetValueSilently(const std::string& key, Value* value); + virtual ReadResult GetMutableValue(const std::string& key, + base::Value** result); + virtual void SetValue(const std::string& key, base::Value* value); + virtual void SetValueSilently(const std::string& key, base::Value* value); virtual void RemoveValue(const std::string& key); virtual bool ReadOnly() const; virtual PrefReadError ReadPrefs(); @@ -57,7 +58,7 @@ class JsonPrefStore : public PersistentPrefStore, // ownership of the |value| pointer. Note, this method is used with // asynchronous file reading, so class exposes it only for the internal needs. // (read: do not call it manually). - void OnFileRead(Value* value_owned, PrefReadError error, bool no_dir); + void OnFileRead(base::Value* value_owned, PrefReadError error, bool no_dir); private: // ImportantFileWriter::DataSerializer overrides: @@ -66,7 +67,7 @@ class JsonPrefStore : public PersistentPrefStore, FilePath path_; scoped_refptr<base::MessageLoopProxy> file_message_loop_proxy_; - scoped_ptr<DictionaryValue> prefs_; + scoped_ptr<base::DictionaryValue> prefs_; bool read_only_; diff --git a/chrome/common/json_schema_validator.h b/chrome/common/json_schema_validator.h index 68030f8..b49480b 100644 --- a/chrome/common/json_schema_validator.h +++ b/chrome/common/json_schema_validator.h @@ -11,11 +11,13 @@ #include "base/basictypes.h" +namespace base { class DictionaryValue; class FundamentalValue; class ListValue; class StringValue; class Value; +} //============================================================================== // This class implements a subset of JSON Schema. @@ -85,7 +87,7 @@ class JSONSchemaValidator { static const char kInvalidType[]; // Classifies a Value as one of the JSON schema primitive types. - static std::string GetJSONSchemaType(Value* value); + static std::string GetJSONSchemaType(base::Value* value); // Utility methods to format error messages. The first method can have one // wildcard represented by '*', which is replaced with s1. The second method @@ -101,7 +103,7 @@ class JSONSchemaValidator { // NOTE: This constructor assumes that |schema| is well formed and valid. // Errors will result in CHECK at runtime; this constructor should not be used // with untrusted schemas. - explicit JSONSchemaValidator(DictionaryValue* schema); + explicit JSONSchemaValidator(base::DictionaryValue* schema); // Creates a validator for the specified schema and user-defined types. Each // type must be a valid JSONSchema type description with an additional "id" @@ -111,7 +113,7 @@ class JSONSchemaValidator { // NOTE: This constructor assumes that |schema| and |types| are well-formed // and valid. Errors will result in CHECK at runtime; this constructor should // not be used with untrusted schemas. - JSONSchemaValidator(DictionaryValue* schema, ListValue* types); + JSONSchemaValidator(base::DictionaryValue* schema, base::ListValue* types); ~JSONSchemaValidator(); @@ -139,10 +141,10 @@ class JSONSchemaValidator { // Validates a JSON value. Returns true if the instance is valid, false // otherwise. If false is returned any errors are available from the errors() // getter. - bool Validate(Value* instance); + bool Validate(base::Value* instance); private: - typedef std::map<std::string, DictionaryValue*> TypeMap; + typedef std::map<std::string, base::DictionaryValue*> TypeMap; // Each of the below methods handle a subset of the validation process. The // path paramater is the path to |instance| from the root of the instance tree @@ -151,50 +153,54 @@ class JSONSchemaValidator { // Validates any instance node against any schema node. This is called for // every node in the instance tree, and it just decides which of the more // detailed methods to call. - void Validate(Value* instance, DictionaryValue* schema, + void Validate(base::Value* instance, base::DictionaryValue* schema, const std::string& path); // Validates a node against a list of possible schemas. If any one of the // schemas match, the node is valid. - void ValidateChoices(Value* instance, ListValue* choices, + void ValidateChoices(base::Value* instance, base::ListValue* choices, const std::string& path); // Validates a node against a list of exact primitive values, eg 42, "foobar". - void ValidateEnum(Value* instance, ListValue* choices, + void ValidateEnum(base::Value* instance, base::ListValue* choices, const std::string& path); // Validates a JSON object against an object schema node. - void ValidateObject(DictionaryValue* instance, DictionaryValue* schema, + void ValidateObject(base::DictionaryValue* instance, + base::DictionaryValue* schema, const std::string& path); // Validates a JSON array against an array schema node. - void ValidateArray(ListValue* instance, DictionaryValue* schema, + void ValidateArray(base::ListValue* instance, base::DictionaryValue* schema, const std::string& path); // Validates a JSON array against an array schema node configured to be a // tuple. In a tuple, there is one schema node for each item expected in the // array. - void ValidateTuple(ListValue* instance, DictionaryValue* schema, + void ValidateTuple(base::ListValue* instance, base::DictionaryValue* schema, const std::string& path); // Validate a JSON string against a string schema node. - void ValidateString(StringValue* instance, DictionaryValue* schema, + void ValidateString(base::StringValue* instance, + base::DictionaryValue* schema, const std::string& path); // Validate a JSON number against a number schema node. - void ValidateNumber(Value* instance, DictionaryValue* schema, + void ValidateNumber(base::Value* instance, + base::DictionaryValue* schema, const std::string& path); // Validates that the JSON node |instance| has |expected_type|. - bool ValidateType(Value* instance, const std::string& expected_type, + bool ValidateType(base::Value* instance, const std::string& expected_type, const std::string& path); // Returns true if |schema| will allow additional items of any type. bool SchemaAllowsAnyAdditionalItems( - DictionaryValue* schema, DictionaryValue** addition_items_schema); + base::DictionaryValue* schema, + base::DictionaryValue** addition_items_schema); // The root schema node. - DictionaryValue* schema_root_; + base::DictionaryValue* schema_root_; // Map of user-defined name to type. TypeMap types_; diff --git a/chrome/common/json_schema_validator_unittest_base.h b/chrome/common/json_schema_validator_unittest_base.h index 8530a13..6208489 100644 --- a/chrome/common/json_schema_validator_unittest_base.h +++ b/chrome/common/json_schema_validator_unittest_base.h @@ -7,9 +7,11 @@ #include "testing/gtest/include/gtest/gtest.h" +namespace base { class DictionaryValue; class ListValue; class Value; +} // Base class for unit tests for JSONSchemaValidator. There is currently only // one implementation, JSONSchemaValidatorCPPTest. @@ -29,12 +31,14 @@ class JSONSchemaValidatorTestBase : public testing::Test { protected: virtual void ExpectValid(const std::string& test_source, - Value* instance, DictionaryValue* schema, - ListValue* types) = 0; + base::Value* instance, + base::DictionaryValue* schema, + base::ListValue* types) = 0; virtual void ExpectNotValid(const std::string& test_source, - Value* instance, DictionaryValue* schema, - ListValue* types, + base::Value* instance, + base::DictionaryValue* schema, + base::ListValue* types, const std::string& expected_error_path, const std::string& expected_error_message) = 0; diff --git a/chrome/common/jstemplate_builder.h b/chrome/common/jstemplate_builder.h index 0c4fcf8..ae4563b 100644 --- a/chrome/common/jstemplate_builder.h +++ b/chrome/common/jstemplate_builder.h @@ -16,8 +16,8 @@ #include <string> -class DictionaryValue; namespace base { +class DictionaryValue; class StringPiece; } @@ -27,20 +27,20 @@ namespace jstemplate_builder { // string includes the HTML and the javascript code necessary to generate the // full page with support for JsTemplates. std::string GetTemplateHtml(const base::StringPiece& html_template, - const DictionaryValue* json, + const base::DictionaryValue* json, const base::StringPiece& template_id); // A helper function that generates a string of HTML to be loaded. The // string includes the HTML and the javascript code necessary to generate the // full page with support for i18n Templates. std::string GetI18nTemplateHtml(const base::StringPiece& html_template, - const DictionaryValue* json); + const base::DictionaryValue* json); // A helper function that generates a string of HTML to be loaded. The // string includes the HTML and the javascript code necessary to generate the // full page with support for both i18n Templates and JsTemplates. std::string GetTemplatesHtml(const base::StringPiece& html_template, - const DictionaryValue* json, + const base::DictionaryValue* json, const base::StringPiece& template_id); // The following functions build up the different parts that the above @@ -48,11 +48,11 @@ std::string GetTemplatesHtml(const base::StringPiece& html_template, // Appends a script tag with a variable name |templateData| that has the JSON // assigned to it. -void AppendJsonHtml(const DictionaryValue* json, std::string* output); +void AppendJsonHtml(const base::DictionaryValue* json, std::string* output); // Same as AppendJsonHtml(), execpt does not include the <script></script> // tag wrappers. -void AppendJsonJS(const DictionaryValue* json, std::string* output); +void AppendJsonJS(const base::DictionaryValue* json, std::string* output); // Appends the source for JsTemplates in a script tag. void AppendJsTemplateSourceHtml(std::string* output); diff --git a/chrome/common/net/gaia/google_service_auth_error.h b/chrome/common/net/gaia/google_service_auth_error.h index 747df44..74cc11d 100644 --- a/chrome/common/net/gaia/google_service_auth_error.h +++ b/chrome/common/net/gaia/google_service_auth_error.h @@ -27,7 +27,9 @@ #include "googleurl/src/gurl.h" +namespace base { class DictionaryValue; +} class GoogleServiceAuthError { public: @@ -114,7 +116,7 @@ class GoogleServiceAuthError { // Returns info about this object in a dictionary. Caller takes // ownership of returned dictionary. - DictionaryValue* ToValue() const; + base::DictionaryValue* ToValue() const; private: GoogleServiceAuthError(State s, int error); diff --git a/chrome/common/persistent_pref_store.h b/chrome/common/persistent_pref_store.h index 0f007c5..b209716 100644 --- a/chrome/common/persistent_pref_store.h +++ b/chrome/common/persistent_pref_store.h @@ -43,7 +43,7 @@ class PersistentPrefStore : public PrefStore { // Equivalent to PrefStore::GetValue but returns a mutable value. virtual ReadResult GetMutableValue(const std::string& key, - Value** result) = 0; + base::Value** result) = 0; // Triggers a value changed notification. This function needs to be called // if one retrieves a list or dictionary with GetMutableValue and change its @@ -53,13 +53,13 @@ class PersistentPrefStore : public PrefStore { // Sets a |value| for |key| in the store. Assumes ownership of |value|, which // must be non-NULL. - virtual void SetValue(const std::string& key, Value* value) = 0; + virtual void SetValue(const std::string& key, base::Value* value) = 0; // Same as SetValue, but doesn't generate notifications. This is used by // PrefService::GetMutableUserPref() in order to put empty entries // into the user pref store. Using SetValue is not an option since existing // tests rely on the number of notifications generated. - virtual void SetValueSilently(const std::string& key, Value* value) = 0; + virtual void SetValueSilently(const std::string& key, base::Value* value) = 0; // Removes the value for |key|. virtual void RemoveValue(const std::string& key) = 0; diff --git a/chrome/common/pref_store.h b/chrome/common/pref_store.h index eec74e9..bc74af1 100644 --- a/chrome/common/pref_store.h +++ b/chrome/common/pref_store.h @@ -11,7 +11,9 @@ #include "base/basictypes.h" #include "base/memory/ref_counted.h" +namespace base { class Value; +} // This is an abstract interface for reading and writing from/to a persistent // preference store, used by PrefService. An implementation using a JSON file @@ -56,7 +58,7 @@ class PrefStore : public base::RefCounted<PrefStore> { // |result| is only modified if the return value is READ_OK. Ownership of the // |result| value remains with the PrefStore. virtual ReadResult GetValue(const std::string& key, - const Value** result) const = 0; + const base::Value** result) const = 0; protected: friend class base::RefCounted<PrefStore>; diff --git a/chrome/common/web_apps.h b/chrome/common/web_apps.h index 7e7c9cb..4bc5d0a 100644 --- a/chrome/common/web_apps.h +++ b/chrome/common/web_apps.h @@ -19,7 +19,9 @@ class WebDocument; class WebFrame; } +namespace base { class Value; +} // Structure used when installing a web page as an app. struct WebApplicationInfo { @@ -100,7 +102,7 @@ bool ParseWebAppFromWebDocument(WebKit::WebFrame* frame, // Parses |web_app| information out of |definition|. Returns true on success, or // false and |error| on failure. This function assumes that |web_app| has a // valid manifest_url. -bool ParseWebAppFromDefinitionFile(Value* definition, +bool ParseWebAppFromDefinitionFile(base::Value* definition, WebApplicationInfo* web_app, string16* error); diff --git a/chrome/common/web_resource/web_resource_unpacker.h b/chrome/common/web_resource/web_resource_unpacker.h index d438826..4927c64 100644 --- a/chrome/common/web_resource/web_resource_unpacker.h +++ b/chrome/common/web_resource/web_resource_unpacker.h @@ -18,7 +18,9 @@ #include "base/basictypes.h" #include "base/memory/scoped_ptr.h" +namespace base { class DictionaryValue; +} class WebResourceUnpacker { public: @@ -36,7 +38,7 @@ class WebResourceUnpacker { const std::string& error_message() { return error_message_; } // Gets data which has been parsed by Run(). - DictionaryValue* parsed_json() { + base::DictionaryValue* parsed_json() { return parsed_json_.get(); } @@ -45,7 +47,7 @@ class WebResourceUnpacker { std::string resource_data_; // Holds the result of JSON parsing of resource_data_. - scoped_ptr<DictionaryValue> parsed_json_; + scoped_ptr<base::DictionaryValue> parsed_json_; // Holds the last error message produced by Run(). std::string error_message_; diff --git a/chrome/installer/setup/install.h b/chrome/installer/setup/install.h index d05a955..623e343 100644 --- a/chrome/installer/setup/install.h +++ b/chrome/installer/setup/install.h @@ -15,7 +15,6 @@ #include "chrome/installer/util/product.h" #include "chrome/installer/util/util_constants.h" -class DictionaryValue; class FilePath; class WorkItemList; diff --git a/chrome/installer/util/google_chrome_distribution.h b/chrome/installer/util/google_chrome_distribution.h index 637b639..afb22e7 100644 --- a/chrome/installer/util/google_chrome_distribution.h +++ b/chrome/installer/util/google_chrome_distribution.h @@ -15,9 +15,12 @@ #include "chrome/installer/util/browser_distribution.h" #include "chrome/installer/util/util_constants.h" -class DictionaryValue; class FilePath; +namespace base { +class DictionaryValue; +} + class GoogleChromeDistribution : public BrowserDistribution { public: // Opens the Google Chrome uninstall survey window. @@ -115,7 +118,7 @@ class GoogleChromeDistribution : public BrowserDistribution { const FilePath& file_path, std::wstring* uninstall_metrics); // Extracts uninstall metrics from the given JSON value. - virtual bool ExtractUninstallMetrics(const DictionaryValue& root, + virtual bool ExtractUninstallMetrics(const base::DictionaryValue& root, std::wstring* uninstall_metrics); // Given a DictionaryValue containing a set of uninstall metrics, @@ -123,7 +126,7 @@ class GoogleChromeDistribution : public BrowserDistribution { // Returns true if at least one uninstall metric was found in // uninstall_metrics_dict, false otherwise. virtual bool BuildUninstallMetricsString( - DictionaryValue* uninstall_metrics_dict, std::wstring* metrics); + base::DictionaryValue* uninstall_metrics_dict, std::wstring* metrics); // The product ID for Google Update. std::wstring product_guid_; diff --git a/chrome/installer/util/google_chrome_distribution_dummy.cc b/chrome/installer/util/google_chrome_distribution_dummy.cc index 19e2800..b2b83a5 100644 --- a/chrome/installer/util/google_chrome_distribution_dummy.cc +++ b/chrome/installer/util/google_chrome_distribution_dummy.cc @@ -14,6 +14,7 @@ #include "base/file_path.h" #include "base/logging.h" +#include "base/values.h" GoogleChromeDistribution::GoogleChromeDistribution() : BrowserDistribution(CHROME_BROWSER) { diff --git a/chrome/installer/util/master_preferences.h b/chrome/installer/util/master_preferences.h index a0cbfef..a05ae92 100644 --- a/chrome/installer/util/master_preferences.h +++ b/chrome/installer/util/master_preferences.h @@ -16,9 +16,12 @@ #include "base/memory/scoped_ptr.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class FilePath; +namespace base { +class DictionaryValue; +} + namespace installer { // This is the default name for the master preferences file used to pre-set @@ -149,7 +152,7 @@ class MasterPreferences { // } // } // - bool GetExtensionsBlock(DictionaryValue** extensions) const; + bool GetExtensionsBlock(base::DictionaryValue** extensions) const; // Returns true iff the master preferences were successfully read from a file. bool read_from_file() const { @@ -184,8 +187,8 @@ class MasterPreferences { void InitializeFromCommandLine(const CommandLine& cmd_line); protected: - scoped_ptr<DictionaryValue> master_dictionary_; - DictionaryValue* distribution_; + scoped_ptr<base::DictionaryValue> master_dictionary_; + base::DictionaryValue* distribution_; bool preferences_read_from_file_; bool ceee_; bool chrome_; diff --git a/chrome/profile_import/profile_import_thread.h b/chrome/profile_import/profile_import_thread.h index 3347d40..b689ed4 100644 --- a/chrome/profile_import/profile_import_thread.h +++ b/chrome/profile_import/profile_import_thread.h @@ -18,13 +18,13 @@ #include "content/common/child_thread.h" #include "webkit/glue/password_form.h" -class DictionaryValue; class ExternalProcessImporterBridge; class GURL; class Importer; class TemplateURL; namespace base { +class DictionaryValue; class Thread; } @@ -75,7 +75,7 @@ class ProfileImportThread : public ChildThread { void OnImportStart( const importer::SourceProfile& source_profile, uint16 items, - const DictionaryValue& localized_strings); + const base::DictionaryValue& localized_strings); // Calls cleanup to stop the import operation. void OnImportCancel(); diff --git a/chrome/renderer/extensions/event_bindings.h b/chrome/renderer/extensions/event_bindings.h index 0397762..1d69150 100644 --- a/chrome/renderer/extensions/event_bindings.h +++ b/chrome/renderer/extensions/event_bindings.h @@ -12,10 +12,13 @@ class ExtensionDispatcher; class GURL; -class ListValue; class RenderThreadBase; class RenderView; +namespace base { +class ListValue; +} + namespace WebKit { class WebFrame; } @@ -46,7 +49,7 @@ class EventBindings { // v8::Undefined(). A DCHECK is setup to break if it is otherwise. static void CallFunction(const std::string& extension_id, const std::string& function_name, - const ListValue& arguments, + const base::ListValue& arguments, RenderView* render_view, const GURL& event_url); }; diff --git a/chrome/renderer/extensions/extension_dispatcher.h b/chrome/renderer/extensions/extension_dispatcher.h index 8050522..f2ae6fe9 100644 --- a/chrome/renderer/extensions/extension_dispatcher.h +++ b/chrome/renderer/extensions/extension_dispatcher.h @@ -16,12 +16,15 @@ #include "chrome/common/extensions/extension_set.h" class GURL; -class ListValue; class RenderThread; class URLPattern; class UserScriptSlave; struct ExtensionMsg_Loaded_Params; +namespace base { +class ListValue; +} + namespace WebKit { class WebFrame; } @@ -63,7 +66,7 @@ class ExtensionDispatcher : public RenderProcessObserver { void OnMessageInvoke(const std::string& extension_id, const std::string& function_name, - const ListValue& args, + const base::ListValue& args, const GURL& event_url); void OnSetFunctionNames(const std::vector<std::string>& names); void OnLoaded(const ExtensionMsg_Loaded_Params& params); diff --git a/chrome/renderer/extensions/extension_helper.h b/chrome/renderer/extensions/extension_helper.h index 8410602..277b78b 100644 --- a/chrome/renderer/extensions/extension_helper.h +++ b/chrome/renderer/extensions/extension_helper.h @@ -15,10 +15,13 @@ class ExtensionDispatcher; class GURL; -class ListValue; struct ExtensionMsg_ExecuteCode_Params; struct WebApplicationInfo; +namespace base { +class ListValue; +} + namespace webkit_glue { class ResourceFetcher; } @@ -57,7 +60,7 @@ class ExtensionHelper : public RenderViewObserver, const std::string& error); void OnExtensionMessageInvoke(const std::string& extension_id, const std::string& function_name, - const ListValue& args, + const base::ListValue& args, const GURL& event_url); void OnExecuteCode(const ExtensionMsg_ExecuteCode_Params& params); void OnGetApplicationInfo(int page_id); diff --git a/chrome/renderer/localized_error.h b/chrome/renderer/localized_error.h index a5a36c1..f327161 100644 --- a/chrome/renderer/localized_error.h +++ b/chrome/renderer/localized_error.h @@ -10,10 +10,13 @@ #include "base/basictypes.h" -class DictionaryValue; class Extension; class GURL; +namespace base { +class DictionaryValue; +} + namespace WebKit { struct WebURLError; } @@ -23,7 +26,7 @@ class LocalizedError { // Fills |error_strings| with values to be used to build an error page used // on HTTP errors, like 404 or connection reset. static void GetStrings(const WebKit::WebURLError& error, - DictionaryValue* strings); + base::DictionaryValue* strings); // Returns true if an error page exists for the specified parameters. static bool HasStrings(const std::string& error_domain, int error_code); @@ -33,7 +36,7 @@ class LocalizedError { // repost "error page" has no real error associated with it, and doesn't have // enough strings localized to meaningfully fill the net error template. static void GetFormRepostStrings(const GURL& display_url, - DictionaryValue* error_strings); + base::DictionaryValue* error_strings); // Fills |error_strings| with values to be used to build an error page used // on HTTP errors, like 404 or connection reset, but using information from @@ -42,7 +45,7 @@ class LocalizedError { static void GetAppErrorStrings(const WebKit::WebURLError& error, const GURL& display_url, const Extension* app, - DictionaryValue* error_strings); + base::DictionaryValue* error_strings); static const char kHttpErrorDomain[]; diff --git a/chrome/renderer/print_web_view_helper.h b/chrome/renderer/print_web_view_helper.h index ba0d9e5..429829d 100644 --- a/chrome/renderer/print_web_view_helper.h +++ b/chrome/renderer/print_web_view_helper.h @@ -16,11 +16,14 @@ #include "third_party/WebKit/Source/WebKit/chromium/public/WebViewClient.h" #include "ui/gfx/size.h" -class DictionaryValue; struct PrintMsg_Print_Params; struct PrintMsg_PrintPage_Params; struct PrintMsg_PrintPages_Params; +namespace base { +class DictionaryValue; +} + // Class that calls the Begin and End print functions on the frame and changes // the size of the view temporarily to support full page printing.. // Do not serve any events in the time between construction and destruction of @@ -107,14 +110,14 @@ class PrintWebViewHelper : public RenderViewObserver, void OnInitiatePrintPreview(); // Generate a print preview using |settings|. - void OnPrintPreview(const DictionaryValue& settings); + void OnPrintPreview(const base::DictionaryValue& settings); // Print / preview the node under the context menu. void OnPrintNodeUnderContextMenu(); // Print the pages for print preview. Do not display the native print dialog // for user settings. |job_settings| has new print job settings values. - void OnPrintForPrintPreview(const DictionaryValue& job_settings); + void OnPrintForPrintPreview(const base::DictionaryValue& job_settings); void OnPrintingDone(bool success); @@ -124,7 +127,7 @@ class PrintWebViewHelper : public RenderViewObserver, void PrintPreview(WebKit::WebFrame* frame, WebKit::WebNode* node, - const DictionaryValue& settings); + const base::DictionaryValue& settings); enum PrintingResult { OK, @@ -144,7 +147,7 @@ class PrintWebViewHelper : public RenderViewObserver, // Update the current print settings with new |job_settings|. |job_settings| // dictionary contains print job details such as printer name, number of // copies, page range, etc. - bool UpdatePrintSettings(const DictionaryValue& job_settings); + bool UpdatePrintSettings(const base::DictionaryValue& job_settings); // Get final print settings from the user. // Return false if the user cancels or on error. diff --git a/chrome/service/cloud_print/cloud_print_helpers.h b/chrome/service/cloud_print/cloud_print_helpers.h index 6f2034f..5fb73c7 100644 --- a/chrome/service/cloud_print/cloud_print_helpers.h +++ b/chrome/service/cloud_print/cloud_print_helpers.h @@ -12,10 +12,13 @@ #include "chrome/service/cloud_print/print_system.h" #include "googleurl/src/gurl.h" -class DictionaryValue; class Task; class URLFetcher; +namespace base { +class DictionaryValue; +} + // Helper methods for the cloud print proxy code. class CloudPrintHelpers { public: @@ -47,7 +50,8 @@ class CloudPrintHelpers { // value returns the value of the "success" value in the response JSON. // Returns the response as a dictionary value. static bool ParseResponseJSON(const std::string& response_data, - bool* succeeded, DictionaryValue** response_dict); + bool* succeeded, + base::DictionaryValue** response_dict); // Prepares one value as part of a multi-part upload request. static void AddMultipartValueForUpload( @@ -72,4 +76,3 @@ class CloudPrintHelpers { }; #endif // CHROME_SERVICE_CLOUD_PRINT_CLOUD_PRINT_HELPERS_H_ - diff --git a/chrome/service/cloud_print/cloud_print_proxy_backend.h b/chrome/service/cloud_print/cloud_print_proxy_backend.h index 603d4cd..8841ade 100644 --- a/chrome/service/cloud_print/cloud_print_proxy_backend.h +++ b/chrome/service/cloud_print/cloud_print_proxy_backend.h @@ -13,7 +13,10 @@ class CloudPrintProxyService; class GURL; + +namespace base { class DictionaryValue; +} namespace gaia { struct OAuthClientInfo; @@ -56,7 +59,7 @@ class CloudPrintProxyBackend { CloudPrintProxyBackend( CloudPrintProxyFrontend* frontend, const GURL& cloud_print_server_url, - const DictionaryValue* print_sys_settings, + const base::DictionaryValue* print_sys_settings, const gaia::OAuthClientInfo& oauth_client_info, bool enable_job_poll); ~CloudPrintProxyBackend(); diff --git a/chrome/service/cloud_print/cloud_print_url_fetcher.h b/chrome/service/cloud_print/cloud_print_url_fetcher.h index 0abb3d7..f6f3680 100644 --- a/chrome/service/cloud_print/cloud_print_url_fetcher.h +++ b/chrome/service/cloud_print/cloud_print_url_fetcher.h @@ -11,9 +11,12 @@ #include "base/memory/scoped_ptr.h" #include "content/common/url_fetcher.h" -class DictionaryValue; class GURL; +namespace base { +class DictionaryValue; +} + namespace net { class URLRequestStatus; } // namespace net @@ -65,7 +68,7 @@ class CloudPrintURLFetcher // |succeeded| is the value of the "success" field in the response JSON. virtual ResponseAction HandleJSONData(const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded) { return CONTINUE_PROCESSING; } diff --git a/chrome/service/cloud_print/cloud_print_url_fetcher_unittest.cc b/chrome/service/cloud_print/cloud_print_url_fetcher_unittest.cc index 9fd4318..fccb2ec 100644 --- a/chrome/service/cloud_print/cloud_print_url_fetcher_unittest.cc +++ b/chrome/service/cloud_print/cloud_print_url_fetcher_unittest.cc @@ -7,6 +7,7 @@ #include "base/message_loop_proxy.h" #include "base/synchronization/waitable_event.h" #include "base/threading/thread.h" +#include "base/values.h" #include "chrome/service/cloud_print/cloud_print_url_fetcher.h" #include "chrome/service/service_process.h" #include "googleurl/src/gurl.h" diff --git a/chrome/service/cloud_print/job_status_updater.cc b/chrome/service/cloud_print/job_status_updater.cc index 2f16536..6182ba6 100644 --- a/chrome/service/cloud_print/job_status_updater.cc +++ b/chrome/service/cloud_print/job_status_updater.cc @@ -7,6 +7,7 @@ #include "base/json/json_reader.h" #include "base/string_util.h" #include "base/utf_string_conversions.h" +#include "base/values.h" #include "chrome/common/net/http_return.h" #include "chrome/service/cloud_print/cloud_print_consts.h" #include "chrome/service/cloud_print/cloud_print_helpers.h" diff --git a/chrome/service/cloud_print/job_status_updater.h b/chrome/service/cloud_print/job_status_updater.h index cece13a..c5b2de5 100644 --- a/chrome/service/cloud_print/job_status_updater.h +++ b/chrome/service/cloud_print/job_status_updater.h @@ -48,7 +48,7 @@ class JobStatusUpdater : public base::RefCountedThreadSafe<JobStatusUpdater>, virtual CloudPrintURLFetcher::ResponseAction HandleJSONData( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); virtual void OnRequestAuthError(); diff --git a/chrome/service/cloud_print/print_system.h b/chrome/service/cloud_print/print_system.h index cba16c3..b922c52 100644 --- a/chrome/service/cloud_print/print_system.h +++ b/chrome/service/cloud_print/print_system.h @@ -15,9 +15,12 @@ #include "printing/backend/print_backend.h" -class DictionaryValue; class FilePath; +namespace base { +class DictionaryValue; +} + namespace printing { class PrintBackend; struct PrinterBasicInfo; @@ -197,7 +200,7 @@ class PrintSystem : public base::RefCountedThreadSafe<PrintSystem> { // If print settings are NULL, default settings will be used. // Return NULL if no print system available. static scoped_refptr<PrintSystem> CreateInstance( - const DictionaryValue* print_system_settings); + const base::DictionaryValue* print_system_settings); }; diff --git a/chrome/service/cloud_print/print_system_dummy.cc b/chrome/service/cloud_print/print_system_dummy.cc index ea3fac1..1db2286 100644 --- a/chrome/service/cloud_print/print_system_dummy.cc +++ b/chrome/service/cloud_print/print_system_dummy.cc @@ -18,11 +18,10 @@ std::string PrintSystem::GenerateProxyId() { } scoped_refptr<PrintSystem> PrintSystem::CreateInstance( - const DictionaryValue* print_system_settings) { + const base::DictionaryValue* print_system_settings) { NOTREACHED(); return NULL; } } // namespace cloud_print #endif // CP_PRINT_SYSTEM_AVAILABLE - diff --git a/chrome/service/cloud_print/print_system_win.cc b/chrome/service/cloud_print/print_system_win.cc index 84ad4929..d1cb33c 100644 --- a/chrome/service/cloud_print/print_system_win.cc +++ b/chrome/service/cloud_print/print_system_win.cc @@ -864,7 +864,7 @@ std::string PrintSystem::GenerateProxyId() { } scoped_refptr<PrintSystem> PrintSystem::CreateInstance( - const DictionaryValue* print_system_settings) { + const base::DictionaryValue* print_system_settings) { return new PrintSystemWin; } diff --git a/chrome/service/cloud_print/printer_job_handler.h b/chrome/service/cloud_print/printer_job_handler.h index 12e19df..f01d74d 100644 --- a/chrome/service/cloud_print/printer_job_handler.h +++ b/chrome/service/cloud_print/printer_job_handler.h @@ -140,7 +140,7 @@ class PrinterJobHandler : public base::RefCountedThreadSafe<PrinterJobHandler>, virtual CloudPrintURLFetcher::ResponseAction HandleJSONData( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); virtual void OnRequestGiveUp(); virtual void OnRequestAuthError(); @@ -166,7 +166,7 @@ class PrinterJobHandler : public base::RefCountedThreadSafe<PrinterJobHandler>, typedef CloudPrintURLFetcher::ResponseAction (PrinterJobHandler::*JSONDataHandler)(const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); // Prototype for a data handler. typedef CloudPrintURLFetcher::ResponseAction @@ -177,19 +177,19 @@ class PrinterJobHandler : public base::RefCountedThreadSafe<PrinterJobHandler>, CloudPrintURLFetcher::ResponseAction HandlePrinterUpdateResponse( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); CloudPrintURLFetcher::ResponseAction HandlePrinterDeleteResponse( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); CloudPrintURLFetcher::ResponseAction HandleJobMetadataResponse( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); CloudPrintURLFetcher::ResponseAction HandlePrintTicketResponse( @@ -205,13 +205,13 @@ class PrinterJobHandler : public base::RefCountedThreadSafe<PrinterJobHandler>, CloudPrintURLFetcher::ResponseAction HandleSuccessStatusUpdateResponse( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); CloudPrintURLFetcher::ResponseAction HandleFailureStatusUpdateResponse( const URLFetcher* source, const GURL& url, - DictionaryValue* json_data, + base::DictionaryValue* json_data, bool succeeded); // End request handlers for each state in the state machine diff --git a/chrome/service/service_process_prefs.h b/chrome/service/service_process_prefs.h index 6816f50..e5aecde 100644 --- a/chrome/service/service_process_prefs.h +++ b/chrome/service/service_process_prefs.h @@ -10,6 +10,10 @@ #include "chrome/common/json_pref_store.h" +namespace base { +class DictionaryValue; +} + // Manages persistent preferences for the service process. This is basically a // thin wrapper around JsonPrefStore for more comfortable use. class ServiceProcessPrefs { @@ -39,7 +43,8 @@ class ServiceProcessPrefs { void SetBoolean(const std::string& key, bool value); // Get a dictionary preference for |key| and store it in |result|. - void GetDictionary(const std::string& key, const DictionaryValue** result); + void GetDictionary(const std::string& key, + const base::DictionaryValue** result); // Removes the pref specified by |key|. void RemovePref(const std::string& key); diff --git a/chrome/test/automation/automation_json_requests.h b/chrome/test/automation/automation_json_requests.h index be7a5bb..a095a92 100644 --- a/chrome/test/automation/automation_json_requests.h +++ b/chrome/test/automation/automation_json_requests.h @@ -17,9 +17,12 @@ class AutomationMessageSender; class FilePath; class GURL; + +namespace base { class DictionaryValue; class ListValue; class Value; +} struct WebKeyEvent { WebKeyEvent(automation::KeyEventTypes type, @@ -91,7 +94,7 @@ bool SendExecuteJavascriptJSONRequest( int tab_index, const std::string& frame_xpath, const std::string& javascript, - Value** result, + base::Value** result, std::string* error_msg) WARN_UNUSED_RESULT; // Requests the specified tab to go forward. Waits for the load to complete. @@ -150,7 +153,7 @@ bool SendGetTabTitleJSONRequest( bool SendGetCookiesJSONRequest( AutomationMessageSender* sender, const std::string& url, - ListValue** cookies, + base::ListValue** cookies, std::string* error_msg) WARN_UNUSED_RESULT; // Requests all the cookies for the given URL. Returns true on success. @@ -185,7 +188,7 @@ bool SendDeleteCookieJSONRequestDeprecated( bool SendSetCookieJSONRequest( AutomationMessageSender* sender, const std::string& url, - DictionaryValue* cookie_dict, + base::DictionaryValue* cookie_dict, std::string* error_msg) WARN_UNUSED_RESULT; // Requests setting the given cookie for the given URL. Returns true on diff --git a/chrome/test/automation/tab_proxy.h b/chrome/test/automation/tab_proxy.h index d2c7e87..f4b89d5 100644 --- a/chrome/test/automation/tab_proxy.h +++ b/chrome/test/automation/tab_proxy.h @@ -29,11 +29,14 @@ class BrowserProxy; class GURL; -class Value; namespace IPC { class Message; } +namespace base { +class Value; +} + class TabProxy : public AutomationResourceProxy, public JavaScriptExecutionController { public: @@ -87,7 +90,7 @@ class TabProxy : public AutomationResourceProxy, int* value) WARN_UNUSED_RESULT; bool ExecuteAndExtractValue(const std::wstring& frame_xpath, const std::wstring& jscript, - Value** value) WARN_UNUSED_RESULT; + base::Value** value) WARN_UNUSED_RESULT; // Returns a DOMElementProxyRef to the tab's current DOM document. // This proxy is invalidated when the document changes. diff --git a/chrome/test/live_sync/live_preferences_sync_test.h b/chrome/test/live_sync/live_preferences_sync_test.h index e961aeb..2d0f8b9 100644 --- a/chrome/test/live_sync/live_preferences_sync_test.h +++ b/chrome/test/live_sync/live_preferences_sync_test.h @@ -64,7 +64,7 @@ class LivePreferencesSyncTest : public LiveSyncTest { // |verifier| if DisableVerifier() hasn't been called. void ChangeListPref(int index, const char* pref_name, - const ListValue& new_value); + const base::ListValue& new_value); // Used to verify that the boolean preference with name |pref_name| has the // same value across all profiles. Also checks |verifier| if DisableVerifier() diff --git a/chrome/test/ui/ui_test.h b/chrome/test/ui/ui_test.h index 6dc0c7d..a0f4ec6 100644 --- a/chrome/test/ui/ui_test.h +++ b/chrome/test/ui/ui_test.h @@ -31,12 +31,15 @@ class AutomationProxy; class BrowserProxy; -class DictionaryValue; class FilePath; class GURL; class ScopedTempDir; class TabProxy; +namespace base { +class DictionaryValue; +} + // Base class for UI Tests. This implements the core of the functions. // This base class decouples all automation functionality from testing // infrastructure, for use without gtest. @@ -376,12 +379,12 @@ class UITest : public UITestBase, public PlatformTest { // Returns a copy of local state preferences. The caller is responsible for // deleting the returned object. Returns NULL if there is an error. - DictionaryValue* GetLocalState(); + base::DictionaryValue* GetLocalState(); // Returns a copy of the default profile preferences. The caller is // responsible for deleting the returned object. Returns NULL if there is an // error. - DictionaryValue* GetDefaultProfilePreferences(); + base::DictionaryValue* GetDefaultProfilePreferences(); // Waits for the test case to finish. // ASSERTS if there are test failures. diff --git a/chrome/test/ui_test_utils.h b/chrome/test/ui_test_utils.h index a01cdae..f89f392 100644 --- a/chrome/test/ui_test_utils.h +++ b/chrome/test/ui_test_utils.h @@ -44,7 +44,6 @@ class ScopedTempDir; class SkBitmap; class TabContents; class TabContentsWrapper; -class Value; namespace gfx { class Size; diff --git a/chrome/test/values_test_util.h b/chrome/test/values_test_util.h index a1baf28..0e9b948 100644 --- a/chrome/test/values_test_util.h +++ b/chrome/test/values_test_util.h @@ -8,9 +8,11 @@ #include <string> +namespace base { class DictionaryValue; class ListValue; class StringValue; +} namespace test { @@ -18,27 +20,28 @@ namespace test { // the given dictionary equals the given expected value. void ExpectDictBooleanValue(bool expected_value, - const DictionaryValue& value, + const base::DictionaryValue& value, const std::string& key); -void ExpectDictDictionaryValue(const DictionaryValue& expected_value, - const DictionaryValue& value, +void ExpectDictDictionaryValue(const base::DictionaryValue& expected_value, + const base::DictionaryValue& value, const std::string& key); void ExpectDictIntegerValue(int expected_value, - const DictionaryValue& value, + const base::DictionaryValue& value, const std::string& key); -void ExpectDictListValue(const ListValue& expected_value, - const DictionaryValue& value, +void ExpectDictListValue(const base::ListValue& expected_value, + const base::DictionaryValue& value, const std::string& key); void ExpectDictStringValue(const std::string& expected_value, - const DictionaryValue& value, + const base::DictionaryValue& value, const std::string& key); // Takes ownership of |actual|. -void ExpectStringValue(const std::string& expected_str, StringValue* actual); +void ExpectStringValue(const std::string& expected_str, + base::StringValue* actual); } // namespace test diff --git a/chrome/test/webdriver/automation.h b/chrome/test/webdriver/automation.h index 6d3ffc0..5e2bec9 100644 --- a/chrome/test/webdriver/automation.h +++ b/chrome/test/webdriver/automation.h @@ -18,13 +18,16 @@ class AutomationProxy; class CommandLine; -class DictionaryValue; class FilePath; class GURL; -class ListValue; class ProxyLauncher; struct WebKeyEvent; +namespace base { +class DictionaryValue; +class ListValue; +} + namespace gfx { class Point; } @@ -92,7 +95,9 @@ class Automation { void GoBack(int tab_id, Error** error); void Reload(int tab_id, Error** error); - void GetCookies(const std::string& url, ListValue** cookies, Error** error); + void GetCookies(const std::string& url, + base::ListValue** cookies, + Error** error); void GetCookiesDeprecated( int tab_id, const GURL& gurl, std::string* cookies, bool* success); void DeleteCookie(const std::string& url, @@ -102,8 +107,9 @@ class Automation { const GURL& gurl, const std::string& cookie_name, bool* success); - void SetCookie( - const std::string& url, DictionaryValue* cookie_dict, Error** error); + void SetCookie(const std::string& url, + base::DictionaryValue* cookie_dict, + Error** error); void SetCookieDeprecated( int tab_id, const GURL& gurl, const std::string& cookie, bool* success); diff --git a/chrome/test/webdriver/commands/alert_commands.h b/chrome/test/webdriver/commands/alert_commands.h index 48c30a5..cc5c049 100644 --- a/chrome/test/webdriver/commands/alert_commands.h +++ b/chrome/test/webdriver/commands/alert_commands.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -20,7 +22,7 @@ class Response; class AlertTextCommand : public WebDriverCommand { public: AlertTextCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~AlertTextCommand(); virtual bool DoesGet(); @@ -35,7 +37,7 @@ class AlertTextCommand : public WebDriverCommand { class AcceptAlertCommand : public WebDriverCommand { public: AcceptAlertCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~AcceptAlertCommand(); virtual bool DoesPost(); @@ -48,7 +50,7 @@ class AcceptAlertCommand : public WebDriverCommand { class DismissAlertCommand : public WebDriverCommand { public: DismissAlertCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~DismissAlertCommand(); virtual bool DoesPost(); diff --git a/chrome/test/webdriver/commands/cookie_commands.h b/chrome/test/webdriver/commands/cookie_commands.h index ab0fbb5..10d23d4 100644 --- a/chrome/test/webdriver/commands/cookie_commands.h +++ b/chrome/test/webdriver/commands/cookie_commands.h @@ -12,7 +12,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" #include "googleurl/src/gurl.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -25,7 +27,7 @@ class Response; class CookieCommand : public WebDriverCommand { public: CookieCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~CookieCommand(); virtual bool Init(Response* const response); @@ -51,7 +53,7 @@ class CookieCommand : public WebDriverCommand { class NamedCookieCommand : public WebDriverCommand { public: NamedCookieCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~NamedCookieCommand(); virtual bool Init(Response* const response); diff --git a/chrome/test/webdriver/commands/execute_async_script_command.h b/chrome/test/webdriver/commands/execute_async_script_command.h index 70ac769..40c75b8 100644 --- a/chrome/test/webdriver/commands/execute_async_script_command.h +++ b/chrome/test/webdriver/commands/execute_async_script_command.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -24,7 +26,7 @@ class Response; class ExecuteAsyncScriptCommand : public WebDriverCommand { public: ExecuteAsyncScriptCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ExecuteAsyncScriptCommand(); virtual bool DoesPost(); @@ -37,4 +39,3 @@ class ExecuteAsyncScriptCommand : public WebDriverCommand { } // namespace webdriver #endif // CHROME_TEST_WEBDRIVER_COMMANDS_EXECUTE_ASYNC_SCRIPT_COMMAND_H_ - diff --git a/chrome/test/webdriver/commands/mouse_commands.h b/chrome/test/webdriver/commands/mouse_commands.h index af1deec..0b8360b 100644 --- a/chrome/test/webdriver/commands/mouse_commands.h +++ b/chrome/test/webdriver/commands/mouse_commands.h @@ -11,7 +11,9 @@ #include "chrome/test/webdriver/commands/webelement_commands.h" #include "chrome/test/webdriver/web_element_id.h" +namespace base { class DictionaryValue; +} namespace gfx { class Point; @@ -27,7 +29,7 @@ class Response; class MoveAndClickCommand : public WebElementCommand { public: MoveAndClickCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~MoveAndClickCommand(); virtual bool DoesPost(); @@ -42,7 +44,7 @@ class MoveAndClickCommand : public WebElementCommand { class HoverCommand : public WebElementCommand { public: HoverCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~HoverCommand(); virtual bool DoesPost(); @@ -58,7 +60,7 @@ class HoverCommand : public WebElementCommand { class DragCommand : public WebElementCommand { public: DragCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~DragCommand(); virtual bool Init(Response* const response); @@ -80,7 +82,7 @@ class DragCommand : public WebElementCommand { class AdvancedMouseCommand : public WebDriverCommand { public: AdvancedMouseCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~AdvancedMouseCommand(); virtual bool DoesPost(); @@ -97,7 +99,7 @@ class AdvancedMouseCommand : public WebDriverCommand { class MoveToCommand : public AdvancedMouseCommand { public: MoveToCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~MoveToCommand(); virtual bool Init(Response* const response); @@ -121,7 +123,7 @@ class MoveToCommand : public AdvancedMouseCommand { class ClickCommand : public AdvancedMouseCommand { public: ClickCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ClickCommand(); virtual bool Init(Response* const response); @@ -141,7 +143,7 @@ class ClickCommand : public AdvancedMouseCommand { class ButtonDownCommand : public AdvancedMouseCommand { public: ButtonDownCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ButtonDownCommand(); virtual void ExecutePost(Response* const response); @@ -157,7 +159,7 @@ class ButtonDownCommand : public AdvancedMouseCommand { class ButtonUpCommand : public AdvancedMouseCommand { public: ButtonUpCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ButtonUpCommand(); virtual void ExecutePost(Response* const response); @@ -171,7 +173,7 @@ class ButtonUpCommand : public AdvancedMouseCommand { class DoubleClickCommand : public AdvancedMouseCommand { public: DoubleClickCommand(const std::vector<std::string>& ps, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~DoubleClickCommand(); virtual void ExecutePost(Response* const response); diff --git a/chrome/test/webdriver/commands/screenshot_command.h b/chrome/test/webdriver/commands/screenshot_command.h index a00da3e..5fe8bdf 100644 --- a/chrome/test/webdriver/commands/screenshot_command.h +++ b/chrome/test/webdriver/commands/screenshot_command.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -21,7 +23,7 @@ class Response; class ScreenshotCommand : public WebDriverCommand { public: ScreenshotCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ScreenshotCommand(); virtual bool DoesGet(); @@ -34,4 +36,3 @@ class ScreenshotCommand : public WebDriverCommand { } // namespace webdriver #endif // CHROME_TEST_WEBDRIVER_COMMANDS_SCREENSHOT_COMMAND_H_ - diff --git a/chrome/test/webdriver/commands/set_timeout_commands.h b/chrome/test/webdriver/commands/set_timeout_commands.h index 5325fb3..88f79cb 100644 --- a/chrome/test/webdriver/commands/set_timeout_commands.h +++ b/chrome/test/webdriver/commands/set_timeout_commands.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -19,7 +21,7 @@ class Response; class SetTimeoutCommand : public WebDriverCommand { public: SetTimeoutCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~SetTimeoutCommand(); virtual bool DoesPost(); @@ -34,7 +36,7 @@ class SetTimeoutCommand : public WebDriverCommand { class SetAsyncScriptTimeoutCommand : public SetTimeoutCommand { public: SetAsyncScriptTimeoutCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~SetAsyncScriptTimeoutCommand(); virtual void SetTimeout(int timeout_ms); @@ -46,7 +48,7 @@ class SetAsyncScriptTimeoutCommand : public SetTimeoutCommand { class ImplicitWaitCommand : public SetTimeoutCommand { public: ImplicitWaitCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~ImplicitWaitCommand(); virtual void SetTimeout(int timeout_ms); @@ -57,4 +59,3 @@ class ImplicitWaitCommand : public SetTimeoutCommand { } // namespace webdriver #endif // CHROME_TEST_WEBDRIVER_COMMANDS_SET_TIMEOUT_COMMANDS_H_ - diff --git a/chrome/test/webdriver/commands/source_command.h b/chrome/test/webdriver/commands/source_command.h index 0248d34..7444009 100644 --- a/chrome/test/webdriver/commands/source_command.h +++ b/chrome/test/webdriver/commands/source_command.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -21,7 +23,7 @@ class Response; class SourceCommand : public WebDriverCommand { public: SourceCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~SourceCommand(); virtual bool DoesGet(); diff --git a/chrome/test/webdriver/commands/target_locator_commands.h b/chrome/test/webdriver/commands/target_locator_commands.h index 6ab3a6c..1580a42 100644 --- a/chrome/test/webdriver/commands/target_locator_commands.h +++ b/chrome/test/webdriver/commands/target_locator_commands.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -22,7 +24,7 @@ class WebElementId; class WindowHandleCommand : public WebDriverCommand { public: WindowHandleCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~WindowHandleCommand(); virtual bool DoesGet(); @@ -37,7 +39,7 @@ class WindowHandleCommand : public WebDriverCommand { class WindowHandlesCommand : public WebDriverCommand { public: WindowHandlesCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~WindowHandlesCommand(); virtual bool DoesGet(); @@ -53,7 +55,7 @@ class WindowHandlesCommand : public WebDriverCommand { class WindowCommand : public WebDriverCommand { public: WindowCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~WindowCommand(); virtual bool DoesPost(); @@ -70,7 +72,7 @@ class WindowCommand : public WebDriverCommand { class SwitchFrameCommand : public WebDriverCommand { public: SwitchFrameCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~SwitchFrameCommand(); virtual bool DoesPost(); @@ -86,7 +88,7 @@ class SwitchFrameCommand : public WebDriverCommand { class ActiveElementCommand : public WebDriverCommand { public: ActiveElementCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ActiveElementCommand(); virtual bool DoesPost(); diff --git a/chrome/test/webdriver/commands/webdriver_command.h b/chrome/test/webdriver/commands/webdriver_command.h index c4e759d..248aa58 100644 --- a/chrome/test/webdriver/commands/webdriver_command.h +++ b/chrome/test/webdriver/commands/webdriver_command.h @@ -10,7 +10,9 @@ #include "chrome/test/webdriver/commands/command.h" +namespace base { class DictionaryValue; +} namespace webdriver { @@ -26,7 +28,7 @@ class Session; class WebDriverCommand : public Command { public: WebDriverCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~WebDriverCommand(); // Initializes this webdriver command by fetching the command session. diff --git a/chrome/test/webdriver/commands/webelement_commands.h b/chrome/test/webdriver/commands/webelement_commands.h index 634bdc7..676402b 100644 --- a/chrome/test/webdriver/commands/webelement_commands.h +++ b/chrome/test/webdriver/commands/webelement_commands.h @@ -11,7 +11,9 @@ #include "chrome/test/webdriver/commands/webdriver_command.h" #include "chrome/test/webdriver/web_element_id.h" +namespace base { class DictionaryValue; +} namespace gfx { class Point; @@ -27,7 +29,7 @@ class Response; class WebElementCommand : public WebDriverCommand { public: WebElementCommand(const std::vector<std::string>& path_segments, - const DictionaryValue* const parameters); + const base::DictionaryValue* const parameters); virtual ~WebElementCommand(); virtual bool Init(Response* const response); @@ -45,7 +47,7 @@ class WebElementCommand : public WebDriverCommand { class ElementAttributeCommand : public WebElementCommand { public: ElementAttributeCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementAttributeCommand(); virtual bool DoesGet(); @@ -60,7 +62,7 @@ class ElementAttributeCommand : public WebElementCommand { class ElementClearCommand : public WebElementCommand { public: ElementClearCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementClearCommand(); virtual bool DoesPost(); @@ -75,7 +77,7 @@ class ElementClearCommand : public WebElementCommand { class ElementCssCommand : public WebElementCommand { public: ElementCssCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementCssCommand(); virtual bool DoesGet(); @@ -90,7 +92,7 @@ class ElementCssCommand : public WebElementCommand { class ElementDisplayedCommand : public WebElementCommand { public: ElementDisplayedCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementDisplayedCommand(); virtual bool DoesGet(); @@ -105,7 +107,7 @@ class ElementDisplayedCommand : public WebElementCommand { class ElementEnabledCommand : public WebElementCommand { public: ElementEnabledCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementEnabledCommand(); virtual bool DoesGet(); @@ -120,7 +122,7 @@ class ElementEnabledCommand : public WebElementCommand { class ElementEqualsCommand : public WebElementCommand { public: ElementEqualsCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementEqualsCommand(); virtual bool DoesGet(); @@ -135,7 +137,7 @@ class ElementEqualsCommand : public WebElementCommand { class ElementLocationCommand : public WebElementCommand { public: ElementLocationCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementLocationCommand(); virtual bool DoesGet(); @@ -151,7 +153,7 @@ class ElementLocationCommand : public WebElementCommand { class ElementLocationInViewCommand : public WebElementCommand { public: ElementLocationInViewCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementLocationInViewCommand(); virtual bool DoesGet(); @@ -166,7 +168,7 @@ class ElementLocationInViewCommand : public WebElementCommand { class ElementNameCommand : public WebElementCommand { public: ElementNameCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementNameCommand(); virtual bool DoesGet(); @@ -182,7 +184,7 @@ class ElementNameCommand : public WebElementCommand { class ElementSelectedCommand : public WebElementCommand { public: ElementSelectedCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementSelectedCommand(); virtual bool DoesGet(); @@ -199,7 +201,7 @@ class ElementSelectedCommand : public WebElementCommand { class ElementSizeCommand : public WebElementCommand { public: ElementSizeCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementSizeCommand(); virtual bool DoesGet(); @@ -214,7 +216,7 @@ class ElementSizeCommand : public WebElementCommand { class ElementSubmitCommand : public WebElementCommand { public: ElementSubmitCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementSubmitCommand(); virtual bool DoesPost(); @@ -229,7 +231,7 @@ class ElementSubmitCommand : public WebElementCommand { class ElementToggleCommand : public WebElementCommand { public: ElementToggleCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementToggleCommand(); virtual bool DoesPost(); @@ -245,7 +247,7 @@ class ElementToggleCommand : public WebElementCommand { class ElementValueCommand : public WebElementCommand { public: ElementValueCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementValueCommand(); virtual bool DoesGet(); @@ -269,7 +271,7 @@ class ElementValueCommand : public WebElementCommand { class ElementTextCommand : public WebElementCommand { public: ElementTextCommand(const std::vector<std::string>& path_segments, - DictionaryValue* parameters); + base::DictionaryValue* parameters); virtual ~ElementTextCommand(); virtual bool DoesGet(); diff --git a/chrome/test/webdriver/dispatch.h b/chrome/test/webdriver/dispatch.h index b3d2fd0..8454fbb 100644 --- a/chrome/test/webdriver/dispatch.h +++ b/chrome/test/webdriver/dispatch.h @@ -13,9 +13,8 @@ #include "chrome/test/webdriver/commands/response.h" #include "third_party/mongoose/mongoose.h" -class DictionaryValue; - namespace base { +class DictionaryValue; class WaitableEvent; } @@ -43,7 +42,7 @@ void SendResponse(struct mg_connection* const connection, bool ParseRequestInfo(const struct mg_request_info* const request_info, std::string* method, std::vector<std::string>* path_segments, - DictionaryValue** parameters, + base::DictionaryValue** parameters, Response* const response); // Allows the bulk of the implementation of |Dispatch| to be moved out of this @@ -62,7 +61,7 @@ void Dispatch(struct mg_connection* connection, void* user_data) { std::string method; std::vector<std::string> path_segments; - DictionaryValue* parameters = NULL; + base::DictionaryValue* parameters = NULL; Response response; if (internal::ParseRequestInfo(request_info, &method, diff --git a/chrome/test/webdriver/session.h b/chrome/test/webdriver/session.h index 948642a..3842f00 100644 --- a/chrome/test/webdriver/session.h +++ b/chrome/test/webdriver/session.h @@ -20,13 +20,13 @@ #include "ui/gfx/point.h" class CommandLine; -class DictionaryValue; class FilePath; class GURL; -class ListValue; -class Value; namespace base { +class DictionaryValue; +class ListValue; +class Value; class WaitableEvent; } @@ -77,13 +77,13 @@ class Session { // |value|, which is set only if there is no error. Error* ExecuteScript(const FrameId& frame_id, const std::string& script, - const ListValue* const args, - Value** value); + const base::ListValue* const args, + base::Value** value); // Same as above, but uses the currently targeted window and frame. Error* ExecuteScript(const std::string& script, - const ListValue* const args, - Value** value); + const base::ListValue* const args, + base::Value** value); // Executes given |script| in the context of the given frame. // The |script| should be in the form of a function body @@ -92,8 +92,8 @@ class Session { // |value|, which is set only if there is no error. Error* ExecuteAsyncScript(const FrameId& frame_id, const std::string& script, - const ListValue* const args, - Value** value); + const base::ListValue* const args, + base::Value** value); // Send the given keys to the given element dictionary. This function takes // ownership of |element|. @@ -122,14 +122,14 @@ class Session { Error* GetTitle(std::string* tab_title); Error* GetScreenShot(std::string* png); - Error* GetCookies(const std::string& url, ListValue** cookies); + Error* GetCookies(const std::string& url, base::ListValue** cookies); bool GetCookiesDeprecated(const GURL& url, std::string* cookies); bool GetCookieByNameDeprecated(const GURL& url, const std::string& cookie_name, std::string* cookie); Error* DeleteCookie(const std::string& url, const std::string& cookie_name); bool DeleteCookieDeprecated(const GURL& url, const std::string& cookie_name); - Error* SetCookie(const std::string& url, DictionaryValue* cookie_dict); + Error* SetCookie(const std::string& url, base::DictionaryValue* cookie_dict); bool SetCookieDeprecated(const GURL& url, const std::string& cookie); // Gets all the currently existing window IDs. Returns true on success. @@ -268,7 +268,7 @@ class Session { // Gets the attribute of the given element. If there are no errors, the // function sets |value| and the caller takes ownership. Error* GetAttribute(const WebElementId& element, const std::string& key, - Value** value); + base::Value** value); // Waits for all tabs to stop loading. Returns true on success. Error* WaitForAllTabsToStopLoading(); @@ -306,12 +306,12 @@ class Session { // The caller is responsible for the script result |value|. Error* ExecuteScriptAndParseResponse(const FrameId& frame_id, const std::string& script, - Value** value); + base::Value** value); void SendKeysOnSessionThread(const string16& keys, Error** error); Error* SwitchToFrameWithJavaScriptLocatedFrame( const std::string& script, - ListValue* args); + base::ListValue* args); Error* FindElementsHelper(const FrameId& frame_id, const WebElementId& root_element, const std::string& locator, diff --git a/chrome/test/webdriver/utility_functions.cc b/chrome/test/webdriver/utility_functions.cc index 2d4cb6f..b6af918 100644 --- a/chrome/test/webdriver/utility_functions.cc +++ b/chrome/test/webdriver/utility_functions.cc @@ -9,6 +9,7 @@ #include "base/json/json_writer.h" #include "base/rand_util.h" #include "base/stringprintf.h" +#include "base/values.h" namespace webdriver { diff --git a/chrome/test/webdriver/utility_functions.h b/chrome/test/webdriver/utility_functions.h index b0a449d..701c2703 100644 --- a/chrome/test/webdriver/utility_functions.h +++ b/chrome/test/webdriver/utility_functions.h @@ -7,7 +7,9 @@ #include <string> +namespace base { class Value; +} namespace webdriver { @@ -15,7 +17,7 @@ namespace webdriver { std::string GenerateRandomID(); // Returns the equivalent JSON string for the given value. -std::string JsonStringify(const Value* value); +std::string JsonStringify(const base::Value* value); } // namespace webdriver diff --git a/chrome/test/webdriver/web_element_id.h b/chrome/test/webdriver/web_element_id.h index 55cfd8a..037f633 100644 --- a/chrome/test/webdriver/web_element_id.h +++ b/chrome/test/webdriver/web_element_id.h @@ -8,7 +8,9 @@ #include <string> +namespace base { class Value; +} namespace webdriver { @@ -25,13 +27,13 @@ class WebElementId { // Creates a |WebElementId| from an element dictionary returned by a WebDriver // atom. It will be valid iff the dictionary is correctly constructed. - explicit WebElementId(Value* value); + explicit WebElementId(base::Value* value); ~WebElementId(); // Returns the appropriate |Value| type to be used to identify the element // to a WebDriver atom. The client takes ownership. - Value* ToValue() const; + base::Value* ToValue() const; // Returns whether this ID is valid. Even if the ID is valid, it may not refer // to a valid ID on the page. diff --git a/content/browser/debugger/debugger_host.h b/content/browser/debugger/debugger_host.h index 493fde6..44482d5 100644 --- a/content/browser/debugger/debugger_host.h +++ b/content/browser/debugger/debugger_host.h @@ -13,7 +13,9 @@ #include "base/basictypes.h" #include "base/memory/ref_counted.h" +namespace base { class ListValue; +} class DebuggerHost : public base::RefCountedThreadSafe<DebuggerHost> { public: @@ -36,7 +38,7 @@ class DebuggerHost : public base::RefCountedThreadSafe<DebuggerHost> { virtual void ProcessCommand(const std::wstring& data) {} // Handles messages from debugger UI. - virtual void OnDebuggerHostMsg(const ListValue* args) {} + virtual void OnDebuggerHostMsg(const base::ListValue* args) {} // Shows the debugger UI and returns true if it has any. virtual bool ShowWindow() { return false; } diff --git a/content/browser/debugger/debugger_remote_service.h b/content/browser/debugger/debugger_remote_service.h index b157b77..3a0bb9c 100644 --- a/content/browser/debugger/debugger_remote_service.h +++ b/content/browser/debugger/debugger_remote_service.h @@ -16,9 +16,12 @@ class DevToolsProtocolHandler; class DevToolsRemoteMessage; +class TabContents; + +namespace base { class DictionaryValue; class Value; -class TabContents; +} // Contains constants for DebuggerRemoteService tool protocol commands // (V8-related only). @@ -58,7 +61,7 @@ class DebuggerRemoteService : public DevToolsRemoteListener { // as the "result" field in |response|, otherwise the result // will not be propagated back to the caller. void DetachFromTab(const std::string& destination, - DictionaryValue* response); + base::DictionaryValue* response); // DevToolsRemoteListener interface. @@ -89,7 +92,7 @@ class DebuggerRemoteService : public DevToolsRemoteListener { // Attaches a remote debugger to the tab specified by |destination|. // Writes the attachment result (one of Result enum values) into |response|. void AttachToTab(const std::string& destination, - DictionaryValue* response); + base::DictionaryValue* response); // Retrieves a WebContents instance for the specified |tab_uid| // or NULL if no such tab is found or no WebContents instance @@ -98,7 +101,7 @@ class DebuggerRemoteService : public DevToolsRemoteListener { // Sends a JSON message with the |response| to the remote debugger. // |tool| and |destination| are used as the respective header values. - void SendResponse(const Value& response, + void SendResponse(const base::Value& response, const std::string& tool, const std::string& destination); @@ -106,15 +109,15 @@ class DebuggerRemoteService : public DevToolsRemoteListener { // with the |tab_uid| and writes the result into |response| if it becomes // known immediately. bool DispatchDebuggerCommand(int tab_uid, - DictionaryValue* content, - DictionaryValue* response); + base::DictionaryValue* content, + base::DictionaryValue* response); // Redirects a Javascript evaluation command from |content| to // a V8 debugger associated with the |tab_uid| and writes the result // into |response| if it becomes known immediately. bool DispatchEvaluateJavascript(int tab_uid, - DictionaryValue* content, - DictionaryValue* response); + base::DictionaryValue* content, + base::DictionaryValue* response); // The delegate is used to get an InspectableTabProxy instance. DevToolsProtocolHandler* delegate_; diff --git a/content/browser/debugger/devtools_remote_service.h b/content/browser/debugger/devtools_remote_service.h index 377e4b3..165e277 100644 --- a/content/browser/debugger/devtools_remote_service.h +++ b/content/browser/debugger/devtools_remote_service.h @@ -11,8 +11,10 @@ class DevToolsRemoteMessage; class DevToolsProtocolHandler; + +namespace base { class DictionaryValue; -class Value; +} // Contains constants for DevToolsRemoteService tool protocol commands. struct DevToolsRemoteServiceCommand { @@ -39,7 +41,8 @@ class DevToolsRemoteService : public DevToolsRemoteListener { static const int kUnknownCommand = 1; }; virtual ~DevToolsRemoteService(); - void ProcessJson(DictionaryValue* json, const DevToolsRemoteMessage& message); + void ProcessJson(base::DictionaryValue* json, + const DevToolsRemoteMessage& message); DevToolsProtocolHandler* delegate_; DISALLOW_COPY_AND_ASSIGN(DevToolsRemoteService); }; diff --git a/content/browser/debugger/devtools_window.h b/content/browser/debugger/devtools_window.h index e8af7eb..5cc83f4 100644 --- a/content/browser/debugger/devtools_window.h +++ b/content/browser/debugger/devtools_window.h @@ -24,7 +24,10 @@ class Browser; class BrowserWindow; class Profile; class RenderViewHost; + +namespace base { class Value; +} class DevToolsWindow : public DevToolsClientHost, @@ -77,7 +80,7 @@ class DevToolsWindow void UpdateTheme(); void AddDevToolsExtensionsToClient(); void CallClientFunction(const string16& function_name, - const Value& arg); + const base::Value& arg); // Overridden from TabContentsDelegate. virtual void OpenURLFromTab(TabContents* source, const GURL& url, diff --git a/content/browser/debugger/extension_ports_remote_service.h b/content/browser/debugger/extension_ports_remote_service.h index 3efaa49..eb96ddeb 100644 --- a/content/browser/debugger/extension_ports_remote_service.h +++ b/content/browser/debugger/extension_ports_remote_service.h @@ -21,10 +21,13 @@ class DevToolsProtocolHandler; class DevToolsRemoteMessage; -class DictionaryValue; class GURL; + +namespace base { +class DictionaryValue; class ListValue; class Value; +} class ExtensionPortsRemoteService : public DevToolsRemoteListener, public IPC::Message::Sender { @@ -70,14 +73,14 @@ class ExtensionPortsRemoteService : public DevToolsRemoteListener, // Sends a JSON message with the |response| to the external client. // |tool| and |destination| are used as the respective header values. - void SendResponse(const Value& response, + void SendResponse(const base::Value& response, const std::string& tool, const std::string& destination); // Handles a message from the ExtensionMessageService. void OnExtensionMessageInvoke(const std::string& extension_id, const std::string& function_name, - const ListValue& args, + const base::ListValue& args, const GURL& event_url); // Handles a message sent from an extension through the // ExtensionMessageService, to be passed to the external client. @@ -87,12 +90,14 @@ class ExtensionPortsRemoteService : public DevToolsRemoteListener, // Implementation for the commands we can receive from the external client. // Opens a channel to an extension. - void ConnectCommand(DictionaryValue* content, DictionaryValue* response); + void ConnectCommand(base::DictionaryValue* content, + base::DictionaryValue* response); // Disconnects a message port. - void DisconnectCommand(int port_id, DictionaryValue* response); + void DisconnectCommand(int port_id, base::DictionaryValue* response); // Sends a message to an extension through an established message port. - void PostMessageCommand(int port_id, DictionaryValue* content, - DictionaryValue* response); + void PostMessageCommand(int port_id, + base::DictionaryValue* content, + base::DictionaryValue* response); // The delegate is used to send responses and events back to the // external client, and to resolve tab IDs. diff --git a/content/browser/font_list_async.h b/content/browser/font_list_async.h index 0c3e786..9693dfb 100644 --- a/content/browser/font_list_async.h +++ b/content/browser/font_list_async.h @@ -9,7 +9,9 @@ #include "base/memory/ref_counted.h" #include "base/memory/scoped_ptr.h" +namespace base { class ListValue; +} namespace content { @@ -20,7 +22,7 @@ struct FontListResult : public base::RefCountedThreadSafe<FontListResult> { FontListResult(); ~FontListResult(); - scoped_ptr<ListValue> list; + scoped_ptr<base::ListValue> list; }; // Retrieves the list of fonts on the system as a list of strings. It provides diff --git a/content/browser/gpu/gpu_blacklist.h b/content/browser/gpu/gpu_blacklist.h index cacac35..109c4f8 100644 --- a/content/browser/gpu/gpu_blacklist.h +++ b/content/browser/gpu/gpu_blacklist.h @@ -14,10 +14,13 @@ #include "base/values.h" #include "content/common/gpu/gpu_feature_flags.h" -class DictionaryValue; class Version; struct GPUInfo; +namespace base { +class DictionaryValue; +} + class GpuBlacklist { public: enum OsType { @@ -39,7 +42,7 @@ class GpuBlacklist { // If failed, the current GpuBlacklist is un-touched. bool LoadGpuBlacklist(const std::string& json_context, bool current_os_only); - bool LoadGpuBlacklist(const DictionaryValue& parsed_json, + bool LoadGpuBlacklist(const base::DictionaryValue& parsed_json, bool current_os_only); // Collects system information and combines them with gpu_info and blacklist @@ -87,11 +90,11 @@ class GpuBlacklist { // "crBugs": [1234], // "webkitBugs": [] // } - Value* GetFeatureStatus(bool gpu_access_allowed, - bool disable_accelerated_compositing, - bool disable_accelerated_2D_canvas, - bool disable_experimental_webgl, - bool disable_multisampling) const; + base::Value* GetFeatureStatus(bool gpu_access_allowed, + bool disable_accelerated_compositing, + bool disable_accelerated_2D_canvas, + bool disable_experimental_webgl, + bool disable_multisampling) const; // Return the largest entry id. This is used for histogramming. uint32 max_entry_id() const; @@ -103,7 +106,7 @@ class GpuBlacklist { // Collects the version of the current blacklist from a parsed json file. // Returns false and sets major and minor to 0 on failure. static bool GetVersion( - const DictionaryValue& parsed_json, uint16* major, uint16* minor); + const base::DictionaryValue& parsed_json, uint16* major, uint16* minor); private: class VersionInfo { @@ -194,7 +197,7 @@ class GpuBlacklist { // Constructs GpuBlacklistEntry from DictionaryValue loaded from json. // Top-level entry must have an id number. Others are exceptions. static GpuBlacklistEntry* GetGpuBlacklistEntryFromValue( - DictionaryValue* value, bool top_level); + base::DictionaryValue* value, bool top_level); // Determines if a given os/gc/driver is included in the Entry set. bool Contains(OsType os_type, @@ -284,7 +287,7 @@ class GpuBlacklist { // By default, if there is no browser version information in the entry, // return kSupported; BrowserVersionSupport IsEntrySupportedByCurrentBrowserVersion( - DictionaryValue* value); + base::DictionaryValue* value); scoped_ptr<Version> version_; std::vector<GpuBlacklistEntry*> blacklist_; diff --git a/content/browser/renderer_host/render_view_host.h b/content/browser/renderer_host/render_view_host.h index c4dae8a..a20ae50 100644 --- a/content/browser/renderer_host/render_view_host.h +++ b/content/browser/renderer_host/render_view_host.h @@ -27,7 +27,6 @@ class ChildProcessSecurityPolicy; struct DesktopNotificationHostMsg_Show_Params; class FilePath; class GURL; -class ListValue; class RenderViewHostDelegate; class RenderViewHostObserver; class SessionStorageNamespace; @@ -43,6 +42,10 @@ struct ViewMsg_Navigate_Params; struct WebDropData; struct UserMetricsAction; +namespace base { +class ListValue; +} + namespace gfx { class Point; } // namespace gfx @@ -450,7 +453,7 @@ class RenderViewHost : public RenderWidgetHost { void OnMsgClosePageACK(); void OnAccessibilityNotifications( const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params); - void OnScriptEvalResponse(int id, const ListValue& result); + void OnScriptEvalResponse(int id, const base::ListValue& result); void OnDidZoomURL(double zoom_level, bool remember, const GURL& url); void OnRequestDesktopNotificationPermission(const GURL& origin, int callback_id); diff --git a/content/browser/webui/generic_handler.h b/content/browser/webui/generic_handler.h index 408ecbb..c4ed317 100644 --- a/content/browser/webui/generic_handler.h +++ b/content/browser/webui/generic_handler.h @@ -8,7 +8,9 @@ #include "content/browser/webui/web_ui.h" +namespace base { class ListValue; +} // A place to add handlers for messages shared across all WebUI pages. class GenericHandler : public WebUIMessageHandler { @@ -20,7 +22,7 @@ class GenericHandler : public WebUIMessageHandler { virtual void RegisterMessages(); private: - void HandleNavigateToUrl(const ListValue* args); + void HandleNavigateToUrl(const base::ListValue* args); DISALLOW_COPY_AND_ASSIGN(GenericHandler); }; diff --git a/content/browser/webui/web_ui.h b/content/browser/webui/web_ui.h index 8c41e4c..66ee230 100644 --- a/content/browser/webui/web_ui.h +++ b/content/browser/webui/web_ui.h @@ -16,14 +16,17 @@ #include "content/common/page_transition_types.h" #include "ipc/ipc_channel.h" -class DictionaryValue; class WebUIMessageHandler; class GURL; -class ListValue; class Profile; class RenderViewHost; class TabContents; + +namespace base { +class DictionaryValue; +class ListValue; class Value; +} // A WebUI sets up the datasources and message handlers for a given HTML-based // UI. @@ -39,7 +42,7 @@ class WebUI : public IPC::Channel::Listener { virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; virtual void OnWebUISend(const GURL& source_url, const std::string& message, - const ListValue& args); + const base::ListValue& args); // Called by RenderViewHost when the RenderView is first created. This is // *not* called for every page load because in some cases @@ -63,7 +66,7 @@ class WebUI : public IPC::Channel::Listener { virtual void DidBecomeActiveForReusedRenderView() {} // Used by WebUIMessageHandlers. - typedef Callback1<const ListValue*>::Type MessageCallback; + typedef Callback1<const base::ListValue*>::Type MessageCallback; void RegisterMessageCallback(const std::string& message, MessageCallback* callback); @@ -120,21 +123,21 @@ class WebUI : public IPC::Channel::Listener { // There are variants for calls with more arguments. void CallJavascriptFunction(const std::string& function_name); void CallJavascriptFunction(const std::string& function_name, - const Value& arg); + const base::Value& arg); void CallJavascriptFunction(const std::string& function_name, - const Value& arg1, - const Value& arg2); + const base::Value& arg1, + const base::Value& arg2); void CallJavascriptFunction(const std::string& function_name, - const Value& arg1, - const Value& arg2, - const Value& arg3); + const base::Value& arg1, + const base::Value& arg2, + const base::Value& arg3); void CallJavascriptFunction(const std::string& function_name, - const Value& arg1, - const Value& arg2, - const Value& arg3, - const Value& arg4); + const base::Value& arg1, + const base::Value& arg2, + const base::Value& arg3, + const base::Value& arg4); void CallJavascriptFunction(const std::string& function_name, - const std::vector<const Value*>& args); + const std::vector<const base::Value*>& args); // May be overridden by WebUI's which do not have a tab contents. // TODO(estade): removing this Profile dependency is predicated on reworking @@ -156,8 +159,9 @@ class WebUI : public IPC::Channel::Listener { // Returns JavaScript code that, when executed, calls the function specified // by |function_name| with the arguments specified in |arg_list|. - static string16 GetJavascriptCall(const std::string& function_name, - const std::vector<const Value*>& arg_list); + static string16 GetJavascriptCall( + const std::string& function_name, + const std::vector<const base::Value*>& arg_list); protected: void AddMessageHandler(WebUIMessageHandler* handler); @@ -209,7 +213,7 @@ class WebUIMessageHandler { protected: // Adds "url" and "title" keys on incoming dictionary, setting title // as the url as a fallback on empty title. - static void SetURLAndTitle(DictionaryValue* dictionary, + static void SetURLAndTitle(base::DictionaryValue* dictionary, string16 title, const GURL& gurl); @@ -217,10 +221,10 @@ class WebUIMessageHandler { virtual void RegisterMessages() = 0; // Extract an integer value from a list Value. - bool ExtractIntegerValue(const ListValue* value, int* out_int); + bool ExtractIntegerValue(const base::ListValue* value, int* out_int); // Extract a string value from a list Value. - string16 ExtractStringValue(const ListValue* value); + string16 ExtractStringValue(const base::ListValue* value); WebUI* web_ui_; diff --git a/content/common/font_list.h b/content/common/font_list.h index e4c01a9..af33b24 100644 --- a/content/common/font_list.h +++ b/content/common/font_list.h @@ -5,7 +5,9 @@ #ifndef CONTENT_COMMON_FONT_LIST_H_ #define CONTENT_COMMON_FONT_LIST_H_ +namespace base { class ListValue; +} namespace content { @@ -19,7 +21,7 @@ namespace content { // // Most callers will want to use the GetFontListAsync function in // content/browser/font_list_async.h which does an asynchronous call. -ListValue* GetFontList_SlowBlocking(); +base::ListValue* GetFontList_SlowBlocking(); } // namespace content diff --git a/content/common/view_messages.h b/content/common/view_messages.h index f7a1bcd..258ea13 100644 --- a/content/common/view_messages.h +++ b/content/common/view_messages.h @@ -1289,7 +1289,7 @@ IPC_MESSAGE_ROUTED1(ViewHostMsg_ShowPopup, // String. IPC_MESSAGE_ROUTED2(ViewHostMsg_ScriptEvalResponse, int /* id */, - ListValue /* result */) + base::ListValue /* result */) // Result of string search in the page. // Response to ViewMsg_Find with the results of the requested find-in-page @@ -1601,7 +1601,7 @@ IPC_MESSAGE_ROUTED1(ViewHostMsg_DidContentsPreferredSizeChange, IPC_MESSAGE_ROUTED3(ViewHostMsg_WebUISend, GURL /* source_url */, std::string /* message */, - ListValue /* args */) + base::ListValue /* args */) // A renderer sends this to the browser process when it wants to // create a ppapi plugin. The browser will create the plugin process if diff --git a/content/renderer/v8_value_converter.h b/content/renderer/v8_value_converter.h index acb2d0a..6c3c6a9 100644 --- a/content/renderer/v8_value_converter.h +++ b/content/renderer/v8_value_converter.h @@ -7,9 +7,11 @@ #include "v8/include/v8.h" -class Value; -class ListValue; +namespace base { class DictionaryValue; +class ListValue; +class Value; +} // Converts between v8::Value (JavaScript values in the v8 heap) and Chrome's // values (from base/values.h). Lists and dictionaries are converted @@ -34,23 +36,23 @@ class V8ValueConverter { // Converts Value to v8::Value. Unsupported types are replaced with null. // If an array or object throws while setting a value, that property or item // is skipped, leaving a hole in the case of arrays. - v8::Handle<v8::Value> ToV8Value(Value* value, + v8::Handle<v8::Value> ToV8Value(base::Value* value, v8::Handle<v8::Context> context) const; // Converts v8::Value to Value. Unsupported types are replaced with null. // If an array or object throws while getting a value, that property or item // is replaced with null. - Value* FromV8Value(v8::Handle<v8::Value> value, - v8::Handle<v8::Context> context) const; + base::Value* FromV8Value(v8::Handle<v8::Value> value, + v8::Handle<v8::Context> context) const; private: - v8::Handle<v8::Value> ToV8ValueImpl(Value* value) const; - v8::Handle<v8::Value> ToV8Array(ListValue* list) const; - v8::Handle<v8::Value> ToV8Object(DictionaryValue* dictionary) const; + v8::Handle<v8::Value> ToV8ValueImpl(base::Value* value) const; + v8::Handle<v8::Value> ToV8Array(base::ListValue* list) const; + v8::Handle<v8::Value> ToV8Object(base::DictionaryValue* dictionary) const; - Value* FromV8ValueImpl(v8::Handle<v8::Value> value) const; - ListValue* FromV8Array(v8::Handle<v8::Array> array) const; - DictionaryValue* FromV8Object(v8::Handle<v8::Object> object) const; + base::Value* FromV8ValueImpl(v8::Handle<v8::Value> value) const; + base::ListValue* FromV8Array(v8::Handle<v8::Array> array) const; + base::DictionaryValue* FromV8Object(v8::Handle<v8::Object> object) const; // If true, we will convert undefined JavaScript values to null. bool allow_undefined_; diff --git a/ipc/ipc_message_utils.h b/ipc/ipc_message_utils.h index 3f16ea4..7d444b5 100644 --- a/ipc/ipc_message_utils.h +++ b/ipc/ipc_message_utils.h @@ -96,12 +96,12 @@ enum IPCMessageStart { LastIPCMsgStart // Must come last. }; -class DictionaryValue; class FilePath; -class ListValue; class NullableString16; namespace base { +class DictionaryValue; +class ListValue; class Time; class TimeDelta; struct FileDescriptor; @@ -382,16 +382,16 @@ struct ParamTraits<MSG> { #endif // defined(OS_WIN) template <> -struct ParamTraits<DictionaryValue> { - typedef DictionaryValue param_type; +struct ParamTraits<base::DictionaryValue> { + typedef base::DictionaryValue param_type; static void Write(Message* m, const param_type& p); static bool Read(const Message* m, void** iter, param_type* r); static void Log(const param_type& p, std::string* l); }; template <> -struct ParamTraits<ListValue> { - typedef ListValue param_type; +struct ParamTraits<base::ListValue> { + typedef base::ListValue param_type; static void Write(Message* m, const param_type& p); static bool Read(const Message* m, void** iter, param_type* r); static void Log(const param_type& p, std::string* l); diff --git a/net/base/address_list_net_log_param.h b/net/base/address_list_net_log_param.h index 141c2d0..4c621b3 100644 --- a/net/base/address_list_net_log_param.h +++ b/net/base/address_list_net_log_param.h @@ -18,7 +18,7 @@ class AddressListNetLogParam : public NetLog::EventParameters { public: explicit AddressListNetLogParam(const AddressList& address_list); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: AddressList address_list_; diff --git a/net/base/crl_filter.h b/net/base/crl_filter.h index 5368a12..787d82a 100644 --- a/net/base/crl_filter.h +++ b/net/base/crl_filter.h @@ -17,8 +17,6 @@ #include "base/synchronization/lock.h" #include "net/base/net_api.h" -class DictionaryValue; - namespace net { class GolombCompressedSet; diff --git a/net/base/net_log.h b/net/base/net_log.h index 9f7af36..39fa915 100644 --- a/net/base/net_log.h +++ b/net/base/net_log.h @@ -13,7 +13,9 @@ #include "base/memory/ref_counted.h" #include "net/base/net_api.h" +namespace base { class Value; +} namespace base { class TimeTicks; @@ -64,7 +66,7 @@ class NET_API NetLog { bool is_valid() const { return id != kInvalidId; } // The caller takes ownership of the returned Value*. - Value* ToValue() const; + base::Value* ToValue() const; SourceType type; uint32 id; @@ -82,7 +84,7 @@ class NET_API NetLog { // Serializes the parameters to a Value tree. This is intended to be a // lossless conversion, which is used to serialize the parameters to JSON. // The caller takes ownership of the returned Value*. - virtual Value* ToValue() const = 0; + virtual base::Value* ToValue() const = 0; private: DISALLOW_COPY_AND_ASSIGN(EventParameters); @@ -146,12 +148,12 @@ class NET_API NetLog { // Serializes the specified event to a DictionaryValue. // If |use_strings| is true, uses strings rather than numeric ids. - static Value* EntryToDictionaryValue(NetLog::EventType type, - const base::TimeTicks& time, - const NetLog::Source& source, - NetLog::EventPhase phase, - NetLog::EventParameters* params, - bool use_strings); + static base::Value* EntryToDictionaryValue(NetLog::EventType type, + const base::TimeTicks& time, + const NetLog::Source& source, + NetLog::EventPhase phase, + NetLog::EventParameters* params, + bool use_strings); private: DISALLOW_COPY_AND_ASSIGN(NetLog); @@ -233,7 +235,7 @@ class NetLogStringParameter : public NetLog::EventParameters { return value_; } - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const char* const name_; @@ -252,7 +254,7 @@ class NetLogIntegerParameter : public NetLog::EventParameters { return value_; } - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const char* name_; @@ -271,7 +273,7 @@ class NET_API NetLogSourceParameter : public NetLog::EventParameters { return value_; } - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const char* name_; diff --git a/net/disk_cache/net_log_parameters.h b/net/disk_cache/net_log_parameters.h index f708c79..f248f0f 100644 --- a/net/disk_cache/net_log_parameters.h +++ b/net/disk_cache/net_log_parameters.h @@ -19,7 +19,7 @@ namespace disk_cache { class EntryCreationParameters : public net::NetLog::EventParameters { public: EntryCreationParameters(const std::string& key, bool created); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const std::string key_; @@ -33,7 +33,7 @@ class ReadWriteDataParameters : public net::NetLog::EventParameters { public: // For reads, |truncate| must be false. ReadWriteDataParameters(int index, int offset, int buf_len, bool truncate); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const int index_; @@ -51,7 +51,7 @@ class ReadWriteCompleteParameters : public net::NetLog::EventParameters { // code. |bytes_copied| must not be ERR_IO_PENDING, as it's not a valid // result for an operation. explicit ReadWriteCompleteParameters(int bytes_copied); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const int bytes_copied_; @@ -63,7 +63,7 @@ class ReadWriteCompleteParameters : public net::NetLog::EventParameters { class SparseOperationParameters : public net::NetLog::EventParameters { public: SparseOperationParameters(int64 offset, int buff_len); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const int64 offset_; @@ -75,7 +75,7 @@ class SparseOperationParameters : public net::NetLog::EventParameters { class SparseReadWriteParameters : public net::NetLog::EventParameters { public: SparseReadWriteParameters(const net::NetLog::Source& source, int child_len); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const net::NetLog::Source source_; @@ -87,7 +87,7 @@ class GetAvailableRangeResultParameters : public net::NetLog::EventParameters { public: // |start| is ignored when |result| < 0. GetAvailableRangeResultParameters(int64 start, int result); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const int64 start_; diff --git a/net/http/http_net_log_params.h b/net/http/http_net_log_params.h index 92039ca..1ba94de 100644 --- a/net/http/http_net_log_params.h +++ b/net/http/http_net_log_params.h @@ -13,7 +13,9 @@ #include "net/base/net_log.h" #include "net/http/http_request_headers.h" +namespace base { class Value; +} namespace net { @@ -33,7 +35,7 @@ class NetLogHttpRequestParameter : public NetLog::EventParameters { } // NetLog::EventParameters - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: virtual ~NetLogHttpRequestParameter(); @@ -54,7 +56,7 @@ class NetLogHttpResponseParameter : public NetLog::EventParameters { } // NetLog::EventParameters - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: virtual ~NetLogHttpResponseParameter(); @@ -67,4 +69,3 @@ class NetLogHttpResponseParameter : public NetLog::EventParameters { } // namespace net #endif // NET_HTTP_HTTP_NET_LOG_PARAMS_H_ - diff --git a/net/http/http_network_session.h b/net/http/http_network_session.h index 7d5b67f..f7da921 100644 --- a/net/http/http_network_session.h +++ b/net/http/http_network_session.h @@ -20,7 +20,9 @@ #include "net/spdy/spdy_session_pool.h" #include "net/spdy/spdy_settings_storage.h" +namespace base { class Value; +} namespace net { @@ -127,11 +129,11 @@ class NET_API HttpNetworkSession // Creates a Value summary of the state of the socket pools. The caller is // responsible for deleting the returned value. - Value* SocketPoolInfoToValue() const; + base::Value* SocketPoolInfoToValue() const; // Creates a Value summary of the state of the SPDY sessions. The caller is // responsible for deleting the returned value. - Value* SpdySessionPoolInfoToValue() const; + base::Value* SpdySessionPoolInfoToValue() const; void CloseAllConnections(); void CloseIdleConnections(); diff --git a/net/http/http_proxy_client_socket_pool.h b/net/http/http_proxy_client_socket_pool.h index ac254ff..c3dc24b 100644 --- a/net/http/http_proxy_client_socket_pool.h +++ b/net/http/http_proxy_client_socket_pool.h @@ -211,9 +211,10 @@ class NET_TEST HttpProxyClientSocketPool : public ClientSocketPool { virtual LoadState GetLoadState(const std::string& group_name, const ClientSocketHandle* handle) const; - virtual DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type, - bool include_nested_pools) const; + virtual base::DictionaryValue* GetInfoAsValue( + const std::string& name, + const std::string& type, + bool include_nested_pools) const; virtual base::TimeDelta ConnectionTimeout() const; diff --git a/net/proxy/proxy_config.h b/net/proxy/proxy_config.h index be5e2fb..fe3a1d17 100644 --- a/net/proxy/proxy_config.h +++ b/net/proxy/proxy_config.h @@ -13,7 +13,9 @@ #include "net/proxy/proxy_bypass_rules.h" #include "net/proxy/proxy_server.h" +namespace base { class Value; +} namespace net { @@ -131,7 +133,7 @@ class NET_API ProxyConfig { // Creates a Value dump of this configuration. The caller is responsible for // deleting the returned value. - Value* ToValue() const; + base::Value* ToValue() const; ProxyRules& proxy_rules() { return proxy_rules_; diff --git a/net/socket/client_socket_pool.h b/net/socket/client_socket_pool.h index 77d58fa..c50af84 100644 --- a/net/socket/client_socket_pool.h +++ b/net/socket/client_socket_pool.h @@ -19,7 +19,9 @@ #include "net/base/net_api.h" #include "net/base/request_priority.h" +namespace base { class DictionaryValue; +} namespace net { @@ -125,9 +127,10 @@ class NET_API ClientSocketPool { // DictionaryValue. Caller takes possession of the returned value. // If |include_nested_pools| is true, the states of any nested // ClientSocketPools will be included. - virtual DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type, - bool include_nested_pools) const = 0; + virtual base::DictionaryValue* GetInfoAsValue( + const std::string& name, + const std::string& type, + bool include_nested_pools) const = 0; // Returns the maximum amount of time to wait before retrying a connect. static const int kMaxConnectRetryIntervalMs = 250; diff --git a/net/socket/client_socket_pool_base.h b/net/socket/client_socket_pool_base.h index d4b1dbc..dd73f8b 100644 --- a/net/socket/client_socket_pool_base.h +++ b/net/socket/client_socket_pool_base.h @@ -298,8 +298,8 @@ class NET_TEST ClientSocketPoolBaseHelper void CleanupIdleSockets(bool force); // See ClientSocketPool::GetInfoAsValue for documentation on this function. - DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type) const; + base::DictionaryValue* GetInfoAsValue(const std::string& name, + const std::string& type) const; base::TimeDelta ConnectionTimeout() const { return connect_job_factory_->ConnectionTimeout(); @@ -712,8 +712,8 @@ class ClientSocketPoolBase { return helper_.CleanupIdleSockets(force); } - DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type) const { + base::DictionaryValue* GetInfoAsValue(const std::string& name, + const std::string& type) const { return helper_.GetInfoAsValue(name, type); } diff --git a/net/socket/client_socket_pool_base_unittest.cc b/net/socket/client_socket_pool_base_unittest.cc index 27c1aaa..e9b4ae9 100644 --- a/net/socket/client_socket_pool_base_unittest.cc +++ b/net/socket/client_socket_pool_base_unittest.cc @@ -12,6 +12,7 @@ #include "base/stringprintf.h" #include "base/string_number_conversions.h" #include "base/threading/platform_thread.h" +#include "base/values.h" #include "net/base/net_errors.h" #include "net/base/net_log.h" #include "net/base/net_log_unittest.h" diff --git a/net/socket/client_socket_pool_manager.h b/net/socket/client_socket_pool_manager.h index 72cb500..27e6f03 100644 --- a/net/socket/client_socket_pool_manager.h +++ b/net/socket/client_socket_pool_manager.h @@ -24,7 +24,10 @@ #include "net/socket/client_socket_pool_histograms.h" class GURL; + +namespace base { class Value; +} namespace net { @@ -160,7 +163,7 @@ class ClientSocketPoolManager : public base::NonThreadSafe, // Creates a Value summary of the state of the socket pools. The caller is // responsible for deleting the returned value. - Value* SocketPoolInfoToValue() const; + base::Value* SocketPoolInfoToValue() const; // CertDatabase::Observer methods: virtual void OnUserCertAdded(const X509Certificate* cert); diff --git a/net/socket/socks_client_socket_pool.h b/net/socket/socks_client_socket_pool.h index e17273f..c160eda 100644 --- a/net/socket/socks_client_socket_pool.h +++ b/net/socket/socks_client_socket_pool.h @@ -147,9 +147,10 @@ class NET_TEST SOCKSClientSocketPool : public ClientSocketPool { virtual LoadState GetLoadState(const std::string& group_name, const ClientSocketHandle* handle) const; - virtual DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type, - bool include_nested_pools) const; + virtual base::DictionaryValue* GetInfoAsValue( + const std::string& name, + const std::string& type, + bool include_nested_pools) const; virtual base::TimeDelta ConnectionTimeout() const; diff --git a/net/socket/ssl_client_socket_pool.h b/net/socket/ssl_client_socket_pool.h index 8baab94..dec7e50 100644 --- a/net/socket/ssl_client_socket_pool.h +++ b/net/socket/ssl_client_socket_pool.h @@ -224,9 +224,10 @@ class NET_TEST SSLClientSocketPool : public ClientSocketPool, virtual LoadState GetLoadState(const std::string& group_name, const ClientSocketHandle* handle) const; - virtual DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type, - bool include_nested_pools) const; + virtual base::DictionaryValue* GetInfoAsValue( + const std::string& name, + const std::string& type, + bool include_nested_pools) const; virtual base::TimeDelta ConnectionTimeout() const; diff --git a/net/socket/ssl_error_params.h b/net/socket/ssl_error_params.h index ae546fe..c0d685a 100644 --- a/net/socket/ssl_error_params.h +++ b/net/socket/ssl_error_params.h @@ -16,7 +16,7 @@ class SSLErrorParams : public NetLog::EventParameters { SSLErrorParams(int net_error, int ssl_lib_error); virtual ~SSLErrorParams(); - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const int net_error_; diff --git a/net/socket/transport_client_socket_pool.cc b/net/socket/transport_client_socket_pool.cc index a75b426..aa0932f 100644 --- a/net/socket/transport_client_socket_pool.cc +++ b/net/socket/transport_client_socket_pool.cc @@ -10,6 +10,7 @@ #include "base/metrics/histogram.h" #include "base/string_util.h" #include "base/time.h" +#include "base/values.h" #include "net/base/ip_endpoint.h" #include "net/base/net_log.h" #include "net/base/net_errors.h" diff --git a/net/socket/transport_client_socket_pool.h b/net/socket/transport_client_socket_pool.h index dab1679..bcd8703 100644 --- a/net/socket/transport_client_socket_pool.h +++ b/net/socket/transport_client_socket_pool.h @@ -176,9 +176,10 @@ class NET_TEST TransportClientSocketPool : public ClientSocketPool { virtual LoadState GetLoadState(const std::string& group_name, const ClientSocketHandle* handle) const; - virtual DictionaryValue* GetInfoAsValue(const std::string& name, - const std::string& type, - bool include_nested_pools) const; + virtual base::DictionaryValue* GetInfoAsValue( + const std::string& name, + const std::string& type, + bool include_nested_pools) const; virtual base::TimeDelta ConnectionTimeout() const; diff --git a/net/spdy/spdy_session.h b/net/spdy/spdy_session.h index 5fd3520..58e617b 100644 --- a/net/spdy/spdy_session.h +++ b/net/spdy/spdy_session.h @@ -172,7 +172,7 @@ class NET_API SpdySession : public base::RefCounted<SpdySession>, // Retrieves information on the current state of the SPDY session as a // Value. Caller takes possession of the returned value. - Value* GetInfoAsValue() const; + base::Value* GetInfoAsValue() const; // Indicates whether the session is being reused after having successfully // used to send/receive data in the past. @@ -452,7 +452,7 @@ class NetLogSpdySynParameter : public NetLog::EventParameters { return headers_; } - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: virtual ~NetLogSpdySynParameter(); diff --git a/net/spdy/spdy_session_pool.h b/net/spdy/spdy_session_pool.h index 99319ee..74b8874 100644 --- a/net/spdy/spdy_session_pool.h +++ b/net/spdy/spdy_session_pool.h @@ -99,7 +99,7 @@ class NET_API SpdySessionPool // Creates a Value summary of the state of the spdy session pool. The caller // responsible for deleting the returned value. - Value* SpdySessionPoolInfoToValue() const; + base::Value* SpdySessionPoolInfoToValue() const; SpdySettingsStorage* mutable_spdy_settings() { return &spdy_settings_; } const SpdySettingsStorage& spdy_settings() const { return spdy_settings_; } diff --git a/net/test/test_server.h b/net/test/test_server.h index 81b0ad3..5efd6ba 100644 --- a/net/test/test_server.h +++ b/net/test/test_server.h @@ -24,9 +24,12 @@ #endif class CommandLine; -class DictionaryValue; class GURL; +namespace base { +class DictionaryValue; +} + namespace net { class AddressList; @@ -117,7 +120,7 @@ class TestServer { const FilePath& document_root() const { return document_root_; } const HostPortPair& host_port_pair() const; - const DictionaryValue& server_data() const; + const base::DictionaryValue& server_data() const; std::string GetScheme() const; bool GetAddressList(AddressList* address_list) const WARN_UNUSED_RESULT; @@ -171,7 +174,7 @@ class TestServer { HostPortPair host_port_pair_; // Holds the data sent from the server (e.g., port number). - scoped_ptr<DictionaryValue> server_data_; + scoped_ptr<base::DictionaryValue> server_data_; // Handle of the Python process running the test server. base::ProcessHandle process_handle_; diff --git a/net/url_request/url_request_netlog_params.h b/net/url_request/url_request_netlog_params.h index 19e2de2f..5a147dc 100644 --- a/net/url_request/url_request_netlog_params.h +++ b/net/url_request/url_request_netlog_params.h @@ -32,7 +32,7 @@ class NET_API URLRequestStartEventParameters : public NetLog::EventParameters { return load_flags_; } - virtual Value* ToValue() const; + virtual base::Value* ToValue() const; private: const GURL url_; diff --git a/printing/backend/print_backend.h b/printing/backend/print_backend.h index f53eaa5..b6d0b91 100644 --- a/printing/backend/print_backend.h +++ b/printing/backend/print_backend.h @@ -12,7 +12,9 @@ #include "base/memory/ref_counted.h" +namespace base { class DictionaryValue; +} // This is the interface for platform-specific code for a print backend namespace printing { @@ -69,7 +71,7 @@ class PrintBackend : public base::RefCountedThreadSafe<PrintBackend> { // settings will be used. // Return NULL if no print backend available. static scoped_refptr<PrintBackend> CreateInstance( - const DictionaryValue* print_backend_settings); + const base::DictionaryValue* print_backend_settings); }; } // namespace printing diff --git a/printing/backend/print_backend_dummy.cc b/printing/backend/print_backend_dummy.cc index 008f00b..fdc3b7f 100644 --- a/printing/backend/print_backend_dummy.cc +++ b/printing/backend/print_backend_dummy.cc @@ -9,6 +9,7 @@ #include "printing/backend/print_backend.h" #include "base/logging.h" +#include "base/values.h" namespace printing { diff --git a/printing/backend/print_backend_win.cc b/printing/backend/print_backend_win.cc index 3fb0573..dbbb270 100644 --- a/printing/backend/print_backend_win.cc +++ b/printing/backend/print_backend_win.cc @@ -186,7 +186,7 @@ bool PrintBackendWin::IsValidPrinter(const std::string& printer_name) { } scoped_refptr<PrintBackend> PrintBackend::CreateInstance( - const DictionaryValue* print_backend_settings) { + const base::DictionaryValue* print_backend_settings) { return new PrintBackendWin; } diff --git a/printing/print_dialog_gtk_interface.h b/printing/print_dialog_gtk_interface.h index c47f978..4fb9341 100644 --- a/printing/print_dialog_gtk_interface.h +++ b/printing/print_dialog_gtk_interface.h @@ -24,7 +24,7 @@ class PrintDialogGtkInterface { // dictionary of settings with possible keys from // printing/print_job_constants.h. Only used when printing without the system // print dialog. E.g. for Print Preview. Returns false on error. - virtual bool UpdateSettings(const DictionaryValue& settings, + virtual bool UpdateSettings(const base::DictionaryValue& settings, const PageRanges& ranges) = 0; // Shows the dialog and handles the response with |callback|. Only used when diff --git a/printing/printing_context.h b/printing/printing_context.h index 8247aca..dd7e058 100644 --- a/printing/printing_context.h +++ b/printing/printing_context.h @@ -13,7 +13,9 @@ #include "printing/print_settings.h" #include "ui/gfx/native_widget_types.h" +namespace base { class DictionaryValue; +} namespace printing { @@ -51,7 +53,7 @@ class PrintingContext { // Updates print settings. |job_settings| contains all print job settings // information. |ranges| has the new page range settings. - virtual Result UpdatePrintSettings(const DictionaryValue& job_settings, + virtual Result UpdatePrintSettings(const base::DictionaryValue& job_settings, const PageRanges& ranges) = 0; // Initializes with predefined settings. diff --git a/printing/printing_context_cairo.h b/printing/printing_context_cairo.h index 5bc30e6..49d72b5 100644 --- a/printing/printing_context_cairo.h +++ b/printing/printing_context_cairo.h @@ -9,6 +9,10 @@ #include "printing/printing_context.h" +namespace base { +class DictionaryValue; +} + namespace printing { class Metafile; @@ -35,7 +39,7 @@ class PrintingContextCairo : public PrintingContext { bool has_selection, PrintSettingsCallback* callback); virtual Result UseDefaultSettings(); - virtual Result UpdatePrintSettings(const DictionaryValue& job_settings, + virtual Result UpdatePrintSettings(const base::DictionaryValue& job_settings, const PageRanges& ranges); virtual Result InitWithSettings(const PrintSettings& settings); virtual Result NewDocument(const string16& document_name); diff --git a/printing/printing_context_mac.h b/printing/printing_context_mac.h index af6f9f6..cb3e0e2 100644 --- a/printing/printing_context_mac.h +++ b/printing/printing_context_mac.h @@ -30,7 +30,7 @@ class PrintingContextMac : public PrintingContext { bool has_selection, PrintSettingsCallback* callback); virtual Result UseDefaultSettings(); - virtual Result UpdatePrintSettings(const DictionaryValue& job_settings, + virtual Result UpdatePrintSettings(const base::DictionaryValue& job_settings, const PageRanges& ranges); virtual Result InitWithSettings(const PrintSettings& settings); virtual Result NewDocument(const string16& document_name); diff --git a/printing/printing_context_win.h b/printing/printing_context_win.h index 98ee8e9..81a61c3 100644 --- a/printing/printing_context_win.h +++ b/printing/printing_context_win.h @@ -28,7 +28,7 @@ class PrintingContextWin : public PrintingContext { bool has_selection, PrintSettingsCallback* callback); virtual Result UseDefaultSettings(); - virtual Result UpdatePrintSettings(const DictionaryValue& job_settings, + virtual Result UpdatePrintSettings(const base::DictionaryValue& job_settings, const PageRanges& ranges); virtual Result InitWithSettings(const PrintSettings& settings); virtual Result NewDocument(const string16& document_name); diff --git a/remoting/host/in_memory_host_config.h b/remoting/host/in_memory_host_config.h index e0a876d..1d3f8a6 100644 --- a/remoting/host/in_memory_host_config.h +++ b/remoting/host/in_memory_host_config.h @@ -12,9 +12,12 @@ #include "base/synchronization/lock.h" #include "remoting/host/host_config.h" -class DictionaryValue; class Task; +namespace base { +class DictionaryValue; +} + namespace remoting { // In-memory host config. Used by unittests. @@ -35,7 +38,7 @@ class InMemoryHostConfig : public MutableHostConfig { protected: // |lock_| must be locked whenever |values_| is used. base::Lock lock_; - scoped_ptr<DictionaryValue> values_; + scoped_ptr<base::DictionaryValue> values_; private: DISALLOW_COPY_AND_ASSIGN(InMemoryHostConfig); diff --git a/remoting/host/json_host_config.h b/remoting/host/json_host_config.h index 56ec01d..efcf28a 100644 --- a/remoting/host/json_host_config.h +++ b/remoting/host/json_host_config.h @@ -12,7 +12,6 @@ #include "base/memory/scoped_ptr.h" #include "remoting/host/in_memory_host_config.h" -class DictionaryValue; class Task; namespace base { diff --git a/tools/cros.DEPS/DEPS b/tools/cros.DEPS/DEPS index f136e6b..2a94358 100644 --- a/tools/cros.DEPS/DEPS +++ b/tools/cros.DEPS/DEPS @@ -4,5 +4,5 @@ vars = { deps = { "src/third_party/cros": - Var("chromium_git") + "/cros.git@30822022", + Var("chromium_git") + "/cros.git@a0020010", } diff --git a/webkit/plugins/npapi/plugin_group.h b/webkit/plugins/npapi/plugin_group.h index 063713a..7d5f67b 100644 --- a/webkit/plugins/npapi/plugin_group.h +++ b/webkit/plugins/npapi/plugin_group.h @@ -16,12 +16,15 @@ #include "base/string16.h" #include "webkit/plugins/npapi/webplugininfo.h" -class DictionaryValue; class FilePath; class TableModelArrayControllerTest; class PluginExceptionsTableModelTest; class Version; +namespace base { +class DictionaryValue; +} + namespace webkit { namespace npapi { @@ -165,10 +168,10 @@ class PluginGroup { const string16& description() const { return description_; } // Returns a DictionaryValue with data to display in the UI. - DictionaryValue* GetDataForUI() const; + base::DictionaryValue* GetDataForUI() const; // Returns a DictionaryValue with data to save in the preferences. - DictionaryValue* GetSummary() const; + base::DictionaryValue* GetSummary() const; // Returns the update URL. std::string GetUpdateURL() const { return update_url_; } |