OLD | NEW |
---|---|
1 <html> | 1 <html> |
2 <head> | 2 <head> |
3 | 3 |
4 <style> | 4 <style> |
5 .editing { | 5 .editing { |
6 border: 2px solid red; | 6 border: 2px solid red; |
7 padding: 12px; | 7 padding: 12px; |
8 font-size: 24px; | 8 font-size: 24px; |
9 } | 9 } |
10 .cell { | 10 .cell { |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
58 range.setStart($("test").querySelectorAll("li")[0], 0); | 58 range.setStart($("test").querySelectorAll("li")[0], 0); |
59 var selection = window.getSelection(); | 59 var selection = window.getSelection(); |
60 selection.removeAllRanges(); | 60 selection.removeAllRanges(); |
61 selection.addRange(range); | 61 selection.addRange(range); |
62 for (var i = 0; i < 6; ++i) | 62 for (var i = 0; i < 6; ++i) |
63 selection.modify('extend', 'forward', 'word'); | 63 selection.modify('extend', 'forward', 'word'); |
64 shouldBeEqualToString('selection.type', 'Range'); | 64 shouldBeEqualToString('selection.type', 'Range'); |
65 shouldBe('selection.anchorNode', '$("test").querySelectorAll("li")[0].childNodes [0]'); | 65 shouldBe('selection.anchorNode', '$("test").querySelectorAll("li")[0].childNodes [0]'); |
66 shouldBe('selection.anchorOffset', '0'); | 66 shouldBe('selection.anchorOffset', '0'); |
67 shouldBe('selection.focusNode', '$("test").querySelectorAll("li a")[3].firstChil d'); | 67 shouldBe('selection.focusNode', '$("test").querySelectorAll("li a")[3].firstChil d'); |
68 shouldBe('selection.focusOffset', '4'); | 68 shouldBe('selection.focusOffset', '5'); |
mario.prada
2014/03/27 14:12:39
This needs to be changed now because the starting
| |
69 if (window.testRunner) | 69 if (window.testRunner) |
70 $('container').outerHTML = ''; | 70 $('container').outerHTML = ''; |
71 </script> | 71 </script> |
72 </body> | 72 </body> |
73 </html> | 73 </html> |
OLD | NEW |