6 <p id=
"description"><select
> test for opening two popup menus.
</p>
7 <div id=
"console"></div>
8 <p id=
"debug">PASS if the test didn't crash.
</p>
10 if (window
.testRunner
)
11 testRunner
.dumpAsText();
13 var parent
= document
.createElement('div');
14 parent
.innerHTML
= '<select id="sl1">'
15 + '<option>one</option>'
16 + '<option>two</option>'
17 + '<option>three</option>'
18 + '<option>four</option>'
19 + '<option>five</option>'
20 + '<option>six</option>'
21 + '<option>seven</option>'
22 + '<option>eight</option>'
23 + '<option>nine</option>'
24 + '<option>ten</option>'
25 + '<option>eleven</option>'
26 + '<option>twelve</option>'
27 + '<option>thirteen</option>'
28 + '<option>fourteen</option>'
29 + '<option>fifteen</option>'
30 + '<option>sixteen</option>'
31 + '<option>seventeen</option>'
34 + '<option>one</option>'
35 + '<option>two</option>'
36 + '<option>three</option>'
38 document
.body
.appendChild(parent
);
40 function mouseDownOnSelect(selId
)
42 var sl
= document
.getElementById(selId
);
43 var event
= document
.createEvent("MouseEvent");
44 event
.initMouseEvent("mousedown", true, true, document
.defaultView
, 1, sl
.offsetLeft
, sl
.offsetTop
, sl
.offsetLeft
, sl
.offsetTop
, false, false, false, false, 0, document
);
45 sl
.dispatchEvent(event
);
48 mouseDownOnSelect("sl1");
49 mouseDownOnSelect("sl2");