| <!DOCTYPE html> |
| <html> |
| <body> |
| <div id="editor" contenteditable><div>Hello %)</div><div><object type="application/x-something" height="50" width="50" border="1"></object><br><div>World</div></div></div> |
| <script src="../../resources/dump-as-markup.js"></script> |
| <script> |
| |
| Markup.description('This tests moving right and left by word boundary across an object element. WebKit should not hang.'); |
| editor.focus(); |
| getSelection().setPosition(editor, 0); |
| |
| Markup.dump(editor, 'Initial state'); |
| for (let i = 0; i < 3; i++) { |
| getSelection().modify('move', 'right', 'word'); |
| Markup.dump(editor, `Move right count: ${i + 1}`); |
| } |
| |
| for (let i = 0; i < 3; i++) { |
| getSelection().modify('move', 'left', 'word'); |
| Markup.dump(editor, `Move left count: ${i + 1}`); |
| } |
| |
| </script> |
| </body> |
| </html> |