aboutsummaryrefslogtreecommitdiff
path: root/include/wlr/wayland.h
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-05-07 12:26:48 -0400
committerDrew DeVault <sir@cmpwn.com>2017-05-07 12:26:48 -0400
commit00931f2f8fa4098c5e70b5ececd6d2dcb8786f90 (patch)
tree45d3e79648d601161f483d3f66ac960851ba233f /include/wlr/wayland.h
parent15b1ce9e6ced22a90ab0df7a6b86c6d35c40ca93 (diff)
Generalize output handling
Diffstat (limited to 'include/wlr/wayland.h')
-rw-r--r--include/wlr/wayland.h41
1 files changed, 18 insertions, 23 deletions
diff --git a/include/wlr/wayland.h b/include/wlr/wayland.h
index bbbd2457..158acc33 100644
--- a/include/wlr/wayland.h
+++ b/include/wlr/wayland.h
@@ -3,26 +3,26 @@
#include <wayland-server.h>
#include <wlr/common/list.h>
+#include <stdbool.h>
-struct wlr_wl_seat {
- struct wl_seat *wl_seat;
- uint32_t capabilities;
- char *name;
- list_t *keyboards;
- list_t *pointers;
-};
-
-void wlr_wl_seat_free(struct wlr_wl_seat *seat);
+struct wlr_output_mode_state;
-struct wlr_wl_output_mode {
+struct wlr_output_mode {
+ struct wlr_output_mode_state *state;
uint32_t flags; // enum wl_output_mode
int32_t width, height;
int32_t refresh; // mHz
};
-struct wlr_wl_output {
- struct wl_output *wl_output;
+struct wlr_output_impl;
+struct wlr_output_state;
+
+struct wlr_output {
+ const struct wlr_output_impl *impl;
+ struct wlr_output_state *state;
+
uint32_t flags;
+ char *name;
char *make;
char *model;
uint32_t scale;
@@ -30,20 +30,15 @@ struct wlr_wl_output {
int32_t phys_width, phys_height; // mm
int32_t subpixel; // enum wl_output_subpixel
int32_t transform; // enum wl_output_transform
- list_t *modes;
- struct wlr_wl_output_mode *current_mode;
-};
-void wlr_wl_output_free(struct wlr_wl_output *output);
+ list_t *modes;
+ struct wlr_output_mode *current_mode;
-struct wlr_wl_keyboard {
- struct wl_keyboard *wl_keyboard;
+ struct {
+ struct wl_signal frame;
+ } events;
};
-struct wlr_wl_pointer {
- struct wl_pointer *wl_pointer;
- struct wl_surface *current_surface;
- wl_fixed_t x, y;
-};
+bool wlr_output_set_mode(struct wlr_output *output, struct wlr_output_mode *mode);
#endif