Small fixes

This commit is contained in:
Roman Sorokin 2014-09-24 10:15:48 +03:00 committed by Alex Zolotarev
parent 3932f732ee
commit 4f5ea66f79
2 changed files with 3 additions and 5 deletions

View file

@ -1,5 +1,7 @@
#include "texture_of_colors.hpp"
#include "../base/stl_add.hpp"
namespace dp
{
@ -11,9 +13,7 @@ ColorPalette::ColorPalette(m2::PointU const & canvasSize)
ColorPalette::~ColorPalette()
{
TPalette::iterator it = m_palette.begin();
for (; it != m_palette.end(); ++it)
it->second.Destroy();
DeleteRange(m_palette, MasterPointerDeleter());
}
ColorResourceInfo const * ColorPalette::MapResource(const ColorKey &key)

View file

@ -35,9 +35,7 @@ public:
private:
typedef MasterPointer<ColorResourceInfo> TResourcePtr;
typedef map<uint32_t, TResourcePtr> TPalette;
typedef pair<TPalette::iterator, bool> TInserted;
void Move(uint32_t step);
TPalette m_palette;
vector<uint32_t> m_pendingNodes;
m2::PointU m_textureSize;