<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: onHeaderClick timing issue</title>
	<link>http://www.trirand.com/blog/?page_id=393/bugs/onheaderclick-timing-issue</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/bugs/onheaderclick-timing-issue/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>flack on onHeaderClick timing issue</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/onheaderclick-timing-issue#p20457</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/onheaderclick-timing-issue#p20457</guid>
        	        	<description><![CDATA[<p>Hi!</p>
</p>
<p>I&#39;m trying to write a function where multiple grids on one page should together always fill 100% of the container height. To allow them to dynamically resize when one is closed, I added a callback to onHeaderClick that goes like this (pseudocode)</p>
<p>onHeaderClick: function()</p>
<p>{</p>
<p>&#160;&#160;&#160; // read the current outerHeight(true) of all grids</p>
<p>&#160;&#160;&#160; // do some computations&#8230;</p>
<p>&#160;&#160;&#160; // set new height to all visible grids so that they add up to container height</p>
<p>}</p>
</p>
<p>The code as such works fine, but the problem is that the onHeaderClick callback gets executed while the animations are still running, so I always get a useless intermediate value from get_grid_height() instead of the final new height. IMO, onHeaderClick should be executed synchronously at the end of the show/hide animation. I did a proof-of-concept patch that solves the problem for me, if you&#39;re interested, you can take a look here:</p>
</p>
<p><a rel="nofollow" href="http://github.com/flack/jqGrid/commit/27230a43892b41291747dbaaf852dfc69bc2a34a" target="_blank"></a><a href="http://github.com/flack/jqGrid" rel="nofollow" target="_blank">http://github.com/flack/jqGrid</a>.....c69bc2a34a</p>
]]></description>
        	        	<pubDate>Mon, 25 Oct 2010 14:49:56 +0300</pubDate>
        </item>
</channel>
</rss>