summaryrefslogtreecommitdiffstats
path: root/editor/libeditor/tests/test_contenteditable_text_input_handling.html
diff options
context:
space:
mode:
Diffstat (limited to 'editor/libeditor/tests/test_contenteditable_text_input_handling.html')
-rw-r--r--editor/libeditor/tests/test_contenteditable_text_input_handling.html5
1 files changed, 2 insertions, 3 deletions
diff --git a/editor/libeditor/tests/test_contenteditable_text_input_handling.html b/editor/libeditor/tests/test_contenteditable_text_input_handling.html
index c00056a0f0..13a00a65b8 100644
--- a/editor/libeditor/tests/test_contenteditable_text_input_handling.html
+++ b/editor/libeditor/tests/test_contenteditable_text_input_handling.html
@@ -34,8 +34,7 @@ function runTests() {
aEvent.preventDefault(); // prevent the browser default behavior
},
};
- var els = Services.els;
- els.addSystemEventListener(window, "keypress", listener, false);
+ SpecialPowers.wrap(window).addEventListener("keypress", listener, { mozSystemGroup: true });
var staticContent = document.getElementById("static");
staticContent._defaultValue = getTextValue(staticContent);
@@ -306,7 +305,7 @@ function runTests() {
testTextInput(inputInEditor);
testTextInput(textareaInEditor);
- els.removeSystemEventListener(window, "keypress", listener, false);
+ SpecialPowers.wrap(window).removeEventListener("keypress", listener, { mozSystemGroup: true });
SimpleTest.finish();
}