| Index: remoting/host/input_injector_chromeos.cc
|
| diff --git a/remoting/host/input_injector_chromeos.cc b/remoting/host/input_injector_chromeos.cc
|
| index 65c58de51e89407aecacc3fd941a3d05a6e87ae8..1398e3f864c84e35cfefe71ce0abfe561482f073 100644
|
| --- a/remoting/host/input_injector_chromeos.cc
|
| +++ b/remoting/host/input_injector_chromeos.cc
|
| @@ -60,6 +60,9 @@ class InputInjectorChromeos::Core {
|
| void Start(std::unique_ptr<protocol::ClipboardStub> client_clipboard);
|
|
|
| private:
|
| + // Sets the caps lock state to match states
|
| + void SetLockStates(uint32_t states);
|
| +
|
| std::unique_ptr<ui::SystemInputInjector> delegate_;
|
| std::unique_ptr<Clipboard> clipboard_;
|
|
|
| @@ -82,6 +85,10 @@ void InputInjectorChromeos::Core::InjectKeyEvent(const KeyEvent& event) {
|
| DCHECK(event.has_pressed());
|
| DCHECK(event.has_usb_keycode());
|
|
|
| + if (event.has_lock_states()) {
|
| + SetLockStates(event.lock_states());
|
| + }
|
| +
|
| ui::DomCode dom_code =
|
| ui::KeycodeConverter::UsbKeycodeToDomCode(event.usb_keycode());
|
|
|
| @@ -123,6 +130,13 @@ void InputInjectorChromeos::Core::Start(
|
| point_transformer_.reset(new PointTransformer());
|
| }
|
|
|
| +void InputInjectorChromeos::Core::SetLockStates(uint32_t states) {
|
| + ui::InputController* input_controller =
|
| + ui::OzonePlatform::GetInstance()->GetInputController();
|
| + input_controller->SetCapsLockEnabled(
|
| + states & protocol::KeyEvent::LOCK_STATES_CAPSLOCK);
|
| +}
|
| +
|
| InputInjectorChromeos::InputInjectorChromeos(
|
| scoped_refptr<base::SingleThreadTaskRunner> task_runner)
|
| : input_task_runner_(task_runner) {
|
|
|