Fix: Incoming Skype messages stealing focus on Linux Mint (Cinnamon)

After upgrading my PCs to Linux Mint Debian Edition, and thereby using the Cinnamon user interfacen, I encountered a particularly bothersome behaviour: For every incoming Skype message the skype window would come to the front and grab focus. So while typing you would even  continue to type in the Skype Window. Luckily I found a fix in the Skype Linux support forums.

This behaviour is already fixed in the Cinnamon Repository, But you can fix it yourself and don’t have to wait for an update. For instance the problem doesn’t seem to be fixed in the Update Pack 5 to Linux Mint Debian Edition.

Solution

At first locate the file called windowAttentionHandler.js – this can easily be done on the command line:

locate windowAttentionHandler.js

For me the path is /usr/share/cinnamon/js/ui/windowAttentionHandler.js – now you just need to open this file as a super user and make the same change as in the commit.

More easily speaking, at first open the file in a simple editor (pluma, gedit, nano, vi…) as the super user:

sudo gedit /usr/share/cinnamon/js/ui/windowAttentionHandler.js

now find this line:

if (!window || window.has_focus() || window.is_skip_taskbar())

And replace it with this line (or just adjust the latter part so it lookes like the line below):

if (!window || window.has_focus() || window.is_skip_taskbar() || window.get_wm_class() == "Skype")

For some weird reason the line wrapping of the code block doesn’t work. So hover that code box with your mouse and select view source code, you can then copy and paste from there!

Please be careful not to mess with the file, that could break your system (or at least the handling of the attention of windows). So make sure to make a backup of that file.

After this a restart is probably required for the changes to take effect, at least it was for me. As commenter Clement said you can also just hit Alt + F2 and type “r” and hit ENTERin order to restart cinnamon (Thanks for the comment!). So now, happy using Skype 😉

(By the way: there is a new Skype version for Linux – which doesn’t seem to be in the repositories yet. Check it out!)

Advertisements

Getting the “fortune cookies” back in the Linux Mint Debian Edition terminal

Some weeks ago I installed Linux Mint Debian edition after being a loyal and happy user of the Linux Mint main edition for some years. It was a very nice experience but something was missing… in the main edition, every time you open a terminal you are greeted by an animal, which has something more or less funny to say. I always liked that, it’s part of Linux Mint for me. However when I opened the terminal in my freshly installed Linux Mint Debian Edition I saw the following:

empty_terminal

No one greeted me. So I decided to ask on the forums. Gladly there is a solution for this (thanks to äxl for the answer!). You can simply run:


gconftool -s -t bol /desktop/linuxmint/terminal/show_fortunes true

Alternatively you can open the graphical configuration tool with “gconf-editor”, navigate to that path and change the value by hand. And then there they are again, my beloved “funny greeting messages”, “fortune cookies” or whatever you want to call them. And notice what really important wisdom my terminal has to share with me this time:

funny terminal