OLD | NEW |
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/screen_locker.h" | 5 #include "chrome/browser/chromeos/login/screen_locker.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/ash_switches.h" | 10 #include "ash/ash_switches.h" |
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
392 g_screen_lock_observer.Get(); | 392 g_screen_lock_observer.Get(); |
393 } | 393 } |
394 | 394 |
395 //////////////////////////////////////////////////////////////////////////////// | 395 //////////////////////////////////////////////////////////////////////////////// |
396 // ScreenLocker, private: | 396 // ScreenLocker, private: |
397 | 397 |
398 ScreenLocker::~ScreenLocker() { | 398 ScreenLocker::~ScreenLocker() { |
399 VLOG(1) << "Destroying ScreenLocker " << this; | 399 VLOG(1) << "Destroying ScreenLocker " << this; |
400 DCHECK(base::MessageLoop::current()->type() == base::MessageLoop::TYPE_UI); | 400 DCHECK(base::MessageLoop::current()->type() == base::MessageLoop::TYPE_UI); |
401 | 401 |
402 if (authenticator_) | 402 if (authenticator_.get()) |
403 authenticator_->SetConsumer(NULL); | 403 authenticator_->SetConsumer(NULL); |
404 ClearErrors(); | 404 ClearErrors(); |
405 | 405 |
406 VLOG(1) << "Moving desktop background to unlocked container"; | 406 VLOG(1) << "Moving desktop background to unlocked container"; |
407 ash::Shell::GetInstance()-> | 407 ash::Shell::GetInstance()-> |
408 desktop_background_controller()->MoveDesktopToUnlockedContainer(); | 408 desktop_background_controller()->MoveDesktopToUnlockedContainer(); |
409 | 409 |
410 screen_locker_ = NULL; | 410 screen_locker_ = NULL; |
411 bool state = false; | 411 bool state = false; |
412 VLOG(1) << "Emitting SCREEN_LOCK_STATE_CHANGED with state=" << state; | 412 VLOG(1) << "Emitting SCREEN_LOCK_STATE_CHANGED with state=" << state; |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
451 bool ScreenLocker::IsUserLoggedIn(const std::string& username) { | 451 bool ScreenLocker::IsUserLoggedIn(const std::string& username) { |
452 for (UserList::const_iterator it = users_.begin(); it != users_.end(); ++it) { | 452 for (UserList::const_iterator it = users_.begin(); it != users_.end(); ++it) { |
453 if ((*it)->email() == username) | 453 if ((*it)->email() == username) |
454 return true; | 454 return true; |
455 } | 455 } |
456 return false; | 456 return false; |
457 } | 457 } |
458 | 458 |
459 } // namespace chromeos | 459 } // namespace chromeos |
460 | 460 |
OLD | NEW |