Title: Message

Andy,

 

I wasn’t asking for implementation details.  I was looking for consensus.  Is there consensus that we should add mouse over under through functions?  I really see the need where I am currently implementing the tag, but I don’t want to be too narrow sighted…

 

Guys???

 

 

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andy Pruitt
Sent: Friday, October 24, 2003 6:52 PM
To: [EMAIL PROTECTED]
Subject: RE: [displaytag-devel] on mouse over

 

 

 

I would like to see both onclick, onmouseover, and onmouseout added; for TR via a TableTag attribute and for TD via ColumnTag. 

 

The attribute would not be output directly, but rather, taken as the name of a _javascript_ function that will be invoked.

The function would pass the HTML element (this) that is being highlighted, and the value(s) of the cell(s).

 

So if a user says: 

<display:table .. rowOnclick="chooseRow">

<display:column property="fname" cellOnmouseover="highlightColumn"/>

the tag would output: 

<tr 'the value of the property of the first column', 'the value of the property of the second column') ">   

    <td 'The Title', 'the value of the property or tableDecorator call' )" >

 

you can then write a nifty js function like:

 

// Submit the page when the user selects a row  -- ignores uninteresting parameters

function chooseRow( selectedTR,  companyName, companyId ){

    form.companyId.value = companyId;

    form.submit();

}

 

var currentHighlighted = null;

// highlight something useful

function highlightColumn( selectedTD,  title, value){

    setCurrentSomething(value);

    if ( currentHighlighted != null ){    currentHighlighted.className = ''; }

    selectedTd.className = 'highlighted';

    currentHighlighted = selectedTD;

}

 

Something like this would be very flexible.

 

-----Original Message-----
From: Benjamin Simpson [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 23, 2003 8:30 PM
To: [EMAIL PROTECTED]
Subject: [displaytag-devel] on mouse over

Guys,

 

I really love this tag.  I am beating the heck out of it at my current consulting gig and very proud of the work that Fabrizio has done.

 

As part of that, I see the need to make an onMouseOver attribute for the column tag.  Does anyone object?

 

Ben

 

Reply via email to