Keep proper track of MD5 checksums of addons
[supertux.git] / src / supertux / menu / menu_storage.hpp
index b4b78b7..dbd622d 100644 (file)
@@ -1,5 +1,5 @@
 //  SuperTux
-//  Copyright (C) 2009 Ingo Ruhnke <grumbel@gmx.de>
+//  Copyright (C) 2009 Ingo Ruhnke <grumbel@gmail.com>
 //
 //  This program is free software: you can redistribute it and/or modify
 //  it under the terms of the GNU General Public License as published by
@@ -33,19 +33,29 @@ public:
   static MenuStorage& instance();
 
 public:
+  enum MenuId {
+    NO_MENU,
+    MAIN_MENU,
+    OPTIONS_MENU,
+    INGAME_OPTIONS_MENU,
+    PROFILE_MENU,
+    CONTRIB_MENU,
+    CONTRIB_WORLD_MENU,
+    ADDON_MENU,
+    LANGUAGE_MENU,
+    KEYBOARD_MENU,
+    JOYSTICK_MENU,
+    WORLDMAP_MENU,
+    WORLDMAP_CHEAT_MENU,
+    GAME_MENU,
+    CHEAT_MENU
+  };
+
+public:
   MenuStorage();
   ~MenuStorage();
 
-  OptionsMenu*  get_options_menu();
-  ProfileMenu*  get_profile_menu();
-  KeyboardMenu* get_key_options_menu();
-  JoystickMenu* get_joystick_options_menu();
-
-private:
-  std::unique_ptr<OptionsMenu>  m_options_menu;
-  std::unique_ptr<ProfileMenu>  m_profile_menu;
-  std::unique_ptr<KeyboardMenu> m_key_options_menu;
-  std::unique_ptr<JoystickMenu> m_joystick_options_menu;
+  std::unique_ptr<Menu> create(MenuId menu_id);
 
 private:
   MenuStorage(const MenuStorage&);