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

Unified Diff: chrome/browser/ui/views/avatar_menu_bubble_view.h

Issue 8621004: Revert 111018 - Rebase AvatarMenuBubbleView on the new views bubble. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 1 month 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 | « no previous file | chrome/browser/ui/views/avatar_menu_bubble_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/avatar_menu_bubble_view.h
===================================================================
--- chrome/browser/ui/views/avatar_menu_bubble_view.h (revision 111023)
+++ chrome/browser/ui/views/avatar_menu_bubble_view.h (working copy)
@@ -11,7 +11,7 @@
#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "chrome/browser/profiles/avatar_menu_model_observer.h"
-#include "ui/views/bubble/bubble_delegate.h"
+#include "chrome/browser/ui/views/bubble/bubble.h"
#include "views/controls/button/button.h"
#include "views/controls/link_listener.h"
@@ -26,15 +26,13 @@
// This bubble view is displayed when the user clicks on the avatar button.
// It displays a list of profiles and allows users to switch between profiles.
-class AvatarMenuBubbleView : public views::BubbleDelegateView,
+class AvatarMenuBubbleView : public views::View,
public views::ButtonListener,
public views::LinkListener,
+ public BubbleDelegate,
public AvatarMenuModelObserver {
public:
- AvatarMenuBubbleView(views::View* anchor_view,
- views::BubbleBorder::ArrowLocation arrow_location,
- const gfx::Rect& anchor_rect,
- Browser* browser);
+ explicit AvatarMenuBubbleView(Browser* browser);
virtual ~AvatarMenuBubbleView();
// views::View implementation.
@@ -50,8 +48,10 @@
virtual void LinkClicked(views::Link* source, int event_flags) OVERRIDE;
// BubbleDelegate implementation.
- virtual gfx::Point GetAnchorPoint() OVERRIDE;
- virtual void Init() OVERRIDE;
+ virtual void BubbleShown() OVERRIDE;
+ virtual void BubbleClosing(Bubble* bubble, bool closed_by_escape) OVERRIDE;
+ virtual bool CloseOnEscape() OVERRIDE;
+ virtual bool FadeInOnShow() OVERRIDE;
// AvatarMenuModelObserver implementation.
virtual void OnAvatarMenuModelChanged(
@@ -60,7 +60,6 @@
private:
views::Link* add_profile_link_;
scoped_ptr<AvatarMenuModel> avatar_menu_model_;
- gfx::Rect anchor_rect_;
Browser* browser_;
std::vector<views::CustomButton*> item_views_;
views::Separator* separator_;
« no previous file with comments | « no previous file | chrome/browser/ui/views/avatar_menu_bubble_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698