Mir
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
rudimentary_input_reader_policy.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2012 Canonical Ltd.
3  *
4  * This program is free software: you can redistribute it and/or modify it
5  * under the terms of the GNU General Public License version 3,
6  * as published by the Free Software Foundation.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * GNU General Public License for more details.
12  *
13  * You should have received a copy of the GNU General Public License
14  * along with this program. If not, see <http://www.gnu.org/licenses/>.
15  *
16  * Authored by: Robert Carr <robert.carr@canonical.com>
17  */
18 #ifndef MIR_INPUT_ANDROID_RUDIMENTARY_INPUT_READER_POLICY_H_
19 #define MIR_INPUT_ANDROID_RUDIMENTARY_INPUT_READER_POLICY_H_
20 
21 // from android
22 #include <InputReader.h>
23 
24 namespace droidinput = android;
25 
26 namespace mir
27 {
28 namespace input
29 {
30 namespace android
31 {
32 class RudimentaryInputReaderPolicy : public droidinput::InputReaderPolicyInterface
33 {
34  public:
35  // From InputReaderPolicyInterface
36  virtual void getReaderConfiguration(
37  droidinput::InputReaderConfiguration* out_config);
38 
39  // TODO: We should think about refactoring the device identification approach
40  virtual droidinput::sp<droidinput::PointerControllerInterface> obtainPointerController(
41  int32_t device_id);
42 
43  virtual void notifyInputDevicesChanged(
44  const droidinput::Vector<droidinput::InputDeviceInfo>& input_devices);
45 
46  virtual droidinput::sp<droidinput::KeyCharacterMap> getKeyboardLayoutOverlay(
47  const droidinput::String8& input_device_descriptor);
48 
49  virtual droidinput::String8 getDeviceAlias(
50  const droidinput::InputDeviceIdentifier& identifier);
51 
52  private:
53  droidinput::sp<droidinput::PointerController> pointer_controller;
54 };
55 
56 }
57 }
58 } // namespace mir
59 
60 #endif // MIR_INPUT_ANDROID_RUDIMENTARY_INPUT_READER_POLICY_H_
All things Mir.
Definition: aging_buffer.h:24
virtual droidinput::sp< droidinput::PointerControllerInterface > obtainPointerController(int32_t device_id)
Definition: rudimentary_input_reader_policy.h:32
virtual droidinput::String8 getDeviceAlias(const droidinput::InputDeviceIdentifier &identifier)
virtual void getReaderConfiguration(droidinput::InputReaderConfiguration *out_config)
virtual droidinput::sp< droidinput::KeyCharacterMap > getKeyboardLayoutOverlay(const droidinput::String8 &input_device_descriptor)
Definition: android_input_receiver.h:32
virtual void notifyInputDevicesChanged(const droidinput::Vector< droidinput::InputDeviceInfo > &input_devices)

Copyright © 2012,2013 Canonical Ltd.
Generated on Fri Oct 10 14:07:14 UTC 2014