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

Unified Diff: ash/system/status_area_widget.h

Issue 10535112: Prepare status area to support multiple trays. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years, 6 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 | « ash/shell/content_client/shell_browser_main_parts.cc ('k') | ash/system/status_area_widget.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/status_area_widget.h
diff --git a/ash/system/status_area_widget.h b/ash/system/status_area_widget.h
index 1a99a0f328978735734a87139bf65aa4d3a7e776..8e56688e55657aa5e024e2253eb2d54b074b7a40 100644
--- a/ash/system/status_area_widget.h
+++ b/ash/system/status_area_widget.h
@@ -11,6 +11,11 @@
#include "ui/views/widget/widget.h"
namespace ash {
+
+class ShellDelegate;
+class SystemTray;
+class SystemTrayDelegate;
+
namespace internal {
class StatusAreaWidgetDelegate;
@@ -20,11 +25,27 @@ class ASH_EXPORT StatusAreaWidget : public views::Widget {
StatusAreaWidget();
virtual ~StatusAreaWidget();
- void AddTray(views::View* tray);
+ // Creates the SystemTray.
+ void CreateTrayViews(ShellDelegate* shell_delegate);
+
+ // Destroys the system tray. Called before tearing down the windows to avoid
+ // shutdown ordering issues.
+ void Shutdown();
+
void SetShelfAlignment(ShelfAlignment alignment);
+ SystemTray* system_tray() { return system_tray_; }
+ SystemTrayDelegate* system_tray_delegate() {
+ return system_tray_delegate_.get();
+ }
+
private:
+ void AddSystemTray(SystemTray* system_tray, ShellDelegate* shell_delegate);
+
+ scoped_ptr<SystemTrayDelegate> system_tray_delegate_;
+ // Weak pointers to View classes that are parented to StatusAreaWidget:
internal::StatusAreaWidgetDelegate* widget_delegate_;
+ SystemTray* system_tray_;
DISALLOW_COPY_AND_ASSIGN(StatusAreaWidget);
};
« no previous file with comments | « ash/shell/content_client/shell_browser_main_parts.cc ('k') | ash/system/status_area_widget.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698