//
// $Id$
+#ifdef HAVE_CONFIG_H
+# include <simgear_config.h>
+#endif
+
#include <simgear/bucket/newbucket.hxx>
#include <simgear/debug/logstream.hxx>
#include <simgear/misc/sg_path.hxx>
#include "TileEntry.hxx"
#include "TileCache.hxx"
-SG_USING_NAMESPACE(std);
-
using simgear::TileEntry;
using simgear::TileCache;
TileCache::TileCache( void ) :
- max_cache_size(100)
+ max_cache_size(100), current_time(0.0)
{
tile_cache.clear();
}
TileEntry *tile = tile_cache[cache_index];
tile->removeFromSceneGraph();
- tile->free_tile();
delete tile;
tile_cache.erase( cache_index );
// register tile in the cache
long tile_index = e->get_tile_bucket().gen_index();
tile_cache[tile_index] = e;
+ e->set_timestamp(current_time);
return true;
}