Closedown
This commit is contained in:
@@ -43,13 +43,15 @@ public class ManipulatorScan extends Panel {
|
||||
dvpAcqTime.setDevice(scienta.getAcquisitionTime());
|
||||
}
|
||||
|
||||
protected void onTimer(){
|
||||
protected void onTimer(){
|
||||
try{
|
||||
int steps = radioSteps.isSelected() ?
|
||||
(Integer)spinnerSteps.getValue():
|
||||
(int)(Math.abs((Double)spinnerTo.getValue() - (Double)spinnerFrom.getValue()) / (Double)spinnerStepSize.getValue() + 1);
|
||||
int seconds = (int) (Double.valueOf(dvpAcqTime.getLabel().getText()) * steps);
|
||||
textTotalTime.setText(LocalTime.ofSecondOfDay(seconds).toString());
|
||||
(Integer)spinnerSteps.getValue():
|
||||
(int) ((radioRelative.isSelected()? ((Double)spinnerRange.getValue()).intValue():
|
||||
(Math.abs((Double)spinnerTo.getValue() - (Double)spinnerFrom.getValue()) )) / (Double)spinnerStepSize.getValue() + 1);
|
||||
int seconds = (int) (Double.valueOf(dvpAcqTime.getLabel().getText()) * steps);
|
||||
int hours= seconds / (60 * 60);
|
||||
textTotalTime.setText(hours >= 24 ? hours+"h": LocalTime.ofSecondOfDay(seconds).toString());
|
||||
} catch (Exception ex){
|
||||
textTotalTime.setText("");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user