From f605308ee3da739aee2a690c870c5b567d11d859 Mon Sep 17 00:00:00 2001 From: Josiah VanderZee Date: Tue, 20 Oct 2020 18:28:25 -0500 Subject: Improve drawEntry. --- src/gui/cheatMenu.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/gui/cheatMenu.h') diff --git a/src/gui/cheatMenu.h b/src/gui/cheatMenu.h index 61637b1d4..e7fb4dc93 100644 --- a/src/gui/cheatMenu.h +++ b/src/gui/cheatMenu.h @@ -20,6 +20,7 @@ with this program; if not, write to the Free Software Foundation, Inc., #pragma once #include "irrlichttypes_extrabloated.h" +#include #include #define CHEAT_MENU_GET_SCRIPTPTR \ @@ -29,12 +30,12 @@ with this program; if not, write to the Free Software Foundation, Inc., class Client; -typedef enum +enum CheatMenuEntryType { CHEAT_MENU_ENTRY_TYPE_HEAD, CHEAT_MENU_ENTRY_TYPE_CATEGORY, CHEAT_MENU_ENTRY_TYPE_ENTRY, -} CheatMenuEntryType; +}; class CheatMenu { @@ -43,8 +44,9 @@ public: void draw(video::IVideoDriver *driver, bool show_debug); - void drawEntry(video::IVideoDriver *driver, std::string name, int number, - bool selected, bool active, int category_count, + void drawEntry(video::IVideoDriver *driver, std::string name, + std::size_t column_align_index, std::size_t cheat_entry_index, + bool is_selected, bool is_enabled, CheatMenuEntryType entry_type = CHEAT_MENU_ENTRY_TYPE_ENTRY); void selectUp(); -- cgit v1.2.3