/** * Sets the anchor's target frame (the frame in which navigation will occur * when the link is selected). * * @param target the target frame */ public void setTarget(String target) { getAnchorElement().setTarget(target); }
/** * Gets the anchor's target frame (the frame in which navigation will occur * when the link is selected). * * @return the target frame */ public String getTarget() { return getAnchorElement().getTarget(); }
@Override public void setFocus(boolean focused) { if (focused) { getAnchorElement().focus(); } else { getAnchorElement().blur(); } }
/** * Gets the anchor's href (the url to which it links). * * @return the anchor's href */ public String getHref() { return getAnchorElement().getHref(); }
/** * Sets the anchor's href (the url to which it links). * * @param href the anchor's href */ public void setHref(SafeUri href) { getAnchorElement().setHref(href); }
@Override public int getTabIndex() { return getAnchorElement().getTabIndex(); }
@Override public void setTabIndex(int index) { getAnchorElement().setTabIndex(index); }
@Override public String getName() { return getAnchorElement().getName(); }
@Override public void setName(String name) { getAnchorElement().setName(name); }
@Override public void setAccessKey(char key) { getAnchorElement().setAccessKey(Character.toString(key)); }
/** * Sets the anchor's href (the url to which it links). * * @param href the anchor's href */ public void setHref(@IsSafeUri String href) { getAnchorElement().setHref(href); }
/** * This constructor may be used by subclasses to explicitly use an existing * element. This element must be an <a> element. * * @param element the element to be used */ protected Anchor(Element element) { AnchorElement.as(element); setElement(element); directionalTextHelper = new DirectionalTextHelper(getAnchorElement(), /* is inline */ true); }
setElement(Document.get().createAnchorElement()); setStyleName("gwt-Anchor"); directionalTextHelper = new DirectionalTextHelper(getAnchorElement(), /* is inline */true); if (useDefaultHref) {
/** * Sets the anchor's target frame (the frame in which navigation will occur * when the link is selected). * * @param target the target frame */ public void setTarget(String target) { getAnchorElement().setTarget(target); }
@Override public void setFocus(boolean focused) { if (focused) { getAnchorElement().focus(); } else { getAnchorElement().blur(); } }
/** * Gets the anchor's target frame (the frame in which navigation will occur * when the link is selected). * * @return the target frame */ public String getTarget() { return getAnchorElement().getTarget(); }
@Override public void setFocus(boolean focused) { if (focused) { getAnchorElement().focus(); } else { getAnchorElement().blur(); } }
/** * Sets the anchor's target frame (the frame in which navigation will occur * when the link is selected). * * @param target the target frame */ public void setTarget(String target) { getAnchorElement().setTarget(target); }
/** * Sets the anchor's href (the url to which it links). * * @param href the anchor's href */ public void setHref(SafeUri href) { getAnchorElement().setHref(href); }
/** * This constructor may be used by subclasses to explicitly use an existing * element. This element must be an <a> element. * * @param element the element to be used */ protected Anchor(Element element) { AnchorElement.as(element); setElement(element); directionalTextHelper = new DirectionalTextHelper(getAnchorElement(), /* is inline */ true); }