summaryrefslogtreecommitdiffstats
path: root/chrome/browser/first_run.h
diff options
context:
space:
mode:
authorcpu@chromium.org <cpu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-26 20:21:40 +0000
committercpu@chromium.org <cpu@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-26 20:21:40 +0000
commita5391559831871c15cb5239c06c39753efed209a (patch)
treeab81f5f083ab73587d3b93430e63529e21c6c21d /chrome/browser/first_run.h
parente3be97ce298466ce151ae856b3bf4164ec5a87c5 (diff)
downloadchromium_src-a5391559831871c15cb5239c06c39753efed209a.zip
chromium_src-a5391559831871c15cb5239c06c39753efed209a.tar.gz
chromium_src-a5391559831871c15cb5239c06c39753efed209a.tar.bz2
First part of the pre-set bookmarks feature
- master prefs format (just url) - defer actual bookmark fu, because early on the bookmarkmodel and other services are not yet running. - cleanup master prefs test, too much code duplication - cleanup ProcessMasterPreferences it had too many params BUG=32728 TEST=unit test included Review URL: http://codereview.chromium.org/660116 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40150 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/first_run.h')
-rw-r--r--chrome/browser/first_run.h16
1 files changed, 11 insertions, 5 deletions
diff --git a/chrome/browser/first_run.h b/chrome/browser/first_run.h
index 3b2d996..08a101a4 100644
--- a/chrome/browser/first_run.h
+++ b/chrome/browser/first_run.h
@@ -28,6 +28,15 @@ class ProcessSingleton;
// install work for this user. After that the sentinel file is created.
class FirstRun {
public:
+ // See ProcessMasterPreferences for more info about this structure.
+ struct MasterPrefs {
+ int ping_delay;
+ bool homepage_defined;
+ int do_import_items;
+ int dont_import_items;
+ std::vector<std::wstring> new_tabs;
+ std::vector<std::wstring> bookmarks;
+ };
#if defined(OS_WIN)
// Creates the desktop shortcut to chrome for the current user. Returns
// false if it fails. It will overwrite the shortcut if it exists.
@@ -40,6 +49,7 @@ class FirstRun {
// FirstRun::ImportSettings(). This function might or might not show
// a visible UI depending on the cmdline parameters.
static int ImportNow(Profile* profile, const CommandLine& cmdline);
+
// The master preferences is a JSON file with the same entries as the
// 'Default\Preferences' file. This function locates this file from
// master_pref_path or if that path is empty from the default location
@@ -57,11 +67,7 @@ class FirstRun {
// 'master_preferences' file.
static bool ProcessMasterPreferences(const FilePath& user_data_dir,
const FilePath& master_prefs_path,
- std::vector<std::wstring>* new_tabs,
- int* ping_delay,
- bool* homepage_defined,
- int* do_import_items,
- int* dont_import_items);
+ MasterPrefs* out_prefs);
#endif // OS_WIN
// Returns true if this is the first time chrome is run for this user.