display.asyncExec(new Runnable() { public void run() { songProgressBar.setCurrentTime(currentTime); songProgressBar.setTotalTime(finalTime); } });
  public void positionUpdated(int position, int length) {    final int currentTime = position;    int checkedTime;    if(length == 0) {      checkedTime = (int)playThread.getCurrentTrack().getPlayingTime();    }    else {      checkedTime = length;    }        final int finalTime = checkedTime;        display.asyncExec(new Runnable() {      public void run() {        songProgressBar.setCurrentTime(currentTime);        songProgressBar.setTotalTime(finalTime);      }    });  }