/** * Determines whether or not the widget is read-only. * * @return <code>true</code> if the widget is currently read-only, * <code>false</code> if the widget is currently editable */ public boolean isReadOnly() { return getElement().getPropertyBoolean("readOnly"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
Element $wnd = (Element)Document.get().<Element>cast().getPropertyObject("defaultView"); boolean mybool = $wnd.getPropertyBoolean("mybool");
@Override public boolean isEnabled() { return !getElement().getPropertyBoolean(DISABLED); } }
@Override public boolean isEnabled() { return !getElement().getPropertyBoolean(DISABLED); } }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/*************************************** * @see HasEnabled#isEnabled() */ @Override public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/** * Determines whether or not the widget is read-only. * * @return <code>true</code> if the widget is currently read-only, * <code>false</code> if the widget is currently editable */ public boolean isReadOnly() { return getElement().getPropertyBoolean("readOnly"); }
/** * Determines whether or not the widget is read-only. * * @return <code>true</code> if the widget is currently read-only, * <code>false</code> if the widget is currently editable */ public boolean isReadOnly() { return getElement().getPropertyBoolean("readOnly"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
/** * Gets whether this widget is enabled. * * @return <code>true</code> if the widget is enabled */ public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); } /**
public boolean isEnabled() { return !getElement().getPropertyBoolean("disabled"); }
Element window = ScriptInjector.TOP_WINDOW.cast(); window.setPropertyJSO("key_jso", JsArray.createArray()); JavaScriptObject jso = window.getPropertyJSO("key_jso") window.setPropertyBoolean("key_boolean", true); boolean b = window.getPropertyBoolean("key_boolean") // and the same with: // setPropertyDouble, getPropertyDouble // setPropertyInt, getPropertyInt // setPropertyString, getPropertyString // setPropertyObject, getPropertyObject
@SuppressWarnings("unchecked") @Override public T getValue() { final String inputType = getElement().getPropertyString("type"); final Class<?> valueType = getValueClassForInputType(inputType); if (Boolean.class.equals(valueType)) { return (T) (Boolean) getElement().getPropertyBoolean("checked"); } else if (String.class.equals(valueType)) { final Object rawValue = getElement().getPropertyObject("value"); return (T) (rawValue != null ? rawValue : ""); } else { throw new RuntimeException("Unrecognized input element type [" + inputType + "]"); } }
@SuppressWarnings("unchecked") @Override public T getValue() { final String inputType = getElement().getPropertyString("type"); final Class<?> valueType = getValueClassForInputType(inputType); if (Boolean.class.equals(valueType)) { return (T) (Boolean) getElement().getPropertyBoolean("checked"); } else if (String.class.equals(valueType)) { final Object rawValue = getElement().getPropertyObject("value"); return (T) (rawValue != null ? rawValue : ""); } else { throw new RuntimeException("Unrecognized input element type [" + inputType + "]"); } }
@Override protected void onClick(ComponentEvent ce) { super.onClick(ce); if (readOnly) { ce.stopEvent(); return; } boolean v = getInputEl().dom.getPropertyBoolean("checked"); setValue(v); }
|| ce.getTarget().getPropertyBoolean("disabled")) { ce.preventDefault();