| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #include "chromeos/ime/ime_keyboard.h" |
| 6 |
| 7 namespace chromeos { |
| 8 namespace input_method { |
| 9 |
| 10 |
| 11 ImeKeyboard::ImeKeyboard() |
| 12 : caps_lock_is_enabled_(false) { |
| 13 } |
| 14 |
| 15 ImeKeyboard::~ImeKeyboard() { |
| 16 } |
| 17 |
| 18 bool ImeKeyboard::SetCurrentKeyboardLayoutByName( |
| 19 const std::string& layout_name) { |
| 20 last_layout_ = layout_name; |
| 21 } |
| 22 |
| 23 void ImeKeyboard::AddObserver(Observer* observer) { |
| 24 observers_.AddObserver(observer); |
| 25 } |
| 26 |
| 27 void ImeKeyboard::RemoveObserver(Observer* observer) { |
| 28 observers_.RemoveObserver(observer); |
| 29 } |
| 30 |
| 31 bool ImeKeyboard::ReapplyCurrentKeyboardLayout() { |
| 32 return true; |
| 33 } |
| 34 |
| 35 void ImeKeyboard::ReapplyCurrentModifierLockStatus() { |
| 36 } |
| 37 |
| 38 void ImeKeyboard::DisableNumLock() { |
| 39 } |
| 40 |
| 41 void ImeKeyboard::SetCapsLockEnabled(bool enable_caps_lock) { |
| 42 bool old_state = caps_lock_is_enabled_; |
| 43 caps_lock_is_enabled_ = enable_caps_lock; |
| 44 if (old_state != enable_caps_lock) { |
| 45 FOR_EACH_OBSERVER(ImeKeyboard::Observer, observers_, |
| 46 OnCapsLockChanged(enable_caps_lock)); |
| 47 } |
| 48 } |
| 49 |
| 50 bool ImeKeyboard::ReapplyCurrentKeyboardLayout() { |
| 51 return true; |
| 52 } |
| 53 |
| 54 void ImeKeyboard::ReapplyCurrentModifierLockStatus() { |
| 55 } |
| 56 |
| 57 void ImeKeyboard::DisableNumLock() { |
| 58 } |
| 59 |
| 60 |
| 61 bool ImeKeyboard::CapsLockIsEnabled() { |
| 62 return caps_lock_is_enabled_; |
| 63 } |
| 64 |
| 65 bool ImeKeyboard::IsISOLevel5ShiftAvailable() const { |
| 66 return false; |
| 67 } |
| 68 |
| 69 bool ImeKeyboard::IsAltGrAvailable() const { |
| 70 return false; |
| 71 } |
| 72 |
| 73 bool ImeKeyboard::SetAutoRepeatEnabled(bool enabled) { |
| 74 return true; |
| 75 } |
| 76 |
| 77 bool ImeKeyboard::SetAutoRepeatRate(const AutoRepeatRate& rate) { |
| 78 return true; |
| 79 } |
| 80 |
| 81 } // namespace input_method |
| 82 } // namespace chromeos |
| OLD | NEW |