Skip to content

Commit

Permalink
add compass
Browse files Browse the repository at this point in the history
  • Loading branch information
woheller69 committed May 3, 2023
1 parent 84752ce commit 757caef
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ private void editCityToWatch(CityToWatch city) {
editLatitude.setFilters(new InputFilter[]{ new InputFilterMinMax(-90, 90)});
editLongitude.setText(Float.toString(city.getLongitude()));
editLongitude.setFilters(new InputFilter[]{ new InputFilterMinMax(-180, 180)});
editCompass.setDegrees(city.getLongitude());
editCompass.setDegrees(city.getAzimuthAngle());
editCompass.setOnCompassDragListener(degrees -> { editAzimuth.setText(Float.toString(Math.round(degrees))); });
editAzimuth.setText(Float.toString(city.getAzimuthAngle()));
editAzimuth.setFilters(new InputFilter[]{ new InputFilterMinMax(0, 360)});
Expand Down

0 comments on commit 757caef

Please sign in to comment.