Firefox window moves to current workspace

Bug #175904 reported by Mark Schouten
98
This bug affects 7 people
Affects Status Importance Assigned to Milestone
GTK+
Fix Released
Medium
Mozilla Firefox
Confirmed
Unknown
firefox (Ubuntu)
Triaged
Medium
Unassigned
firefox-3.0 (Fedora)
Won't Fix
High
gnome-terminal (Ubuntu)
Invalid
Undecided
Unassigned
kdebase (Ubuntu)
Fix Released
Undecided
Unassigned
meta-gnome2 (Ubuntu)
Invalid
Undecided
Unassigned
metacity (Ubuntu)
Fix Released
High
Alexander Sack
ubufox (Ubuntu)
Invalid
Medium
Alexander Sack

Bug Description

Binary package hint: firefox-3.0

FYI: I upgraded to Hardy to be able to point people at bugs, if needed. So I am aware of the pre-alpha status of Hardy.

When Firefox-3.0 is set as the default browser for Gnome (System, Preferences, Preferred Applications) all applications use the correct browser. However, I have my workspaces nicely arranged, and my browser is in workspace 2.

When clicking a link (to open it) in gnome-terminal or Evolution, the Firefox-3.0 window moves to the workspace where I clicked the link. But I don't want the window to move, I want to move to the workspace where I left the window.

IMHO, this is a bug.

Thanks!

Revision history for this message
In , Joe Smith (yasumoto7) wrote :

Running Ubuntu Gutsy Tribe 5, GNOME 2.19.7, Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9a8pre) Gecko/2007090304 Minefield/3.0a8pre

This has been happening to me every time I click a link from the gnome-terminal.

Revision history for this message
In , Joe Smith (yasumoto7) wrote :

A bit of clarification:

Gutsy Tribe 5 is the 5th development (alpha) release of Ubuntu 7.10 Gutsy Gibbon.

New pages are set to open in a new tab, and I am not using MOZ_NO_REMOTE/-no-remote

Revision history for this message
In , Myk (myk) wrote :

This is a real pain. I find myself clicking links and quickly switching to the desktop with Firefox on it, hoping I can outrace the request so Firefox comes to the foreground on its proper desktop and I don't have to move it back into place (again). Requesting blocking status.

Revision history for this message
In , L. David Baron (dbaron) wrote :

Sounds like something that could be a regression from bug 295447 (which introduced gtk_window_present calls).

80 comments hidden view all 118 comments
Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

Description of problem:

When I open a new tab (via right click on a terminal, clicking on something in
liferea, whatever), firefox immediately jumps onto the current workspace.

This is irritating.

Version-Release number of selected component (if applicable):

firefox-2.0.0.6-11.fc8

Additional info:

Seems related to the startup notification patch, as it worked ok in 2.0.0.6-8.fc8.

Revision history for this message
In , Adam (adam-redhat-bugs) wrote :

I will second this. Very irritating!

Revision history for this message
In , Christopher (christopher-redhat-bugs) wrote :

Owen says this is a metacity bug. The following program also hops windows.

#!/bin/env python

import gtk
import gobject
w = gtk.Window()
w.set_title("Foo")
w.show()

def on_timeout():
        w.present()
        return False

gobject.timeout_add(5000, on_timeout)
gtk.main()

Revision history for this message
In , Christopher (christopher-redhat-bugs) wrote :

er, hops workspaces

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

To give some background on this issue, Firefox now supports startup notification:
https://bugzilla.mozilla.org/show_bug.cgi?id=223492

The issue in this bug only occurs when there are multiple workspaces.

Removing this Firefox patch would be a regression in the single workspace case
because it would require clicking on a flashing browser entry in the task list
after activating an external link.

From IRC:

<owen> walters: metacity could look at the window role and alter the behavior
based on that

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

FWIW, commenting out the call to gdk_window_focus() in the patch makes it DTRT
for me.

Revision history for this message
In , Owen (owen-redhat-bugs) wrote :

Actually, what I meant was that based on the "type" of the window application
vs. dialog, you could do different things.

A application never, under any circumstances, should be moved between desktops.

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

Bill, what effect does that have in the single-workspace case?

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

Also, I've filed this bug upstream here:

http://bugzilla.gnome.org/show_bug.cgi?id=482354

Since there seems to be agreement this is an upstream Metacity issue, please
continue discussion there.

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

Colin: when it's on the same workspace, I get the throbbing entry in the panel.
When it's on the other workspace, I don't.

Revision history for this message
In , David (david-redhat-bugs) wrote :

We need to fix this for F8...

Revision history for this message
In , Jeremy (jeremy-redhat-bugs) wrote :

This is also happening in compiz... so more than just metacity at work here.

Revision history for this message
In , Christopher (christopher-redhat-bugs) wrote :

Jeremy: not quite...

in metacity, the _window_ switches to the current workspace.

In compiz, the _active workspace_ switches.

This is about the metacity issue, which everyone agrees is clearly wrong. The
compiz behavior seems more or less sane. While different, i've already gotten
used to it.

Revision history for this message
In , Matthias (matthias-redhat-bugs) wrote :

The long discussion leading to the current metacity behaviour can be found
here: http://bugzilla.gnome.org/show_bug.cgi?id=166379

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

So, going back to the beginning. The original patch (for firefox) has the
following comments usptream from Elijah
(https://bugzilla.mozilla.org/show_bug.cgi?id=223492#c31):

************
>+ if (desktopStartupID.IsEmpty()) {
>+ PRUint32 timestamp = GTKToolkit->GetFocusTimestamp();
>+ if (timestamp) {
>+ gdk_window_focus(aWindow->window, timestamp);
>+ GTKToolkit->SetFocusTimestamp(0);
>+ }
>+ return;
>+ }

This block of SetUserTimeAndStartupIDForActivatedWindow() is a little
confusing. It doesn't set the user time or the startup id for the activated
window. Instead, it sends an "activate me, please" message to the window
manager. I understand it's just a workaround when no startup id is available
(because either firefox wasn't launched with startup-notification or wasn't
built with MOZ_ENABLE_STARTUP_NOTIFICATION), but it'd be nice to have it
documented as such. It'd also be good to verify in testing that this block of
code isn't being executed (i.e. that startup id is non-empty), since it is just
a workaround.
*****************

I find it odd that the supposed 'workaround' part of the code is what's causing
the problem in my testing.

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

Created attachment 225081
partial fix for firefox

Note that due to missing changes to the configury, we aren't even *building*
the SN support at the moment - this patch fixes that.

Doesn't change the behavior, though.

Revision history for this message
In , David (david-redhat-bugs) wrote :

"This is not a blocker"

Revision history for this message
In , Jens (jens-redhat-bugs) wrote :

<notting> halfline: why not just take the patch out of ff, since we're not even
applying it in a way that works
<juhp> notting: exactly
<halfline> notting: that's not a horrible idea
 notting: might be worth talking to stransky about
 or caillon if he pops on

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

*** Bug 337721 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

Note there is now a patch for metacity upstream at:
http://bugzilla.gnome.org/show_bug.cgi?id=482354#c2

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

Also in response to:

<notting> halfline: why not just take the patch out of ff, since we're not even
applying it in a way that works

The patch does function as expected in the single workspace case, even if it may
be entering into a fallback section of the code (will investigate).

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

I have built a new version of metacity with the patch:
http://koji.fedoraproject.org/koji/buildinfo?buildID=21629

Please test, if it works well then we can reable to re-enable the Firefox fix.

Revision history for this message
In , Bill (bill-redhat-bugs) wrote :

(In reply to comment #20)
> Also in response to:
>
> <notting> halfline: why not just take the patch out of ff, since we're not even
> applying it in a way that works
>
> The patch does function as expected in the single workspace case, even if it may
> be entering into a fallback section of the code (will investigate).

The patch adds configury for using libstartupnotification, and ifdef'd code to
use libsn. We then build moz without sn support. If it's functioning, it's
completely by accident.

Revision history for this message
In , Jens (jens-redhat-bugs) wrote :

(In reply to comment #21)
> I have built a new version of metacity with the patch:
> http://koji.fedoraproject.org/koji/buildinfo?buildID=21629
>
> Please test, if it works well then we can reable to re-enable the Firefox fix.

Thanks, Colin! Yes, that works well for me so far. :)

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

(In reply to comment #22)
>
> The patch adds configury for using libstartupnotification, and ifdef'd code to
> use libsn. We then build moz without sn support. If it's functioning, it's
> completely by accident.

Ok, I'm at home so I can't actually test this with my rawhide computer, but from
looking at the patch again, the section you identified earlier (which calls
gdk_window_focus which ultimately causes the focus event) is the source of the
behavior under discussion.

The startup notification specification if supported correctly would make Firefox
display a progress status on first launch, but this (to me) is not the most
useful part of the patch. The most useful part is the behavior that when one
clicks on a link in an external program, the web browser appears and displays
the link.

Some people feel that behavior wasn't right for multiple desktops (and the
metacity patch addresses this), but please when testing things, try the single
workspace case. The expected behavior is that the browser appears; it should
not pulse as in comment #9. This is the way clicking on links works on other
platforms, and is the most sensible thing I believe for most situations in the
single-workspace case.

There might be some more special cases such as feed readers (liferea?) where one
wants to click a number of links to "queue" urls; I am open to discussion around
those. Probably the right solution for them will be to have the ability at
link-click time whether or not you want to see it.

Revision history for this message
In , Colin (colin-redhat-bugs) wrote :

I meant to mention above; the reason the patch still has effect is because the
gdk_window_focus call is outside the #ifdef MOZ_ENABLE_STARTUP_NOTIFICATION.

Also, bear in mind this patch is already upstreamed and will be in the Firefox 3
release; I am not yet sure whether it will be in the 2.0.0.7 stream.

Revision history for this message
In , Christopher (christopher-redhat-bugs) wrote :

We'll probably want this metacity fix for FC7 too before Firefox's support makes
it there.

Revision history for this message
In , Matthias (matthias-redhat-bugs) wrote :

Fixed in F8, moving off blocker

Revision history for this message
In , Mauricio (mauricio-redhat-bugs) wrote :

Its fixed for me after last update in F8
Cheers

107 comments hidden view all 118 comments
Revision history for this message
Mark Schouten (mark-prevented) wrote : Firefox-3.0 window moves to current workspace

Binary package hint: firefox-3.0

FYI: I upgraded to Hardy to be able to point people at bugs, if needed. So I am aware of the pre-alpha status of Hardy.

When Firefox-3.0 is set as the default browser for Gnome (System, Preferences, Preferred Applications) all applications use the correct browser. However, I have my workspaces nicely arranged, and my browser is in workspace 2.

When clicking a link (to open it) in gnome-terminal or Evolution, the Firefox-3.0 window moves to the workspace where I clicked the link. But I don't want the window to move, I want to move to the workspace where I left the window.

IMHO, this is a bug.

Thanks!

Changed in firefox-3.0:
importance: Undecided → Low
Revision history for this message
Fabien Tassin (fta) wrote :

What did you use as "Command" ? (in Preferred Applications)

Try "firefox-3.0 %s", works for me.

Revision history for this message
Mark Schouten (mark-prevented) wrote :

Fabien:

The command is '/usr/bin/firefox-3.0 %s'. Please note that Firefor starts ok, but it changes workspace.

Revision history for this message
Fabien Tassin (fta) wrote :

Strange, it's working fine for me, I also hate to see windows moving against my will.

Could you try manually, i.e.:

1/ open a shell in workspace 1
2/ open firefox 3 in workspace 2
3/ in the shell, type : firefox-3.0 about:plugins

do you see the firefox moved in workspace 1 ?

Also, in Firefox preferences / Tabs, do you open new pages in new windows or in new tabs ? (i do tabs)

Another question, when the window is moved, do you see the requested page opened somewhere (either visible or last tab) ? or do you see a blank tab instead (about:blank) ?

Revision history for this message
Mark Schouten (mark-prevented) wrote :

When I follow the steps you gave me, the ff-window is moved to workspace 1.

I open new pages in new tabs.

It opens the right page, in a new tab. So no about:blank pages.

Revision history for this message
In , Raúl Porcel (armin76) wrote :

http://bugzilla.gnome.org/show_bug.cgi?id=482354 thanks to Mart Raudsepp for the link

Revision history for this message
Martin Pitt (pitti) wrote : Re: Firefox-3.0 window moves to current workspace

I confirm this behavior, it happens to me, too. It is highly annoying.

Changed in firefox-3.0:
importance: Low → Medium
status: New → Confirmed
Revision history for this message
In , Alexander Sack (asac) wrote :

 1. new-window : makes sense to open on current desktop
 2. new-tab: moving all tabs to current desktop is annoying; but opening new tab on other desktop is probably too confusing.

Thus: if new-tab is selected as open mode, use new-window if there is no firefox window on current desktop. optionally, we could add a pref to disable this auto-new-window feature for power users that want the ffox 2 behaviour.

(fwiw gedit behaves in a similar fashion)

Revision history for this message
Colin Watson (cjwatson) wrote : Re: Firefox-3.0 window moves to current workspace

The same thing happens to me when Firefox pops up a dialog (e.g. password for HTTP basic auth); the whole window teleports to my current workspace.

Changed in gtk:
status: Unknown → New
Changed in firefox:
status: Unknown → Confirmed
Revision history for this message
In , Jruderman (jruderman) wrote :

*** Bug 414879 has been marked as a duplicate of this bug. ***

Revision history for this message
ubunturox (ubuntu-rox) wrote : Re: Firefox-3.0 window moves to current workspace

I have the same Problem with Firefox Version 2.0.0.12 in Ubuntu 7.10.
It just happend short while ago - can't say exactly when though - maybe since 7.10 because I upgraded only a while ago...
I too like my Firefox on desktop 2 and when I click on a link in a mail in evolution on desktop 1 it used to open on desktop 2.

Revision history for this message
ubunturox (ubuntu-rox) wrote :

I just discovered that the problem does not exist if I doubleclick an *.htm file in nautilus and click view.
Those files get opened correctly in the last active Firefox window and that stays on it's current workspace.
So it's probably a gnome problem?

Revision history for this message
Simos Xenitellis  (simosx) wrote :

It appears to be a Firefox feature.

Can you try to
1. bring up about:config
2. set browser.tabs.loadDivertedInBackground to True

Revision history for this message
Martin Pitt (pitti) wrote :

For the record, this even seems to behave differently on my two boxes; on the desktop (metacity) Firefox moves to the current workspace when clicking a link, whereas on the laptop (compiz) the current workspace is switched to the one where Firefox resides. The is a more sane behaviour, and I think it's an acceptable default if it can be switched off.

Revision history for this message
Mark Schouten (mark-prevented) wrote :

Thanks! This kindof fixes the problem. Although it really isn't the same thing.

The option you mention make the tab open up in the background. It SHOULD NOT have anything to do with where the window goes, IMHO.

So, appearantly where you open the tab also defines where your window travels. :/

Revision history for this message
Martin Pitt (pitti) wrote :

I confirm that setting browser.tabs.loadDivertedInBackground to True disables this behavior with metacity at least. I didn't check compiz yet.

Revision history for this message
Simos Xenitellis  (simosx) wrote :

Ahem, the real source of the bug is the window manager,
http://bugzilla.gnome.org/show_bug.cgi?id=482354

It is already marked above in the bug report.

Revision history for this message
ubunturox (ubuntu-rox) wrote :

yes - this seems to fix it - thank you!

For the record I use gnome with xfwm4.

Revision history for this message
Emilio Pozuelo Monfort (pochu) wrote : Re: [Bug 175904] Re: Firefox-3.0 window moves to current workspace

Simos Xenitellis wrote:
> 2. set browser.tabs.loadDivertedInBackground to True

awesome. this is still a workaround though, since this makes the tab not to be
focused and that means if you have many tabs opened (so many that they take all
the tab bar) the new tab won't be shown and you may not notice it's been opened.

But this is indeed better that the previous behaviour.

Revision history for this message
In , Myk (myk) wrote :

*** Bug 420186 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Rimas Kudelis (rq) wrote :

(In reply to comment #6)
> 1. new-window : makes sense to open on current desktop
> 2. new-tab: moving all tabs to current desktop is annoying; but opening new
> tab on other desktop is probably too confusing.

What about opening new tab on other desktop and flashing the window title button?

> Thus: if new-tab is selected as open mode, use new-window if there is no
> firefox window on current desktop. optionally, we could add a pref to disable
> this auto-new-window feature for power users that want the ffox 2 behaviour.

I would certainly make use of that pref. :)

Revision history for this message
In , Caillon (caillon) wrote :

This isn't a bug in Firefox, it is a bug in metacity which Colin Walters at Red Hat reported and supplied a patch for.

http://bugzilla.gnome.org/show_bug.cgi?id=482354

If you see this bug on Linux, you're probably not running Fedora Rawhide/9. But, I recommend you forward this to your distro and ask that they temporarily take the metacity patch until the upstream metacity developers decide this bug is important enough to warrant their attention.

Revision history for this message
In , Caillon (caillon) wrote :

Alternatively, switching window managers to something other than metacity is a workaround.

Revision history for this message
In , Jakub 'Livio' Rusinek (liviopl-pl) wrote :

> Alternatively, switching window managers to something other than metacity is a
workaround.

I could say "lie". It's simply not true :P . I had this issue with Compiz running.

> If you see this bug on Linux, you're probably not running Fedora Rawhide/9.

Fedora is innovative ^^ .

Revision history for this message
In , Caillon (caillon) wrote :

Compiz in Fedora 8 certainly doesn't have that problem. If compiz regressed, that's unfortunate, and I'd suggest filing a bug against compiz.

Revision history for this message
In , Jakub 'Livio' Rusinek (liviopl-pl) wrote :

Until I set an option in about:config I saw this bug. Now everything from other apps is opened in background tabs. That is great and doesn't require fixing anything.

Revision history for this message
In , Myk (myk) wrote :

(In reply to comment #14)
> Until I set an option in about:config I saw this bug. Now everything from other
> apps is opened in background tabs. That is great and doesn't require fixing
> anything.

Which option did you set, and what did you set it to?

Revision history for this message
In , Jakub 'Livio' Rusinek (liviopl-pl) wrote :

browser.tabs.loadDivertedInBackground = true

Revision history for this message
In , Caillon (caillon) wrote :

I just tried every compiz version from F8 onward, and metacity from F8 onward. No compiz version features this bug. Metacity didn't get the fix until 2.21.5 and had it except for a day when it got accidentally removed around 2.21.8. It's been fine ever since.

Revision history for this message
In , Myk (myk) wrote :

(In reply to comment #16)
> browser.tabs.loadDivertedInBackground = true

Hmm, indeed, that prevents the window from moving, although it doesn't duplicate the behavior that has regressed, since it doesn't throb the browser's taskbar button nor open the link in a foreground tab.

Revision history for this message
Alexander Sack (asac) wrote : Re: Firefox-3.0 window moves to current workspace

fwiw, there is a metacity fix in the gnome bug. we should take it for hardy.

Revision history for this message
In , Aleksej (aleksejrs) wrote :

*** Bug 406167 has been marked as a duplicate of this bug. ***

Changed in gtk:
status: New → Confirmed
Revision history for this message
Alexander Sack (asac) wrote : Re: Firefox-3.0 window moves to current workspace

in case we cannot find a fix, we should consider to use the |open external links in window| rather than |in new tab| for the release.

Changed in firefox-3.0:
milestone: none → ubuntu-8.04
Alexander Sack (asac)
Changed in firefox-3.0:
assignee: nobody → asac
Revision history for this message
Michael Rooney (mrooney) wrote :

I experienced this as well and found it highly annoying. However when I enabled compositing via Appearances, the problem went away. Compiz must be doing something to disallow this. This may be a difference between people experiencing and not experiencing this bug. I would agree this is a bug and should be fixed for non-composited desktops as well.

Revision history for this message
Mark Schouten (mark-prevented) wrote : Re: [Bug 175904] Re: Firefox-3.0 window moves to current workspace

On Mon, 2008-03-10 at 12:14 +0000, Alexander Sack wrote:
> in case we cannot find a fix, we should consider to use the |open
> external links in window| rather than |in new tab| for the release.
>
> ** Changed in: firefox-3.0 (Ubuntu)
> Target: None => ubuntu-8.04

That would not be a usable fix for me. That would only open up more
windows, also on the wrong workspace.

I don't have a feeling that this bug (I've seen some duplicates btw
(#204927, #197761)) really has the attention it needs. I still prefer
ff2 for usability over ff3, this bug only makes it much worse. Has this
issue made it on any 'critical release buglist' yet?

Mark

Revision history for this message
Manuel McLure (manuel-mclure) wrote : Re: Firefox-3.0 window moves to current workspace

This is not just a metacity bug - it also happens in KDE with kwin, and the workaround does not work in that environment.

Alexander Sack (asac)
Changed in ubufox:
importance: Undecided → Medium
milestone: none → ubuntu-8.04
status: New → Triaged
assignee: nobody → asac
Changed in firefox-3.0:
status: Unknown → In Progress
Changed in kdebase:
status: New → Confirmed
Alexander Sack (asac)
Changed in metacity:
status: New → In Progress
Alexander Sack (asac)
Changed in metacity:
assignee: nobody → asac
importance: Undecided → High
status: In Progress → Fix Committed
Changed in metacity:
status: Fix Committed → Fix Released
Alexander Sack (asac)
Changed in ubufox:
status: Triaged → Invalid
Changed in firefox-3.0:
milestone: ubuntu-8.04 → later
Alexander Sack (asac)
Changed in firefox-3.0:
milestone: later → none
73 comments hidden view all 118 comments
Revision history for this message
In , Bug (bug-redhat-bugs) wrote :

This message is a reminder that Fedora 7 is nearing the end of life. Approximately 30 (thirty) days from now Fedora will stop maintaining and issuing updates for Fedora 7. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as WONTFIX if it remains open with a Fedora 'version' of '7'.

Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version prior to Fedora 7's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that we may not be able to fix it before Fedora 7 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora please change the 'version' of this bug. If you are unable to change the version, please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. If possible, it is recommended that you try the newest available Fedora distribution to see if your bug still exists.

Please read the Release Notes for the newest Fedora distribution to make sure it will meet your needs:
http://docs.fedoraproject.org/release-notes/

The process we are following is described here: http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Revision history for this message
In , Peter (peter-redhat-bugs) wrote :

Thank you for the bug report. Closing bug as per comment #27 and comment #28.

If you still experience this problem after updating to our latest Fedora
release, reopen this bug against that version if this bug exists there.

Changed in firefox-3.0:
status: In Progress → Invalid
Changed in kdebase:
status: Confirmed → Fix Released
Changed in kdebase:
status: Fix Released → Confirmed
Changed in gtk:
status: Confirmed → In Progress
Changed in kdebase:
status: Confirmed → Fix Released
Alexander Sack (asac)
Changed in firefox-3.0:
status: Confirmed → Triaged
35 comments hidden view all 118 comments
Revision history for this message
Alexander Sack (asac) wrote : Re: [Bug 175904] Re: Firefox-3.0 window moves to current workspace

On Thu, Dec 11, 2008 at 01:41:12PM -0000, Jamin W. Collins wrote:
> Not quite sure how to properly list it in the affects area of the bug
> report, but I'm seeing this same behavior under Intrepid with firefox
> and openbox.
>

You think you can come up with a regression window for openbox? doesn
hardy openbox work?

 - Alexander

Changed in gtk:
status: In Progress → Fix Released
Changed in firefox-3.0:
status: Invalid → Fix Released
Revision history for this message
Jamin W. Collins (jcollins) wrote : Re: Firefox-3.0 window moves to current workspace

@Alexander, sorry I'm not following your question...

Changed in kdebase (Ubuntu):
assignee: nobody → Alexander Sack (asac)
Changed in meta-gnome2 (Ubuntu):
assignee: nobody → Ubuntu Desktop Bugs (desktop-bugs)
Changed in gnome-terminal (Ubuntu):
assignee: nobody → Ubuntu Desktop Bugs (desktop-bugs)
Revision history for this message
Micah Gersten (micahg) wrote :

Please do not set tasks/assignment without a reason.

Changed in kdebase (Ubuntu):
assignee: Alexander Sack (asac) → nobody
Changed in meta-gnome2 (Ubuntu):
assignee: Ubuntu Desktop Bugs (desktop-bugs) → nobody
status: New → Invalid
Changed in gnome-terminal (Ubuntu):
assignee: Ubuntu Desktop Bugs (desktop-bugs) → nobody
status: New → Invalid
Revision history for this message
schnittchen (schnittchen) wrote :

This bug affects me (working with kwin) on Ubuntu 9.10, backports enabled.

The symptoms are EXACTLY as described in comment #14 of bug #204927, so I'm not retelling that story ;-)

Packages, for the record:
firefox: 3.5.8+build1+nobinonly-0ubuntu0.9.10.1
kde-window-manager: 4:4.3.5-0ubuntu1~karmic1

Revision history for this message
In , Bugzilla-mozilla-org-pobox (bugzilla-mozilla-org-pobox) wrote :

First, how does this bug report relate to Mozilla bug #263553? Isn't it a duplicate?

I just posted the following to http://bugs.debian.org/486570, but I found no way to update this bug report.

After reading what James wrote[0], I went to investigate this a bit.

0. http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=486570#15

First, I found the single call to gtk_window_present in the Firefox
source and disabled it:

  --- a/widget/src/gtk2/nsWindow.cpp
  +++ b/widget/src/gtk2/nsWindow.cpp
  @@ -1406,7 +1406,7 @@ nsWindow::SetFocus(PRBool aRaise)
          owningWindow->mContainerBlockFocus = PR_TRUE;

          // Set focus to the window
  - if (gRaiseWindows && aRaise && toplevelWidget &&
  + if (0 && gRaiseWindows && aRaise && toplevelWidget &&
              !GTK_WIDGET_HAS_FOCUS(toplevelWidget) &&
              owningWindow->mIsShown && GTK_IS_WINDOW(owningWindow->mShell))
            gtk_window_present(GTK_WINDOW(owningWindow->mShell));

and built new packages, but the problem remained. However, I found
a couple of curiousities. I have three heads one two graphics cards,
and I use Zaphod mode to put them all next to each other. head 0 is
on GPU 0, and heads 1&2 are on GPU 1.

  1. the focus is never stolen when the Firefox window is on heads
     1&2, not even if the link is clicked on another head.

  2. if I move the window from head 0 to head 1 and back, then it no
     longer steals focus, not even if the click is on a separate head.

  3. if I move the window from head 0 to head 1, click a link, and
     move it back to head 0, then the focus stealing happens again.

I then went back to investigate these three points with the original
Firefox packages, i.e. without the above patch, and the behaviour is
identical.

Then I investigated the urgency hint, using xprop -spy: I started it
in a terminal, then X-pasted a link into that terminal and clicked
it. I did this to avoid changing focus with the mouse while testing.
There was nothing in the output of xprop -spy mentioning an urgency
hint. I did verify that xprop -spy shows the urgency hint, using
URxvt.urgentOnBell and echo -e '\a'.

This is starting to feel a bit like a riddle. For me, (2.) above is
an okay workaround at the moment, but it really seems like the
Firefox code needs some cleaning.

Changed in gtk:
importance: Unknown → Medium
Changed in firefox:
importance: Unknown → Medium
Alexander Sack (asac)
Changed in firefox-3.0 (Ubuntu):
assignee: Alexander Sack (asac) → Chris Coulson (chrisccoulson)
Martin Pitt (pitti)
Changed in firefox-3.0 (Ubuntu):
assignee: Chris Coulson (chrisccoulson) → nobody
Revision history for this message
Thomas Hotz (thotz-deactivatedaccount) wrote : Re: Firefox-3.0 window moves to current workspace

So can we get the fix from Fedora into Ubuntu?

affects: firefox-3.0 (Ubuntu) → firefox (Ubuntu)
summary: - Firefox-3.0 window moves to current workspace
+ Firefox window moves to current workspace
31 comments hidden view all 118 comments
Revision history for this message
In , David Faure (faure) wrote :

(In reply to Jeremy Nickurak from comment #23)
> Created attachment 343829
> Shell script to open a URL strictly in a new firefox tab on the current
> workspace
>
> As a substitute for a fix of this bug, I've worked around it with a shell
> script that uses wmctrl to get the ideal behavior. It'll check to see if
> there's an existing firefox window open on the current workspace, and if so,
> (optionally) focus it, and load a url in a new tab there. If there's no such
> window, it'll simply open it in a new window on the current workspace.

Thanks for that script, it works very well.
This is the behavior I wish Firefox could have out of the box (Reuse-window-in-current-desktop otherwise create-new-in-current-desktop). Much better than jumping to another desktop or opening tabs hidden into another desktop. Any chance for this to happen?

Changed in firefox-3.0 (Fedora):
importance: Unknown → High
status: Fix Released → Won't Fix
Changed in firefox:
status: Confirmed → Unknown
Changed in firefox:
status: Unknown → Confirmed
Changed in firefox:
importance: Medium → Unknown
Revision history for this message
In , Release-mgmt-account-bot (release-mgmt-account-bot) wrote :

The severity field for this bug is relatively low, S3. However, the bug has 4 duplicates.
:Amir, could you consider increasing the bug severity?

For more information, please visit [auto_nag documentation](https://wiki.mozilla.org/Release_Management/autonag#severity_underestimated.py).

Revision history for this message
In , Autonag-nomail-bot (autonag-nomail-bot) wrote :

The last needinfo from me was triggered in error by recent activity on the bug. I'm clearing the needinfo since this is a very old bug and I don't know if it's still relevant.

Displaying first 40 and last 40 comments. View all 118 comments or add a comment.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.