@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); if (activeStepIndex <= 0) tag.append("class", "disabled", " "); }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("target", target.getObject()); }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); if (ContentDisposition.INLINE == contentDisposition) { tag.put("target", "_blank"); } }
@Override protected void onComponentTag(ComponentTag tag) { Attribute.addClass(tag, "th"); super.onComponentTag(tag); }
@Override protected void onComponentTag(ComponentTag tag) { if (model.getObject().isFolder()) { tag.put("class", "brix-site-folder-node"); } super.onComponentTag(tag); } });
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); if (ContentDisposition.INLINE.equals(contentDisposition)) { tag.put("target", "_blank"); } } }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("onclick", "menuItemPopup(this)"); tag.put("id", "main" + menuId); tag.put("href", "#"); } @Override
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("onclick", "window.open('" + getURL() + "', '_blank" + htmlContent.getMarkupId() + "');"); }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); tag.put("onclick", "menuItemPopup(this)"); tag.put("id", "main" + menuId); tag.put("href", "#"); } @Override
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); if (isLinkEnabled()) { // disable any href attr in markup if (tag.getName().equalsIgnoreCase("a") || tag.getName().equalsIgnoreCase("link") || tag.getName().equalsIgnoreCase("area")) { tag.put("href", "#"); } } else { disableLink(tag); } }
/** * Removes any inline 'onclick' attributes set by Link#onComponentTag(ComponentTag). * * @param tag * the component tag */ @Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); // Ajax links work with JavaScript Event registration tag.remove("onclick"); String tagName = tag.getName(); if (isEnabledInHierarchy() && !("a".equalsIgnoreCase(tagName) || "area".equalsIgnoreCase(tagName) || "link".equalsIgnoreCase(tagName))) { String msg = String.format( "%s must be used only with <a>, <area> or <link> markup elements. " + "The fallback functionality doesn't work for other markup elements. " + "Component path: %s, markup element: <%s>.", AjaxFallbackLink.class.getSimpleName(), getClassRelativePath(), tagName); findMarkupStream().throwMarkupException(msg); } } }
/** * Removes any inline 'onclick' attributes set by Link#onComponentTag(ComponentTag). * * @param tag * the component tag */ @Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); // Ajax links work with JavaScript Event registration tag.remove("onclick"); String tagName = tag.getName(); if (isEnabledInHierarchy() && !("a".equalsIgnoreCase(tagName) || "area".equalsIgnoreCase(tagName) || "link".equalsIgnoreCase(tagName))) { String msg = String.format( "%s must be used only with <a>, <area> or <link> markup elements. " + "The fallback functionality doesn't work for other markup elements. " + "Component path: %s, markup element: <%s>.", AjaxFallbackLink.class.getSimpleName(), getClassRelativePath(), tagName); findMarkupStream().throwMarkupException(msg); } } }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); if ($m.property(model, "fileName") != null) { tag.getAttributes().put("title", $m.property(model, "fileName")); } }
@Override protected void onComponentTag(ComponentTag tag) { super.onComponentTag(tag); String confirm = TileEditorFragment.this.getString("deleteConfirmation"); tag.put("onclick", "if (!confirm('" + confirm + "')) return false; " + tag.getAttributes().get("onclick")); } });