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

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

Issue 11229022: Move ash/system/web_notification message_center to ui/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase again. Created 8 years, 2 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
« no previous file with comments | « ui/resources/ui_resources.grd ('k') | ui/views/bubble/tray_bubble_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/bubble/tray_bubble_view.h
diff --git a/ash/system/tray/tray_bubble_view.h b/ui/views/bubble/tray_bubble_view.h
similarity index 89%
rename from ash/system/tray/tray_bubble_view.h
rename to ui/views/bubble/tray_bubble_view.h
index 5c2e8220047355fad1713cc855d5300c03a56ab1..a8531ecaa0eb50bcb128e7e7cde4dec43ecb3413 100644
--- a/ash/system/tray/tray_bubble_view.h
+++ b/ui/views/bubble/tray_bubble_view.h
@@ -2,11 +2,11 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef ASH_SYSTEM_TRAY_TRAY_BUBBLE_VIEW_H_
-#define ASH_SYSTEM_TRAY_TRAY_BUBBLE_VIEW_H_
+#ifndef UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
+#define UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
-#include "ash/ash_export.h"
#include "ui/views/bubble/bubble_delegate.h"
+#include "ui/views/views_export.h"
// Specialized bubble view for bubbles associated with a tray icon (e.g. the
// Ash status area). Mostly this handles custom anchor location and arrow and
@@ -22,15 +22,14 @@ class View;
class Widget;
}
-// TODO(stevenjb): Move this out of message_center namespace once in views.
-namespace message_center {
+namespace views {
namespace internal {
class TrayBubbleBorder;
class TrayBubbleBackground;
}
-class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
+class VIEWS_EXPORT TrayBubbleView : public views::BubbleDelegateView {
public:
enum AnchorType {
ANCHOR_TYPE_TRAY,
@@ -43,7 +42,7 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
ANCHOR_ALIGNMENT_RIGHT
};
- class ASH_EXPORT Delegate {
+ class VIEWS_EXPORT Delegate {
public:
typedef TrayBubbleView::AnchorType AnchorType;
typedef TrayBubbleView::AnchorAlignment AnchorAlignment;
@@ -77,7 +76,7 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
DISALLOW_COPY_AND_ASSIGN(Delegate);
};
- struct InitParams {
+ struct VIEWS_EXPORT InitParams {
static const int kArrowDefaultOffset;
InitParams(AnchorType anchor_type,
@@ -97,7 +96,7 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
};
// Constructs and returns a TrayBubbleView. init_params may be modified.
- static TrayBubbleView* Create(aura::Window* parent_window,
+ static TrayBubbleView* Create(gfx::NativeView parent_window,
views::View* anchor,
Delegate* delegate,
InitParams* init_params);
@@ -114,6 +113,9 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
// Sets the maximum bubble height and resizes the bubble.
void SetMaxHeight(int height);
+ // Sets whether or not to paint the bubble border arrow.
+ void SetPaintArrow(bool paint_arrow);
+
// Returns the border insets. Called by TrayEventFilter.
void GetBorderInsets(gfx::Insets* insets) const;
@@ -142,7 +144,7 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE;
protected:
- TrayBubbleView(aura::Window* parent_window,
+ TrayBubbleView(gfx::NativeView parent_window,
views::View* anchor,
Delegate* delegate,
const InitParams& init_params);
@@ -166,6 +168,6 @@ class ASH_EXPORT TrayBubbleView : public views::BubbleDelegateView {
DISALLOW_COPY_AND_ASSIGN(TrayBubbleView);
};
-} // namespace message_center
+} // namespace views
-#endif // ASH_SYSTEM_TRAY_TRAY_BUBBLE_VIEW_H_
+#endif // UI_VIEWS_BUBBLE_TRAY_BUBBLE_VIEW_H_
« no previous file with comments | « ui/resources/ui_resources.grd ('k') | ui/views/bubble/tray_bubble_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698