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

Side by Side Diff: chrome/browser/ui/views/sync/profile_signin_confirmation_dialog_views.cc

Issue 2030503002: Fix spacing for enterprise signin explanation text. (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
« no previous file with comments | « no previous file | 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/views/sync/profile_signin_confirmation_dialog_views. h" 5 #include "chrome/browser/ui/views/sync/profile_signin_confirmation_dialog_views. h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 10
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
181 IDS_ENTERPRISE_SIGNIN_EXPLANATION_WITHOUT_PROFILE_CREATION_NEW_STYLE, 181 IDS_ENTERPRISE_SIGNIN_EXPLANATION_WITHOUT_PROFILE_CREATION_NEW_STYLE,
182 username, learn_more_text, &offsets); 182 username, learn_more_text, &offsets);
183 views::StyledLabel* explanation_label = 183 views::StyledLabel* explanation_label =
184 new views::StyledLabel(signin_explanation_text, this); 184 new views::StyledLabel(signin_explanation_text, this);
185 explanation_label->AddStyleRange( 185 explanation_label->AddStyleRange(
186 gfx::Range(offsets[1], offsets[1] + learn_more_text.size()), 186 gfx::Range(offsets[1], offsets[1] + learn_more_text.size()),
187 views::StyledLabel::RangeStyleInfo::CreateForLink()); 187 views::StyledLabel::RangeStyleInfo::CreateForLink());
188 188
189 // Layout the components. 189 // Layout the components.
190 views::GridLayout* dialog_layout = new views::GridLayout(this); 190 views::GridLayout* dialog_layout = new views::GridLayout(this);
191 dialog_layout->SetInsets(views::kPanelVertMargin, 0, 0, 0);
191 SetLayoutManager(dialog_layout); 192 SetLayoutManager(dialog_layout);
192 193
193 // Use GridLayout inside the prompt bar because StyledLabel requires it. 194 // Use GridLayout inside the prompt bar because StyledLabel requires it.
194 views::GridLayout* prompt_layout = views::GridLayout::CreatePanel(prompt_bar); 195 views::GridLayout* prompt_layout = views::GridLayout::CreatePanel(prompt_bar);
195 prompt_bar->SetLayoutManager(prompt_layout); 196 prompt_bar->SetLayoutManager(prompt_layout);
196 prompt_layout->AddColumnSet(0)->AddColumn( 197 prompt_layout->AddColumnSet(0)->AddColumn(
197 views::GridLayout::FILL, views::GridLayout::CENTER, 100, 198 views::GridLayout::FILL, views::GridLayout::CENTER, 100,
198 views::GridLayout::USE_PREF, 0, 0); 199 views::GridLayout::USE_PREF, 0, 0);
199 prompt_layout->StartRow(0, 0); 200 prompt_layout->StartRow(0, 0);
200 prompt_layout->AddView(prompt_label); 201 prompt_layout->AddView(prompt_label);
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 void ProfileSigninConfirmationDialogViews::ButtonPressed( 243 void ProfileSigninConfirmationDialogViews::ButtonPressed(
243 views::Button* sender, 244 views::Button* sender,
244 const ui::Event& event) { 245 const ui::Event& event) {
245 DCHECK(prompt_for_new_profile_); 246 DCHECK(prompt_for_new_profile_);
246 if (delegate_) { 247 if (delegate_) {
247 delegate_->OnContinueSignin(); 248 delegate_->OnContinueSignin();
248 delegate_ = NULL; 249 delegate_ = NULL;
249 } 250 }
250 GetWidget()->Close(); 251 GetWidget()->Close();
251 } 252 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698