Make Map::getSprite() private

This commit is contained in:
John Firebaugh
2014-11-25 16:22:05 -08:00
parent 576533b18c
commit d3ba1071cb
6 changed files with 21 additions and 14 deletions

View File

@@ -127,12 +127,12 @@ public:
public:
inline const TransformState &getState() const { return state; }
inline util::ptr<Style> getStyle() const { return style; }
util::ptr<Sprite> getSprite();
inline timestamp getAnimationTime() const { return animationTime; }
inline timestamp getTime() const { return animationTime; }
void updateTiles();
private:
util::ptr<Sprite> getSprite();
uv::worker& getWorker();
// uv async callbacks

View File

@@ -21,6 +21,7 @@ class Map;
class GlyphAtlas;
class GlyphStore;
class SpriteAtlas;
class Sprite;
class FileSource;
class Texturepool;
class Painter;
@@ -35,7 +36,7 @@ public:
void load(Map&, FileSource&);
bool update(Map&, uv::worker&,
GlyphAtlas&, GlyphStore&,
SpriteAtlas&,
SpriteAtlas&, util::ptr<Sprite>,
Texturepool&, FileSource&);
void updateMatrices(const mat4 &projMatrix, const TransformState &transform);
@@ -57,12 +58,12 @@ private:
bool updateTiles(Map&, uv::worker&,
GlyphAtlas&, GlyphStore&,
SpriteAtlas&,
SpriteAtlas&, util::ptr<Sprite>,
Texturepool&, FileSource&);
TileData::State addTile(Map&, uv::worker&,
GlyphAtlas&, GlyphStore&,
SpriteAtlas&,
SpriteAtlas&, util::ptr<Sprite>,
FileSource&, Texturepool&,
const Tile::ID&);

View File

@@ -24,6 +24,7 @@ class TileParser;
class GlyphAtlas;
class GlyphStore;
class SpriteAtlas;
class Sprite;
class Texturepool;
class VectorTileData : public TileData {
@@ -32,7 +33,7 @@ class VectorTileData : public TileData {
public:
VectorTileData(Tile::ID const&, Map&,
GlyphAtlas&, GlyphStore&,
SpriteAtlas&,
SpriteAtlas&, util::ptr<Sprite>,
Texturepool&,
const util::ptr<SourceInfo>&);
~VectorTileData();
@@ -59,6 +60,7 @@ protected:
GlyphAtlas& glyphAtlas;
GlyphStore& glyphStore;
SpriteAtlas& spriteAtlas;
util::ptr<Sprite> sprite;
Texturepool& texturepool;
public: