Examples of UIToolBar


Examples of org.apache.myfaces.tobago.component.UIToolBar

    final Style body = new Style();
    body.setWidth(width);
    body.setHeight(tabGroup.getCurrentHeight().subtract(headerHeight));
    writer.endElement(HtmlElements.DIV);
    if (tabGroup.isShowNavigationBar()) {
      final UIToolBar toolBar = createToolBar(facesContext, tabGroup);
      renderToolBar(facesContext, writer, tabGroup, toolBar);
    }
  }
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

          menu.getChildren().add(entry);
        }
        index++;
      }
    }
    final UIToolBar toolBar = (UIToolBar) application.createComponent(UIToolBar.COMPONENT_TYPE);
    toolBar.setId(viewRoot.createUniqueId());
    toolBar.setRendererType("TabGroupToolBar");
    toolBar.setTransient(true);
    toolBar.getChildren().add(previous);
    toolBar.getChildren().add(next);
    toolBar.getChildren().add(all);
    tabGroup.getFacets().put(Facets.TOOL_BAR, toolBar);
    return toolBar;
  }
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

    return UIToolBar.ORIENTATION_RIGHT.equals(toolBar.getOrientation());
  }

  @Override
  public void encodeEnd(final FacesContext context, final UIComponent component) throws IOException {
    final UIToolBar toolBar = (UIToolBar) component;

    final TobagoResponseWriter writer = HtmlRendererUtils.getTobagoResponseWriter(context);

    Measure width = Measure.valueOf(-1);
    for (final UIComponent command : toolBar.getChildren()) {
      if (command instanceof AbstractUICommandBase) {
        width = renderToolbarCommand(context, toolBar, (AbstractUICommandBase) command, writer, width);
      } else if (command instanceof UIToolBarSeparator) {
        width = renderSeparator(context, toolBar, (UIToolBarSeparator) command, writer, width);
      } else {
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

public class ToolBarRenderer extends ToolBarRendererBase {

  @Override
  public void encodeEnd(final FacesContext facesContext, final UIComponent component) throws IOException {

    final UIToolBar toolBar = (UIToolBar) component;

    final TobagoResponseWriter writer = HtmlRendererUtils.getTobagoResponseWriter(facesContext);

    writer.startElement(HtmlElements.DIV, toolBar);
    writer.writeIdAttribute(toolBar.getClientId(facesContext));
    HtmlRendererUtils.writeDataAttributes(facesContext, writer, toolBar);
    HtmlRendererUtils.renderDojoDndItem(toolBar, writer, true);
    writer.writeClassAttribute(Classes.create(toolBar));
    final Style style = new Style(facesContext, toolBar);
    final boolean right = UIToolBar.ORIENTATION_RIGHT.equals(toolBar.getOrientation());
    if (right) {
      style.setTextAlign(TextAlign.RIGHT);
    }
    writer.writeStyleAttribute(style);
    super.encodeEnd(facesContext, toolBar);
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

  protected void renderColumnSelectorHeader(
      FacesContext facesContext, TobagoResponseWriter writer, UISheet sheet)
      throws IOException {

    final UIToolBar toolBar = createToolBar(facesContext, sheet);
    writer.startElement(HtmlElements.DIV, null);
    writer.writeClassAttribute(Classes.create(sheet, "toolBar"));

    if (UISheet.MULTI.equals(sheet.getSelectable())) {
      RenderUtils.prepareRendererAll(facesContext, toolBar);
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

    createMenuItem(facesContext, menu, "sheetMenuSelect", Markup.SHEET_SELECT_ALL, sheetId);
    createMenuItem(facesContext, menu, "sheetMenuUnselect", Markup.SHEET_DESELECT_ALL, sheetId);
    createMenuItem(facesContext, menu, "sheetMenuToggleselect", Markup.SHEET_TOGGLE_ALL, sheetId);

    final UIToolBar toolBar = (UIToolBar) application.createComponent(UIToolBar.COMPONENT_TYPE);
    toolBar.setId(facesContext.getViewRoot().createUniqueId());
    toolBar.setRendererType("TabGroupToolBar");
    toolBar.setTransient(true);
    toolBar.getChildren().add(dropDown);
    sheet.getFacets().put(Facets.TOOL_BAR, toolBar);
    return toolBar;
  }
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

    return UIToolBar.ORIENTATION_RIGHT.equals(toolBar.getOrientation());
  }

  @Override
  public void encodeEnd(FacesContext context, UIComponent component) throws IOException {
    UIToolBar toolBar = (UIToolBar) component;

    TobagoResponseWriter writer = HtmlRendererUtils.getTobagoResponseWriter(context);

    Measure width = Measure.valueOf(-1);
    for (UIComponent command : toolBar.getChildren()) {
      if (command instanceof AbstractUICommandBase) {
        width = renderToolbarCommand(context, toolBar, (AbstractUICommandBase) command, writer, width);
      } else if (command instanceof UIToolBarSeparator) {
        width = renderSeparator(context, toolBar, (UIToolBarSeparator) command, writer, width);
      } else {
View Full Code Here

Examples of org.apache.myfaces.tobago.component.UIToolBar

    Style body = new Style();
    body.setWidth(width);
    body.setHeight(tabGroup.getCurrentHeight().subtract(headerHeight));
    writer.endElement(HtmlElements.DIV);
    if (tabGroup.isShowNavigationBar()) {
      UIToolBar toolBar = createToolBar(facesContext, tabGroup);
      renderToolBar(facesContext, writer, tabGroup, toolBar);
    }
  }
View Full Code Here

Examples of org.richfaces.component.UIToolBar

    "onitemmouseout",
    "onitemmouseup"
  };
 
  public void encodeChildren(FacesContext facesContext, UIComponent component) throws IOException {
    UIToolBar toolBar = (UIToolBar) component;
    List<UIComponent> children = toolBar.getChildren();
    String contentClass = (String) toolBar.getAttributes().get("contentClass");
    String contentStyle = (String) toolBar.getAttributes().get("contentStyle");

    if (null == contentClass) {
      contentClass = "";
    }
    if (null == contentStyle) {
View Full Code Here

Examples of org.richfaces.component.UIToolBar

    "onitemmouseout",
    "onitemmouseup"
  };
 
  public void encodeChildren(FacesContext facesContext, UIComponent component) throws IOException {
    UIToolBar toolBar = (UIToolBar) component;
    List<UIComponent> children = toolBar.getChildren();
    String contentClass = (String) toolBar.getAttributes().get("contentClass");
    String contentStyle = (String) toolBar.getAttributes().get("contentStyle");

    if (null == contentClass) {
      contentClass = "";
    }
    if (null == contentStyle) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.