Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>I had the same problem as you have and I finally found the solution from a pull request made by the user <i><b>icoxfog417</b></i> (thanks mate), the pull request is not yet approved (hopefully soon) but I tried it and it works on all 3 browsers which I tried (in my case FF27, IE8, Chrome31). You do have to modify 1 of the core file <code>slick.grid.js</code> but it's worth it :) <br/>The pull request is this one: <a href="https://github.com/mleibman/SlickGrid/pull/746/files" rel="nofollow">Pull Request #746: fix issue#739</a> <br/><br/>The code change is simple and looks like this:<br/> Modify the file <code>slick.grid.js</code> at line 2236, replace the code with this:</p> <pre><code>// if this click resulted in some cell child node getting focus, // don't steal it back - keyboard events will still bubble up // IE9+ seems to default DIVs to tabIndex=0 instead of -1, so check for cell clicks directly. if (e.target != document.activeElement || $(e.target).hasClass("slick-cell")) { var selection = getTextSelection(); //store text-selection and restore it after setFocus(); setTextSelection(selection); } </code></pre> <p>then insert at line 2418 (after the <code>setFocus()</code> function), insert this new code: <br/></p> <pre><code>//This get/set methods are used for keeping text-selection. These don't consider IE because they don't loose text-selection. function getTextSelection(){ var textSelection = null; if (window.getSelection) { var selection = window.getSelection(); if (selection.rangeCount &gt; 0) { textSelection = selection.getRangeAt(0); } } return textSelection; } function setTextSelection(selection){ if (window.getSelection &amp;&amp; selection) { var target = window.getSelection(); target.removeAllRanges(); target.addRange(selection); } } </code></pre> <p>Voilà!!! Quite happy about it :)</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload