|
Re: Get old value of radio button group after/while changing [message #1270035 is a reply to message #1269862] |
Wed, 12 March 2014 12:31 |
Matthias Otterbach Messages: 9 Registered: June 2013 |
Junior Member |
|
|
I don't think such a method exists. For other field types I have seen/used code similar to (untested code, just wrote it from scratch):
public class MyRadioButtonGroup extends AbstractRadioButtonGroup<Integer> {
private Integer myOldValue;
public class RadioButton1 extends AbstractRadioButton {
@Override
protected Object getConfiguredRadioValue() {
return Integer.valueOf(1);
}
}
public class RadioButton2 extends AbstractRadioButton {
@Override
protected Object getConfiguredRadioValue() {
return Integer.valueOf(2);
}
}
@Override
protected void execChangedValue() throws ProcessingException {
super.execChangedValue();
if(myOldValue > getValue()) {
// do something
}
// last line of code for this method
myOldValue = getValue();
}
}
If the button group has an initial value (or the value is changed by other methods) of course the variable myOldValue should also be set there.
[Updated on: Wed, 12 March 2014 12:32] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.03620 seconds