/** * Sets the value of the attribute with the given name to the given value. */ public void setAttribute(String name, String value) { JQMCommon.setAttribute(this, name, value); }
/** * @param value - true will collapse all panels. This requires the collapsible option to be true. */ public void setCollapseAll(boolean value) { if (value) JQMCommon.setAttribute(this, DATA_ACTIVE, "false"); else JQMCommon.setAttribute(this, DATA_ACTIVE, null); }
public static void setPopupPos(Element elt, String value) { if (value == null) { setAttribute(elt, DATA_POPUP_POSITION, null); return; } setAttribute(elt, DATA_POPUP_POSITION, value); }
/** * Sets the theme swatch for the slider */ public void setTrackTheme(String theme) { JQMCommon.setAttribute(input, "data-track-theme", theme); }
/** * @param value - The type of event that the tabs should react to in order to activate the tab. * To activate on hover, use "mouseover" {@link JQMTabs#ACTIVATE_TAB_ON_HOVER}. * <br> Default value is "click" {@link JQMTabs#ACTIVATE_TAB_ON_CLICK} . */ public void setTabEvent(String value) { JQMCommon.setAttribute(this, "data-event", value); }
/** * Sets the value of the attribute with the given name to the given value. */ public void setAttribute(String name, String value) { JQMCommon.setAttribute(this, name, value); }
/** * @param value - The type of event that the tabs should react to in order to activate the tab. * To activate on hover, use "mouseover" {@link JQMTabs#ACTIVATE_TAB_ON_HOVER}. * <br> Default value is "click" {@link JQMTabs#ACTIVATE_TAB_ON_CLICK} . */ public void setTabEvent(String value) { JQMCommon.setAttribute(this, "data-event", value); }
/** * Sets this select to allow multiple selections. */ public void setMultiple(boolean value) { JQMCommon.setAttribute(select, "multiple", value ? "multiple" : null); }
/** * @param value - Multiple types supported: * <br> Boolean: Enable or disable all tabs. * <br> Array: An array containing the zero-based indexes of the tabs that should be disabled, * e.g., [ 0, 2 ] would disable the first and third tab. */ public void setTabDisabled(String value) { JQMCommon.setAttribute(this, "data-disabled", value); }
public static void setPopupPos(Element elt, String value) { if (value == null) { setAttribute(elt, DATA_POPUP_POSITION, null); return; } setAttribute(elt, DATA_POPUP_POSITION, value); }
public static void setDataFilter(Element elt, String filterSelector) { if (filterSelector == null || filterSelector.isEmpty()) { setAttribute(elt, DATA_FILTER, null); setAttribute(elt, DATA_INPUT, null); } else { setAttribute(elt, DATA_FILTER, "true"); setAttribute(elt, DATA_INPUT, filterSelector); } }
/** * The URL of the source image * * @param src */ public void setSrc(String src) { JQMCommon.setAttribute(img, "src", src); refreshPositioning(); }
public static void setShadowEx(Element elt, boolean value) { if (value) { elt.addClassName(STYLE_UI_SHADOW); setAttribute(elt, DATA_SHADOW, null); } else { elt.removeClassName(STYLE_UI_SHADOW); setAttribute(elt, DATA_SHADOW, "false"); } }
public static void setThemeEx(Element elt, String themeName, String prefix, String... excludes) { String old = getThemeEx(elt, prefix, excludes); if (old != null && !old.isEmpty()) { elt.removeClassName(prefix + old); } if (themeName != null && !themeName.isEmpty()) { elt.addClassName(prefix + themeName); } setAttribute(elt, DATA_THEME, themeName); }
public static void setThemeEx(Element elt, String themeName, String prefix, String... excludes) { String old = getThemeEx(elt, prefix, excludes); if (old != null && !old.isEmpty()) { elt.removeClassName(prefix + old); } if (themeName != null && !themeName.isEmpty()) { elt.addClassName(prefix + themeName); } setAttribute(elt, DATA_THEME, themeName); }
public static void setInlineEx(Element elt, boolean inline, String className) { if (inline) { elt.addClassName(className); setAttribute(elt, DATA_INLINE, "true"); } else { elt.removeClassName(className); removeAttribute(elt, DATA_INLINE); } }
public static void setInlineEx(Element elt, boolean inline, String className) { if (inline) { elt.addClassName(className); setAttribute(elt, DATA_INLINE, "true"); } else { elt.removeClassName(className); removeAttribute(elt, DATA_INLINE); } }
public static void setMiniEx(Element elt, boolean mini) { if (mini) { elt.addClassName(STYLE_UI_MINI); setAttribute(elt, DATA_MINI, "true"); } else { elt.removeClassName(STYLE_UI_MINI); removeAttribute(elt, DATA_MINI); } }
public void setStep(Double value) { String s = doubleToNiceStr(value); JQMCommon.setAttribute(input, "step", s); ignoreChange = true; try { refreshStep(input.getElement().getId(), s); } finally { ignoreChange = false; } }
public JQMColumnToggle() { Element table = getElement(); JQMCommon.setDataRole(table, "table"); JQMCommon.setAttribute(table, "data-mode", TOGGLE); setResponsive(STD_RESPONSIVE); setRowLines(STD_ROW_LINES); setRowStripes(STD_ROW_STRIPES); }