Mir
input_translator.h
Go to the documentation of this file.
1 /*
2  * Copyright © 2014 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: Andreas Pokorny <andreas.pokorny@canonical.com>
17  */
18 
19 #ifndef MIR_INPUT_ANDROID_INPUT_TRANSLATOR_H_
20 #define MIR_INPUT_ANDROID_INPUT_TRANSLATOR_H_
21 
23 
24 #include "InputListener.h"
25 
26 #include <memory>
27 
28 namespace droidinput = android;
29 
30 namespace mir
31 {
32 namespace input
33 {
34 class InputDispatcher;
35 namespace android
36 {
37 class InputTranslator : public droidinput::InputListenerInterface
38 {
39 public:
40  InputTranslator(std::shared_ptr<InputDispatcher> const& dispatcher);
41 
42  void notifyConfigurationChanged(const droidinput::NotifyConfigurationChangedArgs* args) override;
43  void notifyKey(const droidinput::NotifyKeyArgs* args) override;
44  void notifyMotion(const droidinput::NotifyMotionArgs* args) override;
45  void notifySwitch(const droidinput::NotifySwitchArgs* args) override;
46  void notifyDeviceReset(const droidinput::NotifyDeviceResetArgs* args) override;
47 
48 private:
49  std::shared_ptr<InputDispatcher> const dispatcher;
50 };
51 
52 }
53 }
54 }
55 
56 #endif
All things Mir.
Definition: buffer_stream.h:37
void notifyKey(const droidinput::NotifyKeyArgs *args) override
void notifyMotion(const droidinput::NotifyMotionArgs *args) override
InputTranslator(std::shared_ptr< InputDispatcher > const &dispatcher)
void notifyDeviceReset(const droidinput::NotifyDeviceResetArgs *args) override
void notifyConfigurationChanged(const droidinput::NotifyConfigurationChangedArgs *args) override
void notifySwitch(const droidinput::NotifySwitchArgs *args) override
Definition: input_translator.h:37
Definition: android_input_receiver.h:32

Copyright © 2012,2013 Canonical Ltd.
Generated on Tue Mar 24 16:15:19 UTC 2015