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

Side by Side Diff: chrome/browser/ui/sync/one_click_signin_helper.cc

Issue 11778029: Be more consistent about respecting link click dispositions in infobars: for most infobars, we shou… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 years, 8 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
« no previous file with comments | « chrome/browser/autofill/autofill_cc_infobar_delegate.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/ui/sync/one_click_signin_helper.h" 5 #include "chrome/browser/ui/sync/one_click_signin_helper.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 } 539 }
540 540
541 string16 OneClickInfoBarDelegateImpl::GetLinkText() const { 541 string16 OneClickInfoBarDelegateImpl::GetLinkText() const {
542 return l10n_util::GetStringUTF16(IDS_LEARN_MORE); 542 return l10n_util::GetStringUTF16(IDS_LEARN_MORE);
543 } 543 }
544 544
545 bool OneClickInfoBarDelegateImpl::LinkClicked( 545 bool OneClickInfoBarDelegateImpl::LinkClicked(
546 WindowOpenDisposition disposition) { 546 WindowOpenDisposition disposition) {
547 RecordHistogramAction(one_click_signin::HISTOGRAM_LEARN_MORE); 547 RecordHistogramAction(one_click_signin::HISTOGRAM_LEARN_MORE);
548 content::OpenURLParams params( 548 content::OpenURLParams params(
549 GURL(chrome::kChromeSyncLearnMoreURL), content::Referrer(), disposition, 549 GURL(chrome::kChromeSyncLearnMoreURL), content::Referrer(),
550 (disposition == CURRENT_TAB) ? NEW_FOREGROUND_TAB : disposition,
550 content::PAGE_TRANSITION_LINK, false); 551 content::PAGE_TRANSITION_LINK, false);
551 owner()->GetWebContents()->OpenURL(params); 552 owner()->GetWebContents()->OpenURL(params);
552 return false; 553 return false;
553 } 554 }
554 555
555 void OneClickInfoBarDelegateImpl::GetAlternateColors( 556 void OneClickInfoBarDelegateImpl::GetAlternateColors(
556 AlternateColors* alt_colors) { 557 AlternateColors* alt_colors) {
557 if (use_blue_on_white) { 558 if (use_blue_on_white) {
558 alt_colors->enabled = true; 559 alt_colors->enabled = true;
559 alt_colors->infobar_bottom_color = SK_ColorWHITE; 560 alt_colors->infobar_bottom_color = SK_ColorWHITE;
(...skipping 828 matching lines...) Expand 10 before | Expand all | Expand 10 after
1388 1389
1389 void OneClickSigninHelper::SigninSuccess() { 1390 void OneClickSigninHelper::SigninSuccess() {
1390 RedirectOnSigninComplete(true); 1391 RedirectOnSigninComplete(true);
1391 } 1392 }
1392 1393
1393 void OneClickSigninHelper::RedirectOnSigninComplete(bool show_bubble) { 1394 void OneClickSigninHelper::RedirectOnSigninComplete(bool show_bubble) {
1394 // Show the result in the sign-in bubble if desired. 1395 // Show the result in the sign-in bubble if desired.
1395 RedirectToNtpOrAppsPage(show_bubble); 1396 RedirectToNtpOrAppsPage(show_bubble);
1396 signin_tracker_.reset(); 1397 signin_tracker_.reset();
1397 } 1398 }
OLDNEW
« no previous file with comments | « chrome/browser/autofill/autofill_cc_infobar_delegate.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698