final ControlPanel panel = UISession.getControlPanel();
final int percentage = (int) (((currentTime * 100.0) / totalDuration) + 0.5); // jesus
final double seconds = currentTime / 1000.0;
UISession.getControlPanel().seek().setValue(percentage);
panel.seek().setValue(percentage);
panel.current().setText(MediaUtils.calculateTime((int) seconds));
}
}