mirror of
https://github.com/tumic0/GPXSee.git
synced 2025-04-19 19:59:11 +02:00
Compare commits
4 Commits
53685253d7
...
d7d193871a
Author | SHA1 | Date | |
---|---|---|---|
d7d193871a | |||
|
4b9bb04cec | ||
d3889b6dfe | |||
240ddaf39c |
@ -587,7 +587,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="487"/>
|
||||
<source>Show local DEM tiles</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Näytä paikalliset DEM-laatat</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="490"/>
|
||||
@ -699,7 +699,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="695"/>
|
||||
<source>Layers</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Kerrokset</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="721"/>
|
||||
@ -850,12 +850,12 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="1998"/>
|
||||
<source>DEM tiles download limit exceeded. If you really need data for such a huge area, download the files manually.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>DEM-laattojen latausraja ylitetty. Jos todella tarvitset tietoja niin suurelta alueelta, lataa tiedostot manuaalisesti.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="2014"/>
|
||||
<source>Could not download all required DEM files.</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Kaikkia vaadittuja DEM-tiedostoja ei voitu ladata.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="2048"/>
|
||||
@ -898,12 +898,12 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="476"/>
|
||||
<source>Download data DEM</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Lataa data-DEM</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="482"/>
|
||||
<source>Download map DEM</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Lataa kartta-DEM</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="762"/>
|
||||
@ -961,7 +961,7 @@
|
||||
<message>
|
||||
<location filename="../src/GUI/gui.cpp" line="1978"/>
|
||||
<source>Clear "%1" tile cache?</source>
|
||||
<translation type="unfinished"></translation>
|
||||
<translation>Tyhjennetäänkö "%1" ruutuvälimuisti?</translation>
|
||||
</message>
|
||||
<message numerus="yes">
|
||||
<location filename="../src/GUI/gui.cpp" line="2001"/>
|
||||
|
@ -6,31 +6,23 @@ bool AtlasData::pointCb(MapEntry *map, void *context)
|
||||
{
|
||||
PointCTX *ctx = (PointCTX*)context;
|
||||
|
||||
start:
|
||||
map->lock.lock();
|
||||
|
||||
ctx->cacheLock.lock();
|
||||
|
||||
MapData *cached = ctx->cache.object(map->path);
|
||||
|
||||
if (!cached) {
|
||||
ctx->cacheLock.unlock();
|
||||
|
||||
if (map->lock.tryLock()) {
|
||||
MapData *data = new MapData(map->path);
|
||||
data->points(ctx->rect, ctx->points);
|
||||
MapData *data = new MapData(map->path);
|
||||
data->points(ctx->rect, ctx->points);
|
||||
|
||||
ctx->cacheLock.lock();
|
||||
ctx->cache.insert(map->path, data);
|
||||
|
||||
map->lock.unlock();
|
||||
} else {
|
||||
map->lock.lock();
|
||||
map->lock.unlock();
|
||||
goto start;
|
||||
}
|
||||
ctx->cacheLock.lock();
|
||||
ctx->cache.insert(map->path, data);
|
||||
} else
|
||||
cached->points(ctx->rect, ctx->points);
|
||||
|
||||
ctx->cacheLock.unlock();
|
||||
map->lock.unlock();
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -39,34 +31,26 @@ bool AtlasData::polyCb(MapEntry *map, void *context)
|
||||
{
|
||||
PolyCTX *ctx = (PolyCTX*)context;
|
||||
|
||||
start:
|
||||
map->lock.lock();
|
||||
|
||||
ctx->cacheLock.lock();
|
||||
|
||||
MapData *cached = ctx->cache.object(map->path);
|
||||
|
||||
if (!cached) {
|
||||
ctx->cacheLock.unlock();
|
||||
|
||||
if (map->lock.tryLock()) {
|
||||
MapData *data = new MapData(map->path);
|
||||
data->polygons(ctx->rect, ctx->polygons);
|
||||
data->lines(ctx->rect, ctx->lines);
|
||||
MapData *data = new MapData(map->path);
|
||||
data->polygons(ctx->rect, ctx->polygons);
|
||||
data->lines(ctx->rect, ctx->lines);
|
||||
|
||||
ctx->cacheLock.lock();
|
||||
ctx->cache.insert(map->path, data);
|
||||
|
||||
map->lock.unlock();
|
||||
} else {
|
||||
map->lock.lock();
|
||||
map->lock.unlock();
|
||||
goto start;
|
||||
}
|
||||
ctx->cacheLock.lock();
|
||||
ctx->cache.insert(map->path, data);
|
||||
} else {
|
||||
cached->polygons(ctx->rect, ctx->polygons);
|
||||
cached->lines(ctx->rect, ctx->lines);
|
||||
}
|
||||
|
||||
ctx->cacheLock.unlock();
|
||||
map->lock.unlock();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user