if (result == OS.noErr) return result;
int kEventTextInputUnicodeForKeyEvent (int nextHandler, int theEvent, int userData) {	int result = super.kEventTextInputUnicodeForKeyEvent (nextHandler, theEvent, userData);	if (focusIndex == -1) return result;	if (result == OS.noErr) return result;	int [] keyboardEvent = new int [1];	OS.GetEventParameter (theEvent, OS.kEventParamTextInputSendKeyboardEvent, OS.typeEventRef, null, keyboardEvent.length * 4, null, keyboardEvent);	int [] keyCode = new int [1];	OS.GetEventParameter (keyboardEvent [0], OS.kEventParamKeyCode, OS.typeUInt32, null, keyCode.length * 4, null, keyCode);	switch (keyCode [0]) {		case 36: /* Return */		case 49: /* Space */		case 76: /* Enter */			Event event = new Event ();			event.text = ids [focusIndex];			sendEvent (SWT.Selection, event);			break;		case 48: /* Tab */			int [] modifiers = new int [1];			OS.GetEventParameter (keyboardEvent [0], OS.kEventParamKeyModifiers, OS.typeUInt32, null, 4, null, modifiers);			boolean next = (modifiers [0] & OS.shiftKey) == 0;			if (next) {				if (focusIndex < offsets.length - 1) {					focusIndex++;					redraw ();				}			} else {				if (focusIndex > 0) {					focusIndex--;					redraw ();				} 			}			break;				}	return result;}