Commit 1dcc9a20 authored by Bryant Mairs's avatar Bryant Mairs

Fix valgrind leak in opmapcontrol.

parent 4cab8e40
......@@ -42,6 +42,7 @@ namespace internals {
minOfTiles(0,0),
maxOfTiles(0,0),
zoom(0),
projection(NULL),
isDragging(false),
TooltipTextPadding(10,10),
loaderLimit(5),
......@@ -61,6 +62,9 @@ namespace internals {
}
Core::~Core()
{
if (projection) {
delete projection;
}
ProcessLoadTaskCallback.waitForDone();
}
......
......@@ -135,6 +135,9 @@ namespace internals {
}
void SetProjection(PureProjection* value)
{
if (projection) {
delete projection;
}
projection=value;
tileRect=Rectangle(core::Point(0,0),value->TileSize());
}
......
......@@ -42,8 +42,9 @@ namespace internals
class PureProjection
{
public:
virtual ~PureProjection() {}
virtual Size TileSize()const=0;
virtual double Axis()const=0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment