From d9f4fa4058d96f5bfc195ece7bf19a8e0fe32064 Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Sat, 14 Jan 2017 20:59:21 +0100 Subject: [PATCH 1/1] improved changing level in main menu (regardless of cursor position) --- src/screens.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/screens.c b/src/screens.c index a2f63bcd..641c5e07 100644 --- a/src/screens.c +++ b/src/screens.c @@ -1849,11 +1849,7 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button) pos = choice + dy; } - if (pos == MAIN_CONTROL_LEVELS && dx != 0 && button) - { - HandleMainMenu_SelectLevel(1, (dx < 0 ? -1 : +1), NO_DIRECT_LEVEL_SELECT); - } - else if (pos == MAIN_CONTROL_FIRST_LEVEL && !button) + if (pos == MAIN_CONTROL_FIRST_LEVEL && !button) { HandleMainMenu_SelectLevel(MAX_LEVELS, -1, NO_DIRECT_LEVEL_SELECT); } @@ -1882,6 +1878,12 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button) choice = pos; } + else if (dx != 0) + { + if (choice != MAIN_CONTROL_INFO && + choice != MAIN_CONTROL_SETUP) + HandleMainMenu_SelectLevel(1, dx, NO_DIRECT_LEVEL_SELECT); + } } else { -- 2.34.1