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/user_view.h" | 5 #include "chrome/browser/chromeos/login/user_view.h" |
6 | 6 |
7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
8 #include "chrome/browser/chromeos/login/helper.h" | 8 #include "chrome/browser/chromeos/login/helper.h" |
9 #include "chrome/browser/chromeos/login/rounded_rect_painter.h" | 9 #include "chrome/browser/chromeos/login/rounded_rect_painter.h" |
10 #include "chrome/browser/chromeos/view_ids.h" | 10 #include "chrome/browser/chromeos/view_ids.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 // rounded corners at the bottom. | 45 // rounded corners at the bottom. |
46 class SignoutBackgroundPainter : public views::Painter { | 46 class SignoutBackgroundPainter : public views::Painter { |
47 virtual void Paint(int w, int h, gfx::Canvas* canvas) { | 47 virtual void Paint(int w, int h, gfx::Canvas* canvas) { |
48 SkRect rect = {0, 0, w, h}; | 48 SkRect rect = {0, 0, w, h}; |
49 SkPath path; | 49 SkPath path; |
50 path.addRect(rect); | 50 path.addRect(rect); |
51 SkPaint paint; | 51 SkPaint paint; |
52 paint.setStyle(SkPaint::kFill_Style); | 52 paint.setStyle(SkPaint::kFill_Style); |
53 paint.setFlags(SkPaint::kAntiAlias_Flag); | 53 paint.setFlags(SkPaint::kAntiAlias_Flag); |
54 paint.setColor(kSignoutBackgroundColor); | 54 paint.setColor(kSignoutBackgroundColor); |
55 canvas->AsCanvasSkia()->drawPath(path, paint); | 55 canvas->GetSkCanvas()->drawPath(path, paint); |
56 } | 56 } |
57 }; | 57 }; |
58 | 58 |
59 } // namespace | 59 } // namespace |
60 | 60 |
61 namespace chromeos { | 61 namespace chromeos { |
62 | 62 |
63 using login::kBackgroundColor; | 63 using login::kBackgroundColor; |
64 using login::kTextColor; | 64 using login::kTextColor; |
65 using login::kUserImageSize; | 65 using login::kUserImageSize; |
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 delegate_->OnRemoveUser(); | 333 delegate_->OnRemoveUser(); |
334 } | 334 } |
335 | 335 |
336 void UserView::OnLocaleChanged() { | 336 void UserView::OnLocaleChanged() { |
337 remove_button_->SetText( | 337 remove_button_->SetText( |
338 UTF16ToWide(l10n_util::GetStringUTF16(IDS_LOGIN_REMOVE))); | 338 UTF16ToWide(l10n_util::GetStringUTF16(IDS_LOGIN_REMOVE))); |
339 delegate_->OnLocaleChanged(); | 339 delegate_->OnLocaleChanged(); |
340 } | 340 } |
341 | 341 |
342 } // namespace chromeos | 342 } // namespace chromeos |
OLD | NEW |