1
0
Fork 0
forked from wry/wry

xdg-toplevel: center fullscreen surfaces with geometry smaller than output

This commit is contained in:
Julian Orth 2025-08-30 15:23:44 +02:00
parent 642eaffcff
commit 197b069c50
6 changed files with 81 additions and 26 deletions

View file

@ -338,9 +338,8 @@ impl Renderer<'_> {
bounds: Option<&Rect>,
) {
let surface = &xdg.surface;
if let Some(geo) = xdg.geometry() {
(x, y) = geo.translate(x, y);
}
let geo = xdg.geometry();
(x, y) = geo.translate(x, y);
self.render_surface(surface, x, y, bounds);
}