diff options
author | beng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-31 00:21:27 +0000 |
---|---|---|
committer | beng@google.com <beng@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-01-31 00:21:27 +0000 |
commit | d19921bf3f89589fafea8321d5119463bd9f173b (patch) | |
tree | 1d53473c3b01d163a356014fdfa063cb6df772eb /chrome/browser/browser_init.h | |
parent | f211befbc09c492a5c882fd4f08d71a69ea7c1fa (diff) | |
download | chromium_src-d19921bf3f89589fafea8321d5119463bd9f173b.zip chromium_src-d19921bf3f89589fafea8321d5119463bd9f173b.tar.gz chromium_src-d19921bf3f89589fafea8321d5119463bd9f173b.tar.bz2 |
Rollback 8998
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@8999 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_init.h')
-rw-r--r-- | chrome/browser/browser_init.h | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/chrome/browser/browser_init.h b/chrome/browser/browser_init.h index 6475b9f..5e11811 100644 --- a/chrome/browser/browser_init.h +++ b/chrome/browser/browser_init.h @@ -11,6 +11,7 @@ #include "base/basictypes.h" class Browser; +class CommandLine; class GURL; class PrefService; class Profile; @@ -30,7 +31,8 @@ class BrowserInit { class LaunchWithProfile { public: - explicit LaunchWithProfile(const std::wstring& cur_dir); + LaunchWithProfile(const std::wstring& cur_dir, + const std::wstring& cmd_line); ~LaunchWithProfile() { } // Creates the necessary windows for startup. Returns true on success, @@ -49,6 +51,7 @@ class BrowserInit { // // Otherwise false is returned. bool OpenStartupURLs(bool is_process_startup, + const CommandLine& command_line, const std::vector<GURL>& urls_to_open); // Opens the list of urls. If browser is non-null and a tabbed browser, the @@ -65,9 +68,11 @@ class BrowserInit { // Returns the list of URLs to open from the command line. The returned // vector is empty if the user didn't specify any URLs on the command line. - std::vector<GURL> GetURLsFromCommandLine(Profile* profile); + std::vector<GURL> GetURLsFromCommandLine(const CommandLine& command_line, + Profile* profile); std::wstring cur_dir_; + std::wstring command_line_; Profile* profile_; DISALLOW_COPY_AND_ASSIGN(LaunchWithProfile); @@ -78,25 +83,26 @@ class BrowserInit { // process (via the WM_COPYDATA message). The process_startup flag // indicates if this is being called from the process startup code or // the WM_COPYDATA handler. - static bool ProcessCommandLine(const std::wstring& cur_dir, + static bool ProcessCommandLine(const CommandLine& parsed_command_line, + const std::wstring& cur_dir, PrefService* prefs, bool process_startup, Profile* profile, int* return_code); // Helper function to launch a new browser based on command-line arguments // This function takes in a specific profile to use. - static bool LaunchBrowser(Profile* profile, const std::wstring& cur_dir, + static bool LaunchBrowser(const CommandLine& parsed_command_line, + Profile* profile, const std::wstring& cur_dir, bool process_startup, int* return_code); -#if defined(OS_WIN) template <class AutomationProviderClass> static void CreateAutomationProvider(const std::wstring& channel_id, Profile* profile, size_t expected_tabs); -#endif private: // Does the work of LaunchBrowser returning the result. - static bool LaunchBrowserImpl(Profile* profile, const std::wstring& cur_dir, + static bool LaunchBrowserImpl(const CommandLine& parsed_command_line, + Profile* profile, const std::wstring& cur_dir, bool process_startup, int* return_code); // This class is for scoping purposes. |