implemented basic single client proof of concept for the chat history #story[1246]

This commit is contained in:
Peter Galloway
2017-08-25 17:57:45 +12:00
parent 5fb8a0c2c1
commit 75155fe481
2 changed files with 38 additions and 1 deletions
@@ -25,6 +25,8 @@ import javafx.scene.control.Button;
import javafx.scene.control.CheckBox;
import javafx.scene.control.ComboBox;
import javafx.scene.control.Slider;
import javafx.scene.control.TextArea;
import javafx.scene.control.TextField;
import javafx.scene.layout.AnchorPane;
import javafx.scene.layout.Pane;
import javafx.scene.layout.VBox;
@@ -53,6 +55,12 @@ import seng302.visualiser.fxObjects.BoatObject;
*/
public class RaceViewController extends Thread implements ImportantAnnotationDelegate {
@FXML
private Button chatSend;
@FXML
private TextArea chatHistory;
@FXML
private TextField chatInput;
@FXML
private LineChart<String, Double> raceSparkLine;
@FXML
@@ -622,4 +630,9 @@ public class RaceViewController extends Thread implements ImportantAnnotationDel
this.courseData = raceData;
gameView.updateBorder(raceData.getCourseLimit());
}
@FXML
public void onSendAction() {
chatHistory.setText(chatHistory.getText() + chatInput.getText() + '\n');
}
}