diff --git a/OsmAnd/res/layout/server_fragment.xml b/OsmAnd/res/layout/server_fragment.xml index 35f9a16fe9..816a3cf5d5 100644 --- a/OsmAnd/res/layout/server_fragment.xml +++ b/OsmAnd/res/layout/server_fragment.xml @@ -5,7 +5,9 @@ android:orientation="vertical" android:padding="32dp" android:gravity="center" - android:background="@color/color_black"> + android:clickable="true" + android:background="@color/color_black" + android:focusable="true"> = 0) { url = url.substring(0, extInd); @@ -75,6 +77,7 @@ public class TileEndpoint implements OsmAndHttpServer.ApiEndpoint { } private synchronized MetaTileFileSystemCache.MetaTileCache requestMetatile(int x, int y, int zoom) { + long time2 = System.currentTimeMillis(); MetaTileFileSystemCache.MetaTileCache cacheTile = this.cache.get(zoom, x, y); if (cacheTile != null) { return cacheTile; @@ -102,6 +105,7 @@ public class TileEndpoint implements OsmAndHttpServer.ApiEndpoint { } res.bmp = tempBmp.copy(tempBmp.getConfig(), true); this.cache.put(res); + LOG.debug("SERVER: TIME TO REQUEST TILE: " + (System.currentTimeMillis() - time2)); return res; } catch (InterruptedException e) { LOG.error(e); diff --git a/OsmAnd/src/net/osmand/plus/views/OsmandMapTileView.java b/OsmAnd/src/net/osmand/plus/views/OsmandMapTileView.java index a38e5bbaf1..f3d6660e6b 100644 --- a/OsmAnd/src/net/osmand/plus/views/OsmandMapTileView.java +++ b/OsmAnd/src/net/osmand/plus/views/OsmandMapTileView.java @@ -830,7 +830,7 @@ public class OsmandMapTileView implements IMapDownloaderCallback { // this method could be called in non UI thread public void refreshMap(final boolean updateVectorRendering) { - if (view != null && view.isShown()) { + if ((view != null && view.isShown()) || isScreenViewDetached) { boolean nightMode = application.getDaynightHelper().isNightMode(); Boolean currentNightMode = this.nightMode; boolean forceUpdateVectorDrawing = currentNightMode != null && currentNightMode != nightMode;