@Override boolean setTabItemFocus () { int index = 0; while (index < items.length) { ToolItem item = items [index]; if (item != null && (item.style & SWT.SEPARATOR) == 0) { if (item.getEnabled ()) break; } index++; } if (index == items.length) return false; return super.setTabItemFocus (); }
boolean setTabGroupFocus () { if (isTabItem ()) return setTabItemFocus (); boolean takeFocus = (style & SWT.NO_FOCUS) == 0; if ((state & CANVAS) != 0) takeFocus = hooksKeys (); if (takeFocus && setTabItemFocus ()) return true; Control [] children = _getChildren (); for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && child.setTabItemFocus ()) return true; } return false; }
@Override boolean setTabGroupFocus (boolean next) { if (isTabItem ()) return setTabItemFocus (next); boolean takeFocus = (style & SWT.NO_FOCUS) == 0; if ((state & CANVAS) != 0) takeFocus = hooksKeys (); if (socketHandle != 0) takeFocus = true; if (takeFocus && setTabItemFocus (next)) return true; Control [] children = _getChildren (); for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && child.setTabItemFocus (next)) return true; } return false; }
@Override boolean setTabGroupFocus (boolean next) { if (isTabItem ()) return setTabItemFocus (next); boolean takeFocus = (style & SWT.NO_FOCUS) == 0; if ((state & CANVAS) != 0) takeFocus = hooksKeys (); if (socketHandle != 0) takeFocus = true; if (takeFocus && setTabItemFocus (next)) return true; Control [] children = _getChildren (); for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && child.setTabItemFocus (next)) return true; } return false; }
@Override boolean setTabGroupFocus (boolean next) { if (isTabItem ()) return setTabItemFocus (next); boolean takeFocus = (style & SWT.NO_FOCUS) == 0; if ((state & CANVAS) != 0) takeFocus = hooksKeys (); if (socketHandle != 0) takeFocus = true; if (takeFocus && setTabItemFocus (next)) return true; Control [] children = _getChildren (); for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && child.setTabItemFocus (next)) return true; } return false; }
@Override boolean setTabGroupFocus () { if (isTabItem ()) return setTabItemFocus (); boolean takeFocus = (style & SWT.NO_FOCUS) == 0; if ((state & CANVAS) != 0) { takeFocus = hooksKeys (); if ((style & SWT.EMBEDDED) != 0) takeFocus = true; } if (takeFocus && setTabItemFocus ()) return true; Control [] children = _getChildren (); for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && child.setRadioFocus (true)) return true; } for (int i=0; i<children.length; i++) { Control child = children [i]; if (child.isTabItem () && !child.isTabGroup () && child.setTabItemFocus ()) { return true; } } return false; }