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

Side by Side Diff: chrome/browser/chromeos/login/helper.cc

Issue 8402026: [cros] Make login screen take whole screen in case of Aura. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 9 years, 1 month 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 | « 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 (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/helper.h" 5 #include "chrome/browser/chromeos/login/helper.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "chrome/browser/chromeos/cros/network_library.h" 9 #include "chrome/browser/chromeos/cros/network_library.h"
10 #include "chrome/browser/google/google_util.h" 10 #include "chrome/browser/google/google_util.h"
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 throbber->SetFrames( 154 throbber->SetFrames(
155 ResourceBundle::GetSharedInstance().GetBitmapNamed(IDR_SPINNER)); 155 ResourceBundle::GetSharedInstance().GetBitmapNamed(IDR_SPINNER));
156 return throbber; 156 return throbber;
157 } 157 }
158 158
159 views::Painter* CreateBackgroundPainter() { 159 views::Painter* CreateBackgroundPainter() {
160 return new BackgroundPainter(); 160 return new BackgroundPainter();
161 } 161 }
162 162
163 gfx::Rect CalculateScreenBounds(const gfx::Size& size) { 163 gfx::Rect CalculateScreenBounds(const gfx::Size& size) {
164 gfx::Rect bounds(gfx::Screen::GetMonitorWorkAreaNearestWindow(NULL)); 164 gfx::Rect bounds(gfx::Screen::GetMonitorAreaNearestWindow(NULL));
165 if (!size.IsEmpty()) { 165 if (!size.IsEmpty()) {
166 int horizontal_diff = bounds.width() - size.width(); 166 int horizontal_diff = bounds.width() - size.width();
167 int vertical_diff = bounds.height() - size.height(); 167 int vertical_diff = bounds.height() - size.height();
168 bounds.Inset(horizontal_diff / 2, vertical_diff / 2); 168 bounds.Inset(horizontal_diff / 2, vertical_diff / 2);
169 } 169 }
170 return bounds; 170 return bounds;
171 } 171 }
172 172
173 void CorrectLabelFontSize(views::Label* label) { 173 void CorrectLabelFontSize(views::Label* label) {
174 if (label) 174 if (label)
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 gfx::Size preferred_size = NativeTextButton::GetPreferredSize(); 227 gfx::Size preferred_size = NativeTextButton::GetPreferredSize();
228 // Set minimal width. 228 // Set minimal width.
229 if (preferred_size.width() < kButtonMinWidth) 229 if (preferred_size.width() < kButtonMinWidth)
230 preferred_size.set_width(kButtonMinWidth); 230 preferred_size.set_width(kButtonMinWidth);
231 return preferred_size; 231 return preferred_size;
232 } 232 }
233 233
234 } // namespace login 234 } // namespace login
235 235
236 } // namespace chromeos 236 } // namespace chromeos
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