Don't lose swapped window when navigating to current buffer

master
Jeremy O'Brien 2021-01-19 11:52:43 -05:00 committed by C. McEnroe
parent 965b6987a9
commit 1fbc8fe394
1 changed files with 2 additions and 1 deletions

3
ui.c
View File

@ -733,9 +733,10 @@ static void inputUpdate(void) {
} }
static void windowShow(uint num) { static void windowShow(uint num) {
windows.user = num;
if (windows.show == num) return;
windows.swap = windows.show; windows.swap = windows.show;
windows.show = num; windows.show = num;
windows.user = num;
mark(windows.ptrs[windows.swap]); mark(windows.ptrs[windows.swap]);
unmark(windows.ptrs[windows.show]); unmark(windows.ptrs[windows.show]);
windowUpdate(); windowUpdate();