public Boolean getValue(Component cmp) { return cmp.isVisible(); } });
public int size() { int size = 0; for (Component c : children) { if (c.isVisible()) ++size; } return size; }
/** Returns whether this component is real visible (all its parents * are visible). * <p>Note: true is returned if comp is null. * In other words, it can be used to examine parent's real visibility * even if it is a root component, * such as <code>Components.isRealVisible(getParent())</code>. * @see Component#isVisible */ public static boolean isRealVisible(Component comp) { for (; comp != null; comp = comp.getParent()) if (!comp.isVisible()) return false; return true; }
/*package*/ boolean isRealVisible() { if (!isVisible()) return false; Component comp = getParent(); return comp == null || ((comp instanceof Treechildren) ? ((Treechildren) comp).isRealVisible() : comp.isVisible()); }
/** Makes sure it is not draggable. */ private void checkOverlappable(int mode) { if (!"false".equals(getDraggable())) throw new UiException("Draggable window cannot be modal, overlapped, popup, or highlighted: " + this); if (mode == MODAL) for (Component comp = this; (comp = comp.getParent()) != null;) if (!comp.isVisible()) throw new UiException( "One of its ancestors, " + comp + ", is not visible, so unable to be modal or highlighted"); }
.append('\''); if (!comp.isVisible()) { if (first) first = false;
/*package*/ boolean isRealVisible() { if (!isVisible()) return false; Component comp = getParent(); if (comp == null) return true; if (!(comp instanceof Treeitem)) return comp.isVisible(); Treeitem item = (Treeitem) comp; return item.isOpen() && item.isRealVisible(); }
/** * Sets the current active item in this menupopup. * * @param childIndex the index of menupopup children * @since 8.6.0 */ public void setActive(int childIndex) { List<Component> children = getChildren(); int nChild = children.size(); if (childIndex < 0 || childIndex >= nChild) throw new WrongValueException("Out of bound: " + childIndex + " while size=" + nChild); Component child = children.get(childIndex); if (!(child instanceof Menuitem) && !(child instanceof Menu)) throw new WrongValueException("Unsupported child for setActive: " + child); if (((Disable) child).isDisabled() || !child.isVisible()) throw new UiException("Set active on disabled or invisible child: " + child); response("menupopup", new AuInvoke(this, "setActive", childIndex)); } }
if (pgsz == 0) break; if (item.isVisible() && item instanceof Listitem) { if (--ofs < 0) { --pgsz;
if (cmp.isVisible()) { alertCount++;
private boolean validateInputs() { Clients.clearWrongValue(inputs); if (radNo.isChecked()) { syncInputs(); return true; } if (!radYes.isChecked()) { Clients.wrongValue(rgIndicated, "You must provide an indication."); } else if (cboGoal.getSelectedItem() == null) { Clients.wrongValue(cboGoal, "You must provide a goal."); } else if (pnlGoalOther.isVisible() && cboMin.getSelectedItem() == null) { Clients.wrongValue(cboMin, "You must provide a minimum."); } else if (pnlGoalOther.isVisible() && cboMax.getSelectedItem() == null) { Clients.wrongValue(cboMax, "You must provide a maximum."); } else if (cboDuration.getSelectedItem() == null) { Clients.wrongValue(cboDuration, "You must provide a duration."); } else if (datStart.getValue() == null) { Clients.wrongValue(datStart, "You must provide a starting date."); } else if (wbProvider.getSelectedData() == null) { Clients.wrongValue(wbProvider, "You must specify a provider."); } else { syncInputs(); return true; } return false; }
boolean chvisible = child.isVisible(); if (chvisible) { int splen = spacing != null ? spacing.length(): 0;
boolean chvisible = child.isVisible(); if (chvisible) { int splen = spacing != null ? spacing.length(): 0;