diff options
Diffstat (limited to 'include')
51 files changed, 131 insertions, 127 deletions
diff --git a/include/backend/drm/drm.h b/include/backend/drm/drm.h index 12530da6..65db04ef 100644 --- a/include/backend/drm/drm.h +++ b/include/backend/drm/drm.h @@ -1,19 +1,17 @@ #ifndef BACKEND_DRM_DRM_H #define BACKEND_DRM_DRM_H +#include <EGL/egl.h> +#include <gbm.h> #include <stdbool.h> #include <stddef.h> #include <stdint.h> #include <wayland-server.h> -#include <xf86drmMode.h> -#include <EGL/egl.h> -#include <gbm.h> #include <wayland-util.h> - -#include <wlr/backend/session.h> #include <wlr/backend/drm.h> +#include <wlr/backend/session.h> #include <wlr/render/egl.h> - +#include <xf86drmMode.h> #include "iface.h" #include "properties.h" #include "renderer.h" diff --git a/include/backend/drm/iface.h b/include/backend/drm/iface.h index 15cdf1ab..ef0e7bf8 100644 --- a/include/backend/drm/iface.h +++ b/include/backend/drm/iface.h @@ -1,10 +1,9 @@ #ifndef BACKEND_DRM_IFACE_H #define BACKEND_DRM_IFACE_H +#include <gbm.h> #include <stdbool.h> #include <stdint.h> - -#include <gbm.h> #include <xf86drm.h> #include <xf86drmMode.h> diff --git a/include/backend/drm/renderer.h b/include/backend/drm/renderer.h index bf0165bc..a56a8673 100644 --- a/include/backend/drm/renderer.h +++ b/include/backend/drm/renderer.h @@ -1,12 +1,10 @@ #ifndef BACKEND_DRM_RENDERER_H #define BACKEND_DRM_RENDERER_H -#include <stdbool.h> -#include <stdint.h> - #include <EGL/egl.h> #include <gbm.h> - +#include <stdbool.h> +#include <stdint.h> #include <wlr/render.h> struct wlr_drm_backend; diff --git a/include/backend/drm/util.h b/include/backend/drm/util.h index 6818b4db..25da858f 100644 --- a/include/backend/drm/util.h +++ b/include/backend/drm/util.h @@ -2,9 +2,9 @@ #define BACKEND_DRM_UTIL_H #include <stdint.h> +#include <wlr/types/wlr_output.h> #include <xf86drm.h> #include <xf86drmMode.h> -#include <wlr/types/wlr_output.h> // Calculates a more accurate refresh rate (mHz) than what mode itself provides int32_t calculate_refresh_rate(drmModeModeInfo *mode); diff --git a/include/backend/headless.h b/include/backend/headless.h index f9805bcc..e130bae1 100644 --- a/include/backend/headless.h +++ b/include/backend/headless.h @@ -1,8 +1,8 @@ #ifndef BACKEND_HEADLESS_H #define BACKEND_HEADLESS_H -#include <wlr/backend/interface.h> #include <wlr/backend/headless.h> +#include <wlr/backend/interface.h> struct wlr_headless_backend { struct wlr_backend backend; diff --git a/include/backend/libinput.h b/include/backend/libinput.h index 6ec718c6..f828c310 100644 --- a/include/backend/libinput.h +++ b/include/backend/libinput.h @@ -1,10 +1,11 @@ #ifndef BACKEND_LIBINPUT_H #define BACKEND_LIBINPUT_H + #include <libinput.h> #include <wayland-server-core.h> -#include <wlr/types/wlr_input_device.h> #include <wlr/backend/interface.h> #include <wlr/interfaces/wlr_input_device.h> +#include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_list.h> struct wlr_libinput_backend { diff --git a/include/backend/multi.h b/include/backend/multi.h index 3363c608..c57c48f3 100644 --- a/include/backend/multi.h +++ b/include/backend/multi.h @@ -1,10 +1,10 @@ #ifndef BACKEND_MULTI_H #define BACKEND_MULTI_H +#include <wayland-util.h> #include <wlr/backend/interface.h> #include <wlr/backend/multi.h> #include <wlr/backend/session.h> -#include <wayland-util.h> struct wlr_multi_backend { struct wlr_backend backend; diff --git a/include/backend/wayland.h b/include/backend/wayland.h index 78a88f29..16c8e13b 100644 --- a/include/backend/wayland.h +++ b/include/backend/wayland.h @@ -3,13 +3,13 @@ #include <stdbool.h> #include <wayland-client.h> -#include <wayland-server.h> #include <wayland-egl.h> -#include <wlr/render/egl.h> -#include <wlr/render.h> +#include <wayland-server.h> +#include <wayland-util.h> #include <wlr/backend/wayland.h> +#include <wlr/render.h> +#include <wlr/render/egl.h> #include <wlr/types/wlr_box.h> -#include <wayland-util.h> struct wlr_wl_backend { struct wlr_backend backend; diff --git a/include/backend/x11.h b/include/backend/x11.h index fee39eac..c5f258c0 100644 --- a/include/backend/x11.h +++ b/include/backend/x11.h @@ -1,11 +1,11 @@ -#ifndef WLR_X11_H -#define WLR_X11_H +#ifndef BACKEND_X11_H +#define BACKEND_X11_H #include <stdbool.h> -#include <xcb/xcb.h> -#include <X11/Xlib-xcb.h> #include <wayland-server.h> #include <wlr/render/egl.h> +#include <X11/Xlib-xcb.h> +#include <xcb/xcb.h> struct wlr_x11_backend; diff --git a/include/render/gles2.h b/include/render/gles2.h index 0b7032cc..797c5293 100644 --- a/include/render/gles2.h +++ b/include/render/gles2.h @@ -1,13 +1,13 @@ #ifndef RENDER_GLES2_H #define RENDER_GLES2_H -#include <stdint.h> -#include <string.h> -#include <stdbool.h> -#include <GLES2/gl2.h> -#include <GLES2/gl2ext.h> #include <EGL/egl.h> #include <EGL/eglext.h> +#include <GLES2/gl2.h> +#include <GLES2/gl2ext.h> +#include <stdbool.h> +#include <stdint.h> +#include <string.h> #include <wlr/backend.h> #include <wlr/render.h> #include <wlr/render/egl.h> diff --git a/include/rootston/config.h b/include/rootston/config.h index 05f23b75..9926d9c2 100644 --- a/include/rootston/config.h +++ b/include/rootston/config.h @@ -1,7 +1,8 @@ -#ifndef _ROOTSTON_CONFIG_H -#define _ROOTSTON_CONFIG_H -#include <wlr/types/wlr_output_layout.h> +#ifndef ROOTSTON_CONFIG_H +#define ROOTSTON_CONFIG_H + #include <wlr/types/wlr_input_device.h> +#include <wlr/types/wlr_output_layout.h> #define ROOTS_CONFIG_DEFAULT_SEAT_NAME "seat0" diff --git a/include/rootston/cursor.h b/include/rootston/cursor.h index 90d54c12..a1a466c2 100644 --- a/include/rootston/cursor.h +++ b/include/rootston/cursor.h @@ -1,5 +1,5 @@ -#ifndef _ROOTSTON_CURSOR_H -#define _ROOTSTON_CURSOR_H +#ifndef ROOTSTON_CURSOR_H +#define ROOTSTON_CURSOR_H #include "rootston/seat.h" diff --git a/include/rootston/desktop.h b/include/rootston/desktop.h index 1232121a..6572b242 100644 --- a/include/rootston/desktop.h +++ b/include/rootston/desktop.h @@ -1,22 +1,23 @@ -#ifndef _ROOTSTON_DESKTOP_H -#define _ROOTSTON_DESKTOP_H +#ifndef ROOTSTON_DESKTOP_H +#define ROOTSTON_DESKTOP_H + #include <time.h> #include <wayland-server.h> #include <wlr/config.h> -#include <wlr/types/wlr_output.h> -#include <wlr/types/wlr_output_layout.h> #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_idle.h> +#include <wlr/types/wlr_list.h> +#include <wlr/types/wlr_output_layout.h> +#include <wlr/types/wlr_output.h> #include <wlr/types/wlr_primary_selection.h> #include <wlr/types/wlr_screenshooter.h> -#include <wlr/types/wlr_list.h> -#include <wlr/types/wlr_idle.h> -#include "rootston/view.h" +#include <wlr/types/wlr_wl_shell.h> +#include <wlr/types/wlr_xcursor_manager.h> +#include <wlr/types/wlr_xdg_shell_v6.h> #include "rootston/config.h" #include "rootston/output.h" +#include "rootston/view.h" struct roots_desktop { struct wl_list views; // roots_view::link @@ -39,8 +40,7 @@ struct roots_desktop { struct wlr_primary_selection_device_manager *primary_selection_device_manager; struct wlr_idle *idle; - struct wl_listener output_add; - struct wl_listener output_remove; + struct wl_listener new_output; struct wl_listener layout_change; struct wl_listener xdg_shell_v6_surface; struct wl_listener wl_shell_surface; diff --git a/include/rootston/input.h b/include/rootston/input.h index 726dda24..4395a0f7 100644 --- a/include/rootston/input.h +++ b/include/rootston/input.h @@ -1,20 +1,20 @@ -#ifndef _ROOTSTON_INPUT_H -#define _ROOTSTON_INPUT_H +#ifndef ROOTSTON_INPUT_H +#define ROOTSTON_INPUT_H + #include <wayland-server.h> -#include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_cursor.h> +#include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_seat.h> -#include "rootston/cursor.h" #include "rootston/config.h" -#include "rootston/view.h" +#include "rootston/cursor.h" #include "rootston/server.h" +#include "rootston/view.h" struct roots_input { struct roots_config *config; struct roots_server *server; - struct wl_listener input_add; - struct wl_listener input_remove; + struct wl_listener new_input; struct wl_list seats; }; diff --git a/include/rootston/keyboard.h b/include/rootston/keyboard.h index 39650d7c..0140389a 100644 --- a/include/rootston/keyboard.h +++ b/include/rootston/keyboard.h @@ -1,5 +1,5 @@ -#ifndef _ROOTSTON_KEYBOARD_H -#define _ROOTSTON_KEYBOARD_H +#ifndef ROOTSTON_KEYBOARD_H +#define ROOTSTON_KEYBOARD_H #include <xkbcommon/xkbcommon.h> #include "rootston/input.h" @@ -13,6 +13,7 @@ struct roots_keyboard { struct roots_keyboard_config *config; struct wl_list link; + struct wl_listener device_destroy; struct wl_listener keyboard_key; struct wl_listener keyboard_modifiers; diff --git a/include/rootston/output.h b/include/rootston/output.h index 7f42904f..9682e4f5 100644 --- a/include/rootston/output.h +++ b/include/rootston/output.h @@ -1,8 +1,8 @@ -#ifndef _ROOTSTON_OUTPUT_H -#define _ROOTSTON_OUTPUT_H +#ifndef ROOTSTON_OUTPUT_H +#define ROOTSTON_OUTPUT_H -#include <time.h> #include <pixman.h> +#include <time.h> #include <wayland-server.h> #include <wlr/types/wlr_output_damage.h> @@ -18,11 +18,11 @@ struct roots_output { struct timespec last_frame; struct wlr_output_damage *damage; + struct wl_listener destroy; struct wl_listener frame; }; -void output_add_notify(struct wl_listener *listener, void *data); -void output_remove_notify(struct wl_listener *listener, void *data); +void handle_new_output(struct wl_listener *listener, void *data); struct roots_view; struct roots_drag_icon; diff --git a/include/rootston/seat.h b/include/rootston/seat.h index 0047522c..cc0293b5 100644 --- a/include/rootston/seat.h +++ b/include/rootston/seat.h @@ -1,5 +1,6 @@ -#ifndef _ROOTSTON_SEAT_H -#define _ROOTSTON_SEAT_H +#ifndef ROOTSTON_SEAT_H +#define ROOTSTON_SEAT_H + #include <wayland-server.h> #include "rootston/input.h" #include "rootston/keyboard.h" @@ -56,18 +57,21 @@ struct roots_drag_icon { struct roots_pointer { struct roots_seat *seat; struct wlr_input_device *device; + struct wl_listener device_destroy; struct wl_list link; }; struct roots_touch { struct roots_seat *seat; struct wlr_input_device *device; + struct wl_listener device_destroy; struct wl_list link; }; struct roots_tablet_tool { struct roots_seat *seat; struct wlr_input_device *device; + struct wl_listener device_destroy; struct wl_listener axis; struct wl_listener proximity; struct wl_listener tip; diff --git a/include/rootston/server.h b/include/rootston/server.h index 0c26ea92..5f35dd90 100644 --- a/include/rootston/server.h +++ b/include/rootston/server.h @@ -1,11 +1,12 @@ #ifndef _ROOTSTON_SERVER_H #define _ROOTSTON_SERVER_H + #include <wayland-server.h> -#include <wlr/config.h> #include <wlr/backend.h> #include <wlr/backend/session.h> -#include <wlr/types/wlr_data_device.h> +#include <wlr/config.h> #include <wlr/render.h> +#include <wlr/types/wlr_data_device.h> #ifdef WLR_HAS_XWAYLAND #include <wlr/xwayland.h> #endif diff --git a/include/rootston/view.h b/include/rootston/view.h index f6968c7a..b61ac330 100644 --- a/include/rootston/view.h +++ b/include/rootston/view.h @@ -1,5 +1,5 @@ -#ifndef _ROOTSTON_VIEW_H -#define _ROOTSTON_VIEW_H +#ifndef ROOTSTON_VIEW_H +#define ROOTSTON_VIEW_H #include <stdbool.h> #include <wlr/config.h> diff --git a/include/rootston/xcursor.h b/include/rootston/xcursor.h index a7d2b960..f78489a4 100644 --- a/include/rootston/xcursor.h +++ b/include/rootston/xcursor.h @@ -1,5 +1,5 @@ -#ifndef _ROOTSTON_XCURSOR_H -#define _ROOTSTON_XCURSOR_H +#ifndef ROOTSTON_XCURSOR_H +#define ROOTSTON_XCURSOR_H #include <stdint.h> diff --git a/include/util/os-compatibility.h b/include/util/os-compatibility.h index b2ec2db9..2038025e 100644 --- a/include/util/os-compatibility.h +++ b/include/util/os-compatibility.h @@ -1,12 +1,9 @@ -#ifndef _WLR_UTIL_OS_COMPATIBILITY_H -#define _WLR_UTIL_OS_COMPATIBILITY_H +#ifndef UTIL_OS_COMPATIBILITY_H +#define UTIL_OS_COMPATIBILITY_H int os_fd_set_cloexec(int fd); - int set_cloexec_or_close(int fd); - int create_tmpfile_cloexec(char *tmpname); - int os_create_anonymous_file(off_t size); #endif diff --git a/include/util/signal.h b/include/util/signal.h new file mode 100644 index 00000000..cc6cb525 --- /dev/null +++ b/include/util/signal.h @@ -0,0 +1,8 @@ +#ifndef UTIL_SIGNAL_H +#define UTIL_SIGNAL_H + +#include <wayland-server.h> + +void wlr_signal_emit_safe(struct wl_signal *signal, void *data); + +#endif diff --git a/include/wlr/backend.h b/include/wlr/backend.h index d4b1f773..00dc9fdc 100644 --- a/include/wlr/backend.h +++ b/include/wlr/backend.h @@ -12,10 +12,8 @@ struct wlr_backend { struct { struct wl_signal destroy; - struct wl_signal input_add; - struct wl_signal input_remove; - struct wl_signal output_add; - struct wl_signal output_remove; + struct wl_signal new_input; + struct wl_signal new_output; } events; }; diff --git a/include/wlr/backend/drm.h b/include/wlr/backend/drm.h index 133e4f69..90460647 100644 --- a/include/wlr/backend/drm.h +++ b/include/wlr/backend/drm.h @@ -2,8 +2,8 @@ #define WLR_BACKEND_DRM_H #include <wayland-server.h> -#include <wlr/backend/session.h> #include <wlr/backend.h> +#include <wlr/backend/session.h> #include <wlr/types/wlr_output.h> struct wlr_backend *wlr_drm_backend_create(struct wl_display *display, diff --git a/include/wlr/backend/libinput.h b/include/wlr/backend/libinput.h index af873628..c7cfe894 100644 --- a/include/wlr/backend/libinput.h +++ b/include/wlr/backend/libinput.h @@ -3,8 +3,8 @@ #include <libinput.h> #include <wayland-server.h> -#include <wlr/backend/session.h> #include <wlr/backend.h> +#include <wlr/backend/session.h> #include <wlr/types/wlr_input_device.h> struct wlr_backend *wlr_libinput_backend_create(struct wl_display *display, diff --git a/include/wlr/backend/multi.h b/include/wlr/backend/multi.h index d9914efc..2dee7403 100644 --- a/include/wlr/backend/multi.h +++ b/include/wlr/backend/multi.h @@ -5,17 +5,12 @@ #include <wlr/backend/session.h> struct wlr_backend *wlr_multi_backend_create(struct wl_display *display); - void wlr_multi_backend_add(struct wlr_backend *multi, struct wlr_backend *backend); - void wlr_multi_backend_remove(struct wlr_backend *multi, struct wlr_backend *backend); - bool wlr_backend_is_multi(struct wlr_backend *backend); - struct wlr_session *wlr_multi_get_session(struct wlr_backend *base); - bool wlr_multi_is_empty(struct wlr_backend *backend); #endif diff --git a/include/wlr/backend/session.h b/include/wlr/backend/session.h index 3242a13f..7ff9691f 100644 --- a/include/wlr/backend/session.h +++ b/include/wlr/backend/session.h @@ -1,10 +1,10 @@ #ifndef WLR_BACKEND_SESSION_H #define WLR_BACKEND_SESSION_H -#include <stdbool.h> -#include <wayland-server.h> #include <libudev.h> +#include <stdbool.h> #include <sys/types.h> +#include <wayland-server.h> struct session_impl; diff --git a/include/wlr/backend/wayland.h b/include/wlr/backend/wayland.h index f89a6383..e28ffff5 100644 --- a/include/wlr/backend/wayland.h +++ b/include/wlr/backend/wayland.h @@ -1,12 +1,12 @@ #ifndef WLR_BACKEND_WAYLAND_H #define WLR_BACKEND_WAYLAND_H +#include <stdbool.h> #include <wayland-client.h> #include <wayland-server.h> #include <wlr/backend.h> #include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_output.h> -#include <stdbool.h> /** * Creates a new wlr_wl_backend. This backend will be created with no outputs; diff --git a/include/wlr/interfaces/wlr_keyboard.h b/include/wlr/interfaces/wlr_keyboard.h index 570f5721..6960ea87 100644 --- a/include/wlr/interfaces/wlr_keyboard.h +++ b/include/wlr/interfaces/wlr_keyboard.h @@ -1,8 +1,8 @@ #ifndef WLR_INTERFACES_WLR_KEYBOARD_H #define WLR_INTERFACES_WLR_KEYBOARD_H -#include <wlr/types/wlr_keyboard.h> #include <stdint.h> +#include <wlr/types/wlr_keyboard.h> struct wlr_keyboard_impl { void (*destroy)(struct wlr_keyboard *keyboard); diff --git a/include/wlr/interfaces/wlr_output.h b/include/wlr/interfaces/wlr_output.h index a01f8901..5edd1ae1 100644 --- a/include/wlr/interfaces/wlr_output.h +++ b/include/wlr/interfaces/wlr_output.h @@ -2,9 +2,9 @@ #define WLR_INTERFACES_WLR_OUTPUT_H #include <stdbool.h> +#include <wlr/backend.h> #include <wlr/types/wlr_box.h> #include <wlr/types/wlr_output.h> -#include <wlr/backend.h> struct wlr_output_impl { void (*enable)(struct wlr_output *output, bool enable); diff --git a/include/wlr/render.h b/include/wlr/render.h index ccc66d36..3743482b 100644 --- a/include/wlr/render.h +++ b/include/wlr/render.h @@ -1,9 +1,9 @@ #ifndef WLR_RENDER_H #define WLR_RENDER_H -#include <stdint.h> #include <EGL/egl.h> #include <EGL/eglext.h> +#include <stdint.h> #include <wayland-server-protocol.h> #include <wlr/types/wlr_box.h> #include <wlr/types/wlr_output.h> diff --git a/include/wlr/render/egl.h b/include/wlr/render/egl.h index 1facc6b8..97a28016 100644 --- a/include/wlr/render/egl.h +++ b/include/wlr/render/egl.h @@ -1,10 +1,10 @@ -#ifndef WLR_EGL_H -#define WLR_EGL_H +#ifndef WLR_RENDER_EGL_H +#define WLR_RENDER_EGL_H -#include <stdbool.h> #include <EGL/egl.h> #include <EGL/eglext.h> #include <pixman.h> +#include <stdbool.h> #include <wayland-server.h> struct wlr_egl { diff --git a/include/wlr/render/gles2.h b/include/wlr/render/gles2.h index 25e760d5..a924a065 100644 --- a/include/wlr/render/gles2.h +++ b/include/wlr/render/gles2.h @@ -1,8 +1,8 @@ #ifndef WLR_RENDER_GLES2_H #define WLR_RENDER_GLES2_H -#include <wlr/render.h> #include <wlr/backend.h> +#include <wlr/render.h> struct wlr_egl; struct wlr_renderer *wlr_gles2_renderer_create(struct wlr_backend *backend); diff --git a/include/wlr/render/interface.h b/include/wlr/render/interface.h index b8e99898..b989e399 100644 --- a/include/wlr/render/interface.h +++ b/include/wlr/render/interface.h @@ -1,10 +1,10 @@ #ifndef WLR_RENDER_INTERFACE_H #define WLR_RENDER_INTERFACE_H -#include <wayland-server-protocol.h> #include <EGL/egl.h> #include <EGL/eglext.h> #include <stdbool.h> +#include <wayland-server-protocol.h> #include <wlr/render.h> #include <wlr/types/wlr_box.h> #include <wlr/types/wlr_output.h> diff --git a/include/wlr/types/wlr_cursor.h b/include/wlr/types/wlr_cursor.h index e072ca05..da010972 100644 --- a/include/wlr/types/wlr_cursor.h +++ b/include/wlr/types/wlr_cursor.h @@ -2,10 +2,10 @@ #define WLR_TYPES_WLR_CURSOR_H #include <wayland-server.h> -#include <wlr/types/wlr_output.h> -#include <wlr/types/wlr_output_layout.h> -#include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_box.h> +#include <wlr/types/wlr_input_device.h> +#include <wlr/types/wlr_output_layout.h> +#include <wlr/types/wlr_output.h> struct wlr_cursor_state; diff --git a/include/wlr/types/wlr_keyboard.h b/include/wlr/types/wlr_keyboard.h index c67cc4c2..ed0427e8 100644 --- a/include/wlr/types/wlr_keyboard.h +++ b/include/wlr/types/wlr_keyboard.h @@ -1,9 +1,9 @@ #ifndef WLR_TYPES_WLR_KEYBOARD_H #define WLR_TYPES_WLR_KEYBOARD_H -#include <wayland-server.h> -#include <stdint.h> #include <stdbool.h> +#include <stdint.h> +#include <wayland-server.h> #include <wayland-server.h> #include <xkbcommon/xkbcommon.h> diff --git a/include/wlr/types/wlr_list.h b/include/wlr/types/wlr_list.h index 78a30995..23bf53b7 100644 --- a/include/wlr/types/wlr_list.h +++ b/include/wlr/types/wlr_list.h @@ -1,8 +1,8 @@ -#ifndef WLR_UTIL_LIST_H -#define WLR_UTIL_LIST_H +#ifndef WLR_TYPES_WLR_LIST_H +#define WLR_TYPES_WLR_LIST_H -#include <stddef.h> #include <stdbool.h> +#include <stddef.h> struct wlr_list { size_t capacity; diff --git a/include/wlr/types/wlr_output.h b/include/wlr/types/wlr_output.h index 8eed06fe..5c2ffee0 100644 --- a/include/wlr/types/wlr_output.h +++ b/include/wlr/types/wlr_output.h @@ -1,11 +1,11 @@ #ifndef WLR_TYPES_WLR_OUTPUT_H #define WLR_TYPES_WLR_OUTPUT_H +#include <pixman.h> #include <stdbool.h> #include <time.h> -#include <pixman.h> -#include <wayland-util.h> #include <wayland-server.h> +#include <wayland-util.h> struct wlr_output_mode { uint32_t flags; // enum wl_output_mode diff --git a/include/wlr/types/wlr_output_damage.h b/include/wlr/types/wlr_output_damage.h index 52cbce78..6682f942 100644 --- a/include/wlr/types/wlr_output_damage.h +++ b/include/wlr/types/wlr_output_damage.h @@ -1,8 +1,8 @@ #ifndef WLR_TYPES_WLR_OUTPUT_DAMAGE_H #define WLR_TYPES_WLR_OUTPUT_DAMAGE_H -#include <time.h> #include <pixman.h> +#include <time.h> #include <wlr/types/wlr_output.h> /** diff --git a/include/wlr/types/wlr_output_layout.h b/include/wlr/types/wlr_output_layout.h index 9187b377..7dd2b16a 100644 --- a/include/wlr/types/wlr_output_layout.h +++ b/include/wlr/types/wlr_output_layout.h @@ -1,10 +1,10 @@ #ifndef WLR_TYPES_WLR_OUTPUT_LAYOUT_H #define WLR_TYPES_WLR_OUTPUT_LAYOUT_H +#include <stdbool.h> +#include <wayland-util.h> #include <wlr/types/wlr_box.h> #include <wlr/types/wlr_output.h> -#include <wayland-util.h> -#include <stdbool.h> struct wlr_output_layout_state; diff --git a/include/wlr/types/wlr_pointer.h b/include/wlr/types/wlr_pointer.h index 3a6d2175..e7ac9b46 100644 --- a/include/wlr/types/wlr_pointer.h +++ b/include/wlr/types/wlr_pointer.h @@ -1,9 +1,9 @@ #ifndef WLR_TYPES_WLR_POINTER_H #define WLR_TYPES_WLR_POINTER_H -#include <wlr/types/wlr_input_device.h> -#include <wayland-server.h> #include <stdint.h> +#include <wayland-server.h> +#include <wlr/types/wlr_input_device.h> struct wlr_pointer_impl; diff --git a/include/wlr/types/wlr_primary_selection.h b/include/wlr/types/wlr_primary_selection.h index da3c096a..78f23ad6 100644 --- a/include/wlr/types/wlr_primary_selection.h +++ b/include/wlr/types/wlr_primary_selection.h @@ -1,8 +1,8 @@ #ifndef WLR_TYPES_WLR_PRIMARY_SELECTION_H #define WLR_TYPES_WLR_PRIMARY_SELECTION_H -#include <wlr/types/wlr_seat.h> #include <wayland-server.h> +#include <wlr/types/wlr_seat.h> struct wlr_primary_selection_device_manager { struct wl_global *global; diff --git a/include/wlr/types/wlr_screenshooter.h b/include/wlr/types/wlr_screenshooter.h index cfe7742d..680d86f0 100644 --- a/include/wlr/types/wlr_screenshooter.h +++ b/include/wlr/types/wlr_screenshooter.h @@ -1,5 +1,6 @@ -#ifndef _WLR_SCREENSHOOTER_H -#define _WLR_SCREENSHOOTER_H +#ifndef WLR_TYPES_WLR_SCREENSHOOTER_H +#define WLR_TYPES_WLR_SCREENSHOOTER_H + #include <wayland-server.h> struct wlr_screenshooter { diff --git a/include/wlr/types/wlr_seat.h b/include/wlr/types/wlr_seat.h index ffdabd98..b03cab6e 100644 --- a/include/wlr/types/wlr_seat.h +++ b/include/wlr/types/wlr_seat.h @@ -1,10 +1,11 @@ #ifndef WLR_TYPES_WLR_SEAT_H #define WLR_TYPES_WLR_SEAT_H + #include <time.h> -#include <wlr/types/wlr_surface.h> +#include <wayland-server.h> #include <wlr/types/wlr_input_device.h> #include <wlr/types/wlr_keyboard.h> -#include <wayland-server.h> +#include <wlr/types/wlr_surface.h> /** * Contains state for a single client's bound wl_seat resource and can be used diff --git a/include/wlr/types/wlr_surface.h b/include/wlr/types/wlr_surface.h index 50316abc..998b5ae5 100644 --- a/include/wlr/types/wlr_surface.h +++ b/include/wlr/types/wlr_surface.h @@ -1,9 +1,10 @@ #ifndef WLR_TYPES_WLR_SURFACE_H #define WLR_TYPES_WLR_SURFACE_H -#include <stdint.h> + +#include <pixman.h> #include <stdbool.h> +#include <stdint.h> #include <time.h> -#include <pixman.h> #include <wayland-server.h> #include <wlr/types/wlr_output.h> diff --git a/include/wlr/types/wlr_tablet_pad.h b/include/wlr/types/wlr_tablet_pad.h index 51a65dd1..e70db516 100644 --- a/include/wlr/types/wlr_tablet_pad.h +++ b/include/wlr/types/wlr_tablet_pad.h @@ -1,9 +1,9 @@ #ifndef WLR_TYPES_WLR_TABLET_PAD_H #define WLR_TYPES_WLR_TABLET_PAD_H -#include <wlr/types/wlr_input_device.h> -#include <wayland-server.h> #include <stdint.h> +#include <wayland-server.h> +#include <wlr/types/wlr_input_device.h> /* * NOTE: the wlr tablet pad implementation does not currently support tablets diff --git a/include/wlr/types/wlr_tablet_tool.h b/include/wlr/types/wlr_tablet_tool.h index c6984d4d..59e49ef8 100644 --- a/include/wlr/types/wlr_tablet_tool.h +++ b/include/wlr/types/wlr_tablet_tool.h @@ -1,9 +1,9 @@ #ifndef WLR_TYPES_TABLET_TOOL_H #define WLR_TYPES_TABLET_TOOL_H -#include <wlr/types/wlr_input_device.h> -#include <wayland-server.h> #include <stdint.h> +#include <wayland-server.h> +#include <wlr/types/wlr_input_device.h> struct wlr_tablet_tool_impl; diff --git a/include/wlr/types/wlr_touch.h b/include/wlr/types/wlr_touch.h index 2925fd01..8ea293eb 100644 --- a/include/wlr/types/wlr_touch.h +++ b/include/wlr/types/wlr_touch.h @@ -1,8 +1,8 @@ #ifndef WLR_TYPES_WLR_TOUCH_H #define WLR_TYPES_WLR_TOUCH_H -#include <wayland-server.h> #include <stdint.h> +#include <wayland-server.h> struct wlr_touch_impl; diff --git a/include/wlr/types/wlr_xdg_shell_v6.h b/include/wlr/types/wlr_xdg_shell_v6.h index c7b1a24b..7dc746ce 100644 --- a/include/wlr/types/wlr_xdg_shell_v6.h +++ b/include/wlr/types/wlr_xdg_shell_v6.h @@ -1,9 +1,9 @@ #ifndef WLR_TYPES_WLR_XDG_SHELL_V6_H #define WLR_TYPES_WLR_XDG_SHELL_V6_H +#include <wayland-server.h> #include <wlr/types/wlr_box.h> #include <wlr/types/wlr_seat.h> -#include <wayland-server.h> struct wlr_xdg_shell_v6 { struct wl_global *wl_global; diff --git a/include/wlr/xwayland.h b/include/wlr/xwayland.h index c0135943..ad7ceb83 100644 --- a/include/wlr/xwayland.h +++ b/include/wlr/xwayland.h @@ -1,8 +1,8 @@ #ifndef WLR_XWAYLAND_H #define WLR_XWAYLAND_H -#include <time.h> #include <stdbool.h> +#include <time.h> #include <wlr/config.h> #include <wlr/types/wlr_compositor.h> #include <wlr/types/wlr_seat.h> diff --git a/include/wlr/xwm.h b/include/wlr/xwm.h index 35c43b18..242ff9cc 100644 --- a/include/wlr/xwm.h +++ b/include/wlr/xwm.h @@ -1,9 +1,9 @@ -#ifndef XWAYLAND_INTERNALS_H -#define XWAYLAND_INTERNALS_H +#ifndef WLR_XWM_H +#define WLR_XWM_H -#include <xcb/render.h> #include <wayland-server-core.h> #include <wlr/xwayland.h> +#include <xcb/render.h> enum atom_name { WL_SURFACE_ID, |