Fix geometry of fullscreen views

This commit is contained in:
project-repo 2024-01-08 19:28:59 +01:00
commit db8dee68f5
3 changed files with 5 additions and 4 deletions

View file

@ -678,7 +678,7 @@ main(int argc, char *argv[]) {
struct cg_output *output, *output_tmp;
wl_list_for_each_safe(output, output_tmp, &tmp_list, link) {
wl_list_remove(&output->link);
wl_list_insert(&server.outputs,&output->link);
wl_list_insert(&server.outputs, &output->link);
output_configure(&server, output);
}
server.curr_output =

View file

@ -317,7 +317,7 @@ output_apply_config(struct cg_server *server, struct cg_output *output,
prev_box.y = output->layout_box.y;
prev_box.width = output->layout_box.width;
prev_box.height = output->layout_box.height;
bool prio_changed=false;
bool prio_changed = false;
if(config->role != OUTPUT_ROLE_DEFAULT) {
output->role = config->role;
if((output->role == OUTPUT_ROLE_PERIPHERAL) &&

View file

@ -164,8 +164,9 @@ handle_xdg_shell_surface_request_fullscreen(struct wl_listener *listener,
* they display in fullscreen mode, so we set it here.
*/
struct wlr_box layout_box;
wlr_output_layout_get_box(xdg_shell_view->view.server->output_layout, NULL,
&layout_box);
wlr_output_layout_get_box(
xdg_shell_view->view.server->output_layout,
xdg_shell_view->view.workspace->output->wlr_output, &layout_box);
wlr_xdg_toplevel_set_size(xdg_shell_view->xdg_surface->toplevel,
layout_box.width, layout_box.height);