summary refs log tree commit diff
path: root/ui.c
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-02-10 01:09:03 -0500
committerJune McEnroe <june@causal.agency>2020-02-10 01:09:03 -0500
commitf3fa88ef920c5fdfd5b4fd6cc0b00a38d9d25c53 (patch)
tree0a61d833b296ccb0424f9a5c2fdd36ee1bc6c091 /ui.c
parentAdd M-l (diff)
downloadcatgirl-f3fa88ef920c5fdfd5b4fd6cc0b00a38d9d25c53.tar.gz
catgirl-f3fa88ef920c5fdfd5b4fd6cc0b00a38d9d25c53.zip
Fix M-a so it properly cycles back to where it started
Diffstat (limited to 'ui.c')
-rw-r--r--ui.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/ui.c b/ui.c
index 66c695f..d94351a 100644
--- a/ui.c
+++ b/ui.c
@@ -697,12 +697,10 @@ void uiCloseNum(size_t num) {
 }
 
 static void showAuto(void) {
-	static bool origin;
-	if (!origin) {
-		windows.other = windows.active;
-		origin = true;
+	static struct Window *other;
+	if (windows.other != other) {
+		other = windows.active;
 	}
-	struct Window *other = windows.other;
 	for (struct Window *window = windows.head; window; window = window->next) {
 		if (window->heat < Hot) continue;
 		windowShow(window);
@@ -716,7 +714,6 @@ static void showAuto(void) {
 		return;
 	}
 	windowShow(windows.other);
-	origin = false;
 }
 
 static void keyCode(int code) {
500'>2020-02-11Exit focus and paste modes on err exitJune McEnroe 2020-02-11Add startup GPLv3 note and URLJune McEnroe 2020-02-11Make sure -D_GNU_SOURCE ends up in CFLAGS on LinuxJune McEnroe 2020-02-11Add note about setting PKG_CONFIG_PATHJune McEnroe 2020-02-11Rename query ID on nick changeJune McEnroe 2020-02-11Call completeClear when closing a windowJune McEnroe 2020-02-11Don't insert color codes for non-mentionsJune McEnroe 2020-02-11Take first two words in colorMentionsJune McEnroe 2020-02-11Use time_t for save signatureJune McEnroe 2020-02-11Set self.nick to * initiallyJune McEnroe 2020-02-11Define ColorCap instead of hardcoding 100June McEnroe 2020-02-11Move hash to top of chat.hJune McEnroe 2020-02-11Move base64 out of chat.hJune McEnroe 2020-02-11Move XDG_SUBDIR out of chat.hJune McEnroe 2020-02-11Fix whois idle unit calculationJune McEnroe 2020-02-11Cast towupper to wchar_tJune McEnroe 2020-02-11Cast set but unused variables to voidJune McEnroe 2020-02-11Declare strlcatJune McEnroe 2020-02-11Check if VDSUSP existsJune McEnroe 2020-02-11Fix completeReplace iterationJune McEnroe 2020-02-11Use pkg(8) to configure on FreeBSDJune McEnroe 2020-02-11Remove legacy codeJune McEnroe 2020-02-11Add INSTALLING section to READMEJune McEnroe