Synchronous notifications briefly steal focus
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| | notify-osd (Ubuntu) |
High
|
Unassigned | ||
Bug Description
It appears synchronous notifications (at least those for volume and brightness) briefly steal focus when they appear. This is quite problematic for games and some other applications that pause as soon as they lose focus. The focus stealing does not happen with normal, asynchronous notifications.
Here's a quick Python program to reproduce this:
#!/usr/bin/python
import gtk
import time
def cb (wid, ev):
evtime = time.strftime ("%H:%M:%S", time.localtime())
print ("%s: Lost focus!" % evtime)
win = gtk.Window()
win.connect ("focus-out-event", cb)
win.show_all()
gtk.main()
You could also just start playing Quadrapassel, then adjust your volume :)
| Launchpad Janitor (janitor) wrote : | #1 |
| affects: | notify-osd → notify-osd (Ubuntu) |
| Changed in notify-osd (Ubuntu): | |
| status: | New → Confirmed |
| Changed in notify-osd (Ubuntu): | |
| status: | New → Confirmed |
| David Baucum (maxolasersquad) wrote : | #3 |
This is generally problematic with day-to-day use of Ubuntu. For example, if I'm typing out some code in vim, then the song changes, Rhythmbox pops up a notification which steals focus. So I have to click back in the terminal to continue typing.
Just to drive home the point, while I was typing this out a notification popped up which halted my typing.
| Olivier Tilloy (osomon) wrote : | #4 |
This causes webbrowser-app to exit fullscreen mode when adjusting volume with media keys (see bug #1477308). Pretty annoying when watching a fullscreen video.
| Changed in notify-osd (Ubuntu): | |
| importance: | Undecided → High |
| Changed in notify-osd (Ubuntu): | |
| assignee: | nobody → Mirco Müller (macslow) |
| Changed in canonical-devices-system-image: | |
| milestone: | none → ww40-2015 |
| assignee: | nobody → kevin gunn (kgunn72) |
| status: | New → Confirmed |
| importance: | Undecided → Medium |
| Changed in canonical-devices-system-image: | |
| importance: | Medium → High |
| Mirco Müller (macslow) wrote : | #5 |
This lost-focus is not caused by notify-osd itself.
You can verify this by running Dylan's provided python-script and triggering lp:notify-osd/examples/icon-value.py in another terminal (with a "sleep 10" before that, so you've enough time to focus Dylan's running python-script and its output). icon-value.py is triggering the exact same type of notification that a regular volume-up/down would be made of.
What's actually stealing the focus is the process handling the multimedia-keys input. That's the media-keys-manager part (libmedia-keys.so) of lp:gnome-settings-daemon iirc.
| Changed in notify-osd (Ubuntu): | |
| assignee: | Mirco Müller (macslow) → nobody |
| Changed in canonical-devices-system-image: | |
| milestone: | ww40-2015 → ww46-2015 |
| Sean Dague (sdague) wrote : | #7 |
I'm definitely seeing this as new behavior after the 15.10 upgrade. In 15.04 this was fine for me on the destkop, now things that generate notifications steal my focus so that things like F1 no longer get sent to the window manager for things like show/hide of Tilda.


Status changed to 'Confirmed' because the bug affects multiple users.