incubator-adffaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Adam Winer" <awi...@gmail.com>
Subject Re: Problem with showOneAccordion
Date Wed, 04 Apr 2007 22:45:50 GMT
panelAccordion is rather badly broken, last I checked.
See http://issues.apache.org/jira/browse/ADFFACES-398

And the renderer code for panelAccordion, panelRadio,
panelChoice... <shudder>.  Roughly speaking, everything
in org.apache.myfaces.trinidadinternal.renderkit.html.layout
needs to be rewritten.

-- Adam


On 3/28/07, Martin Marinschek <martin.marinschek@gmail.com> wrote:
> Hi again,
>
> I've looked at the combined code for CorePanelAccordion and
> UIXShowDetail and their renderers and I wonder why the code for doing
> the disclosure/closure is spreaded out so much. Wouldn't it be better
> to handle this in the detail and the parent components, and in the
> renderer only do the rendering of the component? That should be
> possible with the event system, right?
>
>
> regards,
>
> Martin
>
>
>
> On 3/29/07, Martin Marinschek <martin.marinschek@gmail.com> wrote:
> > Hi *,
> >
> > can anyone of the Trinidad core developers do me a favour and look at:
> >
> > http://example.irian.at/trinidad-demo-20070328/faces/components/showOneAccordion.jspx
> >
> > do you think the behaviour is what a user expects? I would not think
> > so... When I click on Panel 1 and then on Panel 2, I would suspect
> > Panel 2 to be opened afterwards, but it isn't.
> >
> > I've added the following code to CorePanelAccordion to make this work again:
> >
> >     @Override
> >     public void queueEvent(FacesEvent event) {
> >         super.queueEvent(event);
> >
> >         // Deliver to the default ChartDrillDownEvent
> >         if (event instanceof DisclosureEvent)
> >         {
> >           List li = this.getChildren();
> >
> >           for(int i=0; i<li.size(); i++) {
> >             UIComponent comp = (UIComponent) li.get(i);
> >             if(comp instanceof UIXShowDetail) {
> >                 ((UIXShowDetail) comp).setDisclosed(false);
> >             }
> >           }
> >         }
> >     }
> >
> > but - this code will need to be restricted to take events only of
> > direct children, and only for showOneAccordions. Apart from this -
> > would you think this is the right approach for a fix?
> >
> > regards,
> >
> > Martin
> >
> > --
> >
> > http://www.irian.at
> >
> > Your JSF powerhouse -
> > JSF Consulting, Development and
> > Courses in English and German
> >
> > Professional Support for Apache MyFaces
> >
>
>
> --
>
> http://www.irian.at
>
> Your JSF powerhouse -
> JSF Consulting, Development and
> Courses in English and German
>
> Professional Support for Apache MyFaces
>

Mime
View raw message