Upstream version 7.36.149.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / LayoutTests / editing / selection / unrendered-005.html
1 <html> 
2 <head>
3
4 <style>
5 body { overflow:hidden; }
6 .editing { 
7     border: solid red 50px;
8     font-size: 24px; 
9     line-height: 48px; 
10     padding: 24px; 
11     margin: 64px;
12     width: 600px; 
13 }
14 </style>
15 <script src=../editing.js language="JavaScript" type="text/JavaScript" ></script>
16
17 <script>
18
19 function editingTest() {
20     var elem = document.getElementById("test-2");
21     var selection = window.getSelection();
22     selection.collapse(elem.firstChild, 2);
23     extendSelectionBackwardByCharacterCommand();    
24     moveSelectionForwardByCharacterCommand();    
25 }
26
27 </script>
28
29 <title>Editing Test</title> 
30 </head> 
31 <body>
32 <div contenteditable id="root" class="editing">
33 <span id="test-1">foo</span><span id="test-2" style='display: none;'>bar</span> baz
34 </div>
35
36 <script>
37 runEditingTest();
38 </script>
39
40 </body>
41 </html>