diff options
author | Janne Lahdenpera <felirx@gmail.com> | 2010-04-15 17:26:05 +0300 |
---|---|---|
committer | Robert Vollmert <rvollmert@gmx.net> | 2010-04-21 12:36:41 +0200 |
commit | 3ec286ef4ae42ab7c43d5f25fac40054bb033c81 (patch) | |
tree | 3528e6977fae729f8f84c11dc313156f84b5668f /crawl-ref/source/tilesdl.h | |
parent | e6737585092b9b1b548e9076968c5586640f5bd8 (diff) | |
download | crawl-ref-3ec286ef4ae42ab7c43d5f25fac40054bb033c81.tar.gz crawl-ref-3ec286ef4ae42ab7c43d5f25fac40054bb033c81.zip |
A more generic menu structure approach
Converts the menu structure to a more generic approach,
Converts the species / backgrounds menus to use the structure.
Highlighter changed to a nonfilled rectangle in Tiles.
Added descriptions to menu options in species / backgrounds menus.
Signed-off-by: Janne Lahdenpera <felirx@gmail.com>
Signed-off-by: Robert Vollmert <rvollmert@gmx.net>
Diffstat (limited to 'crawl-ref/source/tilesdl.h')
-rw-r--r-- | crawl-ref/source/tilesdl.h | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/crawl-ref/source/tilesdl.h b/crawl-ref/source/tilesdl.h index b6a2c6463e..3ea0c6625f 100644 --- a/crawl-ref/source/tilesdl.h +++ b/crawl-ref/source/tilesdl.h @@ -57,14 +57,6 @@ class FTFont; class TilesFramework { public: - enum CRTRegionType - { - CRT_NOMOUSESELECT, - CRT_SINGLESELECT, - // CRT_MULTISELECT, - CRT_MAX - }; - TilesFramework(); virtual ~TilesFramework(); @@ -115,9 +107,9 @@ public: MenuRegion *get_menu() { return m_region_menu; } bool is_fullscreen() { return m_fullscreen; } - void set_active_crt(CRTRegionType type); - CRTRegion* get_crt() { return m_region_crt[m_active_crt]; } - + FTFont* get_crt_font() { return m_fonts.at(m_crt_font).font; } + CRTRegion* get_crt() { return m_region_crt; } + const ImageManager& get_image_manager() { return m_image; } protected: int load_font(const char *font_file, int font_size, bool default_on_fail, bool outline); @@ -170,11 +162,9 @@ protected: MemoriseRegion *m_region_mem; // Full-screen CRT layer - CRTRegion *m_region_crt[CRT_MAX]; + CRTRegion *m_region_crt; MenuRegion *m_region_menu; - CRTRegionType m_active_crt; - struct font_info { std::string name; @@ -183,6 +173,7 @@ protected: FTFont *font; }; std::vector<font_info> m_fonts; + int m_crt_font; int m_msg_font; int m_tip_font; |