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

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

Issue 6480001: Migrate Event API methods to Google Style. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 10 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/guest_user_view.h" 5 #include "chrome/browser/chromeos/login/guest_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/user_controller.h" 8 #include "chrome/browser/chromeos/login/user_controller.h"
9 #include "chrome/browser/chromeos/login/wizard_accessibility_helper.h" 9 #include "chrome/browser/chromeos/login/wizard_accessibility_helper.h"
10 #include "grit/generated_resources.h" 10 #include "grit/generated_resources.h"
11 #include "ui/base/l10n/l10n_util.h" 11 #include "ui/base/l10n/l10n_util.h"
12 12
13 namespace chromeos { 13 namespace chromeos {
14 14
15 // Button with custom processing for Tab/Shift+Tab to select entries. 15 // Button with custom processing for Tab/Shift+Tab to select entries.
16 class UserEntryButton : public login::WideButton { 16 class UserEntryButton : public login::WideButton {
17 public: 17 public:
18 UserEntryButton(views::ButtonListener* button_listener, 18 UserEntryButton(views::ButtonListener* button_listener,
19 UserController* user_controller, 19 UserController* user_controller,
20 const std::wstring& label) 20 const std::wstring& label)
21 : WideButton(button_listener, label), 21 : WideButton(button_listener, label),
22 user_controller_(user_controller) {} 22 user_controller_(user_controller) {}
23 23
24 // Overridden from views::View: 24 // Overridden from views::View:
25 virtual bool OnKeyPressed(const views::KeyEvent& e) { 25 virtual bool OnKeyPressed(const views::KeyEvent& e) {
26 if (e.GetKeyCode() == ui::VKEY_TAB) { 26 if (e.key_code() == ui::VKEY_TAB) {
27 user_controller_->SelectUserRelative(e.IsShiftDown() ? -1 : 1); 27 user_controller_->SelectUserRelative(e.IsShiftDown() ? -1 : 1);
28 return true; 28 return true;
29 } 29 }
30 return WideButton::OnKeyPressed(e); 30 return WideButton::OnKeyPressed(e);
31 } 31 }
32 32
33 virtual bool SkipDefaultKeyEventProcessing(const views::KeyEvent& e) { 33 virtual bool SkipDefaultKeyEventProcessing(const views::KeyEvent& e) {
34 if (e.GetKeyCode() == ui::VKEY_TAB) 34 if (e.key_code() == ui::VKEY_TAB)
35 return true; 35 return true;
36 return WideButton::SkipDefaultKeyEventProcessing(e); 36 return WideButton::SkipDefaultKeyEventProcessing(e);
37 } 37 }
38 38
39 private: 39 private:
40 UserController* user_controller_; 40 UserController* user_controller_;
41 41
42 DISALLOW_COPY_AND_ASSIGN(UserEntryButton); 42 DISALLOW_COPY_AND_ASSIGN(UserEntryButton);
43 }; 43 };
44 44
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 119
120 void GuestUserView::ClearAndFocusPassword() { 120 void GuestUserView::ClearAndFocusPassword() {
121 } 121 }
122 122
123 gfx::Rect GuestUserView::GetMainInputScreenBounds() const { 123 gfx::Rect GuestUserView::GetMainInputScreenBounds() const {
124 NOTREACHED(); 124 NOTREACHED();
125 return gfx::Rect(); 125 return gfx::Rect();
126 } 126 }
127 127
128 } // namespace chromeos 128 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698