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_PLUGIN_INSTALLER_INFOBAR_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_PLUGIN_INSTALLER_INFOBAR_DELEGATE_H_ |
6 #define CHROME_BROWSER_PLUGIN_INSTALLER_INFOBAR_DELEGATE_H_ | 6 #define CHROME_BROWSER_PLUGIN_INSTALLER_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 | 10 |
11 class TabContents; | 11 class TabContents; |
12 | 12 |
13 // The main purpose for this class is to popup/close the infobar when there is | 13 // The main purpose for this class is to popup/close the infobar when there is |
14 // a missing plugin. | 14 // a missing plugin. |
15 class PluginInstallerInfoBarDelegate : public ConfirmInfoBarDelegate { | 15 class PluginInstallerInfoBarDelegate : public ConfirmInfoBarDelegate { |
16 public: | 16 public: |
17 explicit PluginInstallerInfoBarDelegate(TabContents* tab_contents); | 17 explicit PluginInstallerInfoBarDelegate(TabContents* tab_contents, |
jam
2011/08/31 17:34:42
nit: explicit isn't needed anymore
ananta
2011/08/31 20:18:14
Done.
| |
18 int window); | |
18 | 19 |
19 private: | 20 private: |
20 virtual ~PluginInstallerInfoBarDelegate(); | 21 virtual ~PluginInstallerInfoBarDelegate(); |
21 | 22 |
22 // ConfirmInfoBarDelegate: | 23 // ConfirmInfoBarDelegate: |
23 virtual gfx::Image* GetIcon() const OVERRIDE; | 24 virtual gfx::Image* GetIcon() const OVERRIDE; |
24 virtual PluginInstallerInfoBarDelegate* | 25 virtual PluginInstallerInfoBarDelegate* |
25 AsPluginInstallerInfoBarDelegate() OVERRIDE; | 26 AsPluginInstallerInfoBarDelegate() OVERRIDE; |
26 virtual string16 GetMessageText() const OVERRIDE; | 27 virtual string16 GetMessageText() const OVERRIDE; |
27 virtual int GetButtons() const OVERRIDE; | 28 virtual int GetButtons() const OVERRIDE; |
28 virtual string16 GetButtonLabel(InfoBarButton button) const OVERRIDE; | 29 virtual string16 GetButtonLabel(InfoBarButton button) const OVERRIDE; |
29 virtual bool Accept() OVERRIDE; | 30 virtual bool Accept() OVERRIDE; |
30 virtual string16 GetLinkText() const OVERRIDE; | 31 virtual string16 GetLinkText() const OVERRIDE; |
31 virtual bool LinkClicked(WindowOpenDisposition disposition) OVERRIDE; | 32 virtual bool LinkClicked(WindowOpenDisposition disposition) OVERRIDE; |
32 | 33 |
33 // The containing TabContents | 34 // The containing TabContents |
34 TabContents* tab_contents_; | 35 TabContents* tab_contents_; |
36 int window_; | |
35 | 37 |
36 DISALLOW_COPY_AND_ASSIGN(PluginInstallerInfoBarDelegate); | 38 DISALLOW_COPY_AND_ASSIGN(PluginInstallerInfoBarDelegate); |
37 }; | 39 }; |
38 | 40 |
39 #endif // CHROME_BROWSER_PLUGIN_INSTALLER_INFOBAR_DELEGATE_H_ | 41 #endif // CHROME_BROWSER_PLUGIN_INSTALLER_INFOBAR_DELEGATE_H_ |
OLD | NEW |