summaryrefslogtreecommitdiffstats
path: root/toolkit/content/tests/chrome/frame_popupremoving_frame.xul
blob: e8f00ce7a908878ad9ddcf05941f2c11d202db6b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
<?xml version="1.0"?>
<?xml-stylesheet href="chrome://global/skin" type="text/css"?>

<window title="Popup Removing Frame Tests"
        onload="setTimeout(init, 0)"
        xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">

<hbox>

<menu id="separatemenu1" label="Menu">
    <menupopup id="separatepopup1" onpopupshown="document.getElementById('separatemenu2').open = true">
        <menuitem label="L1 One"/>
        <menuitem label="L1 Two"/>
        <menuitem label="L1 Three"/>
    </menupopup>
</menu>

<menu id="separatemenu2" label="Menu">
    <menupopup id="separatepopup2" onpopupshown="document.getElementById('separatemenu3').open = true">
        <menuitem label="L2 One"/>
        <menuitem label="L2 Two"/>
        <menuitem label="L2 Three"/>
    </menupopup>
</menu>

<menu id="separatemenu3" label="Menu" onpopupshown="document.getElementById('separatemenu4').open = true">
    <menupopup id="separatepopup3">
        <menuitem label="L3 One"/>
        <menuitem label="L3 Two"/>
        <menuitem label="L3 Three"/>
    </menupopup>
</menu>

<menu id="separatemenu4" label="Menu" onpopupshown="document.getElementById('nestedmenu1').open = true">
    <menupopup id="separatepopup3">
        <menuitem label="L4 One"/>
        <menuitem label="L4 Two"/>
        <menuitem label="L4 Three"/>
    </menupopup>
</menu>

</hbox>

<menu id="nestedmenu1" label="Menu">
    <menupopup id="nestedpopup1" onpopupshown="if (event.target == this) this.firstChild.open = true">
      <menu id="nestedmenu2" label="Menu">
        <menupopup id="nestedpopup2" onpopupshown="if (event.target == this) this.firstChild.open = true">
          <menu id="nestedmenu3" label="Menu">
            <menupopup id="nestedpopup3" onpopupshown="if (event.target == this) this.firstChild.open = true">
              <menu id="nestedmenu4" label="Menu" onpopupshown="parent.popupsOpened()">
                <menupopup id="nestedpopup4">
                  <menuitem label="Nested One"/>
                  <menuitem label="Nested Two"/>
                  <menuitem label="Nested Three"/>
                </menupopup>
              </menu>
            </menupopup>
          </menu>
        </menupopup>
      </menu>
    </menupopup>
</menu>

<script class="testbody" type="application/javascript">
<![CDATA[

function init()
{
  document.getElementById("separatemenu1").open = true;
}

]]>
</script>

</window>