Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/ui/startup/default_browser_prompt.h" | 5 #include "chrome/browser/ui/startup/default_browser_prompt.h" |
| 6 | 6 |
| 7 #include "chrome/browser/prefs/pref_service.h" | 7 #include "chrome/browser/prefs/pref_service.h" |
| 8 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
| 9 #include "chrome/browser/shell_integration.h" | 9 #include "chrome/browser/shell_integration.h" |
| 10 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 76 if ((ShellIntegration::IsDefaultBrowser() == | 76 if ((ShellIntegration::IsDefaultBrowser() == |
| 77 ShellIntegration::NOT_DEFAULT_WEB_CLIENT) && | 77 ShellIntegration::NOT_DEFAULT_WEB_CLIENT) && |
| 78 (ShellIntegration::CanSetAsDefaultBrowser() == | 78 (ShellIntegration::CanSetAsDefaultBrowser() == |
| 79 ShellIntegration::SET_DEFAULT_INTERACTIVE)) { | 79 ShellIntegration::SET_DEFAULT_INTERACTIVE)) { |
| 80 // If the only available mode of setting the default browser requires | 80 // If the only available mode of setting the default browser requires |
| 81 // user interaction, it means this couldn't have been done yet. | 81 // user interaction, it means this couldn't have been done yet. |
| 82 SetMetroBrowserFlowLauncher::LaunchSoon(profile); | 82 SetMetroBrowserFlowLauncher::LaunchSoon(profile); |
| 83 } | 83 } |
| 84 } | 84 } |
| 85 | 85 |
| 86 bool ExpectDefaultBrowserPromptDialog(Profile* profile, bool is_first_run) { | |
| 87 return is_first_run && | |
| 88 profile->GetPrefs()->GetBoolean(prefs::kDefaultBrowserFlowDialog) && | |
| 89 (ShellIntegration::IsDefaultBrowser() == | |
|
grt (UTC plus 2)
2012/07/05 20:08:47
please swap the CanSetAsDefaultBrowser and IsDefau
motek.
2012/08/08 14:28:35
This part is gone altogether now. Changed above fo
| |
| 90 ShellIntegration::NOT_DEFAULT_WEB_CLIENT) && | |
| 91 (ShellIntegration::CanSetAsDefaultBrowser() == | |
| 92 ShellIntegration::SET_DEFAULT_INTERACTIVE); | |
| 93 } | |
| 94 | |
| 86 } // namespace chrome | 95 } // namespace chrome |
| OLD | NEW |