| <!DOCTYPE html> |
| <html> |
| <script src="../fast/js/resources/js-test-pre.js"></script> |
| <body> |
| <div id="embedOwner"> |
| <embed id="embedElem" type="application/x-webkit-test-netscape" width=100 height=100></embed> |
| <object id="objectElem" type="application/x-webkit-test-netscape" windowedPlugin="false" width=100 height=100 tabIndex=1></object> |
| |
| <embed id="embedElemWithFallbackContents" |
| type="application/x-webkit-test-netscape" width=100 height=100 tabIndex=-1>Fallback contents.</embed> |
| <object id="objectElemWithFallbackContents" type="application/x-webkit-test-netscape" windowedPlugin="false" width=100 height=100>Fallback contents.</object> |
| |
| <embed id="noPluginEmbedElem" type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 tabIndex=1></embed> |
| <object id="noPluginObjectElem" type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100></object> |
| |
| <embed id="noPluginEmbedElemWithFallbackContents" |
| type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 tabIndex=0>Fallback contents.</embed> |
| <object id="noPluginObjectElemWithFallbackContents" type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100>Fallback contents.</object> |
| |
| <embed id="noPluginEmbedElemWithDisplayNone" type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 tabindex=-1 style="display:none"></embed> |
| <object id="noPluginObjectElemWithDisplayNone" type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 style="display:none"></object> |
| |
| <embed id="noPluginEmbedElemWithContenteditable" |
| type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 contenteditable></embed> |
| <object id="noPluginObjectElemWithContenteditable" |
| type="application/x-no-such-plugin" windowedPlugin="false" width=100 height=100 tabindex=-1 contenteditable></object> |
| </div> |
| |
| <script> |
| description('Test for the tabIndex of embedded plugins. Plugins may be focusable so their tabIndex should be 0 by default.'); |
| |
| var owner = document.getElementById("embedOwner"); |
| for (var i = 0; i < owner.childNodes.length; ++i) { |
| pluginElement = owner.childNodes[i]; |
| if (pluginElement.id) { |
| tabIndexAttribute = pluginElement.getAttribute("tabindex"); |
| expectedTabIndex = tabIndexAttribute ? tabIndexAttribute : '0'; |
| shouldBe('"' + pluginElement.id + '"; pluginElement.tabIndex', expectedTabIndex); |
| } |
| } |
| </script> |
| <script src="../fast/js/resources/js-test-post.js"></script> |
| </body> |
| </html> |