What Davor's gettng at is that there isn't a mechanism in the Grid
component for accomplishing exactly what you want. No single component
can be all things to all people.

It's quite easy to create your own Grid component by subclassing Grid
and overriding its template a little.  This can be a bit more work
than we'd like ... there may be an AbstractGrid in the future that
makes it easier to subclass without duplicating a lot of code and
work.

Davor's approach is to make up the difference on the client side: use
the CSS class for the table rows as a trigger, using Prototype's $$()
function to select just those <TR> elements and attach the necessary
event handling JavaScript.

On Mon, Aug 18, 2008 at 6:45 AM, Davor Hrg <[EMAIL PROTECTED]> wrote:
> you can use rowClass to mark rows,
> and set global context menu handler on the table,
> and then in the handler find out row's class attribute : row.className
> then based on that decide what to show in context menu...
>
> Davor Hrg
>
> On Mon, Aug 18, 2008 at 3:27 PM, Stranzenbach, Ralf <
> [EMAIL PROTECTED]> wrote:
>
>> This seems to be a really good solution to create the zebar effect. I-ve
>> tried this using the getter based solution - which worked pretty well. I'll
>> give it a try later this evening.
>>
>> But i need to provide some additional JavaScript code to any row to provide
>> parametrized JavaScript code to activate additional functionality based on
>> the row selected.
>>
>> Sincerly
>> Ralf
>>
>>
>> ________________________________
>>
>> Von: Marcelo Lotif [mailto:[EMAIL PROTECTED]
>> Gesendet: Mo 18.08.2008 15:11
>> An: Tapestry users
>> Betreff: Re: "Decorating" Grid rows
>>
>>
>>
>> Maybe this thread helps you
>>
>> http://www.nabble.com/T5%3A-Grid%27s-rowClass-td13810748s302.html#a13810748
>>
>> read the third post from angelo chen, there's an explanation on how to
>> do the "zebra effect"...
>>
>> Cheers.
>>
>> On Mon, Aug 18, 2008 at 9:10 AM, Ralf Edmund Stranzenbach <[EMAIL PROTECTED]>
>> wrote:
>> > Hi,
>> >
>> > one of my application should provide some context aware assistance on the
>> > rows of a grid component. While it was really easy to provide some
>> feedback
>> > by creating specific css classes for the rows, adding of a context aware
>> > menu is more complicated.
>> >
>> > How can i provide some additional code for any row visible in a grid
>> > component (a solution with additional columns is in place, but that's not
>> > what i want).
>> >
>> > With regards,
>> > Ralf E. Stranzenbach
>>
>>
>>
>> --
>> Atenciosamente,
>>
>> Marcelo Lotif
>> Programador Java e Tapestry
>> FIEC - Federação das Indústrias do Estado do Ceará
>> (85) 3477-5910
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>>
>>
>>
>> ***************************************************************************************************
>> The information in this email is confidential and may be legally
>> privileged. Access to this email by anyone other than the intended addressee
>> is unauthorized. If you are not the intended recipient of this message, any
>> review, disclosure, copying, distribution, retention, or any action taken or
>> omitted to be taken in reliance on it is prohibited and may be unlawful. If
>> you are not the intended recipient, please reply to or forward a copy of
>> this message to the sender and delete the message, any attachments, and any
>> copies thereof from your system.
>>
>> ***************************************************************************************************
>>
>> BearingPoint GmbH
>> Geschäftsführer: Peter Mockler (Vorsitzender), Marcel Nickler (stellv.
>> Vorsitzender), Wilfried Erber, Werner Kreutzmann, Hans-Werner Wurzel
>> Aufsichtsratsvorsitzender: Roderick McGeary
>> Sitz: Frankfurt am Main
>> Registergericht: Amtsgericht Frankfurt am Main HRB 55490
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to