Bug 969021 - Some windows not receiving focus when opened with keyboard shortcuts
Some windows not receiving focus when opened with keyboard shortcuts
Product: Fedora
Classification: Fedora
Component: gnome-settings-daemon (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Bastien Nocera
Fedora Extras Quality Assurance
: 949980 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2013-05-30 09:43 EDT by Jamie Nguyen
Modified: 2014-02-23 10:17 EST (History)
8 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2014-02-23 10:17:41 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Jamie Nguyen 2013-05-30 09:43:50 EDT
Using custom keyboard shortcuts to open applications seems to result in some applications not receiving focus.

Opening Firefox or Nautilus/Files using a custom keyboard shortcut (such as Alt-B) on an empty workspace starts the application, but the new window does not receive focus until you click. This is different from the behaviour in Fedora 18 (with gnome-shell 3.6.x), where the new window would immediately receive focus.

Using the mouse to open Firefox or Nautilus gives it focus straight away, so the problem seems to be only when using keyboard shortcuts.

Strangely, opening gnome-terminal using a custom keyboard shortcut doesn't result in the same symptoms. It receives focus immediately. So apparently not all applications are affected.

Fedora 19 x86_64

"halfline" on fedora-devel IRC mentioned the following:

looks like a settings-daemon bug

static void
do_custom_action (GsdMediaKeysManager *manager,
                  guint                deviceid,
                  MediaKey            *key,
                  gint64               timestamp)

        g_debug ("Launching custom action for key (on device id %d)", deviceid);
        execute (manager, key->custom_command, FALSE);

timestamp is getting thrown away

and it's getting hardcoded to GDK_CURRENT_TIME anyway:
do_custom_action (manager, deviceid, key, GDK_CURRENT_TIME);
Comment 1 Jamie Nguyen 2013-05-30 09:51:25 EDT
Also reported upstream:

Comment 2 Stefan 2013-07-14 07:16:32 EDT
This happens to me, when I open the calculator by the calculator key on the keyboard.

var/log/messages contains the following warning:

/etc/gdm/Xsession[820]: Window manager warning: Got a request to focus the no_focus_window with a timestamp of 0.  This shouldn't happen!

Please note: It seems, that bug 949980 is a duplicate of this one
Comment 3 Tim Waugh 2013-07-16 05:58:41 EDT
*** Bug 949980 has been marked as a duplicate of this bug. ***
Comment 4 Jamie Nguyen 2013-08-26 14:44:34 EDT
Looks like this has been fixed upstream. The fix will make it into GNOME 3.10.

Note You need to log in before you can comment on or make changes to this bug.