mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-05 13:29:47 -05:00
bring edges into wlr
This commit is contained in:
parent
f469784bbc
commit
d74ac69f7b
9 changed files with 53 additions and 47 deletions
|
|
@ -10,13 +10,6 @@ enum roots_cursor_mode {
|
|||
ROOTS_CURSOR_ROTATE = 3,
|
||||
};
|
||||
|
||||
enum roots_cursor_resize_edge {
|
||||
ROOTS_CURSOR_RESIZE_EDGE_TOP = 1,
|
||||
ROOTS_CURSOR_RESIZE_EDGE_BOTTOM = 2,
|
||||
ROOTS_CURSOR_RESIZE_EDGE_LEFT = 4,
|
||||
ROOTS_CURSOR_RESIZE_EDGE_RIGHT = 8,
|
||||
};
|
||||
|
||||
struct roots_input_event {
|
||||
uint32_t serial;
|
||||
struct wlr_cursor *cursor;
|
||||
|
|
|
|||
|
|
@ -9,6 +9,4 @@
|
|||
#define ROOTS_XCURSOR_MOVE "grabbing"
|
||||
#define ROOTS_XCURSOR_ROTATE "grabbing"
|
||||
|
||||
const char *roots_xcursor_get_resize_name(uint32_t edges);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@
|
|||
#include <wayland-server.h>
|
||||
#include <wlr/types/wlr_cursor.h>
|
||||
#include <wlr/xcursor.h>
|
||||
#include <wlr/util/edges.h>
|
||||
|
||||
/**
|
||||
* A scaled XCursor theme.
|
||||
|
|
@ -50,4 +51,10 @@ struct wlr_xcursor *wlr_xcursor_manager_get_xcursor(
|
|||
void wlr_xcursor_manager_set_cursor_image(struct wlr_xcursor_manager *manager,
|
||||
const char *name, struct wlr_cursor *cursor);
|
||||
|
||||
/**
|
||||
* Get the name of the cursor image for the given edges.
|
||||
*/
|
||||
const char *wlr_xcursor_manager_get_resize_name(enum wlr_edges edges);
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
|||
12
include/wlr/util/edges.h
Normal file
12
include/wlr/util/edges.h
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
#ifndef WLR_UTIL_EDGES_H
|
||||
#define WLR_UTIL_EDGES_H
|
||||
|
||||
enum wlr_edges {
|
||||
WLR_EDGE_NONE = 0,
|
||||
WLR_EDGE_TOP = 1,
|
||||
WLR_EDGE_BOTTOM = 2,
|
||||
WLR_EDGE_LEFT = 4,
|
||||
WLR_EDGE_RIGHT = 8,
|
||||
};
|
||||
|
||||
#endif
|
||||
Loading…
Add table
Add a link
Reference in a new issue