OLD | NEW |
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/views/aura/caps_lock_handler.h" | 5 #include "chrome/browser/ui/views/ash/caps_lock_handler.h" |
6 #include "chrome/test/base/in_process_browser_test.h" | 6 #include "chrome/test/base/in_process_browser_test.h" |
7 #include "chrome/test/base/ui_test_utils.h" | 7 #include "chrome/test/base/ui_test_utils.h" |
8 | 8 |
9 #if defined(OS_CHROMEOS) | 9 #if defined(OS_CHROMEOS) |
10 #include "chrome/browser/chromeos/input_method/xkeyboard.h" | 10 #include "chrome/browser/chromeos/input_method/xkeyboard.h" |
11 using namespace chromeos::input_method; | 11 using namespace chromeos::input_method; |
12 #endif | 12 #endif |
13 | 13 |
14 namespace { | 14 namespace { |
15 | 15 |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 EXPECT_TRUE(handler_->HandleToggleCapsLock()); | 95 EXPECT_TRUE(handler_->HandleToggleCapsLock()); |
96 EXPECT_EQ(!initial_caps_lock_state_, xkeyboard_.CapsLockIsEnabled()); | 96 EXPECT_EQ(!initial_caps_lock_state_, xkeyboard_.CapsLockIsEnabled()); |
97 handler_->OnCapsLockChange(!initial_caps_lock_state_); | 97 handler_->OnCapsLockChange(!initial_caps_lock_state_); |
98 EXPECT_EQ(!initial_caps_lock_state_, handler_->caps_lock_is_on_for_test()); | 98 EXPECT_EQ(!initial_caps_lock_state_, handler_->caps_lock_is_on_for_test()); |
99 EXPECT_TRUE(handler_->HandleToggleCapsLock()); | 99 EXPECT_TRUE(handler_->HandleToggleCapsLock()); |
100 handler_->OnCapsLockChange(initial_caps_lock_state_); | 100 handler_->OnCapsLockChange(initial_caps_lock_state_); |
101 EXPECT_EQ(initial_caps_lock_state_, xkeyboard_.CapsLockIsEnabled()); | 101 EXPECT_EQ(initial_caps_lock_state_, xkeyboard_.CapsLockIsEnabled()); |
102 EXPECT_EQ(initial_caps_lock_state_, handler_->caps_lock_is_on_for_test()); | 102 EXPECT_EQ(initial_caps_lock_state_, handler_->caps_lock_is_on_for_test()); |
103 } | 103 } |
104 #endif | 104 #endif |
OLD | NEW |