diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 01:47:29 +0000 |
commit | 0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d (patch) | |
tree | a31f07c9bcca9d56ce61e9a1ffd30ef350d513aa /layout/reftests/xul/menuitem-key.xhtml | |
parent | Initial commit. (diff) | |
download | firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.tar.xz firefox-esr-0ebf5bdf043a27fd3dfb7f92e0cb63d88954c44d.zip |
Adding upstream version 115.8.0esr.upstream/115.8.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'layout/reftests/xul/menuitem-key.xhtml')
-rw-r--r-- | layout/reftests/xul/menuitem-key.xhtml | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/layout/reftests/xul/menuitem-key.xhtml b/layout/reftests/xul/menuitem-key.xhtml new file mode 100644 index 0000000000..d9e8a08602 --- /dev/null +++ b/layout/reftests/xul/menuitem-key.xhtml @@ -0,0 +1,47 @@ +<?xml version="1.0"?> +<?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?> +<window class="reftest-wait" onload="changeKeys()" + xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"> + +<menuitem id="m1" label="Menu1" key="keyone"/> +<menuitem id="m2" label="Menu2" key="keytwo"/> +<menuitem id="m3" label="Menu3"/> +<menuitem id="m4" label="Menu4"/> +<menuitem id="m5" label="Menu5"/> +<menuitem id="m6" label="Menu6" key="keythree" acceltext="Text"/> +<menuitem id="m7" label="Menu7" key="keythree" acceltext="Text"/> +<menuitem id="m8" label="Menu8" key="keythree" acceltext="Text"/> +<menuitem id="m9" label="Menu9" key="keytwo"/> + +<script> +function changeKeys() +{ + document.getElementById("m1").setAttribute("key", "keytwo"); + document.getElementById("m2").removeAttribute("key"); + document.getElementById("m3").setAttribute("key", "keythree"); + + document.getElementById("m4").setAttribute("key", "keyone"); + document.getElementById("m4").setAttribute("acceltext", "Text"); + + document.getElementById("m5").setAttribute("acceltext", "Text"); + document.getElementById("m5").setAttribute("key", "keytwo"); + + document.getElementById("m6").removeAttribute("key"); + document.getElementById("m7").removeAttribute("acceltext"); + + document.getElementById("m8").removeAttribute("key"); + document.getElementById("m8").removeAttribute("acceltext"); + + document.getElementById("m9").removeAttribute("key"); + + document.documentElement.className=''; +} +</script> + +<keyset> + <key id="keyone" key="Z" modifiers="control"/> + <key id="keytwo" key="Y" modifiers="control"/> + <key id="keythree" key="X" modifiers="accel"/> +</keyset> + +</window> |