Package org.primefaces.component.tabview

Examples of org.primefaces.component.tabview.Tab


    int stepToGo = Integer.valueOf(facesContext.getExternalContext().getRequestParameterMap().get("stepToGo")).intValue();
    int currentStep = Integer.valueOf(facesContext.getExternalContext().getRequestParameterMap().get("currentStep")).intValue();
    int tabIndexToDisplay = success ? stepToGo : currentStep;
    wizard.setStep(tabIndexToDisplay)//save state
   
    Tab tabToDisplay = (Tab) wizard.getChildren().get(tabIndexToDisplay);
   
    ServletResponse response = (ServletResponse) facesContext.getExternalContext().getResponse();
    response.setContentType("text/xml");
   
    writer.write("<wizardresponse>");
View Full Code Here


   
    for (int i = 0; i < wizard.getChildren().size(); i++) {
      UIComponent kid = wizard.getChildren().get(i);
     
      if(kid.isRendered()) {
        Tab tab = (Tab) kid;
       
        writer.startElement("div", wizard);
        writer.writeAttribute("id", clientId + "_tab" + i, null);
        writer.writeAttribute("class", "pf-wizard-tab", null);
       
View Full Code Here

    writer.write(",navHeaders:new Array(");
   
    for(Iterator<UIComponent> kids = slider.getChildren().iterator(); kids.hasNext();) {
      UIComponent kid = kids.next();
      if(kid.isRendered() && kid instanceof Tab) {
        Tab tab = (Tab) kid;
       
        writer.write("'" + tab.getTitle() + "'");
       
        if(kids.hasNext())
          writer.write(",");
      }
    }
View Full Code Here

   
    writer.startElement("ul", slider);
   
    for(UIComponent kid : slider.getChildren()) {
      if(kid.isRendered() && kid instanceof Tab) {
        Tab tab = (Tab) kid;
       
        writer.startElement("li", null);
        renderChild(facesContext, tab);
        writer.endElement("li");
      }
View Full Code Here

      int currentStep = Integer.valueOf(facesContext.getExternalContext().getRequestParameterMap().get("currentStep")).intValue();
     
      if(stepToGo < currentStep) {
        facesContext.renderResponse();
      } else if(stepToGo > currentStep) {
        Tab tabToProcess = (Tab) getChildren().get(currentStep);
       
        tabToProcess.processDecodes(facesContext);
      }
    } else {
      super.processDecodes(facesContext);
    }
    }
View Full Code Here

   
    for(Iterator<UIComponent> kids = accordionPanel.getChildren().iterator(); kids.hasNext();) {
      UIComponent kid = (UIComponent) kids.next();
     
      if(kid.isRendered() && kid instanceof Tab) {
        Tab tab = (Tab) kid;
       
        writer.startElement("li", null);
        writer.startElement("p", null);
        if(tab.getTitle() != null)
          writer.write(tab.getTitle());
        writer.endElement("p");
       
        writer.startElement("div", null);
        renderChild(facesContext, tab);
        writer.endElement("div");
View Full Code Here

   
    boolean firstStep = true;
    for(int i = 0; i < wizard.getChildCount(); i++) {
      UIComponent child = wizard.getChildren().get(i);
      if(child instanceof Tab && child.isRendered()) {
        Tab tab = (Tab) child;
       
        if(!firstStep)
          writer.write(",");
        else
          firstStep = false;
       
        writer.write("'" + tab.getId() + "'");
      }
    }
    writer.write("]");
   
    //Navigators
View Full Code Here

    ResponseWriter writer = facesContext.getResponseWriter();
   
    boolean contentWritten = false;
    for(UIComponent child : wizard.getChildren()) {
      if(child instanceof Tab && child.isRendered()) {
        Tab tab = (Tab) child;
       
        writer.startElement("div", null);
        writer.writeAttribute("id", tab.getId(), null);
        writer.writeAttribute("class", "step", null);
       
        if((wizard.getStep() == null || tab.getId().equals(wizard.getStep())) && !contentWritten) {
          renderChildren(facesContext, tab);
          contentWritten = true;
        }
       
        writer.endElement("div");
View Full Code Here

    writer.write(",navHeaders:new Array(");
   
    for(Iterator<UIComponent> kids = slider.getChildren().iterator(); kids.hasNext();) {
      UIComponent kid = kids.next();
      if(kid.isRendered() && kid instanceof Tab) {
        Tab tab = (Tab) kid;
       
        writer.write("'" + tab.getTitle() + "'");
       
        if(kids.hasNext())
          writer.write(",");
      }
    }
View Full Code Here

   
    writer.startElement("ul", slider);
   
    for(UIComponent kid : slider.getChildren()) {
      if(kid.isRendered() && kid instanceof Tab) {
        Tab tab = (Tab) kid;
       
        writer.startElement("li", null);
        renderChild(facesContext, tab);
        writer.endElement("li");
      }
View Full Code Here

TOP

Related Classes of org.primefaces.component.tabview.Tab

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.