private void updateSimChangeSpeedValues() {
        //Since this is called many times (the GUI responds to many events...some of which
        //aren't changes the simulator needs to know about), we compare the current values with
        //the values the last time this is called...if no change we don't notify the simulator
        int newdelay = ((Integer) simTimeDelaySpinner.getValue()).intValue();
        long newinbetweenperiod = ((Integer) simTimeCycleSpinner.getValue()).longValue();
        boolean newiorc;
        newiorc = !"cycles".equals(simTimeIorCSelect.getSelectedItem());

        int neweventtype;
        int slidervalue = simTimeSlider.getValue();
        if (slidervalue == 0) {
            neweventtype = 1; //run at full speed
        } else if (slidervalue == 1) {
            neweventtype = 0; //realtime
        } else if (slidervalue == 5) {
            neweventtype = 3; //singlestep
        } else {
            neweventtype = 2; //slow it down
        }

        if (newdelay == olddelay && newinbetweenperiod == oldinbetweenperiod && oldiorc == newiorc && oldeventtype == neweventtype) {
            //do nothing, because there has been no change
        } else {
            // TODO: change the actual simulation speed
            olddelay = newdelay;
            oldinbetweenperiod = newinbetweenperiod;
            oldiorc = newiorc;
            oldeventtype = neweventtype;
        }
    }