| Index: chrome/browser/process_singleton_win.cc
|
| diff --git a/chrome/browser/process_singleton_win.cc b/chrome/browser/process_singleton_win.cc
|
| index d3964617be89049e8fcd4474f535ed958ad255aa..b0f7adcbc20b75aa431734d6ce797f5c4455c8a5 100644
|
| --- a/chrome/browser/process_singleton_win.cc
|
| +++ b/chrome/browser/process_singleton_win.cc
|
| @@ -22,6 +22,7 @@
|
| #include "base/win/win_util.h"
|
| #include "base/win/windows_version.h"
|
| #include "base/win/wrapped_window_proc.h"
|
| +#include "chrome/browser/shell_integration.h"
|
| #include "chrome/browser/ui/simple_message_box.h"
|
| #include "chrome/common/chrome_constants.h"
|
| #include "chrome/common/chrome_paths.h"
|
| @@ -171,9 +172,10 @@ bool ActivateMetroChrome() {
|
| // Following conditions apply:-
|
| // 1. Windows 8 or greater.
|
| // 2. Not in Windows 8 immersive mode.
|
| -// 3. Process integrity level is not high.
|
| -// 4. The profile data directory is the default directory .
|
| -// 5. Last used mode was immersive/machine is a tablet.
|
| +// 3. Chrome is default browser.
|
| +// 4. Process integrity level is not high.
|
| +// 5. The profile data directory is the default directory.
|
| +// 6. Last used mode was immersive/machine is a tablet.
|
| // TODO(ananta)
|
| // Move this function to a common place as the Windows 8 delegate_execute
|
| // handler can possibly use this.
|
| @@ -188,6 +190,9 @@ bool ShouldLaunchInWindows8ImmersiveMode(const FilePath& user_data_dir) {
|
| if (base::win::IsProcessImmersive(base::GetCurrentProcessHandle()))
|
| return false;
|
|
|
| + if (!ShellIntegration::IsDefaultBrowser())
|
| + return false;
|
| +
|
| base::IntegrityLevel integrity_level = base::INTEGRITY_UNKNOWN;
|
| base::GetProcessIntegrityLevel(base::GetCurrentProcessHandle(),
|
| &integrity_level);
|
|
|