MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Tools / pointer_handle_button

Function pointer_handle_button

cube/cube.cpp:579–585  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

577static void pointer_handle_motion(void *data, struct wl_pointer *pointer, uint32_t time, wl_fixed_t sx, wl_fixed_t sy) {}
578
579static void pointer_handle_button(void *data, struct wl_pointer *wl_pointer, uint32_t serial, uint32_t time, uint32_t button,
580 uint32_t state) {
581 Demo &demo = *static_cast<Demo *>(data);
582 if (button == BTN_LEFT && state == WL_POINTER_BUTTON_STATE_PRESSED) {
583 xdg_toplevel_move(demo.window_toplevel, demo.seat, serial);
584 }
585}
586
587static void pointer_handle_axis(void *data, struct wl_pointer *wl_pointer, uint32_t time, uint32_t axis, wl_fixed_t value) {}
588

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected