I’m kind of new to all this.
I have 2 TextFields.
public TextField t1 = new TextField();
public TextField t2 = new TextField();
I have 1 shortcutListener
ShortcutListener enter = new ShortcutListener(“enter”,
KeyCode.ENTER, null) {
@Override
public void handleAction(Object sender, Object target) {
///HOW DO I CHECK WITCH TextField CALLED IT
///something like
if(t1){
DO SOMETHING
}else{
DO SOMETHING ELSE
}
}
};
t1.addShortcutListener(enter);
t2.addShortcutListener(enter);
I can’t figure out from what Object (sender,target) I have to take what info.