public static void register(Animator animator, Object speedBar) {
		SpeedBarListener listener = new SpeedBarListener();
		listener.animator = animator;
		listener.speedBar = speedBar;
		Class<?> speedBarClass = speedBar.getClass();
		Method addListener = lookForMethod(speedBarClass, "addAdjustmentListener");
		if (addListener == null) {
			addListener = lookForMethod(speedBarClass, "addChangeListener");
		}
		if (addListener == null) {
			addListener = lookForMethod(speedBarClass, "addChangeListener");
		}
		try {
			listener.getValue = speedBarClass.getMethod("getValue", new Class[0]);
			listener.getMinimum = speedBarClass.getMethod("getMinimum", new Class[0]);
			listener.getMaximum = speedBarClass.getMethod("getMaximum", new Class[0]);
			Object[] args = { listener };
			addListener.invoke(speedBar, args);
		} catch (Exception ex) {
			throw new ErrorException("Illegal speed bar object");
		}
		listener.setSpeed();
	}