Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(45)

Side by Side Diff: chrome/browser/chromeos/system/ash_system_tray_delegate.cc

Issue 15702004: Open Ash shell after creating Profile (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Unregister pref change notifier in ash::SystemTrayDelegate Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h" 5 #include "chrome/browser/chromeos/system/ash_system_tray_delegate.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 public input_method::InputMethodManager::Observer, 231 public input_method::InputMethodManager::Observer,
232 public system::TimezoneSettings::Observer, 232 public system::TimezoneSettings::Observer,
233 public chromeos::SystemClockClient::Observer, 233 public chromeos::SystemClockClient::Observer,
234 public device::BluetoothAdapter::Observer, 234 public device::BluetoothAdapter::Observer,
235 public SystemKeyEventListener::CapsLockObserver, 235 public SystemKeyEventListener::CapsLockObserver,
236 public ash::NetworkTrayDelegate, 236 public ash::NetworkTrayDelegate,
237 public policy::CloudPolicyStore::Observer { 237 public policy::CloudPolicyStore::Observer {
238 public: 238 public:
239 SystemTrayDelegate() 239 SystemTrayDelegate()
240 : ui_weak_ptr_factory_( 240 : ui_weak_ptr_factory_(
241 new base::WeakPtrFactory<SystemTrayDelegate>(this)), 241 new base::WeakPtrFactory<SystemTrayDelegate>(this)),
242 user_profile_(NULL),
242 clock_type_(base::k24HourClock), 243 clock_type_(base::k24HourClock),
243 search_key_mapped_to_(input_method::kSearchKey), 244 search_key_mapped_to_(input_method::kSearchKey),
244 screen_locked_(false), 245 screen_locked_(false),
245 have_session_start_time_(false), 246 have_session_start_time_(false),
246 have_session_length_limit_(false), 247 have_session_length_limit_(false),
247 data_promo_notification_(new DataPromoNotification()), 248 data_promo_notification_(new DataPromoNotification()),
248 cellular_activating_(false), 249 cellular_activating_(false),
249 cellular_out_of_credits_(false), 250 cellular_out_of_credits_(false),
250 volume_control_delegate_(new VolumeController()) { 251 volume_control_delegate_(new VolumeController()) {
251 // Register notifications on construction so that events such as 252 // Register notifications on construction so that events such as
252 // PROFILE_CREATED do not get missed if they happen before Initialize(). 253 // PROFILE_CREATED do not get missed if they happen before Initialize().
253 registrar_.Add(this, 254 registrar_.reset(new content::NotificationRegistrar);
255 registrar_->Add(this,
254 chrome::NOTIFICATION_UPGRADE_RECOMMENDED, 256 chrome::NOTIFICATION_UPGRADE_RECOMMENDED,
255 content::NotificationService::AllSources()); 257 content::NotificationService::AllSources());
256 registrar_.Add(this, 258 registrar_->Add(this,
257 chrome::NOTIFICATION_LOGIN_USER_IMAGE_CHANGED, 259 chrome::NOTIFICATION_LOGIN_USER_IMAGE_CHANGED,
258 content::NotificationService::AllSources()); 260 content::NotificationService::AllSources());
259 if (GetUserLoginStatus() == ash::user::LOGGED_IN_NONE) { 261 if (GetUserLoginStatus() == ash::user::LOGGED_IN_NONE) {
260 registrar_.Add(this, 262 registrar_->Add(this,
261 chrome::NOTIFICATION_SESSION_STARTED, 263 chrome::NOTIFICATION_SESSION_STARTED,
262 content::NotificationService::AllSources()); 264 content::NotificationService::AllSources());
263 } 265 }
264 registrar_.Add(this, 266 registrar_->Add(this,
265 chrome::NOTIFICATION_PROFILE_CREATED, 267 chrome::NOTIFICATION_PROFILE_CREATED,
266 content::NotificationService::AllSources()); 268 content::NotificationService::AllSources());
267 registrar_.Add(this, 269 registrar_->Add(this,
270 chrome::NOTIFICATION_PROFILE_DESTROYED,
271 content::NotificationService::AllSources());
272 registrar_->Add(this,
268 chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED, 273 chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED,
269 content::NotificationService::AllSources()); 274 content::NotificationService::AllSources());
270 registrar_.Add( 275 registrar_->Add(
271 this, 276 this,
272 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SCREEN_MAGNIFIER, 277 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SCREEN_MAGNIFIER,
273 content::NotificationService::AllSources()); 278 content::NotificationService::AllSources());
274 registrar_.Add( 279 registrar_->Add(
275 this, 280 this,
276 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK, 281 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK,
277 content::NotificationService::AllSources()); 282 content::NotificationService::AllSources());
278 registrar_.Add( 283 registrar_->Add(
279 this, 284 this,
280 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_HIGH_CONTRAST_MODE, 285 chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_HIGH_CONTRAST_MODE,
281 content::NotificationService::AllSources()); 286 content::NotificationService::AllSources());
282 } 287 }
283 288
284 virtual void Initialize() OVERRIDE { 289 virtual void Initialize() OVERRIDE {
285 if (!ash::switches::UseNewAudioHandler()) { 290 if (!ash::switches::UseNewAudioHandler()) {
286 AudioHandler::GetInstance()->AddVolumeObserver(this); 291 AudioHandler::GetInstance()->AddVolumeObserver(this);
287 } 292 }
288 DBusThreadManager::Get()->GetPowerManagerClient()->AddObserver(this); 293 DBusThreadManager::Get()->GetPowerManagerClient()->AddObserver(this);
(...skipping 19 matching lines...) Expand all
308 virtual void Shutdown() OVERRIDE { 313 virtual void Shutdown() OVERRIDE {
309 data_promo_notification_.reset(); 314 data_promo_notification_.reset();
310 } 315 }
311 316
312 void InitializeOnAdapterReady( 317 void InitializeOnAdapterReady(
313 scoped_refptr<device::BluetoothAdapter> adapter) { 318 scoped_refptr<device::BluetoothAdapter> adapter) {
314 bluetooth_adapter_ = adapter; 319 bluetooth_adapter_ = adapter;
315 CHECK(bluetooth_adapter_); 320 CHECK(bluetooth_adapter_);
316 bluetooth_adapter_->AddObserver(this); 321 bluetooth_adapter_->AddObserver(this);
317 322
318 local_state_registrar_.Init(g_browser_process->local_state()); 323 local_state_registrar_.reset(new PrefChangeRegistrar);
324 local_state_registrar_->Init(g_browser_process->local_state());
319 325
320 UpdateSessionStartTime(); 326 UpdateSessionStartTime();
321 UpdateSessionLengthLimit(); 327 UpdateSessionLengthLimit();
322 328
323 local_state_registrar_.Add( 329 local_state_registrar_->Add(
324 prefs::kSessionStartTime, 330 prefs::kSessionStartTime,
325 base::Bind(&SystemTrayDelegate::UpdateSessionStartTime, 331 base::Bind(&SystemTrayDelegate::UpdateSessionStartTime,
326 base::Unretained(this))); 332 base::Unretained(this)));
327 local_state_registrar_.Add( 333 local_state_registrar_->Add(
328 prefs::kSessionLengthLimit, 334 prefs::kSessionLengthLimit,
329 base::Bind(&SystemTrayDelegate::UpdateSessionLengthLimit, 335 base::Bind(&SystemTrayDelegate::UpdateSessionLengthLimit,
330 base::Unretained(this))); 336 base::Unretained(this)));
331 337
332 policy::BrowserPolicyConnector* policy_connector = 338 policy::BrowserPolicyConnector* policy_connector =
333 g_browser_process->browser_policy_connector(); 339 g_browser_process->browser_policy_connector();
334 policy::DeviceCloudPolicyManagerChromeOS* policy_manager = 340 policy::DeviceCloudPolicyManagerChromeOS* policy_manager =
335 policy_connector->GetDeviceCloudPolicyManager(); 341 policy_connector->GetDeviceCloudPolicyManager();
336 if (policy_manager) 342 if (policy_manager)
337 policy_manager->core()->store()->AddObserver(this); 343 policy_manager->core()->store()->AddObserver(this);
338 UpdateEnterpriseDomain(); 344 UpdateEnterpriseDomain();
339 } 345 }
340 346
341 virtual ~SystemTrayDelegate() { 347 virtual ~SystemTrayDelegate() {
348 // Unregister PrefChangeRegistrars.
349 local_state_registrar_.reset();
350 user_pref_registrar_.reset();
351
352 // Unregister content notifications befure destroying any components.
353 registrar_.reset();
354
342 if (!ash::switches::UseNewAudioHandler() && AudioHandler::GetInstance()) { 355 if (!ash::switches::UseNewAudioHandler() && AudioHandler::GetInstance()) {
343 AudioHandler::GetInstance()->RemoveVolumeObserver(this); 356 AudioHandler::GetInstance()->RemoveVolumeObserver(this);
344 } 357 }
345 358
346 DBusThreadManager::Get()->GetSessionManagerClient()->RemoveObserver(this); 359 DBusThreadManager::Get()->GetSessionManagerClient()->RemoveObserver(this);
347 DBusThreadManager::Get()->GetPowerManagerClient()->RemoveObserver(this); 360 DBusThreadManager::Get()->GetPowerManagerClient()->RemoveObserver(this);
348 DBusThreadManager::Get()->GetSystemClockClient()->RemoveObserver(this); 361 DBusThreadManager::Get()->GetSystemClockClient()->RemoveObserver(this);
349 NetworkLibrary* crosnet = CrosLibrary::Get()->GetNetworkLibrary(); 362 NetworkLibrary* crosnet = CrosLibrary::Get()->GetNetworkLibrary();
350 if (crosnet) 363 if (crosnet)
351 crosnet->RemoveNetworkManagerObserver(this); 364 crosnet->RemoveNetworkManagerObserver(this);
(...skipping 543 matching lines...) Expand 10 before | Expand all | Expand 10 after
895 908
896 // Returns the last active browser. If there is no such browser, creates a new 909 // Returns the last active browser. If there is no such browser, creates a new
897 // browser window with an empty tab and returns it. 910 // browser window with an empty tab and returns it.
898 Browser* GetAppropriateBrowser() { 911 Browser* GetAppropriateBrowser() {
899 return chrome::FindOrCreateTabbedBrowser( 912 return chrome::FindOrCreateTabbedBrowser(
900 ProfileManager::GetDefaultProfileOrOffTheRecord(), 913 ProfileManager::GetDefaultProfileOrOffTheRecord(),
901 chrome::HOST_DESKTOP_TYPE_ASH); 914 chrome::HOST_DESKTOP_TYPE_ASH);
902 } 915 }
903 916
904 void SetProfile(Profile* profile) { 917 void SetProfile(Profile* profile) {
918 user_profile_ = profile;
905 PrefService* prefs = profile->GetPrefs(); 919 PrefService* prefs = profile->GetPrefs();
906 user_pref_registrar_.reset(new PrefChangeRegistrar); 920 user_pref_registrar_.reset(new PrefChangeRegistrar);
907 user_pref_registrar_->Init(prefs); 921 user_pref_registrar_->Init(prefs);
908 user_pref_registrar_->Add( 922 user_pref_registrar_->Add(
909 prefs::kUse24HourClock, 923 prefs::kUse24HourClock,
910 base::Bind(&SystemTrayDelegate::UpdateClockType, 924 base::Bind(&SystemTrayDelegate::UpdateClockType,
911 base::Unretained(this))); 925 base::Unretained(this)));
912 user_pref_registrar_->Add( 926 user_pref_registrar_->Add(
913 prefs::kLanguageRemapSearchKeyTo, 927 prefs::kLanguageRemapSearchKeyTo,
914 base::Bind(&SystemTrayDelegate::OnLanguageRemapSearchKeyToChanged, 928 base::Bind(&SystemTrayDelegate::OnLanguageRemapSearchKeyToChanged,
915 base::Unretained(this))); 929 base::Unretained(this)));
916 user_pref_registrar_->Add( 930 user_pref_registrar_->Add(
917 prefs::kShowLogoutButtonInTray, 931 prefs::kShowLogoutButtonInTray,
918 base::Bind(&SystemTrayDelegate::UpdateShowLogoutButtonInTray, 932 base::Bind(&SystemTrayDelegate::UpdateShowLogoutButtonInTray,
919 base::Unretained(this))); 933 base::Unretained(this)));
920 user_pref_registrar_->Add( 934 user_pref_registrar_->Add(
921 prefs::kShouldAlwaysShowAccessibilityMenu, 935 prefs::kShouldAlwaysShowAccessibilityMenu,
922 base::Bind(&SystemTrayDelegate::OnAccessibilityModeChanged, 936 base::Bind(&SystemTrayDelegate::OnAccessibilityModeChanged,
923 base::Unretained(this), 937 base::Unretained(this),
924 ash::A11Y_NOTIFICATION_NONE)); 938 ash::A11Y_NOTIFICATION_NONE));
925 939
926 UpdateClockType(); 940 UpdateClockType();
927 UpdateShowLogoutButtonInTray(); 941 UpdateShowLogoutButtonInTray();
928 search_key_mapped_to_ = 942 search_key_mapped_to_ =
929 profile->GetPrefs()->GetInteger(prefs::kLanguageRemapSearchKeyTo); 943 profile->GetPrefs()->GetInteger(prefs::kLanguageRemapSearchKeyTo);
930 } 944 }
931 945
946 bool UnsetProfile(Profile* profile) {
947 if (profile != user_profile_)
948 return false;
949 user_pref_registrar_.reset();
950 return true;
951 }
952
932 void ObserveGDataUpdates() { 953 void ObserveGDataUpdates() {
933 DriveIntegrationService* integration_service = 954 DriveIntegrationService* integration_service =
934 FindDriveIntegrationService(); 955 FindDriveIntegrationService();
935 if (integration_service) 956 if (integration_service)
936 integration_service->job_list()->AddObserver(this); 957 integration_service->job_list()->AddObserver(this);
937 } 958 }
938 959
939 void UpdateClockType() { 960 void UpdateClockType() {
940 clock_type_ = 961 clock_type_ =
941 user_pref_registrar_->prefs()->GetBoolean(prefs::kUse24HourClock) ? 962 user_pref_registrar_->prefs()->GetBoolean(prefs::kUse24HourClock) ?
942 base::k24HourClock : base::k12HourClock; 963 base::k24HourClock : base::k12HourClock;
943 GetSystemTrayNotifier()->NotifyDateFormatChanged(); 964 GetSystemTrayNotifier()->NotifyDateFormatChanged();
944 } 965 }
945 966
946 void UpdateShowLogoutButtonInTray() { 967 void UpdateShowLogoutButtonInTray() {
947 GetSystemTrayNotifier()->NotifyShowLoginButtonChanged( 968 GetSystemTrayNotifier()->NotifyShowLoginButtonChanged(
948 user_pref_registrar_->prefs()->GetBoolean( 969 user_pref_registrar_->prefs()->GetBoolean(
949 prefs::kShowLogoutButtonInTray)); 970 prefs::kShowLogoutButtonInTray));
950 } 971 }
951 972
952 void UpdateSessionStartTime() { 973 void UpdateSessionStartTime() {
953 const PrefService* local_state = local_state_registrar_.prefs(); 974 const PrefService* local_state = local_state_registrar_->prefs();
954 if (local_state->HasPrefPath(prefs::kSessionStartTime)) { 975 if (local_state->HasPrefPath(prefs::kSessionStartTime)) {
955 have_session_start_time_ = true; 976 have_session_start_time_ = true;
956 session_start_time_ = base::TimeTicks::FromInternalValue( 977 session_start_time_ = base::TimeTicks::FromInternalValue(
957 local_state->GetInt64(prefs::kSessionStartTime)); 978 local_state->GetInt64(prefs::kSessionStartTime));
958 } else { 979 } else {
959 have_session_start_time_ = false; 980 have_session_start_time_ = false;
960 session_start_time_ = base::TimeTicks(); 981 session_start_time_ = base::TimeTicks();
961 } 982 }
962 GetSystemTrayNotifier()->NotifySessionStartTimeChanged(); 983 GetSystemTrayNotifier()->NotifySessionStartTimeChanged();
963 } 984 }
964 985
965 void UpdateSessionLengthLimit() { 986 void UpdateSessionLengthLimit() {
966 const PrefService* local_state = local_state_registrar_.prefs(); 987 const PrefService* local_state = local_state_registrar_->prefs();
967 if (local_state->HasPrefPath(prefs::kSessionLengthLimit)) { 988 if (local_state->HasPrefPath(prefs::kSessionLengthLimit)) {
968 have_session_length_limit_ = true; 989 have_session_length_limit_ = true;
969 session_length_limit_ = base::TimeDelta::FromMilliseconds( 990 session_length_limit_ = base::TimeDelta::FromMilliseconds(
970 std::min(std::max(local_state->GetInteger(prefs::kSessionLengthLimit), 991 std::min(std::max(local_state->GetInteger(prefs::kSessionLengthLimit),
971 kSessionLengthLimitMinMs), 992 kSessionLengthLimitMinMs),
972 kSessionLengthLimitMaxMs)); 993 kSessionLengthLimitMaxMs));
973 } else { 994 } else {
974 have_session_length_limit_ = false; 995 have_session_length_limit_ = false;
975 session_length_limit_ = base::TimeDelta(); 996 session_length_limit_ = base::TimeDelta();
976 } 997 }
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
1065 } 1086 }
1066 break; 1087 break;
1067 } 1088 }
1068 case chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED: { 1089 case chrome::NOTIFICATION_LOGIN_USER_PROFILE_PREPARED: {
1069 // GData system service exists by the time if enabled. 1090 // GData system service exists by the time if enabled.
1070 ObserveGDataUpdates(); 1091 ObserveGDataUpdates();
1071 break; 1092 break;
1072 } 1093 }
1073 case chrome::NOTIFICATION_PROFILE_CREATED: { 1094 case chrome::NOTIFICATION_PROFILE_CREATED: {
1074 SetProfile(content::Source<Profile>(source).ptr()); 1095 SetProfile(content::Source<Profile>(source).ptr());
1075 registrar_.Remove(this, 1096 registrar_->Remove(this,
1076 chrome::NOTIFICATION_PROFILE_CREATED, 1097 chrome::NOTIFICATION_PROFILE_CREATED,
1077 content::NotificationService::AllSources()); 1098 content::NotificationService::AllSources());
1099 break;
1100 }
1101 case chrome::NOTIFICATION_PROFILE_DESTROYED: {
1102 if (UnsetProfile(content::Source<Profile>(source).ptr())) {
1103 registrar_->Remove(this,
1104 chrome::NOTIFICATION_PROFILE_DESTROYED,
1105 content::NotificationService::AllSources());
1106 }
1078 break; 1107 break;
1079 } 1108 }
1080 case chrome::NOTIFICATION_SESSION_STARTED: { 1109 case chrome::NOTIFICATION_SESSION_STARTED: {
1081 ash::Shell::GetInstance()->UpdateAfterLoginStatusChange( 1110 ash::Shell::GetInstance()->UpdateAfterLoginStatusChange(
1082 GetUserLoginStatus()); 1111 GetUserLoginStatus());
1083 SetProfile(ProfileManager::GetDefaultProfile()); 1112 SetProfile(ProfileManager::GetDefaultProfile());
1084 break; 1113 break;
1085 } 1114 }
1086 case chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK: 1115 case chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_SPOKEN_FEEDBACK:
1087 case chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_HIGH_CONTRAST_MODE: 1116 case chrome::NOTIFICATION_CROS_ACCESSIBILITY_TOGGLE_HIGH_CONTRAST_MODE:
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
1276 ash::NetworkObserver::MESSAGE_DATA_PROMO, 1305 ash::NetworkObserver::MESSAGE_DATA_PROMO,
1277 type, 1306 type,
1278 l10n_util::GetStringUTF16(IDS_NETWORK_CELLULAR_ACTIVATED_TITLE), 1307 l10n_util::GetStringUTF16(IDS_NETWORK_CELLULAR_ACTIVATED_TITLE),
1279 l10n_util::GetStringFUTF16(IDS_NETWORK_CELLULAR_ACTIVATED, 1308 l10n_util::GetStringFUTF16(IDS_NETWORK_CELLULAR_ACTIVATED,
1280 UTF8ToUTF16((cellular->name()))), 1309 UTF8ToUTF16((cellular->name()))),
1281 std::vector<string16>()); 1310 std::vector<string16>());
1282 } 1311 }
1283 } 1312 }
1284 1313
1285 scoped_ptr<base::WeakPtrFactory<SystemTrayDelegate> > ui_weak_ptr_factory_; 1314 scoped_ptr<base::WeakPtrFactory<SystemTrayDelegate> > ui_weak_ptr_factory_;
1286 content::NotificationRegistrar registrar_; 1315 scoped_ptr<content::NotificationRegistrar> registrar_;
1287 PrefChangeRegistrar local_state_registrar_; 1316 scoped_ptr<PrefChangeRegistrar> local_state_registrar_;
1288 scoped_ptr<PrefChangeRegistrar> user_pref_registrar_; 1317 scoped_ptr<PrefChangeRegistrar> user_pref_registrar_;
1318 Profile* user_profile_;
1289 std::string active_network_path_; 1319 std::string active_network_path_;
1290 base::HourClockType clock_type_; 1320 base::HourClockType clock_type_;
1291 int search_key_mapped_to_; 1321 int search_key_mapped_to_;
1292 bool screen_locked_; 1322 bool screen_locked_;
1293 bool have_session_start_time_; 1323 bool have_session_start_time_;
1294 base::TimeTicks session_start_time_; 1324 base::TimeTicks session_start_time_;
1295 bool have_session_length_limit_; 1325 bool have_session_length_limit_;
1296 base::TimeDelta session_length_limit_; 1326 base::TimeDelta session_length_limit_;
1297 std::string enterprise_domain_; 1327 std::string enterprise_domain_;
1298 1328
1299 scoped_refptr<device::BluetoothAdapter> bluetooth_adapter_; 1329 scoped_refptr<device::BluetoothAdapter> bluetooth_adapter_;
1300 1330
1301 scoped_ptr<DataPromoNotification> data_promo_notification_; 1331 scoped_ptr<DataPromoNotification> data_promo_notification_;
1302 bool cellular_activating_; 1332 bool cellular_activating_;
1303 bool cellular_out_of_credits_; 1333 bool cellular_out_of_credits_;
1304 1334
1305 scoped_ptr<ash::VolumeControlDelegate> volume_control_delegate_; 1335 scoped_ptr<ash::VolumeControlDelegate> volume_control_delegate_;
1306 1336
1307 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate); 1337 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegate);
1308 }; 1338 };
1309 1339
1310 } // namespace 1340 } // namespace
1311 1341
1312 ash::SystemTrayDelegate* CreateSystemTrayDelegate() { 1342 ash::SystemTrayDelegate* CreateSystemTrayDelegate() {
1313 return new chromeos::SystemTrayDelegate(); 1343 return new chromeos::SystemTrayDelegate();
1314 } 1344 }
1315 1345
1316 } // namespace chromeos 1346 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698