Package org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.table

Examples of org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.table.TreeTableRenderingContext


    FacesContext        context,
    RenderingContext arc,
    UIComponent         component
    )
  {
    return new TreeTableRenderingContext(context, arc, component);
  }
View Full Code Here


                                hasExpandAll || useDivider);
    if (hasExpandAll && supportsScripting(arc)) //not in printable mode
    {
      // must render these IDs so that PPR can restore the focus correctly:
      String preId = component.getClientId(context) + NamingContainer.SEPARATOR_CHAR;
      TreeTableRenderingContext hContext = (TreeTableRenderingContext) tContext;
      String onclick =
            TreeUtils.callJSExpandAll(hContext.getUIXTreeTable(),
                                      tContext.getJSVarName(),
                                      true /*isExpand*/);
       renderControlBarLink(context, arc, onclick, _EXPAND_ALL_TEXT_KEY,
                           arc.getIcon(SkinSelectors.AF_TREE_TABLE_EXPAND_ALL_ICON_NAME),
                            preId+"eAll", true);
      onclick =
            TreeUtils.callJSExpandAll(hContext.getUIXTreeTable(),
                                      tContext.getJSVarName(),
                                      false /*isExpand*/);
       renderControlBarLink(context, arc, onclick, _COLLAPSE_ALL_TEXT_KEY,
                           arc.getIcon(SkinSelectors.AF_TREE_TABLE_COLLAPSE_ALL_ICON_NAME),
                            preId+"cAll", useDivider);
View Full Code Here

                                                     arc,
                                                     tContext,
                                                     component,
                                                     physicalColumnIndex);
    final ColumnData colData = tContext.getColumnData();
    TreeTableRenderingContext ttrc = (TreeTableRenderingContext) tContext;
    if (ttrc.isFocusColumnVisible())
    {
      colData.setColumnIndex(physicalColumnIndex++,
                             ColumnData.SPECIAL_COLUMN_INDEX);
      SpecialColumnRenderer focusRenderer = getFocusColumnRenderer();
      UIComponent column = focusRenderer.getSpecialColumn();
      delegateRenderer(context, arc, column,
                       getFacesBean(column), focusRenderer);
    }

    // render the object hierarchy column:
    colData.setColumnIndex(physicalColumnIndex++,
                           ColumnData.SPECIAL_COLUMN_INDEX);
    UIComponent treeNodeColumn = ttrc.getTreeNodeStamp();
    delegateRenderer(context, arc, treeNodeColumn,
                     getFacesBean(treeNodeColumn), _TREE_NODE);

    return physicalColumnIndex;
  }
View Full Code Here

    RenderingContext   arc,
    TableRenderingContext trc,
    UIComponent           component,
    FacesBean bean) throws IOException
  {
    TreeTableRenderingContext ttrc = (TreeTableRenderingContext) trc;
    final RowData rowData = trc.getRowData();
    boolean isEmptyTable  = rowData.isEmptyTable();

    // render all the table content rows
    if (isEmptyTable)
View Full Code Here

    UIComponent tree,
    FacesBean bean) throws IOException
  {
    // this renders <TR><TD><[crumbs]></TD></TR>

    TreeTableRenderingContext hContext = (TreeTableRenderingContext) context;
    // we will render the breadcrumbs only if they exist.
    if (hContext.isFocusColumnVisible())
    {
      ResponseWriter writer = fc.getResponseWriter();
      writer.startElement(XhtmlConstants.TABLE_ROW_ELEMENT, null);
      writer.startElement(XhtmlConstants.TABLE_DATA_ELEMENT, null);
      writer.writeAttribute(XhtmlConstants.HEIGHT_ATTRIBUTE, "30", null);
View Full Code Here

      RenderingContext arc,
      UIComponent child,
      int renderedCount,
      boolean isLastChild) throws IOException
    {
      TreeTableRenderingContext ttrc = TreeTableRenderingContext.getInstance();
      UIXTreeTable tree = ttrc.getUIXTreeTable();
      ResponseWriter out = context.getResponseWriter();
      out.startElement("a", tree);
      out.writeURIAttribute("href", "#" , null);
      // put style classes on the links
      if (isLastChild)
      {
        renderStyleClass(
          context, arc,
          SkinSelectors.AF_TREE_TABLE_MP_SELECTED_STYLE_CLASS);
      }
      else
      {
        renderStyleClass(
          context, arc,
          SkinSelectors.AF_TREE_TABLE_MP_STEP_STYLE_CLASS);
      }
      Object oldPath = tree.getRowKey();
      Object focusRowKey = ttrc.getFocusRowKey();
      List<Object> focusPath = tree.getAllAncestorContainerRowKeys(focusRowKey);
      Object crumbPath = (renderedCount < focusPath.size())
        ? focusPath.get(renderedCount)
        : focusRowKey;
      try
      {
        tree.setRowKey(crumbPath);
        String onclick =
          TreeUtils.callJSFocusNode(tree, ttrc.getJSVarName());
        out.writeAttribute("onclick", onclick , null);
        super.renderLink(context, arc, child, renderedCount, isLastChild);
      }
      finally
      {
View Full Code Here

    FacesContext        context,
    RenderingContext arc,
    UIComponent         component
    )
  {
    return new TreeTableRenderingContext(context, arc, component);
  }
View Full Code Here

                                hasExpandAll || useDivider);
    if (hasExpandAll && supportsScripting(arc)) //not in printable mode
    {
      // must render these IDs so that PPR can restore the focus correctly:
      String preId = component.getClientId(context) + NamingContainer.SEPARATOR_CHAR;
      TreeTableRenderingContext hContext = (TreeTableRenderingContext) tContext;
      String onclick =
            TreeUtils.callJSExpandAll(hContext.getUIXTreeTable(),
                                      tContext.getJSVarName(),
                                      true /*isExpand*/);
       renderControlBarLink(context, arc, onclick, _EXPAND_ALL_TEXT_KEY,
                           arc.getIcon(SkinSelectors.AF_TREE_TABLE_EXPAND_ALL_ICON_NAME),
                            preId+"eAll", true);
      onclick =
            TreeUtils.callJSExpandAll(hContext.getUIXTreeTable(),
                                      tContext.getJSVarName(),
                                      false /*isExpand*/);
       renderControlBarLink(context, arc, onclick, _COLLAPSE_ALL_TEXT_KEY,
                           arc.getIcon(SkinSelectors.AF_TREE_TABLE_COLLAPSE_ALL_ICON_NAME),
                            preId+"cAll", useDivider);
View Full Code Here

                                                     arc,
                                                     tContext,
                                                     component,
                                                     physicalColumnIndex);
    final ColumnData colData = tContext.getColumnData();
    TreeTableRenderingContext ttrc = (TreeTableRenderingContext) tContext;
    if (ttrc.isFocusColumnVisible())
    {
      colData.setColumnIndex(physicalColumnIndex++,
                             ColumnData.SPECIAL_COLUMN_INDEX);
      SpecialColumnRenderer focusRenderer = getFocusColumnRenderer();
      UIComponent column = focusRenderer.getSpecialColumn();
      delegateRenderer(context, arc, column,
                       getFacesBean(column), focusRenderer);
    }

    // render the object hierarchy column:
    colData.setColumnIndex(physicalColumnIndex++,
                           ColumnData.SPECIAL_COLUMN_INDEX);
    UIComponent treeNodeColumn = ttrc.getTreeNodeStamp();
    delegateRenderer(context, arc, treeNodeColumn,
                     getFacesBean(treeNodeColumn), _TREE_NODE);

    return physicalColumnIndex;
  }
View Full Code Here

    RenderingContext   arc,
    TableRenderingContext trc,
    UIComponent           component,
    FacesBean bean) throws IOException
  {
    TreeTableRenderingContext ttrc = (TreeTableRenderingContext) trc;
    final RowData rowData = trc.getRowData();
    boolean isEmptyTable  = rowData.isEmptyTable();

    // render all the table content rows
    if (isEmptyTable)
View Full Code Here

TOP

Related Classes of org.apache.myfaces.trinidadinternal.renderkit.core.xhtml.table.TreeTableRenderingContext

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.