Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5626)

Unified Diff: chrome/browser/ui/startup/default_browser_prompt.cc

Issue 1142153002: Simplify infobar expiry. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Android compile Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/startup/default_browser_prompt.cc
diff --git a/chrome/browser/ui/startup/default_browser_prompt.cc b/chrome/browser/ui/startup/default_browser_prompt.cc
index 585339997220f2919725a5297aba082a9eac5198..86a592ba84e1473536ef1258ccad48df782d2f89 100644
--- a/chrome/browser/ui/startup/default_browser_prompt.cc
+++ b/chrome/browser/ui/startup/default_browser_prompt.cc
@@ -74,7 +74,7 @@ class DefaultBrowserInfoBarDelegate : public ConfirmInfoBarDelegate {
// ConfirmInfoBarDelegate:
int GetIconID() const override;
- bool ShouldExpireInternal(const NavigationDetails& details) const override;
+ bool ShouldExpire(const NavigationDetails& details) const override;
base::string16 GetMessageText() const override;
base::string16 GetButtonLabel(InfoBarButton button) const override;
bool OKButtonTriggersUACPrompt() const override;
@@ -136,9 +136,9 @@ int DefaultBrowserInfoBarDelegate::GetIconID() const {
return IDR_PRODUCT_LOGO_32;
}
-bool DefaultBrowserInfoBarDelegate::ShouldExpireInternal(
+bool DefaultBrowserInfoBarDelegate::ShouldExpire(
const NavigationDetails& details) const {
- return should_expire_;
+ return should_expire_ && ConfirmInfoBarDelegate::ShouldExpire(details);
}
base::string16 DefaultBrowserInfoBarDelegate::GetMessageText() const {

Powered by Google App Engine
This is Rietveld 408576698