From 962a7539b405c049a662c566fb8a78a7977f5881 Mon Sep 17 00:00:00 2001 From: nick black Date: Tue, 20 Jul 2021 16:00:24 -0400 Subject: [PATCH] whiteout: restore original scrolling mode for standard plane --- src/demo/whiteout.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/demo/whiteout.c b/src/demo/whiteout.c index 99af3e4ae..aaa9de55b 100644 --- a/src/demo/whiteout.c +++ b/src/demo/whiteout.c @@ -455,6 +455,7 @@ int witherworm_demo(struct notcurses* nc){ size_t i; const size_t screens = sizeof(steps) / sizeof(*steps); struct ncplane* n = notcurses_stdplane(nc); + bool initial_scroll = ncplane_scrolling_p(n); ncplane_set_scrolling(n, true); ncplane_erase(n); for(i = 0 ; i < screens ; ++i){ @@ -594,6 +595,6 @@ int witherworm_demo(struct notcurses* nc){ } }while(key == NCKEY_RESIZE); } - ncplane_set_scrolling(n, false); + ncplane_set_scrolling(n, initial_scroll); return 0; }