From: Christian Heller Date: Fri, 30 May 2025 13:57:33 +0000 (+0200) Subject: Move SIGWINCH handling further up in context chain. X-Git-Url: https://plomlompom.com/repos/%22https:/validator.w3.org/templates?a=commitdiff_plain;h=ad203fbde96ded349bbae3ba168d78985ddb3a29;p=ircplom Move SIGWINCH handling further up in context chain. --- diff --git a/ircplom.py b/ircplom.py index abafd7b..2f01c33 100755 --- a/ircplom.py +++ b/ircplom.py @@ -63,6 +63,7 @@ class Terminal: @contextmanager def context(self, q_to_main: EventQueue) -> Generator: 'Combine multiple contexts into one.' + signal(SIGWINCH, lambda *_: q_to_main.eput('SIGWINCH')) self._blessed = BlessedTerminal() with (self._blessed.raw(), self._blessed.fullscreen(), @@ -70,7 +71,6 @@ class Terminal: KeyboardLoop(q_to_main, self.get_keypresses())): with TuiLoop(self, q_to_main) as tui: self.tui = tui - signal(SIGWINCH, lambda *_: self.tui.put(Event('SIGWINCH'))) yield self def calc_geometry(self) -> None: