Package org.apache.myfaces.tobago.taglib.component

Examples of org.apache.myfaces.tobago.taglib.component.ButtonTag


  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Previous" : label); // todo: i18n
    button.setAction("#{" + wizard + ".previous}");
    button.setDisabled("#{!" + wizard + ".previousAvailable}");
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here


  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Finish Wizard" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".finish}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".finishAvailable}").replace("#{", "#{!"));
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Cancel Wizard" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".cancel}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".finishAvailable}").replace("#{", "#{!"));
    button.setImmediate(Boolean.TRUE.toString());
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

        gridLayoutTag.doEndTag();

        facetTag.doEndTag();

        for (WizardStep info : course) {
            ButtonTag button = new ButtonTag();
            button.setPageContext(pageContext);
            button.setParent(panel);
            button.setAction(info.getOutcome());
            button.setActionListener("#{" + wizard + ".gotoStep}");
            button.setLabel(info.getTitle());
            button.doStartTag();

            AttributeTag step = new AttributeTag();
            step.setPageContext(pageContext);
            step.setParent(button);
            step.setName("step");
            step.setValue("" + info.getIndex());
            step.doStartTag();
            step.doEndTag();

            button.doEndTag();
        }
        OutTag spacer = new OutTag();
        spacer.setPageContext(pageContext);
        spacer.setParent(panel);
        spacer.setValue("#{" + wizard + ".index}");
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Next" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".next}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".nextAvailable}").replace("#{", "#{!"));
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Next" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".next}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".nextAvailable}").replace("#{", "#{!"));
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Cancel Wizard" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".cancel}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".finishAvailable}").replace("#{", "#{!"));
    button.setImmediate(Boolean.TRUE.toString());
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

        gridLayoutTag.doEndTag();

        facetTag.doEndTag();

        for (WizardStep info : course) {
            ButtonTag button = new ButtonTag();
            button.setPageContext(pageContext);
            button.setParent(panel);
            button.setAction(info.getOutcome());
            button.setActionListener("#{" + wizard + ".gotoStep}");
            button.setLabel(info.getTitle());
            button.doStartTag();

            AttributeTag step = new AttributeTag();
            step.setPageContext(pageContext);
            step.setParent(button);
            step.setName("step");
            step.setValue("" + info.getIndex());
            step.doStartTag();
            step.doEndTag();

            button.doEndTag();
        }
        OutTag spacer = new OutTag();
        spacer.setPageContext(pageContext);
        spacer.setParent(panel);
        spacer.setValue("#{" + wizard + ".index}");
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Previous" : label); // todo: i18n
    button.setAction("#{" + wizard + ".previous}");
    button.setDisabled("#{!" + wizard + ".previousAvailable}");
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

  @Override
  public int doStartTag() throws JspException {

    int result = super.doStartTag();

    ButtonTag button = new ButtonTag();
    button.setPageContext(pageContext);
    button.setParent(getParent());
    button.setLabel(StringUtils.isEmpty(label) ? "Finish Wizard" : label); // todo: i18n
    button.setAction(action);
    button.setActionListener("#{" + wizard + ".finish}");
    button.setDisabled(Boolean.toString(action == null));
//    button.setDisabled(controller.replace("}", ".finishAvailable}").replace("#{", "#{!"));
    button.doStartTag();
    button.doEndTag();

    return result;
  }
View Full Code Here

TOP

Related Classes of org.apache.myfaces.tobago.taglib.component.ButtonTag

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.