From 349add0f81a37f9a51f970ef2cb1cef7ca35946c Mon Sep 17 00:00:00 2001 From: Lioncash Date: Thu, 8 Jun 2023 13:05:10 -0400 Subject: [PATCH] GCMemcardManager: Shorten-up EnumMap definitions We can make a small alias that gets rid of the need to repeat the long constant. --- Source/Core/DolphinQt/GCMemcardManager.h | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/Source/Core/DolphinQt/GCMemcardManager.h b/Source/Core/DolphinQt/GCMemcardManager.h index dcc4b3324b..f87d001d8a 100644 --- a/Source/Core/DolphinQt/GCMemcardManager.h +++ b/Source/Core/DolphinQt/GCMemcardManager.h @@ -88,16 +88,17 @@ private: QPushButton* m_fix_checksums_button; // Slots - Common::EnumMap, ExpansionInterface::MAX_MEMCARD_SLOT> - m_slot_active_icons; - Common::EnumMap, ExpansionInterface::MAX_MEMCARD_SLOT> - m_slot_memcard; - Common::EnumMap m_slot_group; - Common::EnumMap m_slot_file_edit; - Common::EnumMap m_slot_open_button; - Common::EnumMap m_slot_create_button; - Common::EnumMap m_slot_table; - Common::EnumMap m_slot_stat_label; + template + using SlotEnumMap = Common::EnumMap; + + SlotEnumMap> m_slot_active_icons; + SlotEnumMap> m_slot_memcard; + SlotEnumMap m_slot_group; + SlotEnumMap m_slot_file_edit; + SlotEnumMap m_slot_open_button; + SlotEnumMap m_slot_create_button; + SlotEnumMap m_slot_table; + SlotEnumMap m_slot_stat_label; ExpansionInterface::Slot m_active_slot; u64 m_current_frame = 0;