Closed Bug 362105 Opened 14 years ago Closed 14 years ago

widows.focus() does not focus window nor brings it in front

Categories

(Firefox :: General, defect)

x86
Windows XP
defect
Not set

Tracking

()

RESOLVED DUPLICATE of bug 355482

People

(Reporter: kk, Unassigned)

Details

User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1) Gecko/20061010 Firefox/2.0
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1) Gecko/20061010 Firefox/2.0

function blank(target, loc, x, y) {
    w= window.open(loc,target,"width="+x+",height="+y+",resizable=yes,scrollbars=yes,status=no,menubar=no,titlebar=no',location=yes",true);
    w.focus();
    return false ;
 }

<a href="newfil.htm" onclick="return blank('kom',this.href)">

makes a new window all right, but doesn't focus or bring it in front.



Reproducible: Always




The current "Minefield" version (as of today 2006.11.28) does not seem to have the error.
Check the setting of dom.disable_window_flip (as set by the "Raise or lower windows" checkbox in the advanced javascript settings). If this is true then window.focus() calls from content script should not have any effect and if false then they should work.
Is the window behind something else when it's first created, or is the problem that the window isn't brought in front when it already exists?
(In reply to comment #2)
> Is the window behind something else when it's first created, or is the problem
> that the window isn't brought in front when it already exists?

The latter, but the "bug" id "fixed" by comment # 1: Raise or lower
windows must be checked. This is a little akward that a browser, standard initialised, cannot do this.
As per comment 3, not an actual bug, merely that the default browser settings deny this sort of behaviour
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → INVALID
Status: RESOLVED → UNCONFIRMED
Resolution: INVALID → ---

*** This bug has been marked as a duplicate of 355482 ***
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago14 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.