| OLD | NEW |
| 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_AUDIO_TRAY_VOLUME_H_ | 5 #ifndef ASH_SYSTEM_AUDIO_TRAY_VOLUME_H_ |
| 6 #define ASH_SYSTEM_AUDIO_TRAY_VOLUME_H_ | 6 #define ASH_SYSTEM_AUDIO_TRAY_VOLUME_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "ash/system/audio/audio_controller.h" | 9 #include "ash/system/audio/audio_controller.h" |
| 10 #include "ash/system/tray/system_tray_item.h" | 10 #include "ash/system/tray/system_tray_item.h" |
| 11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
| 12 | 12 |
| 13 namespace views { | 13 namespace ash { |
| 14 class ImageView; | 14 namespace internal { |
| 15 } | |
| 16 | 15 |
| 17 namespace tray { | 16 namespace tray { |
| 18 class VolumeView; | 17 class VolumeView; |
| 19 } | 18 } |
| 20 | 19 |
| 21 namespace ash { | |
| 22 namespace internal { | |
| 23 | |
| 24 class TrayVolume : public SystemTrayItem, | 20 class TrayVolume : public SystemTrayItem, |
| 25 public AudioController { | 21 public AudioController { |
| 26 public: | 22 public: |
| 27 TrayVolume(); | 23 TrayVolume(); |
| 28 virtual ~TrayVolume(); | 24 virtual ~TrayVolume(); |
| 29 | 25 |
| 30 private: | 26 private: |
| 31 // Overridden from SystemTrayItem | 27 // Overridden from SystemTrayItem. |
| 32 virtual views::View* CreateTrayView() OVERRIDE; | 28 virtual views::View* CreateTrayView() OVERRIDE; |
| 33 virtual views::View* CreateDefaultView() OVERRIDE; | 29 virtual views::View* CreateDefaultView() OVERRIDE; |
| 34 virtual views::View* CreateDetailedView() OVERRIDE; | 30 virtual views::View* CreateDetailedView() OVERRIDE; |
| 35 virtual void DestroyTrayView() OVERRIDE; | 31 virtual void DestroyTrayView() OVERRIDE; |
| 36 virtual void DestroyDefaultView() OVERRIDE; | 32 virtual void DestroyDefaultView() OVERRIDE; |
| 37 virtual void DestroyDetailedView() OVERRIDE; | 33 virtual void DestroyDetailedView() OVERRIDE; |
| 38 | 34 |
| 39 // Overridden from AudioController. | 35 // Overridden from AudioController. |
| 40 virtual void OnVolumeChanged(float percent) OVERRIDE; | 36 virtual void OnVolumeChanged(float percent) OVERRIDE; |
| 41 | 37 |
| 42 scoped_ptr<tray::VolumeView> volume_view_; | 38 scoped_ptr<tray::VolumeView> volume_view_; |
| 43 scoped_ptr<views::ImageView> tray_view_; | |
| 44 | 39 |
| 45 DISALLOW_COPY_AND_ASSIGN(TrayVolume); | 40 DISALLOW_COPY_AND_ASSIGN(TrayVolume); |
| 46 }; | 41 }; |
| 47 | 42 |
| 48 } // namespace internal | 43 } // namespace internal |
| 49 } // namespace ash | 44 } // namespace ash |
| 50 | 45 |
| 51 #endif // ASH_SYSTEM_AUDIO_TRAY_VOLUME_H_ | 46 #endif // ASH_SYSTEM_AUDIO_TRAY_VOLUME_H_ |
| OLD | NEW |