input: use keyboard consumers to seperate cell and overlay logic

This commit is contained in:
Megamouse 2024-04-25 23:17:27 +02:00
parent 6fc7fa3b13
commit fcba193a3c
8 changed files with 269 additions and 107 deletions

View file

@ -11,14 +11,16 @@ class basic_keyboard_handler final : public KeyboardHandlerBase, public QObject
using KeyboardHandlerBase::KeyboardHandlerBase;
public:
void Init(const u32 max_connect) override;
void Init(keyboard_consumer& consumer, const u32 max_connect) override;
void SetTargetWindow(QWindow* target);
bool eventFilter(QObject* watched, QEvent* event) override;
void keyPressEvent(QKeyEvent* event);
void keyReleaseEvent(QKeyEvent* event);
static s32 getUnmodifiedKey(QKeyEvent* event);
void LoadSettings();
private:
void LoadSettings(Keyboard& keyboard);
QWindow* m_target = nullptr;
};