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 #include "chrome/browser/sync/sync_error_notifier_ash.h" | 5 #include "chrome/browser/sync/sync_error_notifier_ash.h" |
6 | 6 |
7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
8 #include "ash/shell_delegate.h" | 8 #include "ash/shell_delegate.h" |
9 #include "ash/system/system_notifier.h" | 9 #include "ash/system/system_notifier.h" |
10 #include "base/strings/string16.h" | 10 #include "base/strings/string16.h" |
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
164 message_center::NotifierId notifier_id( | 164 message_center::NotifierId notifier_id( |
165 message_center::NotifierId::SYSTEM_COMPONENT, | 165 message_center::NotifierId::SYSTEM_COMPONENT, |
166 kProfileSyncNotificationId); | 166 kProfileSyncNotificationId); |
167 | 167 |
168 // Set |profile_id| for multi-user notification blocker. | 168 // Set |profile_id| for multi-user notification blocker. |
169 notifier_id.profile_id = multi_user_util::GetUserIDFromProfile(profile_); | 169 notifier_id.profile_id = multi_user_util::GetUserIDFromProfile(profile_); |
170 | 170 |
171 // Add a new notification. | 171 // Add a new notification. |
172 Notification notification( | 172 Notification notification( |
173 message_center::NOTIFICATION_TYPE_SIMPLE, | 173 message_center::NOTIFICATION_TYPE_SIMPLE, |
174 GURL(notification_id_), | |
175 l10n_util::GetStringUTF16(IDS_SYNC_ERROR_BUBBLE_VIEW_TITLE), | 174 l10n_util::GetStringUTF16(IDS_SYNC_ERROR_BUBBLE_VIEW_TITLE), |
176 l10n_util::GetStringUTF16(IDS_SYNC_PASSPHRASE_ERROR_BUBBLE_VIEW_MESSAGE), | 175 l10n_util::GetStringUTF16(IDS_SYNC_PASSPHRASE_ERROR_BUBBLE_VIEW_MESSAGE), |
177 ui::ResourceBundle::GetSharedInstance().GetImageNamed( | 176 ui::ResourceBundle::GetSharedInstance().GetImageNamed( |
178 IDR_NOTIFICATION_ALERT), | 177 IDR_NOTIFICATION_ALERT), |
179 notifier_id, | 178 notifier_id, |
180 base::string16(), // display_source | 179 base::string16(), // display_source |
181 notification_id_, | 180 GURL(notification_id_), notification_id_, data, delegate); |
182 data, | |
183 delegate); | |
184 notification_ui_manager->Add(notification, profile_); | 181 notification_ui_manager->Add(notification, profile_); |
185 } | 182 } |
OLD | NEW |