Avoid redundant redraws on resize
Use a global flag to record whether the terminal was resized instead of redrawing everything each time a KEY_RESIZE is read. Add some additional checks to help_write_pad() as invalid actions may be passed now due to using signals instead of virtual key presses. Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
This commit is contained in:
@@ -59,6 +59,7 @@ generic_hdlr (int sig)
|
||||
;
|
||||
break;
|
||||
case SIGWINCH:
|
||||
resize = 1;
|
||||
clearok (curscr, TRUE);
|
||||
(void)ungetch (KEY_RESIZE);
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user