<?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: a new event after changing the col width -&#62; patch included!</title>
	<link>http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included</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/feature-request/a-new-event-after-changing-the-col-width-patch-included/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>ghum on a new event after changing the col width -&#62; patch included!</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7979</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7979</guid>
        	        	<description><![CDATA[<blockquote>
<p>&#62;If you use 3.5 version this is not needed. When the width of some column is changed it is automatically updated in &#62;colModel. So in this case you just needs getGridParam.</p>
</blockquote>
<blockquote></blockquote>
<p>Thanks for this information!&#160;</p>
<p>But is there also an event fired that signals "hey, the user changed the width of some column" ?</p>
<p>Because that was the main reason for my patch, I need to get noticed that the colModel has changed.&#160;</p>
<p>best wishes,</p>
<p>Harald</p>
]]></description>
        	        	<pubDate>Thu, 23 Jul 2009 02:46:50 +0300</pubDate>
        </item>
        <item>
        	<title>SteveT on a new event after changing the col width -&#62; patch included!</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7943</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7943</guid>
        	        	<description><![CDATA[<p>Actually, I was needing this very thing.&#160; I was wanting some way to know if the user made any column adjustments.</p>
<p>With your event I could set a flag to dirty.&#160; On the unload of the page if this flag is dirty I was going to ajax the new column widths to the server to save them.</p>
]]></description>
        	        	<pubDate>Tue, 21 Jul 2009 19:37:26 +0300</pubDate>
        </item>
        <item>
        	<title>tony on a new event after changing the col width -&#62; patch included!</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7908</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7908</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>Thanks for this.</p>
<p>If you use 3.5 version this is not needed. When the width of some column is changed it is automatically updated in colModel. So in this case you just needs getGridParam.</p>
</p>
<p>Regards</p>
<p>TOny</p>
]]></description>
        	        	<pubDate>Mon, 20 Jul 2009 10:47:36 +0300</pubDate>
        </item>
        <item>
        	<title>ghum on a new event after changing the col width -&#62; patch included!</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7870</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/a-new-event-after-changing-the-col-width-patch-included#p7870</guid>
        	        	<description><![CDATA[<p>Hello tony,</p>
<p>thanks for the wonderfull jquery tool!&#160;&#160; I have the need to remember changes to the width of columns of jQuery.</p>
<p>That is: changes done by the enduser, dragging and dropping the columns-separators.</p>
</p>
<p>I suggest adding a new event-Property onChangeWidth.</p>
<p>Documentation: onChangeWidth(index, newWidth) -&#62; gets called everytime the width of one column is changed; default: null, nothing is done. Index is the index of the changed column, newWidth is the width after the change</p>
<p>That patch adds 3 lines to grid.base.js; the default is no cahnge in behaviour to now. I hereby submit this change to the Public Domain.</p>
<p>best wishes</p>
<p>Harald</p>
</p>
<p>diff --git a/js/grid.base.js b/js/grid.base.js<br />index 7fc3c4a..2635e78 100644<br />--- a/js/grid.base.js<br />+++ b/js/grid.base.js<br />@@ -43,6 +43,7 @@ $.fn.jqGrid = function( p ) {<br />&#160;&#160;&#160;&#160; onRightClickRow: null,<br />&#160;&#160;&#160;&#160; onPaging: null,<br />&#160;&#160;&#160;&#160; onSelectAll: null,<br />+&#160;&#160;&#160; onChangeColWidth:null,<br />&#160;&#160;&#160;&#160; loadComplete: null,<br />&#160;&#160;&#160;&#160; gridComplete: null,<br />&#160;&#160;&#160;&#160; loadError: null,<br />@@ -156,6 +157,8 @@ $.fn.jqGrid = function( p ) {<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; this.sDiv.scrollLeft = this.bDiv.scrollLeft;<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; }<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; }<br />+&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; if($.isFunction(p.onChangeColWidth))<br />+&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; {p.onChangeColWidth(idx, nw);}<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; }<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; },<br />&#160;&#160;&#160;&#160; &#160;&#160;&#160; scrollGrid: function() {</p>
]]></description>
        	        	<pubDate>Thu, 16 Jul 2009 10:45:55 +0300</pubDate>
        </item>
</channel>
</rss>