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/input_method/ibus_keymap.h" | 5 #include "chrome/browser/chromeos/input_method/ibus_keymap.h" |
6 | 6 |
7 #if defined(HAVE_IBUS) | 7 #if defined(HAVE_IBUS) |
8 #include <ibus.h> | 8 #include <ibus.h> |
9 #endif | 9 #endif |
10 | 10 |
| 11 namespace chromeos { |
| 12 namespace input_method { |
| 13 |
11 #if defined(HAVE_IBUS) | 14 #if defined(HAVE_IBUS) |
12 std::string GetIBusKey(int keyval) { | 15 std::string GetIBusKey(int keyval) { |
13 // TODO: Ensure all keys are supported. | 16 // TODO: Ensure all keys are supported. |
14 switch (keyval) { | 17 switch (keyval) { |
15 case IBUS_Escape: | 18 case IBUS_Escape: |
16 return "Esc"; | 19 return "Esc"; |
17 case IBUS_F1: | 20 case IBUS_F1: |
18 return "HistoryBack"; | 21 return "HistoryBack"; |
19 case IBUS_F2: | 22 case IBUS_F2: |
20 return "HistoryForward"; | 23 return "HistoryForward"; |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 } | 82 } |
80 #else | 83 #else |
81 std::string GetIBusKey(int keyval, int keycode) { | 84 std::string GetIBusKey(int keyval, int keycode) { |
82 return ""; | 85 return ""; |
83 } | 86 } |
84 | 87 |
85 std::string GetIBusKeyCode(int keyval, int keycode) { | 88 std::string GetIBusKeyCode(int keyval, int keycode) { |
86 return ""; | 89 return ""; |
87 } | 90 } |
88 #endif // HAVE_IBUS | 91 #endif // HAVE_IBUS |
| 92 |
| 93 } // namespace input_method |
| 94 } // namespace chromeos |
OLD | NEW |