mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-03 18:47:53 +00:00
381332c51e
This was generated with the script at https://bug1544051.bmoattachments.org/attachment.cgi?id=9058672 Differential Revision: https://phabricator.services.mozilla.com/D27761 --HG-- extra : moz-landing-system : lando
20 lines
748 B
HTML
20 lines
748 B
HTML
<!doctype html>
|
|
<script src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
<img id="i" src="green.png">
|
|
<textarea id="t"></textarea>
|
|
|
|
<script>
|
|
let loaded = new Promise(resolve => addLoadEvent(resolve));
|
|
add_task(async function() {
|
|
await loaded;
|
|
SpecialPowers.setCommandNode(window, document.getElementById("i"));
|
|
SpecialPowers.doCommand(window, "cmd_copyImageContents");
|
|
let input = document.getElementById("t");
|
|
input.focus();
|
|
var controller =
|
|
SpecialPowers.wrap(input).controllers.getControllerForCommand("cmd_paste");
|
|
is(controller.isCommandEnabled("cmd_paste"), true,
|
|
"paste should be enabled in html textareas when an image is on the clipboard");
|
|
});
|
|
</script>
|