-
8 Aug 2009 1:10 PM #31
I cant get this much needed functionality to work and I really need it for a project Im working on. Anyone getting this to work with Ext JS 3.0? I realize this thread is for 2.0 though, but I didnt want to start a new one since this may still work in Ext 3.0 for some...
Ive tried everything in this thread. Ive also tried with/without Ext.grid.RowNumberer() but it makes no difference.
Im kind of stuck on this at the moment, so if anyone has some hints...
-
10 Aug 2009 2:08 AM #32
I've got cell text selection working in an ExtJS 3 grid:
- CSS style:
.x-grid3-cell-selectable, .x-grid3-cell-selectable * {-moz-user-select: text!important; -khtml-user-select: text!important}
- Code:
Code:viewConfig: { templates = { cell: new Ext.Template( '<td class="x-grid3-col x-grid3-cell x-grid3-td-{id} x-grid3-cell-selectable {css}"' + ' style="{style}" tabIndex="0" {cellAttr}>', '<div class="x-grid3-cell-inner x-grid3-col-{id}" {attr}>{value}</div>', '</td>') } }
-
10 Aug 2009 2:15 AM #33Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 40
-
10 Aug 2009 5:02 AM #34
Hi guys and thank you for the very quick reply. I had tried everything in the Grid FAQ yesterday (which is excellent by the way!) and I saw this tip but it didnt work.
It turns out that I had enableDragDrop set to true which makes it fail. When its set to false, it works perfectly.
Is there a workaround for the cell text copy when using drag & drop?
Thanks in advance! Having a lot of fun with your product.
-
12 Aug 2009 3:33 AM #35
This should really be a standard feature of the grid. I imagine a lot of people end up implementing this workaround.
-
12 Aug 2009 3:45 AM #36
Yes I agree. Being able to copy/paste entire rows is what Im personally would love to have as built-in functionality. It must be extremely common that people need to get their data into another application like a email program or spreadsheet.
The absolute best would be if it was possible to get it into the clipboard, but after doing some googling on this topic, it seems its awkward to do. Every copy/paste to browser clipboard solution out there seems to be based on having a hidden flash component and then get it into the clipboard from there.
However, in version 10 of Flash, this was made even more difficult since Adobe (for security reasons, I guess) now requires that the user clicks the flash component for copy into clipboard to work. So there are some hacks out there (ZeroClipboard for example) where you can position a invisible flash movie over a button and get it into the clipboard. Not very elegant, but I guess its the only way for now.
-
22 Sep 2009 6:17 AM #37
-
29 Sep 2009 2:14 PM #38
-
15 Oct 2009 1:29 PM #39
+1 for this
or +1000
This is very very annoying "feature" of grid. In this long thread, it was never explained why this behavior is default. It is strange for me, because all native tables, texts, controls etc in html are selectable by default, I think. So it looks like this selection-disablement in grids was made by purpose. But what purpose? I can't imagine any use case where is could be useful. So why?
Please, turn this anti-feature off by default in Ext 3.1. If it is needed by anybody in some cases, probably there can be an option in component settings to turn it on.
-
16 Oct 2009 3:17 AM #40
@grzegorz.borkowski
I suspect because the grid has its own row-level selection. Text selection and row selection never mash together perfectly. With the hacks you find in this page you can get reasonably close, but there are odd quirks in the behavior when the text is selectable.


Reply With Quote
