diff options
author | emersion <contact@emersion.fr> | 2017-11-17 23:29:47 +0100 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2017-11-17 23:29:47 +0100 |
commit | 27937add762bb2594828ac678859bfdde4275f1e (patch) | |
tree | aa9813fd534d019a5e967ffad31d153d30ae7fa1 /rootston/xcursor.c | |
parent | 3e3209cba22c9a5a562acc5e543946408a36e2f4 (diff) | |
parent | bf5640db128b930b38ebca2b1d8a79e028ad9f39 (diff) |
Merge branch 'master' into laggy-move-resize
Diffstat (limited to 'rootston/xcursor.c')
-rw-r--r-- | rootston/xcursor.c | 24 |
1 files changed, 5 insertions, 19 deletions
diff --git a/rootston/xcursor.c b/rootston/xcursor.c index 43cbfc51..74e732c9 100644 --- a/rootston/xcursor.c +++ b/rootston/xcursor.c @@ -1,15 +1,10 @@ -#include <wlr/types/wlr_cursor.h> +#define _POSIX_C_SOURCE 200809L +#include <stdlib.h> +#include <string.h> +#include "rootston/xcursor.h" #include "rootston/input.h" -struct wlr_xcursor *get_default_xcursor(struct wlr_xcursor_theme *theme) { - return wlr_xcursor_theme_get_cursor(theme, "left_ptr"); -} - -struct wlr_xcursor *get_move_xcursor(struct wlr_xcursor_theme *theme) { - return wlr_xcursor_theme_get_cursor(theme, "grabbing"); -} - -static const char *get_resize_xcursor_name(uint32_t edges) { +const char *roots_xcursor_get_resize_name(uint32_t edges) { if (edges & ROOTS_CURSOR_RESIZE_EDGE_TOP) { if (edges & ROOTS_CURSOR_RESIZE_EDGE_RIGHT) { return "ne-resize"; @@ -31,12 +26,3 @@ static const char *get_resize_xcursor_name(uint32_t edges) { } return "se-resize"; // fallback } - -struct wlr_xcursor *get_resize_xcursor(struct wlr_xcursor_theme *theme, - uint32_t edges) { - return wlr_xcursor_theme_get_cursor(theme, get_resize_xcursor_name(edges)); -} - -struct wlr_xcursor *get_rotate_xcursor(struct wlr_xcursor_theme *theme) { - return wlr_xcursor_theme_get_cursor(theme, "grabbing"); -} |