Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(12)

Side by Side Diff: ui/views/bubble/tray_bubble_view.h

Issue 11819048: Implement message center on Windows (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase on master @fa1d2262 and rearrange dependencies. Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_ 5 #ifndef UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
6 #define UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_ 6 #define UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "ui/views/bubble/bubble_delegate.h" 9 #include "ui/views/bubble/bubble_delegate.h"
10 #include "ui/views/views_export.h" 10 #include "ui/views/views_export.h"
(...skipping 16 matching lines...) Expand all
27 27
28 namespace internal { 28 namespace internal {
29 class TrayBubbleBorder; 29 class TrayBubbleBorder;
30 class TrayBubbleContentMask; 30 class TrayBubbleContentMask;
31 } 31 }
32 32
33 class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView { 33 class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView {
34 public: 34 public:
35 enum AnchorType { 35 enum AnchorType {
36 ANCHOR_TYPE_TRAY, 36 ANCHOR_TYPE_TRAY,
37 ANCHOR_TYPE_BUBBLE 37 ANCHOR_TYPE_BUBBLE,
38 }; 38 };
39 39
40 enum AnchorAlignment { 40 enum AnchorAlignment {
41 ANCHOR_ALIGNMENT_BOTTOM, 41 ANCHOR_ALIGNMENT_BOTTOM,
42 ANCHOR_ALIGNMENT_LEFT, 42 ANCHOR_ALIGNMENT_LEFT,
43 ANCHOR_ALIGNMENT_RIGHT 43 ANCHOR_ALIGNMENT_RIGHT
44 }; 44 };
45 45
46 class VIEWS_EXPORT Delegate { 46 class VIEWS_EXPORT Delegate {
47 public: 47 public:
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 79
80 struct VIEWS_EXPORT InitParams { 80 struct VIEWS_EXPORT InitParams {
81 static const int kArrowDefaultOffset; 81 static const int kArrowDefaultOffset;
82 82
83 InitParams(AnchorType anchor_type, 83 InitParams(AnchorType anchor_type,
84 AnchorAlignment anchor_alignment, 84 AnchorAlignment anchor_alignment,
85 int min_width, 85 int min_width,
86 int max_width); 86 int max_width);
87 AnchorType anchor_type; 87 AnchorType anchor_type;
88 AnchorAlignment anchor_alignment; 88 AnchorAlignment anchor_alignment;
89 // The anchor_point is used when no anchor view is available.
90 int anchor_point_x;
91 int anchor_point_y;
89 int min_width; 92 int min_width;
90 int max_width; 93 int max_width;
91 int max_height; 94 int max_height;
92 bool can_activate; 95 bool can_activate;
93 bool close_on_deactivate; 96 bool close_on_deactivate;
94 SkColor arrow_color; 97 SkColor arrow_color;
95 views::BubbleBorder::ArrowLocation arrow_location; 98 views::BubbleBorder::ArrowLocation arrow_location;
96 int arrow_offset; 99 int arrow_offset;
97 views::BubbleBorder::Shadow shadow; 100 views::BubbleBorder::Shadow shadow;
101 views::BubbleBorder::BubbleAlignment arrow_alignment;
98 }; 102 };
99 103
100 // Constructs and returns a TrayBubbleView. init_params may be modified. 104 // Constructs and returns a TrayBubbleView. init_params may be modified.
101 static TrayBubbleView* Create(gfx::NativeView parent_window, 105 static TrayBubbleView* Create(gfx::NativeView parent_window,
102 views::View* anchor, 106 views::View* anchor,
103 Delegate* delegate, 107 Delegate* delegate,
104 InitParams* init_params); 108 InitParams* init_params);
105 109
106 virtual ~TrayBubbleView(); 110 virtual ~TrayBubbleView();
107 111
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 internal::TrayBubbleBorder* bubble_border_; 175 internal::TrayBubbleBorder* bubble_border_;
172 scoped_ptr<internal::TrayBubbleContentMask> bubble_content_mask_; 176 scoped_ptr<internal::TrayBubbleContentMask> bubble_content_mask_;
173 bool is_gesture_dragging_; 177 bool is_gesture_dragging_;
174 178
175 DISALLOW_COPY_AND_ASSIGN(TrayBubbleView); 179 DISALLOW_COPY_AND_ASSIGN(TrayBubbleView);
176 }; 180 };
177 181
178 } // namespace views 182 } // namespace views
179 183
180 #endif // UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_ 184 #endif // UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698