Closed
Bug 357814
Opened 18 years ago
Closed 18 years ago
Scripts are no longer allowed to call window.focus() (except during events when popups would be allowed)
Categories
(Firefox :: General, defect)
Tracking
()
RESOLVED
INVALID
People
(Reporter: robert.stopp, Unassigned)
References
Details
Attachments
(1 file, 1 obsolete file)
(deleted),
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1) Gecko/20061010 Firefox/2.0
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1) Gecko/20061010 Firefox/2.0
Windows created by "newWin = window.open(url, name, features)" cant get focus from creating window by "newWin.focus()" in Firefox 2.0! Additionaly the flags "dependent" or "modal" are not more working (dont work) like described in http://developer.mozilla.org/en/docs/DOM:window.open!
Should that by a new Feature against spam-Windows/ annoying Windows - they mostly work in that way (loading in the background)?! There is not a chance to bring a Properties Dialog, a Filechooser, a Imagegalerie in front to the main window by the main window if they lost the focus.
Reproducible: Always
Steps to Reproduce:
1. See details above!
2.
3.
Actual Results:
nothing happens
Expected Results:
created window get the focus
Updated•18 years ago
|
Assignee: nobody → general
Component: General → DOM
Product: Firefox → Core
QA Contact: general → ian
Version: unspecified → 1.8 Branch
Reporter | ||
Comment 1•18 years ago
|
||
try that with every other browser than FF 2.0! They all do.
Reporter | ||
Comment 2•18 years ago
|
||
Beta-testing for a web-developer would be easier if the Beta takes her own (virgin-like) profile dir and the standard browser (FF 1.5.x) must not be closed.
See http://portableapps.com/apps/internet/firefox_portable !
The Web-developer dont asks: work my browser-extensions? - he asks: work my app.
Reporter | ||
Updated•18 years ago
|
Component: DOM → General
Product: Core → Firefox
Version: 1.8 Branch → 1.0 Branch
Comment 3•18 years ago
|
||
Are scripts allowed to raise or lower windows by default? I don't think so.
Component: General → Bookmarks
Reporter | ||
Comment 4•18 years ago
|
||
@martijn look at
http://developer.mozilla.org/en/docs/DOM:window.open#Syntax
and the security policy for the WindowObjectReference:
http://www.mozilla.org/projects/security/components/same-origin.html
if there is no blocking - WindowObjectReference should have the same capabilities like the standard window object.
Component: Bookmarks → General
Comment 5•18 years ago
|
||
I mean what is set under Tools->Options->Content->Advanced (under enable Javascript).
Updated•18 years ago
|
Assignee: general → nobody
QA Contact: ian → general
Reporter | ||
Comment 6•18 years ago
|
||
@martijn: your are right
the main part seems not to be a bug (the only bug then only was to disable the feature in options using same profile from FF 1.5)
but the other things the flags "modal" and "dependent" are intended for things like above discribed. They dont raise or lower windows (like the option intends), they keep them in front of the calling window.
Severity: major → minor
Reporter | ||
Comment 7•18 years ago
|
||
Martijn is right, but what is set under "Tools->Options->Content->Advanced->Scripts are allowed to raise or lower windows" is not set in FF 2.0 like in FF 1.5 using the same Profile (Settings are deleted). If this is a bug would somebody else file this?
Such things makes it hard to develop a userfriendly Webapplication. Especially on MacOS (new Windows are not shown on something like a Taskbar)
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago
Resolution: --- → INVALID
Version: 1.0 Branch → 2.0 Branch
Can someone please reopen this bug, its closed for no apparant reason and the bug seems to have made it to FF2 final!
Reporter | ||
Comment 9•18 years ago
|
||
Ok, after some testing with disable the Feature for Scripts to raise or lower Windows on FF 1.5 is to say: on FF 1.5 the generated Window looses Focus and can't get Focus from calling Window. BUT: if Flag "dependent" or "modal" is set it stays in Front of the calling Window. This Feature is lost (broken) in FF 2.0!
Additionaly the Settings for Scriptactions are not the same in FF 1.5 using the same profile.
Severity: minor → normal
Status: RESOLVED → UNCONFIRMED
Resolution: INVALID → ---
Comment 10•18 years ago
|
||
*** Bug 358021 has been marked as a duplicate of this bug. ***
Reporter | ||
Comment 11•18 years ago
|
||
see http://developer.mozilla.org/en/docs/DOM:window.open#Window_functionality_features
for documentation details
Attachment #243346 -
Attachment is obsolete: true
Comment 12•18 years ago
|
||
The dependent=yes stuff is covered by bug 354123.
From the testcase:
> setTimeout(function(){win.focus();},100);
Web pages are not allowed to screw with focus like this any more by default and I think that's a good thing.
Status: UNCONFIRMED → RESOLVED
Closed: 18 years ago → 18 years ago
Resolution: --- → INVALID
Reporter | ||
Comment 13•18 years ago
|
||
Yeah! Its not a bug its a Feature!
setTimeout(function() {readDepreceatedTestcase();},3days);-)
I like FF by his options and he says if something should happen but is blocked.
Comment 14•17 years ago
|
||
Bug 360312 is similar to this one.
Updated•17 years ago
|
Summary: windows created by "newWin = window.open(url, name, features)" cant get focus from creating window by "newWin.focus()" in Firefox 2.0 → Scripts are no longer allowed to call window.focus() (except during events when popups would be allowed)
You need to log in
before you can comment on or make changes to this bug.
Description
•