aboutsummaryrefslogtreecommitdiff
path: root/include/rootston
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-11-12 17:10:11 -0500
committerGitHub <noreply@github.com>2017-11-12 17:10:11 -0500
commit855c117efdab06bd232a3f0d6e81d7288a0551ed (patch)
treead2aa347b862cc7446a1cc80f5932847e1491fbe /include/rootston
parenta317ecdab8ef8deb184b72db208794daa4c4a3a0 (diff)
parentf8b43940b1a14e78c5365c9c1d17bfc79f523530 (diff)
Merge pull request #412 from emersion/cursor-scale
Scale cursors on scaled outputs
Diffstat (limited to 'include/rootston')
-rw-r--r--include/rootston/cursor.h2
-rw-r--r--include/rootston/desktop.h2
-rw-r--r--include/rootston/xcursor.h13
3 files changed, 9 insertions, 8 deletions
diff --git a/include/rootston/cursor.h b/include/rootston/cursor.h
index c0dbc010..f49b6439 100644
--- a/include/rootston/cursor.h
+++ b/include/rootston/cursor.h
@@ -30,7 +30,7 @@ struct roots_cursor {
enum roots_cursor_mode mode;
// state from input (review if this is necessary)
- struct wlr_xcursor_theme *xcursor_theme;
+ struct wlr_xcursor_manager *xcursor_manager;
struct wlr_seat *wl_seat;
struct wl_client *cursor_client;
int offs_x, offs_y;
diff --git a/include/rootston/desktop.h b/include/rootston/desktop.h
index 376412fb..b809db43 100644
--- a/include/rootston/desktop.h
+++ b/include/rootston/desktop.h
@@ -7,6 +7,7 @@
#include <wlr/types/wlr_compositor.h>
#include <wlr/types/wlr_wl_shell.h>
#include <wlr/types/wlr_xdg_shell_v6.h>
+#include <wlr/types/wlr_xcursor_manager.h>
#include <wlr/types/wlr_gamma_control.h>
#include <wlr/types/wlr_screenshooter.h>
#include <wlr/types/wlr_list.h>
@@ -31,6 +32,7 @@ struct roots_desktop {
struct roots_config *config;
struct wlr_output_layout *layout;
+ struct wlr_xcursor_manager *xcursor_manager;
struct wlr_compositor *compositor;
struct wlr_wl_shell *wl_shell;
diff --git a/include/rootston/xcursor.h b/include/rootston/xcursor.h
index c96e50ef..bc00f79c 100644
--- a/include/rootston/xcursor.h
+++ b/include/rootston/xcursor.h
@@ -1,15 +1,14 @@
#ifndef _ROOTSTON_XCURSOR_H
#define _ROOTSTON_XCURSOR_H
-#include <wlr/xcursor.h>
+#include <stdint.h>
-struct wlr_xcursor *get_default_xcursor(struct wlr_xcursor_theme *theme);
+#define ROOTS_XCURSOR_SIZE 16
-struct wlr_xcursor *get_move_xcursor(struct wlr_xcursor_theme *theme);
+#define ROOTS_XCURSOR_DEFAULT "left_ptr"
+#define ROOTS_XCURSOR_MOVE "grabbing"
+#define ROOTS_XCURSOR_ROTATE "grabbing"
-struct wlr_xcursor *get_resize_xcursor(struct wlr_xcursor_theme *theme,
- uint32_t edges);
-
-struct wlr_xcursor *get_rotate_xcursor(struct wlr_xcursor_theme *theme);
+const char *roots_xcursor_get_resize_name(uint32_t edges);
#endif