AntiMicroX
winsendinputeventhandler.h
Go to the documentation of this file.
1 /* antimicro Gamepad to KB+M event mapper
2  * Copyright (C) 2015 Travis Nickles <nickles.travis@gmail.com>
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8 
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13 
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef WINSENDINPUTEVENTHANDLER_H
19 #define WINSENDINPUTEVENTHANDLER_H
20 
21 #include <QObject>
22 
23 #include "baseeventhandler.h"
24 
25 #include <joybuttonslot.h>
26 
34 {
35  Q_OBJECT
36  public:
37  explicit WinSendInputEventHandler(QObject *parent = 0);
38 
39  virtual bool init() override;
40  virtual bool cleanup() override;
41  virtual void sendKeyboardEvent(JoyButtonSlot *slot, bool pressed) override;
42  virtual void sendMouseButtonEvent(JoyButtonSlot *slot, bool pressed) override;
43  virtual void sendMouseEvent(int xDis, int yDis) override;
44  virtual void sendMouseSpringEvent(int xDis, int yDis, int width, int height) override;
45  virtual void sendTextEntryEvent(QString maintext) override;
46 
47  virtual QString getName() override;
48  virtual QString getIdentifier() override;
49 
50  signals:
51 
52  public slots:
53 };
54 
55 #endif // WINSENDINPUTEVENTHANDLER_H
WinSendInputEventHandler::sendMouseButtonEvent
virtual void sendMouseButtonEvent(JoyButtonSlot *slot, bool pressed) override
Definition: winsendinputeventhandler.cpp:55
code
the intent is to exercise the right to control the distribution of derivative or collective works based on the Library In mere aggregation of another work not based on the Library with the you must alter all the notices that refer to this so that they refer to the ordinary GNU General Public instead of to this it is irreversible for that so the ordinary GNU General Public License applies to all subsequent copies and derivative works made from that copy This option is useful when you wish to copy part of the code of the Library into a program that is not a library You may copy and distribute the which must be distributed under the terms of Sections and above on a medium customarily used for software interchange If distribution of object code is made by offering access to copy from a designated then offering equivalent access to copy the source code from the same place satisfies the requirement to distribute the source code
Definition: lgpl-2.1.txt:237
WinSendInputEventHandler::init
virtual bool init() override
Definition: winsendinputeventhandler.cpp:31
QtKeyMapperBase::getCharKeyInformation
charKeyInformation getCharKeyInformation(QChar value)
Definition: qtkeymapperbase.cpp:69
WinExtras::scancodeFromVirtualKey
static unsigned int scancodeFromVirtualKey(unsigned int virtualkey, unsigned int alias=0)
Convert a virtual key into the corresponding keyboard scan code.
Definition: winextras.cpp:198
WinSendInputEventHandler::sendTextEntryEvent
virtual void sendTextEntryEvent(QString maintext) override
Definition: winsendinputeventhandler.cpp:131
WinSendInputEventHandler
Input event handler class for Windows.
Definition: winsendinputeventhandler.h:33
antkeymapper.h
WinExtras::EXTENDED_FLAG
static const unsigned int EXTENDED_FLAG
Definition: winextras.h:18
WinSendInputEventHandler::sendMouseSpringEvent
virtual void sendMouseSpringEvent(int xDis, int yDis, int width, int height) override
Do nothing by default. Useful for child classes to define behavior.
Definition: winsendinputeventhandler.cpp:114
winextras.h
joybuttonslot.h
JoyButtonSlot
Represents action which can be performed after pressing button.
Definition: joybuttonslot.h:37
AntKeyMapper
Definition: antkeymapper.h:36
BaseEventHandler
Base class for input event handlers.
Definition: baseeventhandler.h:32
QtWinKeyMapper
Definition: qtwinkeymapper.h:24
AntKeyMapper::getInstance
static AntKeyMapper * getInstance(QString handler="")
Definition: antkeymapper.cpp:80
JoyButtonSlot::getSlotCode
int getSlotCode() const
Definition: joybuttonslot.cpp:110
baseeventhandler.h
WinSendInputEventHandler::sendMouseEvent
virtual void sendMouseEvent(int xDis, int yDis) override
Move cursor to selected relative location (deltax delaty)
Definition: winsendinputeventhandler.cpp:99
WinSendInputEventHandler::cleanup
virtual bool cleanup() override
Definition: winsendinputeventhandler.cpp:33
WinSendInputEventHandler::sendKeyboardEvent
virtual void sendKeyboardEvent(JoyButtonSlot *slot, bool pressed) override
Definition: winsendinputeventhandler.cpp:35
JoyButtonSlot::getSlotCodeAlias
int getSlotCodeAlias() const
Definition: joybuttonslot.cpp:108
WinSendInputEventHandler::getIdentifier
virtual QString getIdentifier() override
Definition: winsendinputeventhandler.cpp:112
QtKeyMapperBase::_charKeyInformation::virtualkey
int virtualkey
Definition: qtkeymapperbase.h:35
winsendinputeventhandler.h
WinSendInputEventHandler::getName
virtual QString getName() override
Definition: winsendinputeventhandler.cpp:110
AntKeyMapper::getKeyMapper
QtKeyMapperBase * getKeyMapper() const
Definition: antkeymapper.cpp:110
QtKeyMapperBase::_charKeyInformation::modifiers
Qt::KeyboardModifiers modifiers
Definition: qtkeymapperbase.h:34
QtKeyMapperBase::_charKeyInformation
Definition: qtkeymapperbase.h:32
WinSendInputEventHandler::WinSendInputEventHandler
WinSendInputEventHandler(QObject *parent=0)
Definition: winsendinputeventhandler.cpp:26