mirror of
https://github.com/cage-kiosk/cage.git
synced 2025-10-29 05:40:19 -04:00
cage: add data device manager
This protocol is required by at least GTK applications to receive mouse input.
This commit is contained in:
parent
21a8539399
commit
4c22c9494b
1 changed files with 9 additions and 0 deletions
9
cageng.c
9
cageng.c
|
|
@ -22,6 +22,7 @@
|
|||
#include <wlr/render/wlr_renderer.h>
|
||||
#include <wlr/types/wlr_compositor.h>
|
||||
#include <wlr/types/wlr_cursor.h>
|
||||
#include <wlr/types/wlr_data_device.h>
|
||||
#include <wlr/types/wlr_seat.h>
|
||||
#include <wlr/types/wlr_xcursor_manager.h>
|
||||
#include <wlr/types/wlr_xdg_shell.h>
|
||||
|
|
@ -385,6 +386,7 @@ main(int argc, char *argv[])
|
|||
struct wlr_renderer *renderer = NULL;
|
||||
struct wlr_compositor *compositor = NULL;
|
||||
struct wlr_xdg_shell *xdg_shell = NULL;
|
||||
struct wlr_data_device_manager *data_device_manager = NULL;
|
||||
pid_t pid = 0;
|
||||
int ret = 0;
|
||||
|
||||
|
|
@ -443,6 +445,13 @@ main(int argc, char *argv[])
|
|||
goto end;
|
||||
}
|
||||
|
||||
data_device_manager = wlr_data_device_manager_create(server.wl_display);
|
||||
if (!data_device_manager) {
|
||||
wlr_log(WLR_ERROR, "Unable to create the data device manager");
|
||||
ret = 1;
|
||||
goto end;
|
||||
}
|
||||
|
||||
wl_list_init(&server.outputs);
|
||||
server.new_output.notify = handle_new_output;
|
||||
wl_signal_add(&backend->events.new_output, &server.new_output);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue