Synchronised GUI with VisualiserInput thread.
- Made StreamedCourse extend Observable - Initialised StartController after data pulled from network - Moved VisualiserInput to visualiser module - Deleted Networking subpackage from visualiser module #story[782]
This commit is contained in:
@@ -31,6 +31,10 @@ public class StreamedBoat extends Boat {
|
||||
this.init();
|
||||
}
|
||||
|
||||
public int getSourceID() {
|
||||
return sourceID;
|
||||
}
|
||||
|
||||
/**
|
||||
* Calculates the azimuth of the travel via heading of the boat
|
||||
*
|
||||
|
||||
@@ -10,7 +10,7 @@ import java.util.*;
|
||||
/**
|
||||
* Created by jjg64 on 21/04/17.
|
||||
*/
|
||||
public class StreamedCourse implements RaceDataSource {
|
||||
public class StreamedCourse extends Observable implements RaceDataSource {
|
||||
StreamedCourseXMLReader streamedCourseXMLReader = null;
|
||||
BoatXMLReader boatXMLReader = null;
|
||||
RegattaXMLReader regattaXMLReader = null;
|
||||
|
||||
@@ -50,7 +50,7 @@ public class StreamedRace extends Race {
|
||||
/**
|
||||
* Checks the position of the boat, this updates the boats current position.
|
||||
*
|
||||
* @param boat Boat that the postion is to be updated for.
|
||||
* @param boat Boat that the position is to be updated for.
|
||||
* @param timeElapsed Time that has elapse since the start of the the race.
|
||||
* @see BoatInRace
|
||||
*/
|
||||
@@ -73,10 +73,10 @@ public class StreamedRace extends Race {
|
||||
*/
|
||||
protected void updatePosition(Boat boat, int millisecondsElapsed) {
|
||||
//TODO Grab info from network
|
||||
// setPostiion(boat, coordinate);
|
||||
// setPosition(boat, coordinate);
|
||||
}
|
||||
|
||||
protected void setPostion(Boat boat, GPSCoordinate coordinate) {
|
||||
protected void setPosition(Boat boat, GPSCoordinate coordinate) {
|
||||
boat.setCurrentPosition(coordinate);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user