The last thing that is preventing text selection from working in IE7 is this code in the MouseKernel.__mouseEvent which<br>which explicitly cancels a mouse event when it's keyCode == 0. <br><br>Now, I'm trying to understand why we need this code.<br>
<br>As I understand it, the LzKeyboardKernel.__cancelKeys flag is being set by the LzInputTextSprite<br>when it wants to make sure that a text field does not respond to any mouse or keyboard events (?). <br><br>In addition, the reason we're passing the mouse event at all to KeyboardKernel is to inspect it's keyCode field for control keys that might be down, but that we didn't get explicit keyboard events for.<br>
<br>So ... if I were to remove this block of code from LzMouseKernel.__mouseEvent, what would<br>I be breaking? <br><br>It seems like if I removed this code, then in some cases input text fields may respond to<br>mouse events when we don't want them to? <br>
<br><br><br> // send option/shift/ctrl key events<br> if (window['LzKeyboardKernel'] && LzKeyboardKernel['__updateControlKeys']) {<br> LzKeyboardKernel.__updateControlKeys(e);<br>
-<br>- // FIXME: [20090602 anba] this prevents text selection, see LPP-8200<br>- if (LzKeyboardKernel.__cancelKeys && e.keyCode == 0) {<br>- e.cancelBubble = true;<br>- e.returnValue = false;<br>
- }<br><br><br><br clear="all"><br>-- <br>Henry Minsky<br>Software Architect<br><a href="mailto:hminsky@laszlosystems.com">hminsky@laszlosystems.com</a><br><br><br>