Closed Bug 644339 Opened 13 years ago Closed 13 years ago

Focus/blur with window.open not working

Categories

(Firefox :: General, defect)

x86
Windows 7
defect
Not set
normal

Tracking

()

RESOLVED DUPLICATE of bug 634067

People

(Reporter: malet.bertrand, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows NT 6.1; rv:2.0) Gecko/20100101 Firefox/4.0
Build Identifier: Mozilla/5.0 (Windows NT 6.1; rv:2.0) Gecko/20100101 Firefox/4.0

When opening a new window in javascript with window.open you can't change the new window focus with focus() or blur().

Reproducible: Always

Steps to Reproduce:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<body>
<script type="text/javascript">
function showPopup()
{
  var popup = window.open(
    "http://www.mozilla.com",
    "mozWin",
    "menubar=yes,location=yes,resizable=yes,scrollbars=yes,status=yes"
  );
  
  popup.blur();
  window.focus();
}
</script>
<a href="#" onclick="showPopup();">ouvrir popup</a>
</body>
</html>
Actual Results:  
New window stay with focus

Expected Results:  
New window should loose focus
Status: UNCONFIRMED → RESOLVED
Closed: 13 years ago
Resolution: --- → DUPLICATE
not exactly a dupe but rather this is intended by that bug. marking as dupe of bug 634067
You need to log in before you can comment on or make changes to this bug.