diff --git a/OsmAnd/res/layout/search_advanced_coords.xml b/OsmAnd/res/layout/search_advanced_coords.xml index 66a9bd03c6..e0397824da 100644 --- a/OsmAnd/res/layout/search_advanced_coords.xml +++ b/OsmAnd/res/layout/search_advanced_coords.xml @@ -92,7 +92,7 @@ android:layout_height="wrap_content" android:hint="@string/navigate_point_latitude" android:imeOptions="actionNext" - android:inputType="textCapSentences" + android:inputType="textCapCharacters|textNoSuggestions" tools:text="22.12345"/> @@ -139,7 +139,7 @@ android:layout_height="wrap_content" android:hint="@string/navigate_point_longitude" android:imeOptions="actionDone" - android:inputType="textCapSentences" + android:inputType="textCapCharacters|textNoSuggestions" tools:text="22.12345"/> @@ -187,7 +187,7 @@ android:layout_height="wrap_content" android:hint="@string/navigate_point_northing" android:imeOptions="actionNext" - android:inputType="textCapSentences" + android:inputType="textCapCharacters|textNoSuggestions" tools:text="22.12345"/> @@ -235,7 +235,7 @@ android:layout_height="wrap_content" android:hint="@string/navigate_point_easting" android:imeOptions="actionNext" - android:inputType="textCapSentences" + android:inputType="textCapCharacters|textNoSuggestions" tools:text="22.12345"/> @@ -278,7 +278,7 @@ android:layout_height="wrap_content" android:hint="@string/navigate_point_zone" android:imeOptions="actionDone" - android:inputType="textCapSentences" + android:inputType="textCapCharacters|textNoSuggestions" tools:text="22.12345"/> diff --git a/OsmAnd/src/net/osmand/plus/search/QuickSearchCoordinatesFragment.java b/OsmAnd/src/net/osmand/plus/search/QuickSearchCoordinatesFragment.java index db92bb2442..78f872ea32 100644 --- a/OsmAnd/src/net/osmand/plus/search/QuickSearchCoordinatesFragment.java +++ b/OsmAnd/src/net/osmand/plus/search/QuickSearchCoordinatesFragment.java @@ -551,15 +551,13 @@ public class QuickSearchCoordinatesFragment extends DialogFragment implements Os AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); builder.setTitle(R.string.coords_format) - .setSingleChoiceItems(entries, parent.currentFormat, null) - .setPositiveButton(R.string.shared_string_ok, new DialogInterface.OnClickListener() { + .setSingleChoiceItems(entries, parent.currentFormat, new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { - int selectedPosition = ((AlertDialog) dialog).getListView().getCheckedItemPosition(); - parent.applyFormat(selectedPosition); + parent.applyFormat(which); + dialog.dismiss(); } - }) - .setNegativeButton(R.string.shared_string_cancel, null); + }); return builder.create(); } }