MacControlEvent macEvent= (MacControlEvent) callData; oldValue= OS.GetControl32BitValue(handle)-1; handleSelectionChange(macEvent.getPartCode()-1);
int newIndex= OS.GetControl32BitValue(handle)-1; for (int i= 0; i < items.length; i++) { if (i != newIndex && items[i] != null) { Control control = items[i].control; if (control != null && !control.isDisposed ()) control.setVisible (false); } } TabItem item = null; if (newIndex != -1) item = items [newIndex]; if (item != null) { Control control = item.control; if (control != null && !control.isDisposed ()) { control.setBounds (getClientArea ()); control.setVisible (true); } } Event event = new Event (); event.item = item; postEvent (SWT.Selection, event); redraw();
int processSelection (Object callData) {	MacControlEvent macEvent= (MacControlEvent) callData;	oldValue= OS.GetControl32BitValue(handle)-1;	handleSelectionChange(macEvent.getPartCode()-1);	return OS.noErr;}