Updated about, hidden accuracy when creating by geouri, alphabetic category order
This commit is contained in:
		| @@ -62,6 +62,10 @@ public class AboutActivity extends AppCompatActivity { | |||||||
|         TextView tvIssues = findViewById(R.id.about_issues); |         TextView tvIssues = findViewById(R.id.about_issues); | ||||||
|         tvIssues.setText(Html.fromHtml(getString(R.string.about_issues, getString(R.string.url_issues)))); |         tvIssues.setText(Html.fromHtml(getString(R.string.about_issues, getString(R.string.url_issues)))); | ||||||
|         tvIssues.setOnClickListener(view -> openUtl(getString(R.string.url_issues))); |         tvIssues.setOnClickListener(view -> openUtl(getString(R.string.url_issues))); | ||||||
|  |  | ||||||
|  |         TextView tvMaps = findViewById(R.id.about_maps); | ||||||
|  |         tvMaps.setText(Html.fromHtml(getString(R.string.about_maps))); | ||||||
|  |         tvMaps.setOnClickListener(view -> openUtl(getString(R.string.url_maps))); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     @Override |     @Override | ||||||
|   | |||||||
| @@ -165,6 +165,7 @@ public class GeofavoriteDetailActivity extends AppCompatActivity implements Loca | |||||||
|                     double[] coords = GeoUriParser.parseUri(getIntent().getData()); |                     double[] coords = GeoUriParser.parseUri(getIntent().getData()); | ||||||
|                     mGeofavorite.setLat(coords[0]); |                     mGeofavorite.setLat(coords[0]); | ||||||
|                     mGeofavorite.setLng(coords[1]); |                     mGeofavorite.setLng(coords[1]); | ||||||
|  |                     mViewHolder.hideAccuracy(); | ||||||
|                 } catch (IllegalArgumentException e) { |                 } catch (IllegalArgumentException e) { | ||||||
|                     Toast.makeText(this, R.string.error_unsupported_uri, Toast.LENGTH_SHORT).show(); |                     Toast.makeText(this, R.string.error_unsupported_uri, Toast.LENGTH_SHORT).show(); | ||||||
|                     finish(); |                     finish(); | ||||||
| @@ -319,6 +320,7 @@ public class GeofavoriteDetailActivity extends AppCompatActivity implements Loca | |||||||
|             // Set map properties |             // Set map properties | ||||||
|             this.binding.map.getZoomController().setVisibility(CustomZoomButtonsController.Visibility.NEVER); |             this.binding.map.getZoomController().setVisibility(CustomZoomButtonsController.Visibility.NEVER); | ||||||
|             this.binding.map.setMultiTouchControls(true); |             this.binding.map.setMultiTouchControls(true); | ||||||
|  | //            this.binding.map.setTilesScaledToDpi(true); | ||||||
|  |  | ||||||
|             // Create marker |             // Create marker | ||||||
|             mapMarker = new Marker(binding.map); |             mapMarker = new Marker(binding.map); | ||||||
|   | |||||||
| @@ -154,7 +154,7 @@ public class Geofavorite implements Serializable { | |||||||
|      */ |      */ | ||||||
|     public static Comparator<Geofavorite> ByTitleAZ = (gf0, gf1) -> gf0.name.compareTo(gf1.name); |     public static Comparator<Geofavorite> ByTitleAZ = (gf0, gf1) -> gf0.name.compareTo(gf1.name); | ||||||
|     public static Comparator<Geofavorite> ByLastCreated = (gf0, gf1) -> (int) (gf1.dateCreated - gf0.dateCreated); |     public static Comparator<Geofavorite> ByLastCreated = (gf0, gf1) -> (int) (gf1.dateCreated - gf0.dateCreated); | ||||||
|     public static Comparator<Geofavorite> ByCategory = (gf0, gf1) -> gf0.category.compareTo(gf1.category); |     public static Comparator<Geofavorite> ByCategory = (gf0, gf1) -> (gf0.category + gf0.name).compareTo(gf1.category + gf1.name); | ||||||
|     public static Comparator<Geofavorite> ByDistance = (gf0, gf1) -> 0; // (int) ((gf1.getDistanceFrom(userPosition) - gf0.getDistanceFrom(userPosition)) * 1000); |     public static Comparator<Geofavorite> ByDistance = (gf0, gf1) -> 0; // (int) ((gf1.getDistanceFrom(userPosition) - gf0.getDistanceFrom(userPosition)) * 1000); | ||||||
|  |  | ||||||
|     public String getCoordinatesString() { |     public String getCoordinatesString() { | ||||||
|   | |||||||
| @@ -115,6 +115,20 @@ | |||||||
|                 android:layout_height="wrap_content" |                 android:layout_height="wrap_content" | ||||||
|                 android:padding="10dp" |                 android:padding="10dp" | ||||||
|                 android:text="@string/about_issues" /> |                 android:text="@string/about_issues" /> | ||||||
|  |  | ||||||
|  |             <TextView | ||||||
|  |                 style="?android:attr/listSeparatorTextViewStyle" | ||||||
|  |                 android:layout_width="match_parent" | ||||||
|  |                 android:layout_height="wrap_content" | ||||||
|  |                 android:text="@string/about_maps_title" /> | ||||||
|  |  | ||||||
|  |             <TextView | ||||||
|  |                 android:id="@+id/about_maps" | ||||||
|  |                 style="?android:attr/editTextPreferenceStyle" | ||||||
|  |                 android:layout_width="match_parent" | ||||||
|  |                 android:layout_height="wrap_content" | ||||||
|  |                 android:padding="10dp" | ||||||
|  |                 android:text="@string/about_maps" /> | ||||||
|         </LinearLayout> |         </LinearLayout> | ||||||
|  |  | ||||||
|     </com.google.android.material.appbar.AppBarLayout> |     </com.google.android.material.appbar.AppBarLayout> | ||||||
|   | |||||||
| @@ -69,6 +69,8 @@ | |||||||
|     <string name="about_source">This project is hosted on GitHub: <a href="%1$s">%1$s</a></string> |     <string name="about_source">This project is hosted on GitHub: <a href="%1$s">%1$s</a></string> | ||||||
|     <string name="about_issues_title">Issues</string> |     <string name="about_issues_title">Issues</string> | ||||||
|     <string name="about_issues">You can report bugs, enhancement proposals and feature requests at the GitHub issue tracker: <a href="%1$s">%1$s</a></string> |     <string name="about_issues">You can report bugs, enhancement proposals and feature requests at the GitHub issue tracker: <a href="%1$s">%1$s</a></string> | ||||||
|  |     <string name="about_maps_title">Maps</string> | ||||||
|  |     <string name="about_maps">This app uses Open Street Maps tiles and servers to display the map. I do not accept any donation for this app, but strongly encourage to make any donation to <a href="%1$s">OpenStreetMap</a>, as this application could not exist without them.</string> | ||||||
|     <string name="about_app_license_title">App license</string> |     <string name="about_app_license_title">App license</string> | ||||||
|     <string name="about_app_license">This application is licensed under the GNU GENERAL PUBLIC LICENSE v3+.</string> |     <string name="about_app_license">This application is licensed under the GNU GENERAL PUBLIC LICENSE v3+.</string> | ||||||
|     <string name="about_app_license_button">View license</string> |     <string name="about_app_license_button">View license</string> | ||||||
| @@ -79,8 +81,9 @@ | |||||||
|  |  | ||||||
|     <!-- URLs --> |     <!-- URLs --> | ||||||
|     <string name="url_source" translatable="false">https://github.com/penguin86/nextcloud-maps-client</string> |     <string name="url_source" translatable="false">https://github.com/penguin86/nextcloud-maps-client</string> | ||||||
|     <string name="url_issues" translatable="false">https://github.com/penguin86/nextcloud-maps-client/issues/new/choose</string> |     <string name="url_issues" translatable="false">https://github.com/penguin86/nextcloud-maps-client/issues</string> | ||||||
|     <string name="url_license" translatable="false">https://raw.githubusercontent.com/penguin86/nextcloud-maps-client/master/LICENSE</string> |     <string name="url_license" translatable="false">https://raw.githubusercontent.com/penguin86/nextcloud-maps-client/master/LICENSE</string> | ||||||
|  |     <string name="url_maps" translatable="false">https://donate.openstreetmap.org</string> | ||||||
|  |  | ||||||
|     <!-- Settings --> |     <!-- Settings --> | ||||||
|     <string name="setting_sort_by">SETTING_SORT_BY</string> |     <string name="setting_sort_by">SETTING_SORT_BY</string> | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user