| OLD | NEW |
| 1 // Copyright (c) 2009 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 #ifndef CHROME_RENDERER_MOCK_KEYBOARD_H_ | 5 #ifndef CONTENT_TEST_MOCK_KEYBOARD_H_ |
| 6 #define CHROME_RENDERER_MOCK_KEYBOARD_H_ | 6 #define CONTENT_TEST_MOCK_KEYBOARD_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
| 12 | 12 |
| 13 #if defined(OS_WIN) | 13 #if defined(OS_WIN) |
| 14 #include "chrome/renderer/mock_keyboard_driver_win.h" | 14 #include "content/test/mock_keyboard_driver_win.h" |
| 15 #endif | 15 #endif |
| 16 | 16 |
| 17 // A mock keyboard interface. | 17 // A mock keyboard interface. |
| 18 // This class defines a pseudo keyboard device, which implements mappings from | 18 // This class defines a pseudo keyboard device, which implements mappings from |
| 19 // a tuple (layout, key code, modifiers) to Unicode characters so that | 19 // a tuple (layout, key code, modifiers) to Unicode characters so that |
| 20 // engineers can write RenderViewTest cases without taking care of such | 20 // engineers can write RenderViewTest cases without taking care of such |
| 21 // mappings. (This mapping is not trivial when using non-US keyboards.) | 21 // mappings. (This mapping is not trivial when using non-US keyboards.) |
| 22 // A pseudo keyboard device consists of two parts: a platform-independent part | 22 // A pseudo keyboard device consists of two parts: a platform-independent part |
| 23 // and a platform-dependent part. This class implements the platform-independent | 23 // and a platform-dependent part. This class implements the platform-independent |
| 24 // part. The platform-dependet part is implemented in the MockKeyboardWin class. | 24 // part. The platform-dependet part is implemented in the MockKeyboardWin class. |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 Layout keyboard_layout_; | 97 Layout keyboard_layout_; |
| 98 Modifiers keyboard_modifiers_; | 98 Modifiers keyboard_modifiers_; |
| 99 | 99 |
| 100 #if defined(OS_WIN) | 100 #if defined(OS_WIN) |
| 101 MockKeyboardDriverWin driver_; | 101 MockKeyboardDriverWin driver_; |
| 102 #endif | 102 #endif |
| 103 | 103 |
| 104 DISALLOW_COPY_AND_ASSIGN(MockKeyboard); | 104 DISALLOW_COPY_AND_ASSIGN(MockKeyboard); |
| 105 }; | 105 }; |
| 106 | 106 |
| 107 #endif // CHROME_RENDERER_MOCK_KEYBOARD_H_ | 107 #endif // CONTENT_TEST_MOCK_KEYBOARD_H_ |
| OLD | NEW |