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

Side by Side Diff: ash/system/status_area_widget.h

Issue 1659283002: ash: Explicitly teach various components about ShelfLayoutManager. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@ozone-ui-event-platform-event
Patch Set: fix-test Created 4 years, 10 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
« no previous file with comments | « ash/shelf/shelf_widget.cc ('k') | ash/system/status_area_widget.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 ASH_SYSTEM_STATUS_AREA_WIDGET_H_ 5 #ifndef ASH_SYSTEM_STATUS_AREA_WIDGET_H_
6 #define ASH_SYSTEM_STATUS_AREA_WIDGET_H_ 6 #define ASH_SYSTEM_STATUS_AREA_WIDGET_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/shelf/shelf_types.h" 9 #include "ash/shelf/shelf_types.h"
10 #include "ash/system/user/login_status.h" 10 #include "ash/system/user/login_status.h"
11 #include "base/macros.h" 11 #include "base/macros.h"
12 #include "ui/views/widget/widget.h" 12 #include "ui/views/widget/widget.h"
13 13
14 namespace ash { 14 namespace ash {
15 class OverviewButtonTray; 15 class OverviewButtonTray;
16 class ShelfWidget;
16 class ShellDelegate; 17 class ShellDelegate;
17 class StatusAreaWidgetDelegate; 18 class StatusAreaWidgetDelegate;
18 class SystemTray; 19 class SystemTray;
19 class WebNotificationTray; 20 class WebNotificationTray;
20 #if defined(OS_CHROMEOS) 21 #if defined(OS_CHROMEOS)
21 class LogoutButtonTray; 22 class LogoutButtonTray;
22 class VirtualKeyboardTray; 23 class VirtualKeyboardTray;
23 #endif 24 #endif
24 25
25 class ASH_EXPORT StatusAreaWidget : public views::Widget { 26 class ASH_EXPORT StatusAreaWidget : public views::Widget {
26 public: 27 public:
27 static const char kNativeViewName[]; 28 static const char kNativeViewName[];
28 29
29 explicit StatusAreaWidget(aura::Window* status_container); 30 StatusAreaWidget(aura::Window* status_container, ShelfWidget* shelf_widget);
30 ~StatusAreaWidget() override; 31 ~StatusAreaWidget() override;
31 32
32 // Creates the SystemTray, WebNotificationTray and LogoutButtonTray. 33 // Creates the SystemTray, WebNotificationTray and LogoutButtonTray.
33 void CreateTrayViews(); 34 void CreateTrayViews();
34 35
35 // Destroys the system tray and web notification tray. Called before 36 // Destroys the system tray and web notification tray. Called before
36 // tearing down the windows to avoid shutdown ordering issues. 37 // tearing down the windows to avoid shutdown ordering issues.
37 void Shutdown(); 38 void Shutdown();
38 39
39 // Update the alignment of the widget and tray views. 40 // Update the alignment of the widget and tray views.
(...skipping 10 matching lines...) Expand all
50 StatusAreaWidgetDelegate* status_area_widget_delegate() { 51 StatusAreaWidgetDelegate* status_area_widget_delegate() {
51 return status_area_widget_delegate_; 52 return status_area_widget_delegate_;
52 } 53 }
53 SystemTray* system_tray() { return system_tray_; } 54 SystemTray* system_tray() { return system_tray_; }
54 WebNotificationTray* web_notification_tray() { 55 WebNotificationTray* web_notification_tray() {
55 return web_notification_tray_; 56 return web_notification_tray_;
56 } 57 }
57 OverviewButtonTray* overview_button_tray() { 58 OverviewButtonTray* overview_button_tray() {
58 return overview_button_tray_; 59 return overview_button_tray_;
59 } 60 }
61 ShelfWidget* shelf_widget() { return shelf_widget_; }
60 62
61 user::LoginStatus login_status() const { return login_status_; } 63 user::LoginStatus login_status() const { return login_status_; }
62 64
63 // Returns true if the shelf should be visible. This is used when the 65 // Returns true if the shelf should be visible. This is used when the
64 // shelf is configured to auto-hide and test if the shelf should force 66 // shelf is configured to auto-hide and test if the shelf should force
65 // the shelf to remain visible. 67 // the shelf to remain visible.
66 bool ShouldShowShelf() const; 68 bool ShouldShowShelf() const;
67 69
68 // True if any message bubble is shown. 70 // True if any message bubble is shown.
69 bool IsMessageBubbleShown() const; 71 bool IsMessageBubbleShown() const;
(...skipping 18 matching lines...) Expand all
88 StatusAreaWidgetDelegate* status_area_widget_delegate_; 90 StatusAreaWidgetDelegate* status_area_widget_delegate_;
89 OverviewButtonTray* overview_button_tray_; 91 OverviewButtonTray* overview_button_tray_;
90 SystemTray* system_tray_; 92 SystemTray* system_tray_;
91 WebNotificationTray* web_notification_tray_; 93 WebNotificationTray* web_notification_tray_;
92 #if defined(OS_CHROMEOS) 94 #if defined(OS_CHROMEOS)
93 LogoutButtonTray* logout_button_tray_; 95 LogoutButtonTray* logout_button_tray_;
94 VirtualKeyboardTray* virtual_keyboard_tray_; 96 VirtualKeyboardTray* virtual_keyboard_tray_;
95 #endif 97 #endif
96 user::LoginStatus login_status_; 98 user::LoginStatus login_status_;
97 99
100 ShelfWidget* shelf_widget_;
101
98 DISALLOW_COPY_AND_ASSIGN(StatusAreaWidget); 102 DISALLOW_COPY_AND_ASSIGN(StatusAreaWidget);
99 }; 103 };
100 104
101 } // namespace ash 105 } // namespace ash
102 106
103 #endif // ASH_SYSTEM_STATUS_AREA_WIDGET_H_ 107 #endif // ASH_SYSTEM_STATUS_AREA_WIDGET_H_
OLDNEW
« no previous file with comments | « ash/shelf/shelf_widget.cc ('k') | ash/system/status_area_widget.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698