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

Unified Diff: chrome/installer/util/master_preferences_dummy.cc

Issue 4342001: Refactoring the master_preferences functions.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/installer/util/master_preferences.cc ('k') | chrome/installer/util/master_preferences_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/util/master_preferences_dummy.cc
===================================================================
--- chrome/installer/util/master_preferences_dummy.cc (revision 64604)
+++ chrome/installer/util/master_preferences_dummy.cc (working copy)
@@ -18,54 +18,37 @@
namespace installer_util {
-bool GetDistroBooleanPreference(const DictionaryValue* prefs,
- const std::string& name,
- bool* value) {
- // This function is called by InstallUtil::IsChromeFrameProcess()
- // We return false because GetInstallPreferences returns an empty value below.
- return false;
+MasterPreferences::MasterPreferences(const CommandLine& cmd_line)
+ : distribution_(NULL), preferences_read_from_file_(false) {
}
-bool GetDistroIntegerPreference(const DictionaryValue* prefs,
- const std::string& name,
- int* value) {
- NOTREACHED();
- return false;
+MasterPreferences::MasterPreferences(const FilePath& prefs_path)
+ : distribution_(NULL), preferences_read_from_file_(false) {
}
-DictionaryValue* GetInstallPreferences(const CommandLine& cmd_line) {
- // This function is called by InstallUtil::IsChromeFrameProcess()
- // so we cannot make it NOTREACHED()
- return new DictionaryValue();;
+MasterPreferences::~MasterPreferences() {
}
-DictionaryValue* ParseDistributionPreferences(
- const FilePath& master_prefs_path) {
- NOTREACHED();
- return NULL;
+bool MasterPreferences::GetBool(const std::string& name, bool* value) const {
+ // This function is called by InstallUtil::IsChromeFrameProcess()
+ // We return false because GetInstallPreferences returns an empty value below.
+ return false;
}
-std::vector<GURL> GetFirstRunTabs(const DictionaryValue* prefs) {
+bool MasterPreferences::GetInt(const std::string& name, int* value) const {
NOTREACHED();
- return std::vector<GURL>();
+ return false;
}
-std::vector<GURL> GetDefaultBookmarks(const DictionaryValue* prefs) {
+bool MasterPreferences::GetString(const std::string& name,
+ std::string* value) const {
NOTREACHED();
- return std::vector<GURL>();
-}
-
-bool SetDistroBooleanPreference(DictionaryValue* prefs,
- const std::string& name,
- bool value) {
- NOTREACHED();
return false;
}
-bool HasExtensionsBlock(const DictionaryValue* prefs,
- DictionaryValue** extensions) {
+std::vector<GURL> MasterPreferences::GetFirstRunTabs() const {
NOTREACHED();
- return false;
+ return std::vector<GURL>();
}
}
« no previous file with comments | « chrome/installer/util/master_preferences.cc ('k') | chrome/installer/util/master_preferences_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698