Index: ash/system/network/tray_sms.h |
diff --git a/ash/system/network/tray_sms.h b/ash/system/network/tray_sms.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..1eb5ca6833e139f88d0823cdc94fa3cecc7eca68 |
--- /dev/null |
+++ b/ash/system/network/tray_sms.h |
@@ -0,0 +1,56 @@ |
+// 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_NETWORK_TRAY_SMS_H |
+#define ASH_SYSTEM_NETWORK_TRAY_SMS_H |
+#pragma once |
+ |
+#include "ash/system/tray/tray_image_item.h" |
+#include "base/memory/scoped_ptr.h" |
+ |
+namespace ash { |
+namespace internal { |
+ |
+class TraySms : public TrayImageItem { |
+ public: |
+ TraySms(); |
+ virtual ~TraySms(); |
+ |
+ // Overridden from SystemTrayItem. |
+ virtual views::View* CreateDefaultView(user::LoginStatus status) OVERRIDE; |
+ virtual views::View* CreateDetailedView(user::LoginStatus status) OVERRIDE; |
+ virtual views::View* CreateNotificationView(user::LoginStatus status) |
+ OVERRIDE; |
sadrul
2012/05/15 15:10:50
OVERRIDE shouldn't be in its own line. You can mov
stevenjb
2012/05/15 16:55:20
Done.
|
+ virtual void DestroyDefaultView() OVERRIDE; |
+ virtual void DestroyDetailedView() OVERRIDE; |
+ virtual void DestroyNotificationView() OVERRIDE; |
+ |
+ // Overridden from TrayImageItem. |
+ virtual bool GetInitialVisibility() OVERRIDE; |
+ |
+ protected: |
+ class SmsDefaultView; |
sadrul
2012/05/15 15:10:50
This is OK. But I wanted to point out that the res
stevenjb
2012/05/15 16:55:20
That works fine too, but in this case most of thes
|
+ class SmsDetailedView; |
+ class SmsMessageView; |
+ class SmsNotificationView; |
+ class SmsObserver; |
+ |
+ // Called when sms messages have changed (by tray::SmsObserver). |
+ void Update(bool notify); |
+ |
+ SmsObserver* sms_observer() const { return sms_observer_.get(); } |
+ |
+ private: |
+ SmsDefaultView* default_; |
+ SmsDetailedView* detailed_; |
+ SmsNotificationView* notification_; |
+ scoped_ptr<SmsObserver> sms_observer_; |
+ |
+ DISALLOW_COPY_AND_ASSIGN(TraySms); |
+}; |
+ |
+} // namespace internal |
+} // namespace ash |
+ |
+#endif // ASH_SYSTEM_NETWORK_TRAY_SMS_H |