From a7cba7d83fc0c881af79792029f36cd46c6cab2c Mon Sep 17 00:00:00 2001 From: emersion Date: Tue, 30 Jan 2018 14:40:22 +0100 Subject: [PATCH] rootston: damage whole output when entering/leaving fullscreen --- include/rootston/output.h | 1 + rootston/desktop.c | 2 ++ rootston/output.c | 2 +- 3 files changed, 4 insertions(+), 1 deletion(-) diff --git a/include/rootston/output.h b/include/rootston/output.h index a9f9bc2b..3a6d3cc7 100644 --- a/include/rootston/output.h +++ b/include/rootston/output.h @@ -39,6 +39,7 @@ void output_remove_notify(struct wl_listener *listener, void *data); struct roots_view; struct roots_drag_icon; +void output_damage_whole(struct roots_output *output); void output_damage_whole_view(struct roots_output *output, struct roots_view *view); void output_damage_from_view(struct roots_output *output, diff --git a/rootston/desktop.c b/rootston/desktop.c index d3654661..91661c05 100644 --- a/rootston/desktop.c +++ b/rootston/desktop.c @@ -243,6 +243,7 @@ void view_set_fullscreen(struct roots_view *view, bool fullscreen, roots_output->fullscreen_view = view; view->fullscreen_output = roots_output; + output_damage_whole(roots_output); } if (was_fullscreen && !fullscreen) { @@ -250,6 +251,7 @@ void view_set_fullscreen(struct roots_view *view, bool fullscreen, view->saved.height); view_rotate(view, view->saved.rotation); + output_damage_whole(view->fullscreen_output); view->fullscreen_output->fullscreen_view = NULL; view->fullscreen_output = NULL; } diff --git a/rootston/output.c b/rootston/output.c index de4922ba..a7fca415 100644 --- a/rootston/output.c +++ b/rootston/output.c @@ -493,7 +493,7 @@ static void output_handle_frame(struct wl_listener *listener, void *data) { render_output(output); } -static void output_damage_whole(struct roots_output *output) { +void output_damage_whole(struct roots_output *output) { int width, height; wlr_output_transformed_resolution(output->wlr_output, &width, &height);