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

Side by Side Diff: chrome/browser/chromeos/login/signin_screen_controller.cc

Issue 2063863002: Use DCHECKs when observing only a single notification. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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
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/login/signin_screen_controller.h" 5 #include "chrome/browser/chromeos/login/signin_screen_controller.h"
6 6
7 #include "chrome/browser/chrome_notification_types.h" 7 #include "chrome/browser/chrome_notification_types.h"
8 #include "chrome/browser/chromeos/login/lock/screen_locker.h" 8 #include "chrome/browser/chromeos/login/lock/screen_locker.h"
9 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h" 9 #include "chrome/browser/chromeos/login/screens/chrome_user_selection_screen.h"
10 #include "chrome/browser/chromeos/login/ui/views/user_board_view.h" 10 #include "chrome/browser/chromeos/login/ui/views/user_board_view.h"
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 int type, 87 int type,
88 const content::NotificationSource& source, 88 const content::NotificationSource& source,
89 const content::NotificationDetails& details) { 89 const content::NotificationDetails& details) {
90 if (type == chrome::NOTIFICATION_SESSION_STARTED) { 90 if (type == chrome::NOTIFICATION_SESSION_STARTED) {
91 // Stop listening to any notification once session has started. 91 // Stop listening to any notification once session has started.
92 // Sign in screen objects are marked for deletion with DeleteSoon so 92 // Sign in screen objects are marked for deletion with DeleteSoon so
93 // make sure no object would be used after session has started. 93 // make sure no object would be used after session has started.
94 // http://crbug.com/125276 94 // http://crbug.com/125276
95 registrar_.RemoveAll(); 95 registrar_.RemoveAll();
96 return; 96 return;
97 } else if (type == chrome::NOTIFICATION_LOGIN_USER_IMAGE_CHANGED) { 97 }
98 if (type == chrome::NOTIFICATION_LOGIN_USER_IMAGE_CHANGED) {
98 user_selection_screen_->OnUserImageChanged( 99 user_selection_screen_->OnUserImageChanged(
99 *content::Details<user_manager::User>(details).ptr()); 100 *content::Details<user_manager::User>(details).ptr());
100 return; 101 return;
101 } 102 }
102 } 103 }
103 104
104 } // namespace chromeos 105 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698