From c2e147401048aa53aebd52f1851b1da8c91043a3 Mon Sep 17 00:00:00 2001 From: emersion Date: Mon, 12 Feb 2018 21:29:23 +0100 Subject: Reformat all #include directives --- backend/backend.c | 16 ++++++++-------- backend/drm/atomic.c | 4 ++-- backend/drm/backend.c | 16 ++++++++-------- backend/drm/drm.c | 24 ++++++++++++------------ backend/drm/legacy.c | 2 +- backend/drm/properties.c | 2 +- backend/drm/renderer.c | 16 +++++++--------- backend/drm/util.c | 8 ++++---- backend/headless/backend.c | 6 +++--- backend/headless/input_device.c | 8 ++++---- backend/headless/output.c | 4 ++-- backend/libinput/backend.c | 6 +++--- backend/libinput/events.c | 6 +++--- backend/libinput/keyboard.c | 6 +++--- backend/libinput/pointer.c | 6 +++--- backend/libinput/tablet_pad.c | 6 +++--- backend/libinput/tablet_tool.c | 6 +++--- backend/libinput/touch.c | 6 +++--- backend/meson.build | 6 +++--- backend/multi/backend.c | 4 ++-- backend/session/direct-freebsd.c | 20 ++++++++++---------- backend/session/direct-ipc.c | 10 +++++----- backend/session/direct.c | 18 +++++++++--------- backend/session/logind.c | 12 ++++++------ backend/session/session.c | 8 ++++---- backend/wayland/backend.c | 14 +++++++------- backend/wayland/output.c | 10 +++++----- backend/wayland/registry.c | 1 - backend/wayland/wl_seat.c | 8 ++++---- backend/x11/backend.c | 26 +++++++++++++------------- 30 files changed, 141 insertions(+), 144 deletions(-) (limited to 'backend') diff --git a/backend/backend.c b/backend/backend.c index aec5781e..c67be617 100644 --- a/backend/backend.c +++ b/backend/backend.c @@ -1,17 +1,17 @@ -#include -#include -#include -#include -#include #include +#include #include -#include -#include +#include +#include +#include +#include #include +#include #include +#include +#include #include #include -#include #include void wlr_backend_init(struct wlr_backend *backend, diff --git a/backend/drm/atomic.c b/backend/drm/atomic.c index 526b2731..29b5ccb1 100644 --- a/backend/drm/atomic.c +++ b/backend/drm/atomic.c @@ -1,8 +1,8 @@ -#include #include +#include +#include #include #include -#include #include "backend/drm/drm.h" #include "backend/drm/iface.h" #include "backend/drm/util.h" diff --git a/backend/drm/backend.c b/backend/drm/backend.c index 682e8c85..47dff227 100644 --- a/backend/drm/backend.c +++ b/backend/drm/backend.c @@ -1,19 +1,19 @@ -#include -#include +#include +#include #include +#include #include -#include -#include +#include #include -#include -#include #include +#include #include +#include #include #include -#include "util/signal.h" -#include +#include #include "backend/drm/drm.h" +#include "util/signal.h" static bool wlr_drm_backend_start(struct wlr_backend *backend) { struct wlr_drm_backend *drm = (struct wlr_drm_backend *)backend; diff --git a/backend/drm/drm.c b/backend/drm/drm.c index 5189ec90..e60b7e1c 100644 --- a/backend/drm/drm.c +++ b/backend/drm/drm.c @@ -1,30 +1,30 @@ #include -#include -#include -#include -#include -#include -#include -#include -#include #include #include #include +#include #include #include #include +#include +#include +#include +#include +#include #include #include #include #include -#include -#include "util/signal.h" -#include -#include #include +#include +#include +#include +#include +#include #include "backend/drm/drm.h" #include "backend/drm/iface.h" #include "backend/drm/util.h" +#include "util/signal.h" bool wlr_drm_check_features(struct wlr_drm_backend *drm) { if (drmSetClientCap(drm->fd, DRM_CLIENT_CAP_UNIVERSAL_PLANES, 1)) { diff --git a/backend/drm/legacy.c b/backend/drm/legacy.c index eec8c642..88a01b89 100644 --- a/backend/drm/legacy.c +++ b/backend/drm/legacy.c @@ -1,7 +1,7 @@ #include +#include #include #include -#include #include "backend/drm/drm.h" #include "backend/drm/iface.h" #include "backend/drm/util.h" diff --git a/backend/drm/properties.c b/backend/drm/properties.c index 153e845e..3d35beb5 100644 --- a/backend/drm/properties.c +++ b/backend/drm/properties.c @@ -2,9 +2,9 @@ #include #include #include +#include #include #include -#include #include "backend/drm/properties.h" /* diff --git a/backend/drm/renderer.c b/backend/drm/renderer.c index 80d3bd9a..f3e570f7 100644 --- a/backend/drm/renderer.c +++ b/backend/drm/renderer.c @@ -1,18 +1,16 @@ +#include +#include +#include +#include #include #include #include - -#include -#include -#include -#include #include - -#include +#include #include -#include #include -#include +#include +#include #include "backend/drm/drm.h" #include "glapi.h" diff --git a/backend/drm/util.c b/backend/drm/util.c index 37d99aa8..41ba47d1 100644 --- a/backend/drm/util.c +++ b/backend/drm/util.c @@ -1,10 +1,10 @@ -#include -#include -#include #include +#include #include -#include "backend/drm/util.h" +#include +#include #include +#include "backend/drm/util.h" int32_t calculate_refresh_rate(drmModeModeInfo *mode) { int32_t refresh = (mode->clock * 1000000LL / mode->htotal + diff --git a/backend/headless/backend.c b/backend/headless/backend.c index a79e4af8..663bc13b 100644 --- a/backend/headless/backend.c +++ b/backend/headless/backend.c @@ -1,10 +1,10 @@ +#include "util/signal.h" #include +#include +#include #include #include #include -#include "util/signal.h" -#include -#include #include "backend/headless.h" #include "glapi.h" diff --git a/backend/headless/input_device.c b/backend/headless/input_device.c index 5d7ca34b..ea335aff 100644 --- a/backend/headless/input_device.c +++ b/backend/headless/input_device.c @@ -1,13 +1,13 @@ #include #include -#include #include -#include -#include +#include #include +#include +#include #include -#include "util/signal.h" #include "backend/headless.h" +#include "util/signal.h" static void input_device_destroy(struct wlr_input_device *wlr_dev) { struct wlr_headless_input_device *device = diff --git a/backend/headless/output.c b/backend/headless/output.c index 63f0b6b4..ba4a094e 100644 --- a/backend/headless/output.c +++ b/backend/headless/output.c @@ -1,11 +1,11 @@ -#include #include #include #include +#include #include #include -#include "util/signal.h" #include "backend/headless.h" +#include "util/signal.h" static EGLSurface egl_create_surface(struct wlr_egl *egl, unsigned int width, unsigned int height) { diff --git a/backend/libinput/backend.c b/backend/libinput/backend.c index 1ec73009..71fe0d93 100644 --- a/backend/libinput/backend.c +++ b/backend/libinput/backend.c @@ -1,11 +1,11 @@ -#include #include #include -#include +#include #include +#include #include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" static int wlr_libinput_open_restricted(const char *path, int flags, void *_backend) { diff --git a/backend/libinput/events.c b/backend/libinput/events.c index 248b8213..603eed07 100644 --- a/backend/libinput/events.c +++ b/backend/libinput/events.c @@ -1,12 +1,12 @@ -#include #include #include +#include +#include #include #include #include -#include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" struct wlr_input_device *get_appropriate_device( enum wlr_input_device_type desired_type, diff --git a/backend/libinput/keyboard.c b/backend/libinput/keyboard.c index 065d8ead..b44bc892 100644 --- a/backend/libinput/keyboard.c +++ b/backend/libinput/keyboard.c @@ -1,9 +1,9 @@ -#include #include #include +#include #include -#include #include +#include #include #include "backend/libinput.h" @@ -57,7 +57,7 @@ void handle_keyboard_key(struct libinput_event *event, wlr_event.time_msec = usec_to_msec(libinput_event_keyboard_get_time_usec(kbevent)); wlr_event.keycode = libinput_event_keyboard_get_key(kbevent); - enum libinput_key_state state = + enum libinput_key_state state = libinput_event_keyboard_get_key_state(kbevent); switch (state) { case LIBINPUT_KEY_STATE_RELEASED: diff --git a/backend/libinput/pointer.c b/backend/libinput/pointer.c index 560e95b5..8a31d312 100644 --- a/backend/libinput/pointer.c +++ b/backend/libinput/pointer.c @@ -1,12 +1,12 @@ -#include #include #include +#include #include -#include #include +#include #include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" struct wlr_pointer *wlr_libinput_pointer_create( struct libinput_device *libinput_dev) { diff --git a/backend/libinput/tablet_pad.c b/backend/libinput/tablet_pad.c index e8ffc6dd..70e4c677 100644 --- a/backend/libinput/tablet_pad.c +++ b/backend/libinput/tablet_pad.c @@ -1,12 +1,12 @@ -#include #include #include +#include #include -#include #include +#include #include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" struct wlr_tablet_pad *wlr_libinput_tablet_pad_create( struct libinput_device *libinput_dev) { diff --git a/backend/libinput/tablet_tool.c b/backend/libinput/tablet_tool.c index 0f2ea70a..4e60367f 100644 --- a/backend/libinput/tablet_tool.c +++ b/backend/libinput/tablet_tool.c @@ -1,12 +1,12 @@ -#include #include #include +#include #include -#include #include +#include #include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" struct wlr_tablet_tool *wlr_libinput_tablet_tool_create( struct libinput_device *libinput_dev) { diff --git a/backend/libinput/touch.c b/backend/libinput/touch.c index fb2b8e3f..2b87f9cd 100644 --- a/backend/libinput/touch.c +++ b/backend/libinput/touch.c @@ -1,12 +1,12 @@ -#include #include #include +#include #include -#include #include +#include #include -#include "util/signal.h" #include "backend/libinput.h" +#include "util/signal.h" struct wlr_touch *wlr_libinput_touch_create( struct libinput_device *libinput_dev) { diff --git a/backend/meson.build b/backend/meson.build index beb3841c..bac43063 100644 --- a/backend/meson.build +++ b/backend/meson.build @@ -1,7 +1,5 @@ backend_files = files( 'backend.c', - 'session/direct-ipc.c', - 'session/session.c', 'drm/atomic.c', 'drm/backend.c', 'drm/drm.c', @@ -10,8 +8,8 @@ backend_files = files( 'drm/renderer.c', 'drm/util.c', 'headless/backend.c', - 'headless/output.c', 'headless/input_device.c', + 'headless/output.c', 'libinput/backend.c', 'libinput/events.c', 'libinput/keyboard.c', @@ -20,6 +18,8 @@ backend_files = files( 'libinput/tablet_tool.c', 'libinput/touch.c', 'multi/backend.c', + 'session/direct-ipc.c', + 'session/session.c', 'wayland/backend.c', 'wayland/output.c', 'wayland/registry.c', diff --git a/backend/multi/backend.c b/backend/multi/backend.c index 1005e6b7..5cb3fbc5 100644 --- a/backend/multi/backend.c +++ b/backend/multi/backend.c @@ -4,9 +4,9 @@ #include #include #include -#include "util/signal.h" -#include "backend/multi.h" #include "backend/drm/drm.h" +#include "backend/multi.h" +#include "util/signal.h" struct subbackend_state { struct wlr_backend *backend; diff --git a/backend/session/direct-freebsd.c b/backend/session/direct-freebsd.c index ceaae2be..6e23bf1b 100644 --- a/backend/session/direct-freebsd.c +++ b/backend/session/direct-freebsd.c @@ -1,22 +1,22 @@ +#include #include -#include -#include -#include -#include +#include #include +#include +#include +#include +#include #include +#include #include -#include -#include #include -#include -#include -#include +#include +#include #include #include #include -#include "util/signal.h" #include "backend/session/direct-ipc.h" +#include "util/signal.h" const struct session_impl session_direct; diff --git a/backend/session/direct-ipc.c b/backend/session/direct-ipc.c index e7a169fa..6c69b70a 100644 --- a/backend/session/direct-ipc.c +++ b/backend/session/direct-ipc.c @@ -4,22 +4,22 @@ #define INPUT_MAJOR 0 #endif #include +#include #include #include #include -#include -#include #include #include #include #include +#include +#include +#include +#include #ifdef __linux__ #include #include #endif -#include -#include -#include #include "backend/session/direct-ipc.h" enum { DRM_MAJOR = 226 }; diff --git a/backend/session/direct.c b/backend/session/direct.c index 1f60ed23..13a26d99 100644 --- a/backend/session/direct.c +++ b/backend/session/direct.c @@ -1,22 +1,22 @@ #define _POSIX_C_SOURCE 200809L #include -#include -#include -#include -#include +#include +#include +#include +#include #include +#include +#include +#include #include #include #include -#include -#include -#include -#include +#include #include #include #include -#include "util/signal.h" #include "backend/session/direct-ipc.h" +#include "util/signal.h" enum { DRM_MAJOR = 226 }; diff --git a/backend/session/logind.c b/backend/session/logind.c index b2206e15..f0ac1e93 100644 --- a/backend/session/logind.c +++ b/backend/session/logind.c @@ -1,17 +1,17 @@ #define _POSIX_C_SOURCE 200809L #include -#include +#include +#include #include +#include #include #include -#include -#include -#include #include -#include +#include +#include #include -#include #include +#include #include #include "util/signal.h" diff --git a/backend/session/session.c b/backend/session/session.c index ac55a191..2d5d9776 100644 --- a/backend/session/session.c +++ b/backend/session/session.c @@ -1,18 +1,18 @@ #define _POSIX_C_SOURCE 200809L #include +#include #include #include #include #include #include -#include #include -#include -#include -#include #include #include +#include #include +#include +#include #include "util/signal.h" extern const struct session_impl session_logind; diff --git a/backend/wayland/backend.c b/backend/wayland/backend.c index 60c8ede9..abb25df5 100644 --- a/backend/wayland/backend.c +++ b/backend/wayland/backend.c @@ -1,18 +1,18 @@ -#include -#include #include -#include #include #include +#include +#include +#include #include -#include -#include #include -#include #include +#include +#include +#include #include -#include "util/signal.h" #include "backend/wayland.h" +#include "util/signal.h" #include "xdg-shell-unstable-v6-client-protocol.h" static int dispatch_events(int fd, uint32_t mask, void *data) { diff --git a/backend/wayland/output.c b/backend/wayland/output.c index fed4c63a..fc40dea0 100644 --- a/backend/wayland/output.c +++ b/backend/wayland/output.c @@ -1,17 +1,17 @@ -#include #include +#include #include +#include #include #include -#include -#include #include +#include +#include #include -#include #include #include -#include "util/signal.h" #include "backend/wayland.h" +#include "util/signal.h" #include "xdg-shell-unstable-v6-client-protocol.h" int os_create_anonymous_file(off_t size); diff --git a/backend/wayland/registry.c b/backend/wayland/registry.c index 0dec0ec5..4aa39f09 100644 --- a/backend/wayland/registry.c +++ b/backend/wayland/registry.c @@ -6,7 +6,6 @@ #include "backend/wayland.h" #include "xdg-shell-unstable-v6-client-protocol.h" - static void xdg_shell_handle_ping(void *data, struct zxdg_shell_v6 *shell, uint32_t serial) { zxdg_shell_v6_pong(shell, serial); diff --git a/backend/wayland/wl_seat.c b/backend/wayland/wl_seat.c index f6328106..b1f7cff6 100644 --- a/backend/wayland/wl_seat.c +++ b/backend/wayland/wl_seat.c @@ -1,17 +1,17 @@ #define _XOPEN_SOURCE 500 #include -#include #include +#include #include #include -#include #include -#include #include +#include +#include #include #include -#include "util/signal.h" #include "backend/wayland.h" +#include "util/signal.h" static void pointer_handle_enter(void *data, struct wl_pointer *wl_pointer, uint32_t serial, struct wl_surface *surface, wl_fixed_t surface_x, diff --git a/backend/x11/backend.c b/backend/x11/backend.c index 2715b366..28a4fcac 100644 --- a/backend/x11/backend.c +++ b/backend/x11/backend.c @@ -1,29 +1,29 @@ #define _POSIX_C_SOURCE 200112L +#include #include #include #include #include -#include #include -#include -#include -#include -#ifdef __linux__ -#include -#elif __FreeBSD__ -#include -#endif #include #include -#include -#include -#include #include #include +#include #include +#include +#include #include -#include "util/signal.h" +#include +#include +#include +#ifdef __linux__ +#include +#elif __FreeBSD__ +#include +#endif #include "backend/x11.h" +#include "util/signal.h" static struct wlr_backend_impl backend_impl; static struct wlr_output_impl output_impl; -- cgit v1.2.3