| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "chrome/browser/tab_contents/confirm_infobar_delegate.h" | 9 #include "chrome/browser/tab_contents/confirm_infobar_delegate.h" |
| 10 #include "content/common/notification_registrar.h" | 10 #include "content/common/notification_registrar.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 protected: | 31 protected: |
| 32 virtual ~ThemeInstalledInfoBarDelegate(); | 32 virtual ~ThemeInstalledInfoBarDelegate(); |
| 33 | 33 |
| 34 ThemeService* theme_service() { return theme_service_; } | 34 ThemeService* theme_service() { return theme_service_; } |
| 35 | 35 |
| 36 // ConfirmInfoBarDelegate: | 36 // ConfirmInfoBarDelegate: |
| 37 virtual bool Cancel(); | 37 virtual bool Cancel(); |
| 38 | 38 |
| 39 private: | 39 private: |
| 40 // ConfirmInfoBarDelegate: | 40 // ConfirmInfoBarDelegate: |
| 41 virtual void InfoBarClosed(); | 41 virtual gfx::Image* GetIcon() const OVERRIDE; |
| 42 virtual gfx::Image* GetIcon() const; | 42 virtual ThemeInstalledInfoBarDelegate* |
| 43 virtual ThemeInstalledInfoBarDelegate* AsThemePreviewInfobarDelegate(); | 43 AsThemePreviewInfobarDelegate() OVERRIDE; |
| 44 virtual string16 GetMessageText() const; | 44 virtual string16 GetMessageText() const OVERRIDE; |
| 45 virtual int GetButtons() const; | 45 virtual int GetButtons() const OVERRIDE; |
| 46 virtual string16 GetButtonLabel(InfoBarButton button) const; | 46 virtual string16 GetButtonLabel(InfoBarButton button) const OVERRIDE; |
| 47 | 47 |
| 48 // NotificationObserver: | 48 // NotificationObserver: |
| 49 virtual void Observe(NotificationType type, | 49 virtual void Observe(NotificationType type, |
| 50 const NotificationSource& source, | 50 const NotificationSource& source, |
| 51 const NotificationDetails& details); | 51 const NotificationDetails& details) OVERRIDE; |
| 52 | 52 |
| 53 Profile* profile_; | 53 Profile* profile_; |
| 54 ThemeService* theme_service_; | 54 ThemeService* theme_service_; |
| 55 | 55 |
| 56 // Name of theme that's just been installed. | 56 // Name of theme that's just been installed. |
| 57 std::string name_; | 57 std::string name_; |
| 58 | 58 |
| 59 // ID of theme that's just been installed. | 59 // ID of theme that's just been installed. |
| 60 std::string theme_id_; | 60 std::string theme_id_; |
| 61 | 61 |
| 62 // Used to undo theme install. | 62 // Used to undo theme install. |
| 63 std::string previous_theme_id_; | 63 std::string previous_theme_id_; |
| 64 bool previous_using_native_theme_; | 64 bool previous_using_native_theme_; |
| 65 | 65 |
| 66 // Tab to which this info bar is associated. | 66 // Tab to which this info bar is associated. |
| 67 TabContents* tab_contents_; | 67 TabContents* tab_contents_; |
| 68 | 68 |
| 69 // Registers and unregisters us for notifications. | 69 // Registers and unregisters us for notifications. |
| 70 NotificationRegistrar registrar_; | 70 NotificationRegistrar registrar_; |
| 71 }; | 71 }; |
| 72 | 72 |
| 73 #endif // CHROME_BROWSER_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ | 73 #endif // CHROME_BROWSER_EXTENSIONS_THEME_INSTALLED_INFOBAR_DELEGATE_H_ |
| OLD | NEW |