mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-12-16 08:56:26 -05:00
backend/libinput: remove wlr_input_device_impl
This commit is contained in:
parent
887516d004
commit
91ba28e020
9 changed files with 64 additions and 35 deletions
|
|
@ -2,12 +2,13 @@
|
|||
#include <libinput.h>
|
||||
#include <stdlib.h>
|
||||
#include <wlr/backend/session.h>
|
||||
#include <wlr/interfaces/wlr_pointer.h>
|
||||
#include <wlr/types/wlr_input_device.h>
|
||||
#include <wlr/util/log.h>
|
||||
#include "backend/libinput.h"
|
||||
#include "util/signal.h"
|
||||
|
||||
const struct wlr_pointer_impl libinput_pointer_impl = {0};
|
||||
|
||||
struct wlr_pointer *create_libinput_pointer(
|
||||
struct libinput_device *libinput_dev) {
|
||||
assert(libinput_dev);
|
||||
|
|
@ -17,7 +18,7 @@ struct wlr_pointer *create_libinput_pointer(
|
|||
return NULL;
|
||||
}
|
||||
const char *name = libinput_device_get_name(libinput_dev);
|
||||
wlr_pointer_init(wlr_pointer, NULL, name);
|
||||
wlr_pointer_init(wlr_pointer, &libinput_pointer_impl, name);
|
||||
wlr_pointer->base.vendor = libinput_device_get_id_vendor(libinput_dev);
|
||||
wlr_pointer->base.product = libinput_device_get_id_product(libinput_dev);
|
||||
return wlr_pointer;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue