Fixed bug with native rendeerer and dashboard. Replaced message for error on dashboard

This commit is contained in:
Bars107 2014-12-02 18:52:49 +02:00
parent ddcb1a8611
commit 39c7968a81
6 changed files with 10 additions and 7 deletions

View file

@ -30,7 +30,7 @@
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:text="@string/default_buttons_cancel"
android:text="@string/dismiss"
style="@style/DashboardGeneralButton"/>
</LinearLayout>

View file

@ -9,6 +9,7 @@
3. All your modified/created strings are in the top of the file (to make easier find what\'s translated).
PLEASE: Have a look at http://code.google.com/p/osmand/wiki/UIConsistency, it may really improve your and our work :-) Thx - Hardy
-->
<string name="dismiss">Dismiss</string>
<string name="everything_up_to_date">Everything up to date</string>
<string name="use_opengl_render">Use opengl rendering</string>
<string name="use_opengl_render_descr">Use hardware accelerated opengl rendering (may not work on some device)</string>

View file

@ -101,7 +101,7 @@ public class MapActivityLayers {
mapView.setMainLayer(mapTileLayer);
// 0.5 layer
mapVectorLayer = new MapVectorLayer(mapTileLayer);
mapVectorLayer = new MapVectorLayer(mapTileLayer, false);
mapView.addLayer(mapVectorLayer, 0.5f);
downloadedRegionsLayer = new DownloadedRegionsLayer();
@ -169,7 +169,7 @@ public class MapActivityLayers {
// mapView.setMainLayer(mapTileLayer);
// 0.5 layer
mapVectorLayer = new MapVectorLayer(mapTileLayer);
mapVectorLayer = new MapVectorLayer(mapTileLayer, true);
// mapView.addLayer(mapVectorLayer, 0.5f);
downloadedRegionsLayer = new DownloadedRegionsLayer();

View file

@ -74,7 +74,7 @@ public class DownloadActivity extends BaseDownloadActivity {
setProgressBarIndeterminateVisibility(false);
setContentView(R.layout.tab_content);
tabHost = (TabHost) findViewById(android.R.id.tabhost);
tabHost.setup();
ViewPager viewPager = (ViewPager) findViewById(R.id.pager);

View file

@ -26,9 +26,11 @@ public class MapVectorLayer extends BaseMapLayer {
private RectF destImage = new RectF();
private final MapTileLayer tileLayer;
private boolean visible = false;
private boolean oldRender = false;
public MapVectorLayer(MapTileLayer tileLayer){
public MapVectorLayer(MapTileLayer tileLayer, boolean oldRender){
this.tileLayer = tileLayer;
this.oldRender = oldRender;
}
@ -94,7 +96,7 @@ public class MapVectorLayer extends BaseMapLayer {
resourceManager.getRenderer().interruptLoadingMap();
} else {
final MapRendererView mapRenderer = view.getMapRenderer();
if (mapRenderer != null) {
if (mapRenderer != null && !oldRender) {
NativeCoreContext.getMapRendererContext().setNightMode(drawSettings.isNightMode());
// opengl renderer
mapRenderer.setTarget(new PointI(tilesRect.getCenter31X(), tilesRect.getCenter31Y()));

View file

@ -34,7 +34,7 @@ public class SherpafyStageItineraryFragment extends SherpafyStageInfoFragment im
app.getResourceManager().getMapTileDownloader().addDownloaderCallback(this);
osmandMapTileView.getView().setVisibility(View.VISIBLE);
osmandMapTileView.removeAllLayers();
MapVectorLayer mapVectorLayer = new MapVectorLayer(null);
MapVectorLayer mapVectorLayer = new MapVectorLayer(null, true);
MapTextLayer mapTextLayer = new MapTextLayer();
mapTextLayer.setAlwaysVisible(true);
// 5.95 all labels