Skip to content

Commit 889ee74

Browse files
committed
Replay fixes
1 parent 1d30b08 commit 889ee74

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

Diff for: MAVGCL/src/main/java/com/comino/flight/ui/widgets/charts/line/LineChartWidget.java

+4-6
Original file line numberDiff line numberDiff line change
@@ -568,7 +568,7 @@ private void initialize() {
568568
replay.addListener((v, ov, nv) -> {
569569
if(isDisabled())
570570
return;
571-
//refreshRequest = true;
571+
572572
if(nv.intValue()<0) {
573573
current_x0_pt = dataService.calculateX0Index(-nv.intValue());
574574
if(current_x0_pt>0)
@@ -720,8 +720,7 @@ public LineChartWidget setup(IMAVController control, int id) {
720720
});
721721

722722
state.getReplayingProperty().addListener((o,ov,nv) -> {
723-
setXResolution(timeFrame.get());
724-
updateGraph(true,0);
723+
updateGraph(true,1);
725724
});
726725

727726
KeyFigureMetaData k1 = meta.getKeyFigureMap().get(prefs.getInt(MAVPreferences.LINECHART_FIG_1+id,0));
@@ -799,9 +798,7 @@ public BooleanProperty getIsScrollingProperty() {
799798
public void refreshChart() {
800799
// current_x0_pt = dataService.calculateX0IndexByFactor(1);
801800
setXResolution(timeFrame.get());
802-
if(!isDisabled()) {
803801
updateRequest();
804-
}
805802
}
806803

807804
public void saveAsPng(String path) {
@@ -859,7 +856,7 @@ else if(frame >= 30) {
859856
refresh_step = REFRESH_RATE / dataService.getCollectorInterval_ms();
860857

861858
if(!isDisabled()) {
862-
updateRequest();
859+
// updateRequest();
863860
Platform.runLater(() -> {
864861
xAxis.setLabel("Seconds ("+resolution_ms+"ms)");
865862
});
@@ -872,6 +869,7 @@ private void updateRequest() {
872869

873870
if(state==null || id == -1 || isDisabled() || refreshRequest)
874871
return;
872+
875873
refreshRequest = true;
876874
if(!state.getReplayingProperty().get())
877875
updateGraph(refreshRequest,0);

0 commit comments

Comments
 (0)