From 722b3d5c9c88318b308929889861a05023acc790 Mon Sep 17 00:00:00 2001 From: Sveinung Kvilhaugsvik Date: Tue, 16 Feb 2021 05:50:18 +0100 Subject: [PATCH 10/10] Qt client: improve button number macros. The non action buttons in the action selection dialog has assigned numbers so they can be looked up "by action id". Number them relative to the previous non action buttons rather than "Keep Moving" so it becomes less work to insert or to remove non action buttons. Add parentheses around the counting just in case. See osdn #41587 --- client/gui-qt/dialogs.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/gui-qt/dialogs.cpp b/client/gui-qt/dialogs.cpp index e30f29b8ac..1b4c9c2e90 100644 --- a/client/gui-qt/dialogs.cpp +++ b/client/gui-qt/dialogs.cpp @@ -64,9 +64,9 @@ /* Locations for non action enabler controlled buttons. */ #define BUTTON_MOVE ACTION_COUNT -#define BUTTON_WAIT BUTTON_MOVE + 1 -#define BUTTON_CANCEL BUTTON_MOVE + 2 -#define BUTTON_COUNT BUTTON_MOVE + 3 +#define BUTTON_WAIT (BUTTON_MOVE + 1) +#define BUTTON_CANCEL (BUTTON_WAIT + 1) +#define BUTTON_COUNT (BUTTON_CANCEL + 1) extern void popdown_all_spaceships_dialogs(); extern void popdown_players_report(); -- 2.20.1