@Override public void onComponentTag(Component aComponent, ComponentTag aTag) { for (IBehavior behavior : behaviors) { behavior.onComponentTag(aComponent, aTag); } }
behavior.onComponentTag(this, tag); behavior.onComponentTag(this, tag);
public void setEnabled(boolean isset) { enabled = isset; if (button != null) { button.setEnabled(isset); if (ajax) { AjaxRequestTarget target = AjaxRequestTarget.get(); if (target != null) { if (!isset) { renderAttribute(target, "disabled", "disabled"); } else { target.appendJavascript("Wicket.$('" + button.getMarkupId() + "').removeAttribute('disabled')"); for (IBehavior behavior : button.getBehaviors()) { ComponentTag tag = new ComponentTag("button", XmlTag.OPEN_CLOSE); behavior.onComponentTag(button, tag); for (Map.Entry<String, Object> entry : tag.getAttributes().entrySet()) { renderAttribute(target, entry.getKey(), entry.getValue()); } } } } } } }
behavior.onComponentTag(this, tag); if (behavior.isEnabled(this)) behavior.onComponentTag(this, tag);