From ae9274d64697b1ac4cb71f481e9aa170edfd9f8b Mon Sep 17 00:00:00 2001 From: "Daniele Verducci (Slimpenguin)" Date: Thu, 22 Feb 2024 07:22:32 +0100 Subject: [PATCH] Map style, graphics refinements --- .../fragments/GeofavoriteMapFragment.java | 4 ++++ ...ting_semitransparent_button_background.xml | 9 +++++++ app/src/main/res/layout/app_toolbar.xml | 3 ++- .../res/layout/fragment_geofavorite_list.xml | 4 +++- .../res/layout/fragment_geofavorite_map.xml | 24 ++++++++++--------- app/src/main/res/values/colors.xml | 2 +- 6 files changed, 32 insertions(+), 14 deletions(-) create mode 100644 app/src/main/res/drawable/unselected_floating_semitransparent_button_background.xml diff --git a/app/src/main/java/it/danieleverducci/nextcloudmaps/fragments/GeofavoriteMapFragment.java b/app/src/main/java/it/danieleverducci/nextcloudmaps/fragments/GeofavoriteMapFragment.java index 188eae9..e9e08a0 100644 --- a/app/src/main/java/it/danieleverducci/nextcloudmaps/fragments/GeofavoriteMapFragment.java +++ b/app/src/main/java/it/danieleverducci/nextcloudmaps/fragments/GeofavoriteMapFragment.java @@ -19,6 +19,7 @@ import androidx.lifecycle.Observer; import org.osmdroid.api.IMapController; import org.osmdroid.events.MapEventsReceiver; import org.osmdroid.util.GeoPoint; +import org.osmdroid.views.CustomZoomButtonsController; import org.osmdroid.views.MapView; import org.osmdroid.views.overlay.MapEventsOverlay; import org.osmdroid.views.overlay.Marker; @@ -54,6 +55,9 @@ public class GeofavoriteMapFragment extends GeofavoritesFragment implements Main // Setup map map = v.findViewById(R.id.map); + map.getZoomController().setVisibility(CustomZoomButtonsController.Visibility.NEVER); + map.setMultiTouchControls(true); + MapUtils.setTheme(map); MapEventsOverlay meo = new MapEventsOverlay(requireContext(), new MapEventsReceiver() { @Override public boolean singleTapConfirmedHelper(GeoPoint p) { diff --git a/app/src/main/res/drawable/unselected_floating_semitransparent_button_background.xml b/app/src/main/res/drawable/unselected_floating_semitransparent_button_background.xml new file mode 100644 index 0000000..d5bb4fa --- /dev/null +++ b/app/src/main/res/drawable/unselected_floating_semitransparent_button_background.xml @@ -0,0 +1,9 @@ + + + + + + + + \ No newline at end of file diff --git a/app/src/main/res/layout/app_toolbar.xml b/app/src/main/res/layout/app_toolbar.xml index c0ac27f..1279674 100644 --- a/app/src/main/res/layout/app_toolbar.xml +++ b/app/src/main/res/layout/app_toolbar.xml @@ -4,7 +4,8 @@ xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" - android:layout_height="wrap_content"> + android:layout_height="wrap_content" + android:layout_marginTop="10dp"> + android:paddingTop="20dp" + android:paddingStart="5dp" + android:paddingEnd="5dp"> - + diff --git a/app/src/main/res/values/colors.xml b/app/src/main/res/values/colors.xml index 98f353b..df34c7c 100644 --- a/app/src/main/res/values/colors.xml +++ b/app/src/main/res/values/colors.xml @@ -20,7 +20,7 @@ #ffffff #00000000 - #CFFF + #AEFFFFFF #0082C9 #550082C9 #666