mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
types/wlr_pointer: add base wlr_input_device
wlr_pointer owns its wlr_input_device. It will be initialized when the pointer is initialized, and finished when the pointer is destroyed.
This commit is contained in:
parent
a1978b1299
commit
d5480efc7a
10 changed files with 53 additions and 51 deletions
|
|
@ -16,7 +16,7 @@ struct wlr_pointer_impl {
|
|||
};
|
||||
|
||||
void wlr_pointer_init(struct wlr_pointer *pointer,
|
||||
const struct wlr_pointer_impl *impl);
|
||||
const struct wlr_pointer_impl *impl, const char *name);
|
||||
void wlr_pointer_destroy(struct wlr_pointer *pointer);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -17,6 +17,8 @@
|
|||
struct wlr_pointer_impl;
|
||||
|
||||
struct wlr_pointer {
|
||||
struct wlr_input_device base;
|
||||
|
||||
const struct wlr_pointer_impl *impl;
|
||||
|
||||
struct {
|
||||
|
|
|
|||
|
|
@ -11,7 +11,6 @@
|
|||
|
||||
#include <wayland-server-core.h>
|
||||
#include <wayland-server-protocol.h>
|
||||
#include <wlr/interfaces/wlr_input_device.h>
|
||||
#include <wlr/interfaces/wlr_pointer.h>
|
||||
#include <wlr/interfaces/wlr_output.h>
|
||||
|
||||
|
|
@ -28,7 +27,7 @@ struct wlr_virtual_pointer_manager_v1 {
|
|||
};
|
||||
|
||||
struct wlr_virtual_pointer_v1 {
|
||||
struct wlr_input_device input_device;
|
||||
struct wlr_pointer pointer;
|
||||
struct wl_resource *resource;
|
||||
/* Vertical and horizontal */
|
||||
struct wlr_event_pointer_axis axis_event[2];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue