mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
Fix #13393. Avoid IE9 activeElement of death.
This commit is contained in:
16
test/data/event/focusElem.html
Normal file
16
test/data/event/focusElem.html
Normal file
@@ -0,0 +1,16 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
|
||||
<title>.focus() (activeElement access #13393)</title>
|
||||
|
||||
<script src="../../jquery.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<a href="#" id="frame-link"></a>
|
||||
<script>
|
||||
jQuery("#frame-link").focus();
|
||||
window.parent.iframeCallback( true );
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -2416,6 +2416,11 @@ testIframeWithCallback( "jQuery.ready promise", "event/promiseReady.html", funct
|
||||
ok( isOk, "$.when( $.ready ) works" );
|
||||
});
|
||||
|
||||
testIframeWithCallback( "Focusing iframe element", "event/focusElem.html", function( isOk ) {
|
||||
expect(1);
|
||||
ok( isOk, "Focused an element in an iframe" );
|
||||
});
|
||||
|
||||
// need PHP here to make the incepted IFRAME hang
|
||||
if ( hasPHP ) {
|
||||
testIframeWithCallback( "jQuery.ready synchronous load with long loading subresources", "event/syncReady.html", function( isOk ) {
|
||||
|
||||
Reference in New Issue
Block a user