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

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

Issue 2092473002: Convert TrayBubbleView to wm common types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@traybubblewrapper
Patch Set: review feedback Created 4 years, 6 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_BUBBLE_DIALOG_DELEGATE_H_ 5 #ifndef UI_VIEWS_BUBBLE_BUBBLE_DIALOG_DELEGATE_H_
6 #define UI_VIEWS_BUBBLE_BUBBLE_DIALOG_DELEGATE_H_ 6 #define UI_VIEWS_BUBBLE_BUBBLE_DIALOG_DELEGATE_H_
7 7
8 #include "base/gtest_prod_util.h" 8 #include "base/gtest_prod_util.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "ui/views/bubble/bubble_border.h" 10 #include "ui/views/bubble/bubble_border.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 bool border_accepts_events() const { return border_accepts_events_; } 92 bool border_accepts_events() const { return border_accepts_events_; }
93 void set_border_accepts_events(bool event) { border_accepts_events_ = event; } 93 void set_border_accepts_events(bool event) { border_accepts_events_ = event; }
94 94
95 bool adjust_if_offscreen() const { return adjust_if_offscreen_; } 95 bool adjust_if_offscreen() const { return adjust_if_offscreen_; }
96 void set_adjust_if_offscreen(bool adjust) { adjust_if_offscreen_ = adjust; } 96 void set_adjust_if_offscreen(bool adjust) { adjust_if_offscreen_ = adjust; }
97 97
98 // Get the arrow's anchor rect in screen space. 98 // Get the arrow's anchor rect in screen space.
99 virtual gfx::Rect GetAnchorRect() const; 99 virtual gfx::Rect GetAnchorRect() const;
100 100
101 // Allows delegates to provide custom parameters before widget initialization. 101 // Allows delegates to provide custom parameters before widget initialization.
102 // For example, mus needs to set a custom mus::Window* parent.
102 virtual void OnBeforeBubbleWidgetInit(Widget::InitParams* params, 103 virtual void OnBeforeBubbleWidgetInit(Widget::InitParams* params,
103 Widget* widget) const; 104 Widget* widget) const;
104 105
105 // Sets |margins_| to a default picked for smaller bubbles. 106 // Sets |margins_| to a default picked for smaller bubbles.
106 void UseCompactMargins(); 107 void UseCompactMargins();
107 108
108 // Sets the bubble alignment relative to the anchor. This may only be called 109 // Sets the bubble alignment relative to the anchor. This may only be called
109 // after calling CreateBubble. 110 // after calling CreateBubble.
110 void SetAlignment(BubbleBorder::BubbleAlignment alignment); 111 void SetAlignment(BubbleBorder::BubbleAlignment alignment);
111 112
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 201
201 // Parent native window of the bubble. 202 // Parent native window of the bubble.
202 gfx::NativeView parent_window_; 203 gfx::NativeView parent_window_;
203 204
204 DISALLOW_COPY_AND_ASSIGN(BubbleDialogDelegateView); 205 DISALLOW_COPY_AND_ASSIGN(BubbleDialogDelegateView);
205 }; 206 };
206 207
207 } // namespace views 208 } // namespace views
208 209
209 #endif // UI_VIEWS_BUBBLE_BUBBLE_DELEGATE2_H_ 210 #endif // UI_VIEWS_BUBBLE_BUBBLE_DELEGATE2_H_
OLDNEW
« no previous file with comments | « ash/system/web_notification/web_notification_tray.cc ('k') | ui/views/bubble/tray_bubble_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698