/** * Sets this button to be a dialog button. This changes the look and feel * of the page that is loaded as a consequence of clicking on this button. */ public void setDialog(boolean dialog) { setRel(dialog ? Mobile.DATA_ROLE_DIALOG : null); }
@Override public JQMButton withCorners(boolean corners) { setCorners(corners); return this; }
public JQMButtonGroup(JQMButton... buttons) { this(); for (JQMButton button : buttons) add(button); }
private void checkAlwaysHover() { if (isAttached()) { if (alwaysHover) { prepareHoverStyle(); applyHoverStyle(); } else { removeHoverStyle(); } } }
/** * Internal method for creating a button */ protected JQMButton createButton(String text, String url, DataIcon icon) { JQMButton button = new JQMButton(text, url); if (icon != null) button.withBuiltInIcon(icon); return button; }
/** Applies the drop shadow icon style to the select button if set to true. */ @Override public JQMButton withIconShadow(boolean shadow) { setIconShadow(shadow); return this; }
@Override public JQMButton withIconURL(String src) { setIconURL(src); return this; }
/** * If set to true then renders a smaller version of the standard-sized element. */ @Override public JQMButton withMini(boolean mini) { setMini(mini); return this; }
/** * @param value - if true button always be highlighted as hover. */ public void setAlwaysHover(boolean value) { if (alwaysHover == value) return; alwaysHover = value; checkAlwaysHover(); }
private void checkAlwaysHover() { if (isAttached()) { if (alwaysHover) { prepareHoverStyle(); applyHoverStyle(); } else { removeHoverStyle(); } } }
/** * @param popup - true if this button is set to load a popup */ public void setPopup(boolean popup) { setRel(popup ? "popup" : null); }
@Override public JQMButton withCorners(boolean corners) { setCorners(corners); return this; }
public JQMButtonGroup(JQMButton... buttons) { this(); for (JQMButton button : buttons) add(button); }
/** Applies the drop shadow icon style to the select button if set to true. */ @Override public JQMButton withIconShadow(boolean shadow) { setIconShadow(shadow); return this; }
@Override public JQMButton withRel(String rel) { setRel(rel); return this; }
@Override public JQMButton withCorners(boolean corners) { setCorners(corners); return this; }
@Override public JQMButton withRel(String rel) { setRel(rel); return this; }
/** * Sets this button to be a dialog button. This changes the look and feel * of the page that is loaded as a consequence of clicking on this button. */ public void setDialog(boolean dialog) { setRel(dialog ? Mobile.DATA_ROLE_DIALOG : null); }
/** * Short cut for withRel("external"); */ public void setExternal(boolean external) { setRel(external ? "external" : null); }
@Override public JQMButton withRel(String rel) { setRel(rel); return this; }