aboutsummaryrefslogtreecommitdiff
path: root/pgo
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2022-04-19 15:24:25 +0000
committerDaniel Eklöf <daniel@ekloef.se>2022-04-19 15:24:25 +0000
commit876044df8d5912f814423815dadd6c192f0cd644 (patch)
tree107882895b36f6730dcc6a6106a7ca27be435359 /pgo
parentsearch: add comment to ‘advance_pos()’ macro (diff)
wayland: remove selection_override_modmask member
This member is no longer valid - we need to use one from the current key-binding set.
Diffstat (limited to 'pgo')
-rw-r--r--pgo/pgo.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/pgo/pgo.c b/pgo/pgo.c
index 4b979990..26e0c10e 100644
--- a/pgo/pgo.c
+++ b/pgo/pgo.c
@@ -13,6 +13,7 @@
#include "async.h"
#include "config.h"
+#include "key-binding.h"
#include "reaper.h"
#include "sixel.h"
#include "user-notification.h"
@@ -170,6 +171,27 @@ void get_current_modifiers(const struct seat *seat,
xkb_mod_mask_t *effective,
xkb_mod_mask_t *consumed, uint32_t key) {}
+static struct key_binding_set kbd;
+static bool kbd_initialized = false;
+
+struct key_binding_set *
+key_binding_for(
+ struct key_binding_manager *mgr, const struct terminal *term,
+ const struct seat *seat)
+{
+ if (!kbd_initialized) {
+ kbd_initialized = true;
+ kbd = (struct key_binding_set){
+ .key = tll_init(),
+ .search = tll_init(),
+ .url = tll_init(),
+ .mouse = tll_init(),
+ .selection_overrides = 0,
+ };
+ }
+
+ return &kbd;
+}
int
main(int argc, const char *const *argv)