| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ | 5 #ifndef ASH_SYSTEM_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ |
| 6 #define ASH_SYSTEM_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ | 6 #define ASH_SYSTEM_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ |
| 7 | 7 |
| 8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
| 9 #include "ash/shell_observer.h" | |
| 10 #include "ash/system/tray/tray_background_view.h" | 9 #include "ash/system/tray/tray_background_view.h" |
| 11 | 10 |
| 12 namespace views { | 11 namespace views { |
| 13 class ImageView; | 12 class ImageView; |
| 14 } | 13 } |
| 15 | 14 |
| 16 namespace ash { | 15 namespace ash { |
| 17 | 16 |
| 18 // Status area tray for showing a toggle for Overview Mode. Overview Mode | 17 // Status area tray for showing a toggle for Overview Mode. Overview Mode |
| 19 // is equivalent to WindowSelectorController being in selection mode. | 18 // is equivalent to WindowSelectorController being in selection mode. |
| 20 // This hosts a ShellObserver that listens for the activation of Maximize Mode | 19 // This hosts a ShellObserver that listens for the activation of Maximize Mode |
| 21 // This tray will only be visible while in this state. This tray does not | 20 // This tray will only be visible while in this state. This tray does not |
| 22 // provide any bubble view windows. | 21 // provide any bubble view windows. |
| 23 class ASH_EXPORT OverviewButtonTray : public TrayBackgroundView, | 22 class ASH_EXPORT OverviewButtonTray : public TrayBackgroundView { |
| 24 public ShellObserver { | |
| 25 public: | 23 public: |
| 26 explicit OverviewButtonTray(StatusAreaWidget* status_area_widget); | 24 explicit OverviewButtonTray(StatusAreaWidget* status_area_widget); |
| 27 virtual ~OverviewButtonTray(); | 25 virtual ~OverviewButtonTray(); |
| 28 | 26 |
| 29 // Updates the tray's visibility based on the LoginStatus and the current | 27 // Updates the tray's visibility based on the LoginStatus and the current |
| 30 // state of MaximizeMode | 28 // state of MaximizeMode |
| 31 virtual void UpdateAfterLoginStatusChange(user::LoginStatus status); | 29 virtual void UpdateAfterLoginStatusChange(user::LoginStatus status); |
| 32 | 30 |
| 33 // ActionableView: | 31 // ActionableView: |
| 34 virtual bool PerformAction(const ui::Event& event) OVERRIDE; | 32 virtual bool PerformAction(const ui::Event& event) OVERRIDE; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 57 | 55 |
| 58 // Weak pointer, will be parented by TrayContainer for its lifetime. | 56 // Weak pointer, will be parented by TrayContainer for its lifetime. |
| 59 views::ImageView* icon_; | 57 views::ImageView* icon_; |
| 60 | 58 |
| 61 DISALLOW_COPY_AND_ASSIGN(OverviewButtonTray); | 59 DISALLOW_COPY_AND_ASSIGN(OverviewButtonTray); |
| 62 }; | 60 }; |
| 63 | 61 |
| 64 } // namespace ash | 62 } // namespace ash |
| 65 | 63 |
| 66 #endif // ASH_SYSTEM_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ | 64 #endif // ASH_SYSTEM_OVERVIEW_OVERVIEW_BUTTON_TRAY_H_ |
| OLD | NEW |