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_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ | 5 #ifndef CHROME_BROWSER_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ |
6 #define CHROME_BROWSER_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ | 6 #define CHROME_BROWSER_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "chrome/browser/extensions/extension_infobar_delegate.h" | 10 #include "chrome/browser/extensions/extension_infobar_delegate.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 // Overridden from InfoBar (through InfoBarGtk): | 29 // Overridden from InfoBar (through InfoBarGtk): |
30 virtual void PlatformSpecificHide(bool animate) OVERRIDE; | 30 virtual void PlatformSpecificHide(bool animate) OVERRIDE; |
31 | 31 |
32 // Overridden from InfoBarGtk: | 32 // Overridden from InfoBarGtk: |
33 virtual void GetTopColor(InfoBarDelegate::Type type, | 33 virtual void GetTopColor(InfoBarDelegate::Type type, |
34 double* r, double* g, double* b) OVERRIDE; | 34 double* r, double* g, double* b) OVERRIDE; |
35 virtual void GetBottomColor(InfoBarDelegate::Type type, | 35 virtual void GetBottomColor(InfoBarDelegate::Type type, |
36 double* r, double* g, double* b) OVERRIDE; | 36 double* r, double* g, double* b) OVERRIDE; |
37 | 37 |
38 // Overridden from ImageLoadingTracker::Observer: | 38 // Overridden from ImageLoadingTracker::Observer: |
39 virtual void OnImageLoaded( | 39 virtual void OnImageLoaded(const gfx::Image& image, |
40 SkBitmap* image, const ExtensionResource& resource, int index) OVERRIDE; | 40 const std::string& extension_id, |
| 41 int index) OVERRIDE; |
41 | 42 |
42 // Overridden from MenuGtk::Delegate: | 43 // Overridden from MenuGtk::Delegate: |
43 virtual void StoppedShowing() OVERRIDE; | 44 virtual void StoppedShowing() OVERRIDE; |
44 | 45 |
45 private: | 46 private: |
46 // Build the widgets of the Infobar. | 47 // Build the widgets of the Infobar. |
47 void BuildWidgets(); | 48 void BuildWidgets(); |
48 | 49 |
49 // Looks at the window the infobar is in and gets the browser. Can return | 50 // Looks at the window the infobar is in and gets the browser. Can return |
50 // NULL if we aren't attached. | 51 // NULL if we aren't attached. |
(...skipping 27 matching lines...) Expand all Loading... |
78 // An alignment with one pixel of bottom padding. This is set so the |view_| | 79 // An alignment with one pixel of bottom padding. This is set so the |view_| |
79 // doesn't overlap the bottom separator. This also makes it more convenient | 80 // doesn't overlap the bottom separator. This also makes it more convenient |
80 // to reattach the view since the alignment_ will have the |hbox_| packing | 81 // to reattach the view since the alignment_ will have the |hbox_| packing |
81 // child properties. Reparenting becomes easier too. | 82 // child properties. Reparenting becomes easier too. |
82 GtkWidget* alignment_; | 83 GtkWidget* alignment_; |
83 | 84 |
84 DISALLOW_COPY_AND_ASSIGN(ExtensionInfoBarGtk); | 85 DISALLOW_COPY_AND_ASSIGN(ExtensionInfoBarGtk); |
85 }; | 86 }; |
86 | 87 |
87 #endif // CHROME_BROWSER_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ | 88 #endif // CHROME_BROWSER_UI_GTK_INFOBARS_EXTENSION_INFOBAR_GTK_H_ |
OLD | NEW |