Chromium Code Reviews| Index: ash/system/drive/tray_drive.h |
| diff --git a/ash/system/drive/tray_drive.h b/ash/system/drive/tray_drive.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..1183506c3471a0268c3c829277606a70a7298dcf |
| --- /dev/null |
| +++ b/ash/system/drive/tray_drive.h |
| @@ -0,0 +1,64 @@ |
| +// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef ASH_SYSTEM_DRIVE_TRAY_DRIVE_H_ |
| +#define ASH_SYSTEM_DRIVE_TRAY_DRIVE_H_ |
| +#pragma once |
| + |
| +#include "ash/system/drive/drive_observer.h" |
| +#include "ash/system/tray/tray_image_item.h" |
| +#include "base/memory/scoped_ptr.h" |
| + |
| + |
|
xiyuan
2012/05/01 16:47:53
nit: nuke one empty line
|
| +namespace views { |
| +class Label; |
| +} |
| + |
| +namespace ash { |
| + |
| +namespace internal { |
| + |
| +namespace tray { |
| +class DriveTrayView; |
| +class DriveDefaultView; |
| +class DriveDetailedView; |
| +}; |
|
sadrul
2012/05/01 14:28:58
I think we avoid ;s after namespace
zel
2012/05/01 16:56:52
Done.
|
| + |
| +class TrayItemView; |
|
sadrul
2012/05/01 14:28:58
- this
zel
2012/05/01 16:56:52
Removed.
|
| + |
| +class TrayDrive : public TrayImageItem, |
| + public DriveObserver { |
| + public: |
| + TrayDrive(); |
| + virtual ~TrayDrive(); |
| + |
| + private: |
| + // Overridden from TrayImageItem. |
| + virtual bool GetInitialVisibility() OVERRIDE; |
| + |
| + // Overridden from SystemTrayItem. |
| + virtual views::View* CreateDefaultView(user::LoginStatus status) OVERRIDE; |
| + virtual views::View* CreateDetailedView(user::LoginStatus status) OVERRIDE; |
| + virtual void DestroyDefaultView() OVERRIDE; |
| + virtual void DestroyDetailedView() OVERRIDE; |
| + virtual void UpdateAfterLoginStatusChange(user::LoginStatus status) OVERRIDE; |
| + |
| + // Overridden from DriveObserver. |
| + virtual void OnDriveRefresh(const DriveOperationStatusList& list) OVERRIDE; |
| + |
| + // Delayed re-check of the status after encounter operation depleted list. |
| + void OnStatusCheck(); |
| + |
| + void UpdateTrayIcon(bool show); |
| + |
| + scoped_ptr<tray::DriveDefaultView> default_; |
| + scoped_ptr<tray::DriveDetailedView> detailed_; |
|
sadrul
2012/05/01 14:28:58
stevenjb@ has a CL (http://codereview.chromium.org
zel
2012/05/01 16:56:52
Done.
zel
2012/05/01 16:56:52
Yes, good point. Done.
|
| + |
| + DISALLOW_COPY_AND_ASSIGN(TrayDrive); |
| +}; |
| + |
| +} // namespace internal |
| +} // namespace ash |
| + |
| +#endif // ASH_SYSTEM_DRIVE_TRAY_DRIVE_H_ |