diff options
author | rachytski <siarhei.rachytski@gmail.com> | 2012-12-09 01:17:23 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:47:50 +0300 |
commit | 67907b5423e2c88b70579b7b06f361610ade7c3b (patch) | |
tree | 9007c16e6aff78af2814ef1c8d901b9b6d27b103 /graphics/skin_loader.hpp | |
parent | c92a5801305a2a2f9e3d3132c28e190133c4eddf (diff) |
refactored ResourceStyle and lot of *Info classes into consistent Resource and Resource::Info system.
Diffstat (limited to 'graphics/skin_loader.hpp')
-rw-r--r-- | graphics/skin_loader.hpp | 31 |
1 files changed, 10 insertions, 21 deletions
diff --git a/graphics/skin_loader.hpp b/graphics/skin_loader.hpp index e132bff3f0..096d3b9d4f 100644 --- a/graphics/skin_loader.hpp +++ b/graphics/skin_loader.hpp @@ -38,8 +38,7 @@ namespace graphics class ResourceManager; class ResourceCache; - struct ResourceStyle; - struct GlyphStyle; + struct Resource; class SkinLoader { @@ -50,10 +49,8 @@ namespace graphics ERoot, EPage, ESkin, - EFontStyle, - EPointStyle, - ELineStyle, - EResourceStyle + EIcon, + EResource }; list<EMode> m_mode; @@ -66,27 +63,19 @@ namespace graphics uint32_t m_texHeight; m2::RectU m_texRect; -/// glyphInfo and glyphMaskInfo specific parameters - int8_t m_xOffset; - int8_t m_yOffset; - int8_t m_xAdvance; - - shared_ptr<GlyphStyle> m_glyphInfo; - shared_ptr<GlyphStyle> m_glyphMaskInfo; - /// pointStyle-specific parameters - string m_styleID; + string m_resID; /// skin-specific parameters - vector<shared_ptr<ResourceCache> > m_pages; + vector<shared_ptr<ResourceCache> > m_caches; /// skin-page specific parameters string m_fileName; - typedef list<pair<int32_t, shared_ptr<ResourceStyle> > > TStylesList; + typedef list<pair<int32_t, shared_ptr<Resource> > > TResourceList; - TStylesList m_stylesList; + TResourceList m_resourceList; shared_ptr<ResourceManager> m_resourceManager; Skin * m_skin; @@ -100,13 +89,13 @@ namespace graphics void AddAttr(string const & attribute, string const & value); void CharData(string const &) {} - void popPointStyle(); + void popIcon(); void popSkin(); void pushPage(); void popPage(); - void pushResourceStyle(); - void popResourceStyle(); + void pushResource(); + void popResource(); Skin * skin(); }; |