Fixed map not redrawn after elements added

This commit is contained in:
Daniele Verducci (Slimpenguin) 2024-02-23 07:18:10 +01:00
parent 513bc368b2
commit 0e8f9e2dfa
2 changed files with 6 additions and 5 deletions

View File

@ -94,6 +94,7 @@ public class GeofavoriteMapFragment extends GeofavoritesFragment implements Main
public void onChanged(List<Geofavorite> geofavorites) {
for(Geofavorite gf : geofavorites)
addMarker(gf);
map.invalidate();
}
});

View File

@ -8,6 +8,11 @@
android:layout_width="match_parent"
android:layout_height="match_parent">
<org.osmdroid.views.MapView
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<FrameLayout
android:id="@+id/loading_wall"
android:layout_width="match_parent"
@ -23,11 +28,6 @@
</FrameLayout>
<org.osmdroid.views.MapView
android:id="@+id/map"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<androidx.appcompat.widget.LinearLayoutCompat
android:id="@+id/appBar"
android:layout_width="match_parent"