diff options
author | rachytski <siarhei.rachytski@gmail.com> | 2013-01-24 19:51:39 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:49:16 +0300 |
commit | 8650c6cd814d6ac04d754689fd15b23701fc7776 (patch) | |
tree | a653c8d7b8e2e9394f514e8f58e6621e52f0f586 /gui/button.hpp | |
parent | 7190e7c12e2b8fd933c9b41939a713f57a0c0cf5 (diff) |
refactored gui::Button to use graphics::DisplayList's for faster rendering.
Diffstat (limited to 'gui/button.hpp')
-rw-r--r-- | gui/button.hpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gui/button.hpp b/gui/button.hpp index 049cf16df1..0be6bc233c 100644 --- a/gui/button.hpp +++ b/gui/button.hpp @@ -33,9 +33,14 @@ namespace gui unsigned m_minHeight; scoped_ptr<TextView> m_textView; + map<EState, shared_ptr<graphics::DisplayList> > m_dls; + + void cacheButtonBody(EState state); mutable vector<m2::AnyRectD> m_boundRects; + void cache(); + public: struct Params : Element::Params @@ -75,6 +80,8 @@ namespace gui vector<m2::AnyRectD> const & boundRects() const; void draw(graphics::OverlayRenderer * r, math::Matrix<double, 3, 3> const & m) const; + void purge(); + /// @} }; } |