protected void onMouseMove(ComponentEvent ce) { Component c = findItem(ce.getTarget()); if (c != null && c instanceof Item) { Item item = (Item) c; if (activeItem != item && item.canActivate && item.isEnabled()) { setActiveItem(item, true); } } }
protected Item tryActivate(int start, int step) { for (int i = start, len = getItemCount(); i >= 0 && i < len; i += step) { Component c = getItem(i); if (c instanceof Item) { Item item = (Item) c; if (item.canActivate && item.isEnabled()) { setActiveItem(item, false); return item; } } } return null; }
protected void onMouseOver(ComponentEvent ce) { EventTarget from = ce.getEvent().getRelatedEventTarget(); if (from == null || (Element.is(from) && !DOM.isOrHasChild(getElement(), (Element) Element.as(from)))) { Component c = findItem(ce.getTarget()); if (c != null && c instanceof Item) { Item item = (Item) c; if (activeItem != item && item.canActivate && item.isEnabled()) { setActiveItem(item, true); } } } }