@Override
        public void onClick(final View view) {
            final Button button = (Button) view;
            final CharSequence text = button.getText();
            if (StringUtils.isBlank(text)) {
                return;
            }
            switch (text.charAt(0)) {
                case 'N':
                    button.setText("S");
                    break;
                case 'S':
                    button.setText("N");
                    break;
                case 'E':
                    button.setText("W");
                    break;
                case 'W':
                    button.setText("E");
                    break;
                default:
                    break;
            }
        }
Provides a dialog to enter coordinates in different formats.
Usage:
1. open the coordinate selection dialog: call CoordinatesInputDialog.show(getSupportFragmentManager(), null, null);
2. in your activity implement CoordinatesInputDialog.CoordinateUpdate, closing the dialog calls public void updateCoordinates(@NonNull final Geopoint gp)
main/src/main/java/cgeo/geocaching/ui/dialog/CoordinatesInputDialog.java