Index: components/infobars/core/infobar.h |
diff --git a/components/infobars/core/infobar.h b/components/infobars/core/infobar.h |
index 6124d880c784c45ce94abb5922d5108b9f52314a..feec5f6bb230f4c21c74155776e398168986cd48 100644 |
--- a/components/infobars/core/infobar.h |
+++ b/components/infobars/core/infobar.h |
@@ -19,6 +19,19 @@ namespace infobars { |
class InfoBarContainer; |
class InfoBarManager; |
+// InfoBarConstants holds embedder specific constants used by InfoBar |
+// animation implementation. |
+struct InfoBarConstants { |
+ int separator_line_height; |
+ int default_bar_target_height; |
+ int default_arrow_target_height; |
+ int maximum_arrow_target_height; |
+ // The half-width (see comments on |arrow_half_width_| below) scales to its |
+ // default and maximum values proportionally to how the height scales to its. |
+ int default_arrow_target_half_width; |
+ int maximum_arrow_target_half_width; |
+}; |
+ |
// InfoBar is a cross-platform base class for an infobar "view" (in the MVC |
// sense), which owns a corresponding InfoBarDelegate "model". Typically, |
// a caller will call XYZInfoBarDelegate::Create() and pass in the |
@@ -40,17 +53,7 @@ class InfoBar : public gfx::AnimationDelegate { |
typedef InfoBar AddedDetails; |
typedef std::pair<InfoBar*, bool> RemovedDetails; |
- // Platforms must define these. |
- static const int kDefaultBarTargetHeight; |
- static const int kSeparatorLineHeight; |
- static const int kDefaultArrowTargetHeight; |
- static const int kMaximumArrowTargetHeight; |
- // The half-width (see comments on |arrow_half_width_| below) scales to its |
- // default and maximum values proportionally to how the height scales to its. |
- static const int kDefaultArrowTargetHalfWidth; |
- static const int kMaximumArrowTargetHalfWidth; |
- |
- explicit InfoBar(scoped_ptr<InfoBarDelegate> delegate); |
+ InfoBar(scoped_ptr<InfoBarDelegate> delegate); |
~InfoBar() override; |
static SkColor GetTopColor(InfoBarDelegate::Type infobar_type); |