Is it possible to tell xdg-open (or alikes) to open a window in the background?
1
vote
0
answers
903
views
I am using
xdg-open
with cronjobs to open our time-management web-app once per hour to log my time (among other repeating things). This works very well, but has an annoying usability problem. Once every hour, at exactly **:00
the browser-window open in the foreground with focus and steals my focus that way. If I am typing something at that time and hit enter, something completely unrelated may be posted to our time-management-software. (This only rarely happens, most of the time it is *just* being annoying instead of destructive.)
Is there maybe some way of making the window appear in the background and not steal my focus, if it was created from a cronjob? Maybe some parameter to be set or some environment-variable to be defined to make the window appear in the background or maybe another program that solves this problem in a better way?
I don't want to just activate the focus-stealing for the whole system, because this would get in the way even more. I would have to focus every summoned window every time to actually use it and otherwise still write into the old window.
It should be possible for the window-manager to distinguish between windows that *I* requested directly (foreground please) and windows that were opened automatically by some cronjob, automatic update or outside message (background please). But that is probably wishful thinking, is it?
I'm currently on Ubuntu 16.04 (Unity), browsing with Firefox. (Can another desktop- or window-manager maybe do this?)
Thank you for taking the time to answer me.
Asked by Gerrit Addiks
(61 rep)
Oct 2, 2020, 07:18 PM