| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ | 6 #define CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ |
| 7 | 7 |
| 8 #include "base/feature_list.h" | 8 #include "base/feature_list.h" |
| 9 #include "chrome/browser/infobars/infobar_service.h" | 9 #include "chrome/browser/infobars/infobar_service.h" |
| 10 #include "chrome/browser/shell_integration.h" | 10 #include "chrome/browser/shell_integration.h" |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 // The user explicitly closed the infobar. | 49 // The user explicitly closed the infobar. |
| 50 DISMISS_INFO_BAR = 3, | 50 DISMISS_INFO_BAR = 3, |
| 51 NUM_INFO_BAR_USER_INTERACTION_TYPES | 51 NUM_INFO_BAR_USER_INTERACTION_TYPES |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 void AllowExpiry(); | 54 void AllowExpiry(); |
| 55 | 55 |
| 56 // ConfirmInfoBarDelegate: | 56 // ConfirmInfoBarDelegate: |
| 57 Type GetInfoBarType() const override; | 57 Type GetInfoBarType() const override; |
| 58 infobars::InfoBarDelegate::InfoBarIdentifier GetIdentifier() const override; | 58 infobars::InfoBarDelegate::InfoBarIdentifier GetIdentifier() const override; |
| 59 gfx::VectorIconId GetVectorIconId() const override; | 59 const gfx::VectorIcon& GetVectorIcon() const override; |
| 60 bool ShouldExpire(const NavigationDetails& details) const override; | 60 bool ShouldExpire(const NavigationDetails& details) const override; |
| 61 void InfoBarDismissed() override; | 61 void InfoBarDismissed() override; |
| 62 base::string16 GetMessageText() const override; | 62 base::string16 GetMessageText() const override; |
| 63 int GetButtons() const override; | 63 int GetButtons() const override; |
| 64 base::string16 GetButtonLabel(InfoBarButton button) const override; | 64 base::string16 GetButtonLabel(InfoBarButton button) const override; |
| 65 bool OKButtonTriggersUACPrompt() const override; | 65 bool OKButtonTriggersUACPrompt() const override; |
| 66 bool Accept() override; | 66 bool Accept() override; |
| 67 | 67 |
| 68 // Declared virtual so tests can override. | 68 // Declared virtual so tests can override. |
| 69 virtual scoped_refptr<shell_integration::DefaultBrowserWorker> | 69 virtual scoped_refptr<shell_integration::DefaultBrowserWorker> |
| (...skipping 18 matching lines...) Expand all Loading... |
| 88 | 88 |
| 89 // Used to delay the expiration of the info-bar. | 89 // Used to delay the expiration of the info-bar. |
| 90 base::WeakPtrFactory<DefaultBrowserInfoBarDelegate> weak_factory_; | 90 base::WeakPtrFactory<DefaultBrowserInfoBarDelegate> weak_factory_; |
| 91 | 91 |
| 92 DISALLOW_COPY_AND_ASSIGN(DefaultBrowserInfoBarDelegate); | 92 DISALLOW_COPY_AND_ASSIGN(DefaultBrowserInfoBarDelegate); |
| 93 }; | 93 }; |
| 94 | 94 |
| 95 } // namespace chrome | 95 } // namespace chrome |
| 96 | 96 |
| 97 #endif // CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ | 97 #endif // CHROME_BROWSER_UI_STARTUP_DEFAULT_BROWSER_INFOBAR_DELEGATE_H_ |
| OLD | NEW |