()
| 1529 | if (te.selectionStart != null) { |
| 1530 | if (!ie || (ie && ie_version < 9)) prepareSelectAllHack(); |
| 1531 | var i = 0, poll = function() { |
| 1532 | if (display.selForContextMenu == cm.doc.sel && te.selectionStart == 0 && |
| 1533 | te.selectionEnd > 0 && input.prevInput == "\u200b") |
| 1534 | operation(cm, commands.selectAll)(cm); |
| 1535 | else if (i++ < 10) display.detectingSelectAll = setTimeout(poll, 500); |
| 1536 | else display.input.reset(); |
| 1537 | }; |
| 1538 | display.detectingSelectAll = setTimeout(poll, 200); |
| 1539 | } |
| 1540 | } |