Chromium Code Reviews| Index: chrome/browser/ui/extensions/extension_message_bubble_factory.cc |
| diff --git a/chrome/browser/ui/extensions/extension_message_bubble_factory.cc b/chrome/browser/ui/extensions/extension_message_bubble_factory.cc |
| index 949bd684efc7dc151a5403437eaafdb39936ba76..4e132687666cf0394186ff0c56e1ccfc4ec610cc 100644 |
| --- a/chrome/browser/ui/extensions/extension_message_bubble_factory.cc |
| +++ b/chrome/browser/ui/extensions/extension_message_bubble_factory.cc |
| @@ -9,6 +9,7 @@ |
| #include "base/lazy_instance.h" |
| #include "base/metrics/field_trial.h" |
| #include "build/build_config.h" |
| +#include "chrome/browser/browser_process.h" |
|
Devlin
2016/09/21 01:50:58
Whoops - will clean up these includes
Finnur
2016/09/21 10:05:10
OK.
Remember the BUG= also.
Devlin
2016/09/21 17:07:31
Done and done. :)
|
| #include "chrome/browser/extensions/dev_mode_bubble_delegate.h" |
| #include "chrome/browser/extensions/extension_message_bubble_controller.h" |
| #include "chrome/browser/extensions/install_verifier.h" |
| @@ -18,7 +19,10 @@ |
| #include "chrome/browser/extensions/suspicious_extension_bubble_delegate.h" |
| #include "chrome/browser/profiles/profile.h" |
| #include "chrome/browser/ui/browser.h" |
| +#include "chrome/browser/ui/startup/startup_browser_creator.h" |
| #include "chrome/common/channel_info.h" |
| +#include "chrome/common/pref_names.h" |
| +#include "components/prefs/pref_service.h" |
| #include "components/version_info/version_info.h" |
| #include "extensions/common/feature_switch.h" |
| @@ -133,8 +137,10 @@ ExtensionMessageBubbleFactory::GetController() { |
| } |
| if (EnableSettingsApiBubble()) { |
| - // No use showing this if it's not the startup of the profile. |
| - if (is_initial_check) { |
| + // No use showing this if it's not the startup of the profile, and if the |
| + // browser was restarted, then we always do a session restore (rather than |
| + // showing normal startup pages). |
| + if (is_initial_check && !StartupBrowserCreator::WasRestarted()) { |
| controller.reset(new extensions::ExtensionMessageBubbleController( |
| new extensions::SettingsApiBubbleDelegate( |
| browser_->profile(), extensions::BUBBLE_TYPE_STARTUP_PAGES), |