Dismiss splash before drawing layers

This commit is contained in:
PavelRatushny 2017-07-20 17:52:44 +03:00
parent 9a3213cb26
commit cfa204106e

View file

@ -658,6 +658,10 @@ public class OsmandMapTileView implements IMapDownloaderCallback {
}
}
if (activity instanceof MapActivity && !((MapActivity) activity).isActivityDestroyed() &&
((MapActivity) activity).getSupportFragmentManager().findFragmentByTag(SecondSplashScreenFragment.TAG) != null) {
((MapActivity) activity).dismissSecondSplashScreen();
}
for (int i = 0; i < layers.size(); i++) {
try {
OsmandMapLayer layer = layers.get(i);
@ -682,9 +686,6 @@ public class OsmandMapTileView implements IMapDownloaderCallback {
} else if (doubleTapScaleDetector.isInZoomMode()) {
drawMapPosition(canvas, doubleTapScaleDetector.getCenterX(), doubleTapScaleDetector.getCenterY());
}
if (activity instanceof MapActivity && !((MapActivity) activity).isActivityDestroyed() && ((MapActivity) activity).getSupportFragmentManager().findFragmentByTag(SecondSplashScreenFragment.TAG) != null) {
((MapActivity) activity).dismissSecondSplashScreen();
}
}