<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Garhard -<div><br></div><div>Thanks! &nbsp;One more stupid question.. &nbsp;Where does that fit into the rest of the rendering code that</div><div>is creating the TableRows? Is this going to be put in for any TR's for the entire form that was rendered</div><div>and there is no relationship (direct anyway) between the two? &nbsp;Anyway, just curious.. Thx!</div><div><br></div><div>-- Rick</div><div><br></div><div><br><div><div>On Nov 7, 2008, at 12:37 AM, Gerhard Obermann wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Hi!<br><br>You could try something like this!<br>You will need an extra CSS class for your rows!<br><br>&nbsp;&nbsp;&nbsp;&nbsp; self session addLoadScript: (html selector<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp; add: 'tr.effect';<br>&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp; do: [ :each | <br> &nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; each element on: 'mouseover' do: '$(event.target).up(''tr'').addClassName(''highlight'')'.<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp; each element on: 'mouseout' do: '$(event.target).up(''tr'').removeClassName(''highlight'')']).<br> <br>cheers<br>Gerhard<br><br><div class="gmail_quote">On Fri, Nov 7, 2008 at 7:55 AM, Richard E. Flower <span dir="ltr">&lt;<a href="mailto:rickf@ca-flower.com">rickf@ca-flower.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> <div class="Ih2E3d">On Nov 6, 2008, at 1:11 AM, Sebastian Sastre wrote:<br> <br> <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> <br> Hi Richard,<br> <br> that will be rendered as javascript so you can't expect a server side halt for<br> code that runs in DOM unless a callback is envolved. Unfortunately there is not<br> Firebug code halts yet to mimic our debugging style. I miss that when<br> javascripting.<br> <br> You can use this to check in firebug's console if your code executes under your<br> condition:<br> <br> &nbsp; &nbsp; &nbsp; &nbsp;SUScript new<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;add: (SULogger new log: 'The mouse is over!');<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;add: (your javascript serius code here);<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;yourself<br> <br> Usage of onClick, onMouseOver, etc are considered the "vile way" to do it.<br> Instead prefer observe(). Details here:<br> <a href="http://www.prototypejs.org/api/event/observe" target="_blank">http://www.prototypejs.org/api/event/observe</a><br> </blockquote> <br></div> Sebastian-<br> <br> I don't suppose you've got an example using the above mentioned observe() code in Prototype<br> do you? &nbsp;Is this what is used by Scriptaculous' SUElement? &nbsp;I saw a reference to 'observe'<br> in there but wasn't sure.. I've just spent the last hour or so looking thru the old email<br> archives for this list and saw some tidbits but no concrete examples.. &nbsp;I also looked at the test<br> code for Scriptaculous but nothing similar to what I want to do, which is to change the css for<br> an id when the mouse goes over the row in a table...<br> <br> I saw a reference in an email you wrote this past August talking about using :<br> <br> ========================<br> <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"> >From Seaside you access that with anElement>>on: anEventString do:<br> </blockquote> aHandlerObject<br> With prototype you can even use your own custom events like this: anElement<br> fire: 'mouse:enter'<br> ========================<br> <br> However, I'm not sure about the context in which to use the above.. &nbsp;An example would<br> be great!<br> <br> Currently my row rendering code looks something like :<div class="Ih2E3d"><br> <br> renderRowNumber: index item: row on: html<br> <br> &nbsp; &nbsp; &nbsp; &nbsp;html tableRow id: 'row' , index asString;<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;class: (self classForRowNumber: index);<br></div> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;script: (self componentScriptOn: html);<div class="Ih2E3d"><br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; onClick: (html evaluator<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;callback: [:aScript | self adjustRowColorsUsingIndex: index onScript: aScript];<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; return: false);<br></div><div class="Ih2E3d"> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;with: [columns<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;do: [:ea | self<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;renderColumn: ea<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;row: row<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;on: html]]<br> <br></div> componentScriptOn: html<br> <br> &nbsp; &nbsp; &nbsp; &nbsp;^(Scriptaculous.SUScript new<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;add: (Scriptaculous.SUEvent new<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;observe: html scriptaculous document<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;on: 'mouseover'<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;do: (Scriptaculous.SULogger new log: 'The mouse is over!')<br> &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;); yourself;<br> &nbsp; &nbsp; &nbsp; &nbsp;yourself).<br> <br> ====================================================<br> When I execute this with Firefox (and Firebug) I get the following error in the console window:<br> <br> Event.observe is not a function<br> &nbsp;onLoad()<br> &nbsp;onLoad(load)<div><div></div><div class="Wj3C7c"><br> <br> _______________________________________________<br> seaside mailing list<br> <a href="mailto:seaside@lists.squeakfoundation.org" target="_blank">seaside@lists.squeakfoundation.org</a><br> <a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br> </div></div></blockquote></div><br> _______________________________________________<br>seaside mailing list<br><a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside<br></blockquote></div><br></div></body></html>