<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mersoft Corporation Blog &#187; GWT</title>
	<atom:link href="http://blog.mersoft.com/tag/gwt/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.mersoft.com</link>
	<description>Achieve, Compete, and Evolve</description>
	<lastBuildDate>Wed, 07 Sep 2011 15:13:56 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>GWT-EXT 2.0.6 ComboBox &#8211; onChange event</title>
		<link>http://blog.mersoft.com/2010/05/25/gwt-ext-2-0-6-combobox-onchange-event/</link>
		<comments>http://blog.mersoft.com/2010/05/25/gwt-ext-2-0-6-combobox-onchange-event/#comments</comments>
		<pubDate>Tue, 25 May 2010 15:30:54 +0000</pubDate>
		<dc:creator>Tom Bollwitt</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[Software Development]]></category>
		<category><![CDATA[EXTJS]]></category>
		<category><![CDATA[google web toolkit]]></category>
		<category><![CDATA[Goolge Web Toolkit]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[GWT-EXT]]></category>
		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=363</guid>
		<description><![CDATA[I ran into an issue where I needed to use the onChange event for a Combobox and it was not working as expected. It only worked when the value was selected from the dropdown. This posed a problem for me since I was not forcing the user to make a selection &#8211; they can enter [...]]]></description>
			<content:encoded><![CDATA[<p>I ran into an issue where I needed to use the onChange event for a Combobox and it was not working as expected. It only worked when the value was selected from the dropdown. This posed a problem for me since I was not forcing the user to make a selection &#8211; they can enter in text manually.</p>
<p>I found <a href="http://www.extjs.com/forum/showthread.php?6343-Solved-1.0.1a-1.1-DateField-change-event-bugs-proposed-fixes&amp;p=52974#post52974" target="_blank">this fix</a> on the EXTJS forum, however the fix did not work when the user entered in their own value into the combo box.</p>
<p>To resolve this I changed 2 lines of code from the fix I found.</p>
<p>I modified&#8230;</p>
<pre>this.startValue = this.getValue();</pre>
<p>to</p>
<pre>this.startValue = this.getRawValue();</pre>
<p>and</p>
<pre>var v = this.getValue();</pre>
<p>to</p>
<pre>var v = this.getRawValue();</pre>
<p>So here is the entire code for the updated fix&#8230;</p>
<pre>Ext.override(Ext.form.Field, {
 onFocus : function() {
 if (!Ext.isOpera) { // don't touch in Opera
 this.el.addClass(this.focusClass);
 }
 if (!this.hasFocus) {
 this.hasFocus = true;
 <span style="color: #0000ff;"><strong>this.startValue = this.getRawValue();</strong></span>
 this.fireEvent("focus", this);
 }
 },

 onBlur : function() {
 this.beforeBlur();
 this.el.removeClass(this.focusClass);
 this.hasFocus = false;
 if (this.validationEvent !== false &amp;&amp; this.validateOnBlur &amp;&amp; this.validationEvent != "blur") {
 this.validate();
 }
 <span style="color: #0000ff;"><strong>var v = this.getRawValue();</strong></span>
 if (String(v) !== String(this.startValue)) {
 this.fireEvent('change', this, v, this.startValue);
 }
 this.fireEvent("blur", this);
 }
 });</pre>
<p>I hope this helps someone out there who may be having the same problem I had.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2010%2F05%2F25%2Fgwt-ext-2-0-6-combobox-onchange-event%2F&amp;linkname=GWT-EXT%202.0.6%20ComboBox%20%26%238211%3B%20onChange%20event"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2010/05/25/gwt-ext-2-0-6-combobox-onchange-event/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Mac &#8211; Eclipse Galileo &#8211; Installing GWT Plugin</title>
		<link>http://blog.mersoft.com/2010/01/15/mac-eclipse-galileo-installing-gwt-plugin/</link>
		<comments>http://blog.mersoft.com/2010/01/15/mac-eclipse-galileo-installing-gwt-plugin/#comments</comments>
		<pubDate>Fri, 15 Jan 2010 22:26:39 +0000</pubDate>
		<dc:creator>Tom Bollwitt</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Goolge Web Toolkit]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[Plugin]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=350</guid>
		<description><![CDATA[Ok, So I was having some real issues when I tried to install the GWT plugin from Google into Eclipse Galileo on my Mac in order create a GWT 2.0 application. After installing the plugin (via the update site &#8211; http://dl.google.com/eclipse/plugin/3.5) you need to restart Eclipse. However when Eclipse restarted all I got was an [...]]]></description>
			<content:encoded><![CDATA[<p>Ok, So I was having some real issues when I tried to install the GWT plugin from Google into Eclipse Galileo on my Mac in order create a GWT 2.0 application. After installing the plugin (via the update site &#8211; http://dl.google.com/eclipse/plugin/3.5) you need to restart Eclipse. However when Eclipse restarted all I got was an error popup telling me to check the Eclipse log file.</p>
<p>The log file contained the following &#8230;</p>
<pre>!SESSION Thu Jan 14 16:42:24 CST 2010
------------------------------------------
!ENTRY org.eclipse.equinox.launcher 4 0 2010-01-14 16:42:24.080
!MESSAGE Exception launching the Eclipse Platform:
!STACK
java.lang.ClassNotFoundException:
org.eclipse.core.runtime.adaptor.EclipseStarter
	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:316)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
	at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:556)
	at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
	at org.eclipse.equinox.launcher.Main.run(Main.java:1311)</pre>
<p>Well, luckily I was able to come up with a workaround.</p>
<p>For development I also use the Subversive and Maven Integration plugins so here is what I did. (This assumes you know how to install plugins via update sites)</p>
<ol>
<li>Start with a fresh copy of Galileo</li>
<li>Add all the plugins without restarting Eclipse in the following order.</li>
<li>Add the GWT plugin from the update site
<ol>
<li>http://dl.google.com/eclipse/plugin/3.5</li>
</ol>
</li>
<li>Add the Subversive plugin and required SVN connectors from Polarion
<ol>
<li>http://community.polarion.com/projects/subversive/download/eclipse/2.0/galileo-site/</li>
</ol>
</li>
<li>Add the maven integration plugin
<ol>
<li>http://m2eclipse.sonatype.org/update</li>
</ol>
</li>
<li>After all the plugins are installed restart Eclipse.</li>
</ol>
<p>And there you have it. Eclipse starts up without any problems.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2010%2F01%2F15%2Fmac-eclipse-galileo-installing-gwt-plugin%2F&amp;linkname=Mac%20%26%238211%3B%20Eclipse%20Galileo%20%26%238211%3B%20Installing%20GWT%20Plugin"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2010/01/15/mac-eclipse-galileo-installing-gwt-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GWT &#8211; Hide Tabs in TabPanel</title>
		<link>http://blog.mersoft.com/2009/08/27/gwt-hide-tabs-in-tabpanel/</link>
		<comments>http://blog.mersoft.com/2009/08/27/gwt-hide-tabs-in-tabpanel/#comments</comments>
		<pubDate>Thu, 27 Aug 2009 21:14:32 +0000</pubDate>
		<dc:creator>Tom Bollwitt</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[google web toolkit]]></category>
		<category><![CDATA[Goolge Web Toolkit]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[GWT-EXT]]></category>
		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=320</guid>
		<description><![CDATA[I was continuing my work on a sample GWT app and needed the ability to use a Menu with CheckItems to show/hide tabs in a tab panel. Here is how I did it.
Note: This post does not cover the creation of the TabPanel, Toolbar and ToolbarButton with a Menu.
Step 1: Override the Ext.TabPanel. (Note: This [...]]]></description>
			<content:encoded><![CDATA[<p>I was continuing my work on a sample GWT app and needed the ability to use a Menu with CheckItems to show/hide tabs in a tab panel. Here is how I did it.</p>
<p>Note: This post does not cover the creation of the TabPanel, Toolbar and ToolbarButton with a Menu.</p>
<p>Step 1: Override the Ext.TabPanel. (Note: This was just added to a JavaScript file I added to my application. I did not modify the ext-all.js file)</p>
<pre style="border: 1px solid grey; padding: 10px;">Ext.override(Ext.TabPanel, {

  hideTabStripItem : function(item){
    //Don't hide if its the last tab
    var cnt = this.items.length;
    var visibleTabs = 0;
    for(var i = 0; i &lt; cnt; i++ ){
      if(!this.isTabStripItemHidden(i)){
        visibleTabs++;
      }
    }
    if(visibleTabs &gt; 1){
      item = this.getComponent(item);
      var isactive = (item == this.activeTab);	    

      var el = this.getTabEl(item);
      if(el){
        el.style.display = 'none';
          this.delegateUpdates();
      }

      if(isactive){
        //Set the next visible tab active
        var curIndx = 0;
        var indx = 0;
        for(var i = 0; i &lt; cnt; i++ ){
          var tab = this.getComponent(i);
          if(tab.id == item.id){
            curIndx = i;
            break;
          }
        }

        //Check for the next available tab
        for(var i = (curIndx+1); i &lt; cnt; i++ ){
          if(!this.isTabStripItemHidden(i)){
            indx = i;
            break;
          }
        }

        if(indx == 0){
          //Check for a tab before the current one
          for(var i = 0; i &lt; curIndx; i++ ){
            if(!this.isTabStripItemHidden(i)){
              indx = i;
              break;
            }
          }
        }

        this.setActiveTab(indx);
      }
    }
    if(visibleTabs == 1){
      throw "Could not hide the tab";
    }
  },

  unhideTabStripItem : function(item){
    item = this.getComponent(item);
    var el = this.getTabEl(item);
    if(el){
      el.style.display = '';
      this.delegateUpdates();
    }

    this.setActiveTab(item);
  },

  isTabStripItemHidden : function(item){
    item = this.getComponent(item);
    var el = this.getTabEl(item);
    if(el){
      return el.style.display == 'none';
    }
    //return true since it does not exist.
    return true;
  }
});</pre>
<p>Step 2: Create a CheckItem with a listener to show/hide the tab (add it to a ToolbarButton&#8217;s Menu).</p>
<pre style="border: 1px solid grey; padding: 10px;">public CheckItem createTabCheckItem(String menuTitle, final String tabId, final TabPanel tabPanel){
  CheckItem ci = new CheckItem(menuTitle);
  ci.addListener(new CheckItemListenerAdapter() {
    public void onCheckChange(CheckItem item, boolean checked) {
      if (checked) {
        tabPanel.unhideTabStripItem(tabId);
      } else {
        try {
          tabPanel.hideTabStripItem(tabId);
        } catch (Exception e) {
          item.setChecked(true);
        }
      }
    }
  });
  ci.setHideOnClick(false);
  return ci;
}</pre>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2009%2F08%2F27%2Fgwt-hide-tabs-in-tabpanel%2F&amp;linkname=GWT%20%26%238211%3B%20Hide%20Tabs%20in%20TabPanel"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2009/08/27/gwt-hide-tabs-in-tabpanel/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GWT Disable ComboBox options</title>
		<link>http://blog.mersoft.com/2009/08/25/gwt-disable-combobox-options/</link>
		<comments>http://blog.mersoft.com/2009/08/25/gwt-disable-combobox-options/#comments</comments>
		<pubDate>Tue, 25 Aug 2009 22:33:15 +0000</pubDate>
		<dc:creator>Tom Bollwitt</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[google web toolkit]]></category>
		<category><![CDATA[Goolge Web Toolkit]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[GWT-EXT]]></category>
		<category><![CDATA[java]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=264</guid>
		<description><![CDATA[I have been working on an application that required the ability to disable ComboBox options. I googled to see if someone else had already done this and I found the following post. I used the code from the post as a starting point and added additional code to flush out a few more features.
The main [...]]]></description>
			<content:encoded><![CDATA[<p>I have been working on an application that required the ability to disable ComboBox options. I googled to see if someone else had already done this and I found the following <a href="https://www.extjs.com/forum/showthread.php?p=181913" target="_blank">post</a>. I used the code from the post as a starting point and added additional code to flush out a few more features.<br />
The main features I added dealt with the option selecting itself, such as using the up and down keys to select options. In order to tie everything together I have posted all the critical code in its entirety to avoid confusion.</p>
<p>To start off with I added the following to a JavaScript file that I included in my application. The main difference from this code and the code from the original post above is the addition of the selectNext and selectPrev overrides. I also had to modify the onViewClick override since I was using Strings instead of booleans for the selectable value (see the SimpleStore created later).</p>
<pre style="border: 1px solid grey; padding: 10px;">Ext.override(Ext.form.ComboBox, {

  tpl: '&lt;tpl for="."&gt;' +
    '&lt;div class="x-combo-list-item &lt;tpl if="selectable == \'false\'"&gt;x-combo-list-item-unsel&lt;/tpl&gt; "&gt;' +
    '&lt;img src="{image}"&gt; ' +
    '{text}&lt;div class="x-clear"&gt;&lt;/div&gt;&lt;/div&gt;' +
    '&lt;/tpl&gt;',

    // private

    onViewClick : function(doFocus){

        var index = this.view.getSelectedIndexes()[0];
        var r = this.store.getAt(index);
        var sel = r.get('selectable');
        if(sel &amp;&amp; sel == 'false'){
            return;
        }

        if(r){
            this.onSelect(r, index);
        }

        if(doFocus !== false){
            this.el.focus();
        }
    },

    selectNext : function(){
        var ct = this.store.getCount();
        if(ct &gt; 0){
        	var hasSelectable = this.store.getAt(0).get('selectable');

        	if(hasSelectable){
        		//check for selectable records
        		//Get the next selectable record
        		var currentIndex = this.selectedIndex;
        		var nextIndex = currentIndex;

        		while(true){
        			if(nextIndex &lt; ct-1){
        				var r = this.store.getAt(++nextIndex);
        				if(r.get('selectable') == 'true'){
        					break;
        				}
        			}else{
        				break;
        			}
        		}

        		this.select(nextIndex);
        	}else{
        		//select the original way
        		if(this.selectedIndex == -1){
                    this.select(0);
                }else if(this.selectedIndex &lt; ct-1){                     this.select(this.selectedIndex+1);                 }         	}         }     },     selectPrev : function(){         var ct = this.store.getCount();         if(ct &gt; 0){
        	var hasSelectable = this.store.getAt(0).get('selectable');

        	if(hasSelectable){
	        	//Get the next selectable record
	        	var currentIndex = this.selectedIndex;
	        	var nextIndex = currentIndex;

				while(true){
					if(nextIndex != -1){
						var r = this.store.getAt(--nextIndex);
						if(r.get('selectable') == 'true'){
							break;
						}
					}else{
						break;
					}
				}

				this.select(nextIndex);
        	}else{
        		//select the original way
        		if(this.selectedIndex == -1){
                    this.select(0);
                }else if(this.selectedIndex != 0){
                    this.select(this.selectedIndex-1);
                }
        	}
        }
    },
}    

);</pre>
<p>I then added the following CSS class to my application&#8217;s CSS file&#8230;</p>
<pre style="border: 1px solid grey; padding: 10px;">.x-combo-list-item-unsel{
  -moz-opacity:0.5;
  opacity: .50;
  filter:alpha(opacity=50);
}</pre>
<p>And now for some java code.</p>
<p>I created the Store for my ComboBox with the following code. If you read the JavaScript code above you will notice that it depends on the Records in the Store having the &#8220;selectable&#8221; attribute.</p>
<p>Note: The getOptions() method is coming up next.</p>
<pre style="border: 1px solid grey; padding: 10px;">final Store store = new SimpleStore(new String[]{"image", "text", "value", "selectable"}, getOptions(false));
store.load();</pre>
<p>In my application I needed to be able to reverse the disabled options so I created the following method to generate the Object array used for my Store.</p>
<pre style="border: 1px solid grey; padding: 10px;">private Object[][] getOptions(boolean isDisabled){
  Object[][] results = new Object[][]{
    new Object[]{"images/image1.gif", "Option 1", "VALUE1", !isDisabled},
    new Object[]{"images/image2.gif", "Option 2", "VALUE2", !isDisabled},
    new Object[]{"images/image3.gif", "Option 3", "VALUE3", isDisabled},
    new Object[]{"images/image4.gif", "Option 4", "VALUE4", !isDisabled},
    new Object[]{"images/image5.gif", "Option 5", "VALUE5", !isDisabled}
  };

  return results;
}</pre>
<p>Then in a listener on a TextField I added the following code to switch the disabled options&#8230;</p>
<pre style="border: 1px solid grey; padding: 10px;">Store store = combobox.getStore();
store.removeAll();
store.add(getOptionRecords(true));  //Note: send true or false depending on which options you want disabled.</pre>
<p>Here is the getOptionRecords() method used in the code above&#8230;</p>
<pre style="border: 1px solid grey; padding: 10px;">private static Record[] getOptionRecords(boolean isDisabled){
  Store store = new SimpleStore(new String[]{"image", "text", "value", "selectable"}, getPhoneLabels(isDisabled));
  store.load();
  return store.getRecords();
}</pre>
<p>I hope that this post helps someone out.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2009%2F08%2F25%2Fgwt-disable-combobox-options%2F&amp;linkname=GWT%20Disable%20ComboBox%20options"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2009/08/25/gwt-disable-combobox-options/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GWT-EXT: Retain Checkbox selections in page-able GridPanel</title>
		<link>http://blog.mersoft.com/2008/12/30/gwt-ext-retain-checkbox-selections-in-page-able-gridpanel/</link>
		<comments>http://blog.mersoft.com/2008/12/30/gwt-ext-retain-checkbox-selections-in-page-able-gridpanel/#comments</comments>
		<pubDate>Tue, 30 Dec 2008 17:59:24 +0000</pubDate>
		<dc:creator>Tom Bollwitt</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[Software Development]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[Javascript]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=179</guid>
		<description><![CDATA[When working on a sample project for Mersoft using GWT-EXT I came across a use case that required a data table that was page-able, had a checkbox selection per row, and needed to maintain the checkbox selections when paging.
Here is what I ended up doing. It may not be pretty, but hey, its a sample.
I [...]]]></description>
			<content:encoded><![CDATA[<p>When working on a sample project for <a title="Mersoft Corporation" href="http://www.mersoft.com">Mersoft</a> using <a href="http://code.google.com/p/gwt-ext/">GWT-EXT</a> I came across a use case that required a data table that was page-able, had a checkbox selection per row, and needed to maintain the checkbox selections when paging.</p>
<p>Here is what I ended up doing. It may not be pretty, but hey, its a sample.</p>
<p>I made a few updates to the CheckboxSelectionModel.js in order to properly update the checkbox in the Header row when a user manually (un)selects all the rows. This required that I comment out the CheckboxSelectionModel definition in the ext-all.js and include the CheckboxSelectionModel.js in my HTML. I updated the onMouseDown function as follows&#8230;</p>
<div style="text-align:left;color:#000000; background-color:#ffffff; border:solid black 1px; padding:0.5em 1em 0.5em 1em; overflow:auto;font-size:small; font-family:monospace; ">onMouseDown : <span style="color:#881350;">function</span>(e, t){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span>(e.button === 0 &amp;&amp; t.className == &#8216;x-grid3-row-checker&#8217;){ <span style="color:#236e25;">// Only fire if left-click<br />
</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;e.<span style="color:#003369;">stopEvent</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> row = e.<span style="color:#003369;">getTarget</span>(<span style="color:#760f15;">&#8216;.x-grid3-row&#8217;</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span>(row){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> index = row.rowIndex;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span>(<span style="color:#881350;">this</span>.<span style="color:#003369;">isSelected</span>(index)){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.<span style="color:#003369;">deselectRow</span>(index);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<span style="color:#881350;">else</span>{<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.<span style="color:#003369;">selectRow</span>(index, <span style="color:#881350;">true</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#236e25;">//Get the CheckboxHeader so it can be updated.<br />
</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#236e25;">//Loop through the header cells since the user may have re-ordered them&#8230;<br />
</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> cbHeader = null;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> i = 0;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> view = <span style="color:#881350;">this</span>.grid.<span style="color:#003369;">getView</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> headerCellEl = view.<span style="color:#003369;">getHeaderCell</span>(i);</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">while</span>(cbHeader == null &amp;&amp; headerCellEl != null){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span>(headerCellEl.className.<span style="color:#003369;">indexOf</span>(<span style="color:#760f15;">&#8216;x-grid3-td-checker&#8217;</span>) &gt; -<span style="color:#0000ff;">1</span>){<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader = headerCellEl.firstChild;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader = Ext.<span style="color:#003369;">fly</span>(cbHeader);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;headerCellEl = view.<span style="color:#003369;">getHeaderCell</span>(++i);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(cbHeader) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(<span style="color:#881350;">this</span>.grid.<span style="color:#003369;">getStore</span>().<span style="color:#003369;">getCount</span>() == <span style="color:#881350;">this</span>.selections.length) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#236e25;">//all the rows are selected, so check the header&#8230;<br />
</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader.<span style="color:#003369;">addClass</span>(<span style="color:#760f15;">&#8216;x-grid3-hd-checker-on&#8217;</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;} <span style="color:#881350;">else</span> {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#236e25;">//not all the rows are selected, so uncheck the header&#8230;<br />
</span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader.<span style="color:#003369;">removeClass</span>(<span style="color:#760f15;">&#8216;x-grid3-hd-checker-on&#8217;</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;},</div>
<p>I also used the code from the URL <a href="http://extjs.com/forum/showthread.php?t=45723&amp;highlight=getselectionmodel">http://extjs.com/forum/showthread.php?t=45723&amp;highlight=getselectionmodel</a>, however it too needed to be modified to update the Header checkbox.</p>
<p>I created a CheckBoxMemory.js with the following code and included it in my HTML&#8230;</p>
<div style="text-align:left;color:#000000; background-color:#ffffff; border:solid black 1px; padding:0.5em 1em 0.5em 1em; overflow:auto;font-size:small; font-family:monospace; ">Ext.<span style="color:#003369;">namespace</span>(<span style="color:#760f15;">&#8216;Ext.ux.plugins&#8217;</span>);</p>
<p>Ext.ux.plugins.CheckBoxMemory = Ext.<span style="color:#003369;">extend</span>(Object, {<br />
&nbsp;&nbsp;&nbsp;constructor : <span style="color:#881350;">function</span>(config) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(!config)<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;config = {};</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.prefix = <span style="color:#760f15;">&#8216;id_&#8217;</span>;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.items = {};<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.idProperty = config.idProperty || <span style="color:#760f15;">&#8216;id&#8217;</span>;<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;init : <span style="color:#881350;">function</span>(grid) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.grid = grid;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.view = grid.<span style="color:#003369;">getView</span>()<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.store = null;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.sm = grid.<span style="color:#003369;">getSelectionModel</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.sm.<span style="color:#003369;">on</span>(<span style="color:#760f15;">&#8216;rowselect&#8217;</span>, <span style="color:#881350;">this</span>.onSelect, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.sm.<span style="color:#003369;">on</span>(<span style="color:#760f15;">&#8216;rowdeselect&#8217;</span>, <span style="color:#881350;">this</span>.onDeselect, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.view.<span style="color:#003369;">on</span>(<span style="color:#760f15;">&#8216;refresh&#8217;</span>, <span style="color:#881350;">this</span>.reConfigure, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;reConfigure : <span style="color:#881350;">function</span>() {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.store = <span style="color:#881350;">this</span>.grid.<span style="color:#003369;">getStore</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.store.<span style="color:#003369;">on</span>(<span style="color:#760f15;">&#8216;clear&#8217;</span>, <span style="color:#881350;">this</span>.onClear, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.store.<span style="color:#003369;">on</span>(<span style="color:#760f15;">&#8216;datachanged&#8217;</span>, <span style="color:#881350;">this</span>.restoreState, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;onSelect : <span style="color:#881350;">function</span>(sm, idx, rec) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.items[<span style="color:#881350;">this</span>.<span style="color:#003369;">getId</span>(rec)] = <span style="color:#881350;">true</span>;<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;onDeselect : <span style="color:#881350;">function</span>(sm, idx, rec) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">delete</span> <span style="color:#881350;">this</span>.items[<span style="color:#881350;">this</span>.<span style="color:#003369;">getId</span>(rec)];<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;restoreState : <span style="color:#881350;">function</span>() {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(<span style="color:#881350;">this</span>.store != null) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> i = 0;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> sel = [];<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.store.<span style="color:#003369;">each</span>( <span style="color:#881350;">function</span>(rec) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> id = <span style="color:#881350;">this</span>.<span style="color:#003369;">getId</span>(rec);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(<span style="color:#881350;">this</span>.items[id] === <span style="color:#881350;">true</span>)<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;sel.<span style="color:#003369;">push</span>(i);</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;++i;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}, <span style="color:#881350;">this</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(sel.length &gt; 0){</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.sm.<span style="color:#003369;">selectRows</span>(sel);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> cbHeader = null;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> j = 0;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> view = <span style="color:#881350;">this</span>.grid.<span style="color:#003369;">getView</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> headerCellEl = view.<span style="color:#003369;">getHeaderCell</span>(j);</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">while</span><span style="color:#003369;"> </span>(cbHeader == null &amp;&amp; headerCellEl != null) {</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(headerCellEl.className.<span style="color:#003369;">indexOf</span>(<span style="color:#760f15;">&#8216;x-grid3-td-checker&#8217;</span>) &gt; -<span style="color:#0000ff;">1</span>) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader = headerCellEl.firstChild;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader = Ext.<span style="color:#003369;">fly</span>(cbHeader);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;headerCellEl = view.<span style="color:#003369;">getHeaderCell</span>(++j);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(cbHeader) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">if</span><span style="color:#003369;"> </span>(<span style="color:#881350;">this</span>.store.<span style="color:#003369;">getCount</span>() == <span style="color:#881350;">this</span>.sm.selections.length) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader.<span style="color:#003369;">addClass</span>(<span style="color:#760f15;">&#8216;x-grid3-hd-checker-on&#8217;</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;} <span style="color:#881350;">else</span> {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cbHeader.<span style="color:#003369;">removeClass</span>(<span style="color:#760f15;">&#8216;x-grid3-hd-checker-on&#8217;</span>);<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;onClear : <span style="color:#881350;">function</span>() {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">var</span> sel = [];<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">this</span>.items = {};<br />
&nbsp;&nbsp;&nbsp;},</p>
<p>&nbsp;&nbsp;&nbsp;getId : <span style="color:#881350;">function</span>(rec) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">return</span> rec.<span style="color:#003369;">get</span>(<span style="color:#881350;">this</span>.idProperty);<br />
&nbsp;&nbsp;&nbsp;}<br />
});</div>
<p>I have not had a chance to really dive in ,but you will need to make sure that your RecordDef has a FieldDef with a name of &#8220;id&#8221;, example&#8230; new StringFieldDef(&#8221;id&#8221;, 0)</p>
<p>I then created the corresponding Java class as follows.</p>
<div style="text-align:left;color:#000000; background-color:#ffffff; border:solid black 1px; padding:0.5em 1em 0.5em 1em; overflow:auto;font-size:small; font-family:monospace; "><span style="color:#881350;">package</span> com.mersoft.gwtsample.client.widgets.grid<span style="color:#683821;">;</span></p>
<p><span style="color:#881350;">import</span> com.google.gwt.core.client.JavaScriptObject<span style="color:#683821;">;</span><br />
<span style="color:#881350;">import</span> com.gwtext.client.widgets.Component<span style="color:#683821;">;</span><br />
<span style="color:#881350;">import</span> com.gwtext.client.widgets.ComponentPlugin<span style="color:#683821;">;</span></p>
<p><span style="color:#881350;">public</span> <span style="color:#881350;">class</span> CheckBoxMemoryPlugin <span style="color:#881350;">extends</span> ComponentPlugin {</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">public</span> <span style="color:#003369;">CheckBoxMemoryPlugin</span>() {<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;jsObj = <span style="color:#003369;">create</span>();<br />
&nbsp;&nbsp;&nbsp;&nbsp;}</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">protected</span> <span style="color:#881350;">native</span> JavaScriptObject <span style="color:#003369;">create</span>() <span style="color:#236e25;">/*-{<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return new $wnd.Ext.ux.plugins.CheckBoxMemory();<br />
&nbsp;&nbsp;&nbsp;&nbsp;}-*/</span>;</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;@Override<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="color:#881350;">public</span> <span style="color:#881350;">void</span> <span style="color:#003369;">init</span>(<span style="color:#440088;">Component</span> component) {<br />
&nbsp;&nbsp;&nbsp;&nbsp;}<br />
}
</div>
<p>Then you just need to add the CheckBoxMemoryPlugin to the GridPanel. (This assumes that you already have set up a Local Paging Checkbox Grid Panel)</p>
<div style="text-align:left;color:#000000; background-color:#ffffff; border:solid black 1px; padding:0.5em 1em 0.5em 1em; overflow:auto;font-size:small; font-family:monospace; ">grid.<span style="color:#003369;">addPlugin</span>(<span style="color:#881350;">new</span> <span style="color:#003369;">CheckBoxMemoryPlugin</span>());</div>
<p>Anyway, I hope this helps someone else who may be looking to solve this.</p>
<p>I still need to update the code in order to be able to get the selected row IDs, but that is for another day.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2008%2F12%2F30%2Fgwt-ext-retain-checkbox-selections-in-page-able-gridpanel%2F&amp;linkname=GWT-EXT%3A%20Retain%20Checkbox%20selections%20in%20page-able%20GridPanel"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2008/12/30/gwt-ext-retain-checkbox-selections-in-page-able-gridpanel/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>My Experience with Google AJAX toolkit</title>
		<link>http://blog.mersoft.com/2008/11/12/my-experience-with-google-ajax-toolkit/</link>
		<comments>http://blog.mersoft.com/2008/11/12/my-experience-with-google-ajax-toolkit/#comments</comments>
		<pubDate>Wed, 12 Nov 2008 16:01:52 +0000</pubDate>
		<dc:creator>Mandi Zinn</dc:creator>
				<category><![CDATA[Java/Java Frameworks]]></category>
		<category><![CDATA[Software Development]]></category>
		<category><![CDATA[AJAX]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[google web toolkit]]></category>
		<category><![CDATA[Goolge Web Toolkit]]></category>
		<category><![CDATA[GWT]]></category>
		<category><![CDATA[interface builder]]></category>
		<category><![CDATA[java]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Struts]]></category>
		<category><![CDATA[Tibco]]></category>

		<guid isPermaLink="false">http://blog.mersoft.com/?p=126</guid>
		<description><![CDATA[ 
 
 
My first task at Mersoft was to develop an ajax-rich web interface with a Java backend. I was told that it must be tabbed and was shown the existing interface which pretty much was just a file upload. The project was to keep the file upload plus have several tabs containing different types of reports [...]]]></description>
			<content:encoded><![CDATA[<p> </p>
<div id="attachment_130" class="wp-caption alignleft" style="width: 280px"><a href="http://blog.mersoft.com/wp-content/uploads/2008/11/gwt_blog.jpg"><img class="size-medium wp-image-130 " title="gwt_blog" src="http://blog.mersoft.com/wp-content/uploads/2008/11/gwt_blog.jpg" alt="Google Web Toolkit" width="270" height="253" /></a><p class="wp-caption-text">Google Web Toolkit</p></div>
<p> </p>
<p> </p>
<p>My first task at <a href="http://www.mersoft.com" target="_blank">Mersoft</a> was to develop an ajax-rich web interface with a Java backend. I was told that it must be tabbed and was shown the existing interface which pretty much was just a file upload. The project was to keep the file upload plus have several tabs containing different types of reports generated from the file upload.</p>
<p>I was originally directed to Tibco&#8217;s GI. The GI has it&#8217;s own &#8220;Interface Builder&#8221; used to build the gui. Creating tabs using the builder was easy, but it looked like the only way the interface could talk to a server was through a web service. Also, I didn&#8217;t see anything that would allow me to do a file upload. I started looking at the source code, and it appeared difficult to customize and/or expand.</p>
<p>After doing some searching, I came across <a href="http://code.google.com/webtoolkit/gettingstarted.html" target="_blank">Google&#8217;s Web Toolkit</a> (GWT). This uses Java code to build the interface and gets compiled to html and javascript. This even works with Eclipse. GWT was able to handle file uploading (although due to security issues, this had to be done with a form submit). I have been able to find lots of plugins, plus it has been very easy to expand most plugins and it seems easy to create my own plugin for GWT. Also, although I haven&#8217;t done this personally, it looks like it&#8217;s easy to integrate with a Javascript library, if the need ever arises. I was also able to integrate it with Struts 2.</p>
<p>I have looked at several other toolkits. Most of them required a lot of Javascript, even with the use of the toolkit. For me (a <a href="http://www.mersoft.com" target="_blank">Java programmer</a>), it is much easier writing code in Java than in Javascript. After reviewing the other frameworks and working with projects that do not use GWT, I highly recommend GWT and look forward to using it on future projects.</p>
<a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?linkurl=http%3A%2F%2Fblog.mersoft.com%2F2008%2F11%2F12%2Fmy-experience-with-google-ajax-toolkit%2F&amp;linkname=My%20Experience%20with%20Google%20AJAX%20toolkit"><img src="http://blog.mersoft.com/wp-content/plugins/add-to-any/share_save_171_16.gif" width="171" height="16" alt="Share/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://blog.mersoft.com/2008/11/12/my-experience-with-google-ajax-toolkit/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

