myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Robinson" <>
Subject Re: [Trinidad] skinning af|showDetail::disclosed-icon for different components
Date Tue, 21 Aug 2007 21:18:29 GMT
I got it to work, but it is a hack and subject to bugs.

I subclassed the PanelAccordionRenderer:
  protected void encodeAll(FacesContext context, RenderingContext arc,
    UIComponent component, FacesBean bean) throws IOException
    Map<String, String> origResMap = arc.getSkinResourceKeyMap();
    Map<String, String> resMap = origResMap == null ?
      new HashMap<String, String>() : new HashMap<String, String>(origResMap);

      super.encodeAll(context, arc, component, bean);

This now lets me have my own icon. Unfortunately the author of
PanelAccordionRenderer made some methods private (like
_encodeDetailItem) and didn't break up encodeAll into smaller methods,
so there is no way I can remove the map for the children. As a result,
all children that may have disclosure icons will also get the
accordion version instead of the standard one.

On 8/21/07, Scott O'Bryan <> wrote:
> No, I don't think there is.  You see, even though these icons are in the
> skinning stylesheet, they are actually served from the server.  The
> server query's the skinning system to get the url for these icons.
> Andrew Robinson wrote:
> > Is there a way to customize "af|showDetail::disclosed-icon" for only
> > one component?
> >
> > For example, this isn't working:
> >
> > af|panelAccordion::container af|showDetail::disclosed-icon
> >
> >

View raw message