| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ | 5 #ifndef UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ |
| 6 #define UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ | 6 #define UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 42 | 42 |
| 43 ArcNotificationManager* const manager_; | 43 ArcNotificationManager* const manager_; |
| 44 message_center::MessageCenter* const message_center_; | 44 message_center::MessageCenter* const message_center_; |
| 45 const AccountId profile_id_; | 45 const AccountId profile_id_; |
| 46 | 46 |
| 47 const std::string notification_key_; | 47 const std::string notification_key_; |
| 48 const std::string notification_id_; | 48 const std::string notification_id_; |
| 49 | 49 |
| 50 // Stores on-going notification data during the image decoding. | 50 // Stores on-going notification data during the image decoding. |
| 51 // This field will be removed after removing async task of image decoding. | 51 // This field will be removed after removing async task of image decoding. |
| 52 scoped_ptr<message_center::Notification> notification_; | 52 std::unique_ptr<message_center::Notification> notification_; |
| 53 | 53 |
| 54 // The flag to indicate that the removing is initiated by the manager and we | 54 // The flag to indicate that the removing is initiated by the manager and we |
| 55 // don't need to notify a remove event to the manager. | 55 // don't need to notify a remove event to the manager. |
| 56 // This is true only when: | 56 // This is true only when: |
| 57 // (1) the notification is being removed | 57 // (1) the notification is being removed |
| 58 // (2) the removing is initiated by manager | 58 // (2) the removing is initiated by manager |
| 59 bool being_removed_by_manager_ = false; | 59 bool being_removed_by_manager_ = false; |
| 60 | 60 |
| 61 // Stores the latest notification data which is newer than the on-going data. | 61 // Stores the latest notification data which is newer than the on-going data. |
| 62 // If the on-going data is either none or the latest, this is null. | 62 // If the on-going data is either none or the latest, this is null. |
| 63 // This field will be removed after removing async task of image decoding. | 63 // This field will be removed after removing async task of image decoding. |
| 64 ArcNotificationDataPtr newer_data_; | 64 ArcNotificationDataPtr newer_data_; |
| 65 | 65 |
| 66 base::ThreadChecker thread_checker_; | 66 base::ThreadChecker thread_checker_; |
| 67 base::WeakPtrFactory<ArcNotificationItem> weak_ptr_factory_; | 67 base::WeakPtrFactory<ArcNotificationItem> weak_ptr_factory_; |
| 68 | 68 |
| 69 DISALLOW_COPY_AND_ASSIGN(ArcNotificationItem); | 69 DISALLOW_COPY_AND_ASSIGN(ArcNotificationItem); |
| 70 }; | 70 }; |
| 71 | 71 |
| 72 } // namespace arc | 72 } // namespace arc |
| 73 | 73 |
| 74 #endif // UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ | 74 #endif // UI_ARC_NOTIFICATION_ARC_NOTIFICATION_ITEM_H_ |
| OLD | NEW |