Upgrade to ExtJS 3.1.1 - Released 02/08/2010
[extjs.git] / examples / ux / CheckColumn.js
index 49b658b..59ceb99 100644 (file)
@@ -1,6 +1,6 @@
 /*!
- * Ext JS Library 3.1.0
- * Copyright(c) 2006-2009 Ext JS, LLC
+ * Ext JS Library 3.1.1
+ * Copyright(c) 2006-2010 Ext JS, LLC
  * licensing@extjs.com
  * http://www.extjs.com/license
  */
@@ -59,7 +59,7 @@ Ext.ux.grid.CheckColumn.prototype ={
     },\r
 \r
     onMouseDown : function(e, t){\r
-        if(t.className && t.className.indexOf('x-grid3-cc-'+this.id) != -1){\r
+        if(Ext.fly(t).hasClass(this.createId())){\r
             e.stopEvent();\r
             var index = this.grid.getView().findRowIndex(t);\r
             var record = this.grid.store.getAt(index);\r
@@ -69,7 +69,11 @@ Ext.ux.grid.CheckColumn.prototype ={
 \r
     renderer : function(v, p, record){\r
         p.css += ' x-grid3-check-col-td'; \r
-        return '<div class="x-grid3-check-col'+(v?'-on':'')+' x-grid3-cc-'+this.id+'">&#160;</div>';\r
+        return String.format('<div class="x-grid3-check-col{0} {1}">&#160;</div>', v ? '-on' : '', this.createId());\r
+    },\r
+    \r
+    createId : function(){\r
+        return 'x-grid3-cc-' + this.id;\r
     }\r
 };\r
 \r