equal
deleted
inserted
replaced
29 |
29 |
30 getSelectionInfo = function () { |
30 getSelectionInfo = function () { |
31 var startNode = null, endNode = null, startOffset = 0, endOffset = 0, text = '' ; |
31 var startNode = null, endNode = null, startOffset = 0, endOffset = 0, text = '' ; |
32 |
32 |
33 if (window.getSelection) { // everything else than IE |
33 if (window.getSelection) { // everything else than IE |
|
34 // SID: if on safari_mobile get the previous meaningfull selection from a global variable set in text_view_comments.html |
34 var userSelection = safari_mobile ? storedSelection : window.getSelection (); |
35 var userSelection = safari_mobile ? storedSelection : window.getSelection (); |
35 |
36 |
36 if (userSelection.rangeCount > 0) { |
37 if (userSelection.rangeCount > 0) { |
37 var range = userSelection.getRangeAt(0) ; |
38 var range = userSelection.getRangeAt(0) ; |
38 text = range.toString() ; |
39 text = range.toString() ; |