Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / editing / spelling / spelling-on-context-menu-key.html
blob8fcc235d6a41f3ff4cde03876f3df050d2675a4b
1 <!DOCTYPE html>
2 <html>
3 <head>
4 <script src="../../resources/js-test.js"></script>
5 <script src="resources/util.js"></script>
6 </head>
7 <body>
8 <div id="container">
9 <div id="destination" contentEditable></div>
10 </div>
12 <script>
14 description("Spell check selects the misspelled word on context menu key. " +
15 "To test manually, type 'wellcome home.' place the cursor on 'wellcome', and press the context menu key. " +
16 "The test succeeds when 'wellcome' is selected after the context menu key.");
18 initSpellTest("destination", "wellcome home.", function(textNode) {
19 var behaviors = ["win", "mac"];
20 for (var i = 0; i < behaviors.length; i++) {
21 internals.settings.setEditingBehavior(behaviors[i]);
23 // Place cursor on "wellcome".
24 window.getSelection().removeAllRanges();
25 var range = document.createRange();
26 range.setStart(textNode, 2);
27 range.setEnd(textNode, 2);
28 window.getSelection().addRange(range);
30 // Context menu key to show the context menu.
31 eventSender.keyDown("menu");
33 // Esc to close the context menu.
34 eventSender.keyDown("escape");
36 shouldBeEqualToString("window.getSelection().toString()", "wellcome");
38 });
40 </script>
41 </body>
42 </html>