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

Side by Side Diff: chrome/browser/ui/views/frame/browser_frame.h

Issue 24647003: Redesign of the avatar menu button. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: better fix for app/popup browser crash Created 7 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 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 CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_ 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
11 #include "chrome/browser/ui/views/frame/browser_non_client_frame_view.h" 11 #include "chrome/browser/ui/views/frame/browser_non_client_frame_view.h"
12 #include "ui/views/context_menu_controller.h" 12 #include "ui/views/context_menu_controller.h"
13 #include "ui/views/widget/widget.h" 13 #include "ui/views/widget/widget.h"
14 14
15 class AvatarMenuButton; 15 class AvatarMenuButton;
16 class BrowserRootView; 16 class BrowserRootView;
17 class BrowserView; 17 class BrowserView;
18 class NativeBrowserFrame; 18 class NativeBrowserFrame;
19 class NewAvatarButton;
19 class NonClientFrameView; 20 class NonClientFrameView;
20 class SystemMenuModelBuilder; 21 class SystemMenuModelBuilder;
21 22
22 namespace gfx { 23 namespace gfx {
23 class Font; 24 class Font;
24 class Rect; 25 class Rect;
25 } 26 }
26 27
27 namespace ui { 28 namespace ui {
28 class MenuModel; 29 class MenuModel;
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 const gfx::Point& p, 92 const gfx::Point& p,
92 ui::MenuSourceType source_type) OVERRIDE; 93 ui::MenuSourceType source_type) OVERRIDE;
93 94
94 // Returns true if we should leave any offset at the frame caption. Typically 95 // Returns true if we should leave any offset at the frame caption. Typically
95 // when the frame is maximized/full screen we want to leave no offset at the 96 // when the frame is maximized/full screen we want to leave no offset at the
96 // top. 97 // top.
97 bool ShouldLeaveOffsetNearTopBorder(); 98 bool ShouldLeaveOffsetNearTopBorder();
98 99
99 AvatarMenuButton* GetAvatarMenuButton(); 100 AvatarMenuButton* GetAvatarMenuButton();
100 101
102 NewAvatarButton* GetNewAvatarMenuButton();
103
101 // Returns the menu model. BrowserFrame owns the returned model. 104 // Returns the menu model. BrowserFrame owns the returned model.
102 ui::MenuModel* GetSystemMenuModel(); 105 ui::MenuModel* GetSystemMenuModel();
103 106
104 private: 107 private:
105 NativeBrowserFrame* native_browser_frame_; 108 NativeBrowserFrame* native_browser_frame_;
106 109
107 // A weak reference to the root view associated with the window. We save a 110 // A weak reference to the root view associated with the window. We save a
108 // copy as a BrowserRootView to avoid evil casting later, when we need to call 111 // copy as a BrowserRootView to avoid evil casting later, when we need to call
109 // functions that only exist on BrowserRootView (versus RootView). 112 // functions that only exist on BrowserRootView (versus RootView).
110 BrowserRootView* root_view_; 113 BrowserRootView* root_view_;
(...skipping 14 matching lines...) Expand all
125 // |theme_provider_|. Initially |theme_provider_| is set to the ThemeService 128 // |theme_provider_|. Initially |theme_provider_| is set to the ThemeService
126 // and |owned_theme_provider_| is NULL (as ThemeServices lifetime is managed 129 // and |owned_theme_provider_| is NULL (as ThemeServices lifetime is managed
127 // externally). 130 // externally).
128 scoped_ptr<ui::ThemeProvider> owned_theme_provider_; 131 scoped_ptr<ui::ThemeProvider> owned_theme_provider_;
129 ui::ThemeProvider* theme_provider_; 132 ui::ThemeProvider* theme_provider_;
130 133
131 DISALLOW_COPY_AND_ASSIGN(BrowserFrame); 134 DISALLOW_COPY_AND_ASSIGN(BrowserFrame);
132 }; 135 };
133 136
134 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_ 137 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/avatar_menu_button_browsertest.cc ('k') | chrome/browser/ui/views/frame/browser_frame.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698