-
6 Sep 2011 3:01 AM #71
Try this solution. Works in all browsers

PHP Code:.x-grid-row ,.x-grid-cell, .x-unselectable, .x-unselectable * {
-webkit-user-select: text !important;
-o-user-select: text !important;
-khtml-user-select: all !important;
-ms-user-select: text !important;
user-select: text !important;
-moz-user-select: text !important;
}
PHP Code:if(typeof Ext != 'undefined'){
Ext.core.Element.prototype.unselectable = function(){return this;};
Ext.view.TableChunker.metaRowTpl = [
'<tr class="' + Ext.baseCSSPrefix + 'grid-row {addlSelector} {[this.embedRowCls()]}" {[this.embedRowAttr()]}>',
'<tpl for="columns">',
'<td class="{cls} ' + Ext.baseCSSPrefix + 'grid-cell ' + Ext.baseCSSPrefix + 'grid-cell-{columnId} {{id}-modified} {{id}-tdCls} {[this.firstOrLastCls(xindex, xcount)]}" {{id}-tdAttr}><div class="' + Ext.baseCSSPrefix + 'grid-cell-inner ' + Ext.baseCSSPrefix + 'unselectable" style="{{id}-style}; text-align: {align};">{{id}}</div></td>',
'</tpl>',
'</tr>'
];
}
www.bizzclick.com - Pay Per Click solutions
-
20 Sep 2011 1:02 PM #72
for ExtJS 4
where GRIDID is your grid id in which you will need to select and copy dataCode:div#GRIDID div.x-unselectable { -webkit-user-select: text !important; -o-user-select: text !important; -khtml-user-select: all !important; -ms-user-select: text !important; user-select: text !important; -moz-user-select: text !important; } div#GRIDID div.x-unselectable tr.x-grid-row div.x-grid-rowwrap-div td.x-grid-cell { -webkit-user-select: text !important; -o-user-select: text !important; -khtml-user-select: all !important; -ms-user-select: text !important; user-select: text !important; -moz-user-select: text !important; } div#GRIDID div.x-unselectable tr.x-grid-row div.x-grid-rowwrap-div td.x-grid-cell div.x-unselectable { -webkit-user-select: text !important; -o-user-select: text !important; -khtml-user-select: all !important; -ms-user-select: text !important; user-select: text !important; -moz-user-select: text !important; } div#GRIDID div.x-unselectable tr.x-grid-row { -webkit-user-select: text !important; -o-user-select: text !important; -khtml-user-select: all !important; -ms-user-select: text !important; user-select: text !important; -moz-user-select: text !important; }
-
17 Nov 2011 4:49 AM #73
GridView select
GridView select
Hi
I created gridview(ie 5 columns, 12 rows).. I want to make 1 row clickable, not all (for example: ID is a Single columnfield) ID in 12 rows should be able to click like we using link in html... if we click on particular ID it should display some other datas in other table(ie another grid view)... pls help me out sir... i am new to extjs..
Clickable and how to give link is needed... pls help me... Thanks in advance..
-
18 Jan 2012 9:58 PM #74
This solution is working for all browsers
This solution is working for all browsers
grid.disableTextSelection(false);
Cheers
-
26 Apr 2012 2:39 PM #75
there is no such method for grids or anywhere else in extjs: disableTextSelection
-
16 Jul 2012 5:09 AM #76
I have ext.3.4.0.
This text select doesn't work in Chrome:
It works in IE. Any idea?Code:if (!Ext.grid.GridView.prototype.templates) { Ext.grid.GridView.prototype.templates = {}; } Ext.grid.GridView.prototype.templates.cell = new Ext.Template( '<td class="x-grid3-col x-grid3-cell x-grid3-td-{id} x-selectable {css}" style="{style}" tabIndex="0" {cellAttr}>', '<div class="x-grid3-cell-inner x-grid3-col-{id}" {attr}>{value}</div>', '</td>' );
br, Simon
-
5 Sep 2012 4:58 AM #77
Hello
your code is very good. Can we apply it only for a specific grid?
Thank you
-
5 Sep 2012 5:25 AM #78
-
7 Sep 2012 1:49 AM #79
Hello
this code works in IE
if(typeof (Ext) != 'undefined'){
Ext.core.Element.prototype.unselectable = function(){return this;};
Ext.view.TableChunker.metaRowTpl = [
'<tr class="' + Ext.baseCSSPrefix + 'grid-row {addlSelector} {[this.embedRowCls()]}" {[this.embedRowAttr()]}>',
'<tpl for="columns">',
'<td class="{cls} ' + Ext.baseCSSPrefix + 'grid-cell ' + Ext.baseCSSPrefix + 'grid-cell-{columnId} {{id}-modified} {{id}-tdCls} {[this.firstOrLastCls(xindex, xcount)]}" {{id}-tdAttr}><div class="' + Ext.baseCSSPrefix + 'grid-cell-inner ' + Ext.baseCSSPrefix + 'unselectable" style="{{id}-style}; text-align: {align};">{{id}}</div></td>',
'</tpl>',
'</tr>'
];
}
but after I change value of record which cause the grid redraw, it doesn't work any more. How can I solve it?
Thank you
-
11 Sep 2012 1:25 AM #80
This code does not work for ExtJS 4. I copied this code in my CSS. Do i need to copy it to ext.css?


Reply With Quote
