This issue has been reported to Ubuntu Launchpad as: https://bugs.launchpad.net/bugs/614314 xfwm4 version 4.6.1-1ubuntu2 xorg version 1:7.5+5ubuntu1 Also observed using: enlightenment 1:0.16.7.2-5 Distro: Ubuntu 10.04.1 LTS And in Jaunty 9.04 and Karmic 9.10 also. (First happened after an upgrade in Jaunty as far as I can remember) Focus mode set to (sloppy) focus follows mouse. I don't know if this is an xorg bug or window-manager problem. I often have numerous windows open across several desktops (e.g. a program running under wine, 3 uxterms, firefox). Several times per day when I use the keyboard to switch to another desktop, then although the correct window is decorated as though focussed the keyboard events do not arrive at it. It can affect any of the running programs. Only moving the mouse so that the window looses focus and then regains it will overcome this. Clicking has no effect. If there is only one window on the desktop, then I cannot get keyboard focus (not just decorations) onto the window I want to use without opening another window (or switching away which is only about 50% effective.)
I have noticed this problem, too. I'm uisng XFCE 4.6.2 in Fedora 13 and Fedora 14. As Fedora 15 gets closer to release, I should be able to see if this happens with XFCE 4.8 as well, but it will probably be a few weeks before I can try. This bug is particularly troublesome if a virtual desktop only has one window. In this case, the only way to get focus to the window is to create a second window (which gets focus as it's created) and then switch focus back to the desired window. Otherwise it seems to be impossible to do.
Does this happen only with Wine apps (focused or not) or any app, even without any Wine app running? Are Wine apps decorated by the window manager or are they decorated by Wine?
I have not used Wine--I see the problem most often with gnome-terminal, since I always have many of these running.
Over time, I have discovered a bit more about the behavior of this bug. Whether or not occurs depends on the location of the mouse pointer. If the pointer is in a position such that it lands within a window as the desktop switches, then that window will properly have focus. However, if the pointer lands within the background as the desktop switches, then no window will have focus. If the mouse is hovering over a panel as the desktop switches, then focus will be given to the window on that desktop that most recently had focus. By the way, I'm still having this problem in Xfce 4.8.3, so it might be nice to update the version on this bug.