From cff4b12a4a7a78c0ffc1ff7e91e3b74934ea4479 Mon Sep 17 00:00:00 2001 From: "Pedro M. de Echanove Pasquin" Date: Mon, 25 May 2026 11:42:45 +0200 Subject: [PATCH] =?UTF-8?q?event=5Floop:=20drop=20the=20duplicate=20on=5Fr?= =?UTF-8?q?esize=20that=20clobbered=20physical=20dimensions=20with=20logic?= =?UTF-8?q?al=20ones=20Both=20`LayerShellHandler::configure`=20and=20`Wind?= =?UTF-8?q?owHandler::configure`=20called=20`self.on=5Fconfigure(=20w,=20h?= =?UTF-8?q?=20)`=20=E2=80=94=20which=20already=20forwards=20`app.on=5Fresi?= =?UTF-8?q?ze(=20w=20*=20sf,=20h=20*=20sf=20)`=20in=20physical=20pixels=20?= =?UTF-8?q?=E2=80=94=20and=20then=20immediately=20called=20`self.app.on=5F?= =?UTF-8?q?resize(=20w,=20h=20)`=20again=20with=20the=20surface-local=20lo?= =?UTF-8?q?gical=20size.=20The=20second=20call=20won,=20so=20on=20any=20sc?= =?UTF-8?q?ale=20>=201=20surface=20the=20app=20saw=20logical=20dimensions?= =?UTF-8?q?=20while=20the=20layout=20pass=20kept=20working=20in=20physical?= =?UTF-8?q?=20pixels.=20On=20a=20Librem=205=20at=20scale=202=20that=20mean?= =?UTF-8?q?t=20`screen=5Fwidth`/`screen=5Fheight`=20came=20through=20as=20?= =?UTF-8?q?360=C3=97720=20against=20a=20720=C3=971440=20layout:=20homescre?= =?UTF-8?q?en=20icons=20rendered=20at=20half=20their=20intended=20footprin?= =?UTF-8?q?t=20and=20the=20mobile=20wallpaper,=20sized=20explicitly=20via?= =?UTF-8?q?=20`.size(=20iw=5Fat=5Fh,=20sh=20)`,=20filled=20only=20the=20to?= =?UTF-8?q?p=20half=20of=20the=20screen=20(the=20launcher=20/=20lockscreen?= =?UTF-8?q?=20/=20greeter=20use=20`.cover()`=20so=20they=20were=20unaffect?= =?UTF-8?q?ed).=20Remove=20the=20redundant=20`app.on=5Fresize`=20from=20bo?= =?UTF-8?q?th=20handlers;=20`on=5Fconfigure`=20is=20the=20single=20source?= =?UTF-8?q?=20of=20truth=20for=20the=20physical=20dimensions=20the=20app?= =?UTF-8?q?=20and=20the=20layout=20both=20expect.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/event_loop/handlers.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/event_loop/handlers.rs b/src/event_loop/handlers.rs index 04f9848..f78203c 100644 --- a/src/event_loop/handlers.rs +++ b/src/event_loop/handlers.rs @@ -172,7 +172,6 @@ impl LayerShellHandler for AppData Some( super::SurfaceFocus::Main ) | None => { self.on_configure( w, h ); - self.app.on_resize( w, h ); } Some( super::SurfaceFocus::Overlay( id ) ) => { @@ -226,7 +225,6 @@ impl WindowHandler for AppData let h = configure.new_size.1.map( |v| v.get() ).unwrap_or( hint_h ); window.xdg_surface().set_window_geometry( 0, 0, w as i32, h as i32 ); self.on_configure( w, h ); - self.app.on_resize( w, h ); } }