diff --git a/cagebreak.c b/cagebreak.c index 6cc2711..4d1bd3b 100644 --- a/cagebreak.c +++ b/cagebreak.c @@ -23,6 +23,7 @@ #include #include #include +#include #include #include #include @@ -31,7 +32,6 @@ #include #include #include -#include #if CG_HAS_XWAYLAND #include #endif @@ -357,7 +357,8 @@ main(int argc, char *argv[]) { goto end; } - data_control_manager=wlr_data_control_manager_v1_create(server.wl_display); + data_control_manager = + wlr_data_control_manager_v1_create(server.wl_display); if(!data_control_manager) { wlr_log(WLR_ERROR, "Unable to create the data control manager"); ret = 1; diff --git a/output.c b/output.c index 2b3d1bd..a330354 100644 --- a/output.c +++ b/output.c @@ -32,13 +32,13 @@ #include #include "keybinding.h" -#include "view.h" #include "message.h" #include "output.h" #include "render.h" #include "seat.h" #include "server.h" #include "util.h" +#include "view.h" #include "workspace.h" #if CG_HAS_XWAYLAND #include "xwayland.h" @@ -595,7 +595,7 @@ handle_new_output(struct wl_listener *listener, void *data) { wl_list_init(&output->messages); if(!wlr_xcursor_manager_load(server->seat->xcursor_manager, - wlr_output->scale)) { + wlr_output->scale)) { wlr_log(WLR_ERROR, "Cannot load XCursor theme for output '%s' with scale %f", wlr_output->name, wlr_output->scale); diff --git a/view.c b/view.c index c5f5265..a7817cf 100644 --- a/view.c +++ b/view.c @@ -318,7 +318,8 @@ view_unmap(struct cg_view *view) { } void -view_map(struct cg_view *view, struct wlr_surface *surface, struct cg_workspace *ws) { +view_map(struct cg_view *view, struct wlr_surface *surface, + struct cg_workspace *ws) { struct cg_output *output = ws->output; view->wlr_surface = surface; @@ -331,21 +332,18 @@ view_map(struct cg_view *view, struct wlr_surface *surface, struct cg_workspace wl_signal_add(&view->wlr_surface->events.new_subsurface, &view->new_subsurface); - view->workspace=ws; + view->workspace = ws; #if CG_HAS_XWAYLAND /* We shouldn't position override-redirect windows. They set their own (x,y) coordinates in handle_wayland_surface_map. */ if(view->type == CG_XWAYLAND_VIEW && !xwayland_view_should_manage(view)) { - wl_list_insert( - &ws->unmanaged_views, - &view->link); + wl_list_insert(&ws->unmanaged_views, &view->link); } else #endif { view_position(view); - wl_list_insert(&ws->views, - &view->link); + wl_list_insert(&ws->views, &view->link); } seat_set_focus(output->server->seat, view); } diff --git a/view.h b/view.h index 3623824..7474198 100644 --- a/view.h +++ b/view.h @@ -99,7 +99,8 @@ view_unmap(struct cg_view *view); void view_maximize(struct cg_view *view, const struct wlr_box *tile_box); void -view_map(struct cg_view *view, struct wlr_surface *surface, struct cg_workspace *ws); +view_map(struct cg_view *view, struct wlr_surface *surface, + struct cg_workspace *ws); void view_destroy(struct cg_view *view); void diff --git a/xdg_shell.c b/xdg_shell.c index 22f911a..9c076f2 100644 --- a/xdg_shell.c +++ b/xdg_shell.c @@ -300,7 +300,10 @@ handle_xdg_shell_surface_map(struct wl_listener *listener, void *_data) { wl_signal_add(&xdg_shell_view->xdg_surface->surface->events.commit, &xdg_shell_view->commit); - view_map(view, xdg_shell_view->xdg_surface->surface,view->workspace->server->curr_output->workspaces[view->workspace->server->curr_output->curr_workspace]); + view_map( + view, xdg_shell_view->xdg_surface->surface, + view->workspace->server->curr_output + ->workspaces[view->workspace->server->curr_output->curr_workspace]); view_damage_whole(view); } diff --git a/xwayland.c b/xwayland.c index bce9a4b..4a19daf 100644 --- a/xwayland.c +++ b/xwayland.c @@ -188,7 +188,10 @@ handle_xwayland_surface_map(struct wl_listener *listener, void *_data) { wl_signal_add(&xwayland_view->xwayland_surface->surface->events.commit, &xwayland_view->commit); - view_map(view, xwayland_view->xwayland_surface->surface,view->workspace->server->curr_output->workspaces[view->workspace->server->curr_output->curr_workspace]); + view_map( + view, xwayland_view->xwayland_surface->surface, + view->workspace->server->curr_output + ->workspaces[view->workspace->server->curr_output->curr_workspace]); view_damage_whole(view); }