Index: ui/views/bubble/tray_bubble_view.h |
diff --git a/ui/views/bubble/tray_bubble_view.h b/ui/views/bubble/tray_bubble_view.h |
index ced054f54fe49c72991a55e419ea9ad68bfb0538..2a2ea443bb610594bbf6020cf4d72d90b411c66a 100644 |
--- a/ui/views/bubble/tray_bubble_view.h |
+++ b/ui/views/bubble/tray_bubble_view.h |
@@ -82,10 +82,12 @@ class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView { |
InitParams(AnchorType anchor_type, |
AnchorAlignment anchor_alignment, |
- int bubble_width); |
+ int min_width, |
+ int max_width); |
AnchorType anchor_type; |
AnchorAlignment anchor_alignment; |
- int bubble_width; |
+ int min_width; |
+ int max_width; |
int max_height; |
bool can_activate; |
bool close_on_deactivate; |
@@ -113,6 +115,9 @@ class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView { |
// Sets the maximum bubble height and resizes the bubble. |
void SetMaxHeight(int height); |
+ // Sets the bubble width. |
+ void SetWidth(int width); |
+ |
// Sets whether or not to paint the bubble border arrow. |
void SetPaintArrow(bool paint_arrow); |
@@ -139,6 +144,7 @@ class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView { |
// Overridden from views::View. |
virtual gfx::Size GetPreferredSize() OVERRIDE; |
+ virtual gfx::Size GetMaximumSize() OVERRIDE; |
virtual void OnMouseEntered(const ui::MouseEvent& event) OVERRIDE; |
virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; |
virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; |
@@ -161,6 +167,7 @@ class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView { |
private: |
InitParams params_; |
Delegate* delegate_; |
+ int preferred_width_; |
internal::TrayBubbleBorder* bubble_border_; |
scoped_ptr<internal::TrayBubbleContentMask> bubble_content_mask_; |
bool is_gesture_dragging_; |