diff options
author | Josh Rahm <rahm@google.com> | 2024-03-19 17:40:37 -0600 |
---|---|---|
committer | Josh Rahm <rahm@google.com> | 2024-03-19 17:42:39 -0600 |
commit | 86d91d7032f2d8175fd1ab3b23ee0c1a6445fb7a (patch) | |
tree | cf0ff519a044a9166d0b508920702c11f40b9e14 /harness/include/plugin.h | |
parent | 103583fd20066b6da829db5c6a72c81e265f0fa4 (diff) | |
download | wetterhorn-86d91d7032f2d8175fd1ab3b23ee0c1a6445fb7a.tar.gz wetterhorn-86d91d7032f2d8175fd1ab3b23ee0c1a6445fb7a.tar.bz2 wetterhorn-86d91d7032f2d8175fd1ab3b23ee0c1a6445fb7a.zip |
Implementing button presses and integrating it with the KeysM monad.
Diffstat (limited to 'harness/include/plugin.h')
-rw-r--r-- | harness/include/plugin.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/harness/include/plugin.h b/harness/include/plugin.h index c48a2f5..be3a022 100644 --- a/harness/include/plugin.h +++ b/harness/include/plugin.h @@ -8,6 +8,7 @@ #include <stdlib.h> #include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_keyboard.h> +#include <wlr/types/wlr_pointer.h> #include "plugin_types.h" #include <foreign_intf.h> @@ -24,6 +25,7 @@ EXPORT_INCLUDE(<foreign_intf.h>) EXPORT_INCLUDE(<wlr/types/wlr_keyboard.h>) EXPORT_INCLUDE(<wlr/types/wlr_input_device.h>) +EXPORT_INCLUDE(<wlr/types/wlr_pointer.h>) // clang-format on #define MAX_QUEUED_ACTIONS 8 @@ -139,9 +141,12 @@ typedef struct PLUGIN { * Handles a keybinding. */ EXPORT(opqst_t (*plugin_handle_keybinding)( - struct wlr_keyboard *keyboard, - struct wlr_keyboard_key_event *event, uint32_t modifiers, uint32_t keysym, - uint32_t codepoint, int *out_handled, opqst_t state)); + struct wlr_keyboard *keyboard, struct wlr_keyboard_key_event *event, + uint32_t modifiers, uint32_t keysym, uint32_t codepoint, int *out_handled, + opqst_t state)); + + EXPORT(opqst_t (*plugin_handle_button)(struct wlr_pointer_button_event *event, + opqst_t state)); /* * Handles a surface being mapped, unmapped or destroyed. |