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

Unified Diff: ui/views/bubble/tray_bubble_view.h

Issue 2901273003: chromeos: Remove TrayBubbleView::Delegate::OnBeforeBubbleWidgetInit (Closed)
Patch Set: cleanup Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
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 7aa054d0713e2ae462012233ac8c18230c4627ff..c104a070245e6d1550eb0a57edfa031d5b74cb55 100644
--- a/ui/views/bubble/tray_bubble_view.h
+++ b/ui/views/bubble/tray_bubble_view.h
@@ -9,6 +9,7 @@
#include "base/macros.h"
#include "base/optional.h"
+#include "ui/gfx/native_widget_types.h"
#include "ui/views/bubble/bubble_dialog_delegate.h"
#include "ui/views/mouse_watcher.h"
#include "ui/views/views_export.h"
@@ -61,15 +62,6 @@ class VIEWS_EXPORT TrayBubbleView : public BubbleDialogDelegateView,
// accessible name for the bubble.
virtual base::string16 GetAccessibleNameForBubble() = 0;
- // Called before Widget::Init() on |bubble_widget|. Allows |params| to be
- // modified.
- // TODO(jamescook): Eliminate this method. It was introduced to let mash set
- // the widget container back when mash could not use aura::Window. Now the
- // anchor view should be sufficient.
- virtual void OnBeforeBubbleWidgetInit(Widget* anchor_widget,
- Widget* bubble_widget,
- Widget::InitParams* params) const = 0;
-
// Called when a bubble wants to hide/destroy itself (e.g. last visible
// child view was closed).
virtual void HideBubble(const TrayBubbleView* bubble_view) = 0;
@@ -91,11 +83,10 @@ class VIEWS_EXPORT TrayBubbleView : public BubbleDialogDelegateView,
base::Optional<SkColor> bg_color;
};
- // Constructs and returns a TrayBubbleView. |init_params| may be modified.
- static TrayBubbleView* Create(views::View* anchor,
- Delegate* delegate,
- InitParams* init_params);
-
+ TrayBubbleView(gfx::NativeWindow parent_window,
+ views::View* anchor,
+ Delegate* delegate,
+ const InitParams& init_params);
~TrayBubbleView() override;
// Returns whether a tray bubble is active.
@@ -152,10 +143,6 @@ class VIEWS_EXPORT TrayBubbleView : public BubbleDialogDelegateView,
void MouseMovedOutOfHost() override;
protected:
- TrayBubbleView(views::View* anchor,
- Delegate* delegate,
- const InitParams& init_params);
-
// Overridden from views::BubbleDialogDelegateView.
int GetDialogButtons() const override;

Powered by Google App Engine
This is Rietveld 408576698