Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(640)

Side by Side Diff: remoting/client/input/keyboard_interpreter.h

Issue 2868383003: [CRD iOS] Send key events to the session. (Closed)
Patch Set: Update based on feedback. Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2017 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 #ifndef REMOTING_CLIENT_INPUT_KEYBOARD_INTERPRETER_H_
6 #define REMOTING_CLIENT_INPUT_KEYBOARD_INTERPRETER_H_
7
8 #include <memory>
9 #include <string>
10
11 #include "base/macros.h"
12
13 namespace remoting {
14
15 class KeyboardInputStrategy;
16 class ClientInputInjector;
17
18 // This is a class for interpreting raw keyboard input, it will delegate
19 // handling of text events to the selected keyboard input strategy.
20 class KeyboardInterpreter {
21 public:
22 explicit KeyboardInterpreter(ClientInputInjector* input_injector);
23 ~KeyboardInterpreter();
24
25 // Delegates to |KeyboardInputStrategy| to covert and send the input.
26 void HandleTextEvent(const std::string& text, uint8_t modifiers);
27 // Delegates to |KeyboardInputStrategy| to covert and send the delete.
28 void HandleDeleteEvent(uint8_t modifiers);
29
30 private:
31 std::unique_ptr<KeyboardInputStrategy> input_strategy_;
32
33 DISALLOW_COPY_AND_ASSIGN(KeyboardInterpreter);
34 };
35
36 } // namespace remoting
37 #endif // REMOTING_CLIENT_INPUT_KEYBOARD_INTERPRETER_H_
OLDNEW
« no previous file with comments | « remoting/client/input/keyboard_input_strategy.h ('k') | remoting/client/input/keyboard_interpreter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698