I am having a problem where if i press/touch outside of a field the fieldChanged() event is triggered for the field that has focus.
The layout for my
Just had the same issue. The main problem is that navigationClick and trackwheelClick are called if the touch event is not consumed in touchEvent.
The solution is to call fieldChangeNotify within the *Click methods only if the click was triggered by a non-touch event. Touch events are given a status of 0 so you can check for that as follows:
protected boolean navigationClick( int status, int time ){
if (status != 0) fieldChangeNotify(0);
return true;
}
protected boolean trackwheelClick( int status, int time ){
if (status != 0) fieldChangeNotify(0);
return true;
}
This method means you don't need to track whether the touch event was within the bounds of the field.