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/ui/sync/one_click_signin_sync_starter.h" | 5 #include "chrome/browser/ui/sync/one_click_signin_sync_starter.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/metrics/histogram_macros.h" | 9 #include "base/metrics/histogram_macros.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
(...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
513 start_mode_ != CONFIGURE_SYNC_FIRST) { | 513 start_mode_ != CONFIGURE_SYNC_FIRST) { |
514 LoadContinueUrl(); | 514 LoadContinueUrl(); |
515 } | 515 } |
516 | 516 |
517 delete this; | 517 delete this; |
518 } | 518 } |
519 | 519 |
520 void OneClickSigninSyncStarter::DisplayFinalConfirmationBubble( | 520 void OneClickSigninSyncStarter::DisplayFinalConfirmationBubble( |
521 const base::string16& custom_message) { | 521 const base::string16& custom_message) { |
522 browser_ = EnsureBrowser(browser_, profile_); | 522 browser_ = EnsureBrowser(browser_, profile_); |
523 LoginUIServiceFactory::GetForProfile(browser_->profile())-> | 523 LoginUIServiceFactory::GetForProfile(browser_->profile()) |
524 DisplayLoginResult(browser_, custom_message); | 524 ->DisplayLoginResult(browser_, custom_message, base::string16()); |
525 } | 525 } |
526 | 526 |
527 void OneClickSigninSyncStarter::DisplayModalSyncConfirmationWindow() { | 527 void OneClickSigninSyncStarter::DisplayModalSyncConfirmationWindow() { |
528 browser_ = EnsureBrowser(browser_, profile_); | 528 browser_ = EnsureBrowser(browser_, profile_); |
529 browser_->ShowModalSyncConfirmationWindow(); | 529 browser_->ShowModalSyncConfirmationWindow(); |
530 } | 530 } |
531 | 531 |
532 // static | 532 // static |
533 Browser* OneClickSigninSyncStarter::EnsureBrowser(Browser* browser, | 533 Browser* OneClickSigninSyncStarter::EnsureBrowser(Browser* browser, |
534 Profile* profile) { | 534 Profile* profile) { |
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
640 false /* user_gesture */); | 640 false /* user_gesture */); |
641 } | 641 } |
642 | 642 |
643 void OneClickSigninSyncStarter::LoadContinueUrl() { | 643 void OneClickSigninSyncStarter::LoadContinueUrl() { |
644 web_contents()->GetController().LoadURL( | 644 web_contents()->GetController().LoadURL( |
645 continue_url_, | 645 continue_url_, |
646 content::Referrer(), | 646 content::Referrer(), |
647 ui::PAGE_TRANSITION_AUTO_TOPLEVEL, | 647 ui::PAGE_TRANSITION_AUTO_TOPLEVEL, |
648 std::string()); | 648 std::string()); |
649 } | 649 } |
OLD | NEW |