Index: chrome/browser/ui/views/infobars/infobar_view.h |
diff --git a/chrome/browser/ui/views/infobars/infobar_view.h b/chrome/browser/ui/views/infobars/infobar_view.h |
index 919284804a3a0f81e201fc62f8627727d3db02b8..9486766001cd0c1bf628594375076c65f4513cd4 100644 |
--- a/chrome/browser/ui/views/infobars/infobar_view.h |
+++ b/chrome/browser/ui/views/infobars/infobar_view.h |
@@ -92,9 +92,9 @@ class InfoBarView : public infobars::InfoBar, |
int StartX() const; |
int EndX() const; |
- // Given a |view|, returns the centered y position within us, taking into |
- // account animation so the control "slides in" (or out) as we animate open |
- // and closed. |
+ // Given a |view|, returns the centered y position within |child_container_|, |
+ // taking into account animation so the control "slides in" (or out) as we |
+ // animate open and closed. |
int OffsetY(views::View* view) const; |
// Convenience getter. |
@@ -107,6 +107,11 @@ class InfoBarView : public infobars::InfoBar, |
views::MenuButton* button, |
views::MenuAnchorPosition anchor); |
+ protected: |
+ // Adds |view| to the content area, i.e. |child_container_|. The |view| won't |
+ // automatically get any layout, so should still be laid out manually. |
+ void AddViewToContentArea(views::View* view); |
+ |
private: |
// Does the actual work for AssignWidths(). Assumes |labels| is sorted by |
// decreasing preferred width. |
@@ -120,11 +125,14 @@ class InfoBarView : public infobars::InfoBar, |
// views::View: |
void GetAccessibleState(ui::AXViewState* state) override; |
gfx::Size GetPreferredSize() const override; |
- void PaintChildren(const ui::PaintContext& context) override; |
// views::ExternalFocusTracker: |
void OnWillChangeFocus(View* focused_before, View* focused_now) override; |
+ // This container holds the children and clips their painting during |
+ // animation. |
+ views::View* child_container_; |
+ |
// The optional icon at the left edge of the InfoBar. |
views::ImageView* icon_; |