OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/login_performer.h" | 5 #include "chrome/browser/chromeos/login/login_performer.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 10 matching lines...) Expand all Loading... |
21 #include "chrome/browser/chromeos/login/screen_locker.h" | 21 #include "chrome/browser/chromeos/login/screen_locker.h" |
22 #include "chrome/browser/chromeos/user_cros_settings_provider.h" | 22 #include "chrome/browser/chromeos/user_cros_settings_provider.h" |
23 #include "chrome/browser/prefs/pref_service.h" | 23 #include "chrome/browser/prefs/pref_service.h" |
24 #include "chrome/browser/profiles/profile.h" | 24 #include "chrome/browser/profiles/profile.h" |
25 #include "chrome/browser/profiles/profile_manager.h" | 25 #include "chrome/browser/profiles/profile_manager.h" |
26 #include "chrome/common/chrome_notification_types.h" | 26 #include "chrome/common/chrome_notification_types.h" |
27 #include "chrome/common/chrome_switches.h" | 27 #include "chrome/common/chrome_switches.h" |
28 #include "chrome/common/pref_names.h" | 28 #include "chrome/common/pref_names.h" |
29 #include "content/browser/browser_thread.h" | 29 #include "content/browser/browser_thread.h" |
30 #include "content/browser/user_metrics.h" | 30 #include "content/browser/user_metrics.h" |
31 #include "content/common/notification_service.h" | 31 #include "content/public/browser/notification_service.h" |
32 #include "content/public/browser/notification_types.h" | 32 #include "content/public/browser/notification_types.h" |
33 #include "net/base/cookie_monster.h" | 33 #include "net/base/cookie_monster.h" |
34 #include "net/base/cookie_store.h" | 34 #include "net/base/cookie_store.h" |
35 #include "net/url_request/url_request_context.h" | 35 #include "net/url_request/url_request_context.h" |
36 #include "net/url_request/url_request_context_getter.h" | 36 #include "net/url_request/url_request_context_getter.h" |
37 #include "grit/generated_resources.h" | 37 #include "grit/generated_resources.h" |
38 #include "ui/base/l10n/l10n_util.h" | 38 #include "ui/base/l10n/l10n_util.h" |
39 #include "ui/base/resource/resource_bundle.h" | 39 #include "ui/base/resource/resource_bundle.h" |
40 | 40 |
41 namespace chromeos { | 41 namespace chromeos { |
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
386 } | 386 } |
387 | 387 |
388 //////////////////////////////////////////////////////////////////////////////// | 388 //////////////////////////////////////////////////////////////////////////////// |
389 // LoginPerformer, private: | 389 // LoginPerformer, private: |
390 | 390 |
391 void LoginPerformer::RequestScreenLock() { | 391 void LoginPerformer::RequestScreenLock() { |
392 DVLOG(1) << "Screen lock requested"; | 392 DVLOG(1) << "Screen lock requested"; |
393 // Will receive notifications on screen unlock and delete itself. | 393 // Will receive notifications on screen unlock and delete itself. |
394 registrar_.Add(this, | 394 registrar_.Add(this, |
395 chrome::NOTIFICATION_SCREEN_LOCK_STATE_CHANGED, | 395 chrome::NOTIFICATION_SCREEN_LOCK_STATE_CHANGED, |
396 NotificationService::AllSources()); | 396 content::NotificationService::AllSources()); |
397 if (ScreenLocker::default_screen_locker()) { | 397 if (ScreenLocker::default_screen_locker()) { |
398 DVLOG(1) << "Screen already locked"; | 398 DVLOG(1) << "Screen already locked"; |
399 ResolveScreenLocked(); | 399 ResolveScreenLocked(); |
400 } else { | 400 } else { |
401 screen_lock_requested_ = true; | 401 screen_lock_requested_ = true; |
402 chromeos::CrosLibrary::Get()->GetScreenLockLibrary()-> | 402 chromeos::CrosLibrary::Get()->GetScreenLockLibrary()-> |
403 NotifyScreenLockRequested(); | 403 NotifyScreenLockRequested(); |
404 } | 404 } |
405 } | 405 } |
406 | 406 |
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
567 // retry online auth, using existing Authenticator instance. | 567 // retry online auth, using existing Authenticator instance. |
568 BrowserThread::PostTask( | 568 BrowserThread::PostTask( |
569 BrowserThread::UI, FROM_HERE, | 569 BrowserThread::UI, FROM_HERE, |
570 base::Bind(&Authenticator::RetryAuth, authenticator_.get(), profile, | 570 base::Bind(&Authenticator::RetryAuth, authenticator_.get(), profile, |
571 username_, password_, captcha_token_, captcha_)); | 571 username_, password_, captcha_token_, captcha_)); |
572 } | 572 } |
573 password_.clear(); | 573 password_.clear(); |
574 } | 574 } |
575 | 575 |
576 } // namespace chromeos | 576 } // namespace chromeos |
OLD | NEW |