Skip to content

Commit

Permalink
Fix replaying
Browse files Browse the repository at this point in the history
  • Loading branch information
ecmnet committed Dec 7, 2021
1 parent b2b372e commit 95173ea
Showing 1 changed file with 9 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -511,12 +511,15 @@ public MAVOpenMapTab setup(IMAVController control) {
});

replay.addListener((v, ov, nv) -> {
Platform.runLater(() -> {
if(nv.intValue()<=5) {
updateMap(true);
} else
updateMap(false);
});
if(isDisabled())
return;

int current_x1_pt = dataService.calculateX0IndexByFactor(nv.floatValue());

if(dataService.getModelList().size()>0 && current_x1_pt > 0)
model = dataService.getModelList().get(current_x1_pt);
else
model = dataService.getCurrent();
});

return this;
Expand Down

0 comments on commit 95173ea

Please sign in to comment.