Example usage for org.apache.wicket Component setOutputMarkupId

List of usage examples for org.apache.wicket Component setOutputMarkupId

Introduction

In this page you can find the example usage for org.apache.wicket Component setOutputMarkupId.

Prototype

public final Component setOutputMarkupId(final boolean output) 

Source Link

Document

Sets whether or not component will output id attribute into the markup.

Usage

From source file:com.googlecode.wicketcontinuouscalendar.wicket15.ContinuousCalendarBehavior.java

License:Apache License

@Override
public void renderHead(final Component component, final IHeaderResponse response) {
    component.setOutputMarkupId(true);
    JsonRenderer renderer = JsonRendererFactory.getInstance().getRenderer();
    includeJavascriptDependencies(response);
    includeCalendarJavascript(response, renderer, component.getMarkupId());
}

From source file:com.locke.library.web.behaviors.focus.FocusBehavior.java

License:Apache License

/**
 * {@inheritDoc}/*  w  w  w  .  ja  va2 s .  c  o m*/
 */
public void bind(Component component) {
    this.component = component;
    component.setOutputMarkupId(true);
}

From source file:com.lyndir.lhunath.opal.wayward.behavior.FocusOnReady.java

License:Open Source License

@Override
public void bind(final Component component) {

    component.setOutputMarkupId(true);
    headerContributor = new IHeaderContributor() {

        @Override/*ww  w. ja  v a2 s .  c  om*/
        public void renderHead(final IHeaderResponse response) {

            if (component.isVisibleInHierarchy()) {
                String id = component.getMarkupId(true);
                response.renderOnDomReadyJavascript(
                        String.format("document.getElementById(%s).focus()", JSUtils.toString(id)));
            }
        }
    };
}

From source file:com.norconex.commons.wicket.behaviors.RelativeOverlay.java

License:Apache License

public RelativeOverlay(Component anchorComponent) {
    super();/*from  w w w . j  a va2  s .c om*/
    this.anchorComponent = anchorComponent;
    anchorComponent.setOutputMarkupId(true);
}

From source file:com.norconex.commons.wicket.bootstrap.tooltip.BootstrapTooltip.java

License:Apache License

@Override
public void bind(Component component) {
    if (text != null) {
        String p = null;/*from w  ww .  j  a  v a 2  s .c  o  m*/
        if (placement == null) {
            p = Placement.AUTO.toString().toLowerCase();
        } else {
            p = placement.toString().toLowerCase();
        }
        component.add(new AttributeModifier("data-toggle", "tooltip"));
        component.add(new AttributeModifier("data-placement", p));
        component.add(new AttributeModifier("data-original-title", text));
        component.add(new AttributeModifier("title", text));
        component.setOutputMarkupId(true);
    }
}

From source file:com.norconex.jefmon.instance.tree.JobsTableTree.java

License:Apache License

@Override
public Component newNodeComponent(String id, IModel<JobStatusTreeNode> model) {
    Component node = new Node<JobStatusTreeNode>(id, this, model) {
        private static final long serialVersionUID = -5096730351024888675L;

        @Override//from  w w w .  j a  va 2  s. c o  m
        protected Component createContent(String id, IModel<JobStatusTreeNode> model) {
            return newContentComponent(id, model);
        }

        @Override
        protected String getCollapsedStyleClass() {
            return "jef-tree-node-collapsed";
        }

        @Override
        protected String getExpandedStyleClass(JobStatusTreeNode t) {
            return "jef-tree-node-expanded";
        }

        @Override
        protected String getOtherStyleClass() {
            return super.getOtherStyleClass();
        }

        @Override
        protected void onBeforeRender() {
            super.onBeforeRender();
        }
    };
    node.setOutputMarkupId(true);
    return node;
}

From source file:com.premiumminds.webapp.wicket.behaviours.DefaultFocusBehaviour.java

License:Open Source License

@Override
public void bind(Component component) {
    super.bind(component);
    component.setOutputMarkupId(true);
}

From source file:com.premiumminds.webapp.wicket.behaviours.DisableSubmitOnEnterBehaviour.java

License:Open Source License

@Override
public void onConfigure(Component component) {
    super.onConfigure(component);
    component.setOutputMarkupId(true);
}

From source file:com.premiumminds.webapp.wicket.bootstrap.datepicker.BootstrapDatePickerBehaviour.java

License:Open Source License

@Override
public void onConfigure(Component component) {
    super.onConfigure(component);

    component.setOutputMarkupId(true);
}

From source file:com.premiumminds.webapp.wicket.datepicker.DatePicker.java

License:Open Source License

@Override
public void bind(Component component) {
    component.setOutputMarkupId(true);
    getDatePattern();
}