[ShareLocation] Added Re-Center logic

If currently following another user, and the map gets moved,
enable a recenter button to update the location to the currently
selected location of the user.
This commit is contained in:
Alexander Dörflinger
2025-04-01 12:32:20 +02:00
parent c8488ab55e
commit be6b5284df
2 changed files with 62 additions and 8 deletions

View File

@@ -31,6 +31,17 @@
</androidx.constraintlayout.widget.ConstraintLayout>
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/fab_recenter_on_follower"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@android:drawable/ic_menu_compass"
app:layout_constraintBottom_toBottomOf="@id/map"
app:layout_constraintEnd_toEndOf="@id/map"
android:layout_marginBottom="25dp"
android:layout_marginEnd="25dp"
android:visibility="gone"/>
<androidx.fragment.app.FragmentContainerView
android:id="@+id/map"
android:name="com.google.android.gms.maps.SupportMapFragment"