Sunday, March 08, 2015

How to Recover Skype Taskbar Flashing in Cinnamon

UPDATE: Confirmed to work on Cinnamon 2.8.6!
This is a problem I've had every time I install Skype under Linux Mint. I don't know if other people have had the same problem, but I know that I'm sick of running around Google trying to hit the specific keywords that will lead me to the solution to this problem.

When one installs Skype under Linux Mint (and this has been happening for a few versions now, starting in 16 for me), new messages have a notification, a notification sound, but no other indicator that a message has been received.
As far as I know, under Linux Mint, applications tell the manager that they need attention. Skype actually does this, but for some reason Cinnamon ignores it.

After a good deal of asking and searching, I've come across this answer on SuperUser which details how to set Cinnamon up to stop ignoring Skype's calls.

It is reproduced below but all credit goes to Curious for the original answer.

  1. Open /usr/share/cinnamon/applets/ in your favorite text editor.

    sudo subl /usr/share/cinnamon/applets/

  2. Find the lines: = this;'button-release-event', Lang.bind(this, this._onButtonRelease));
    this.metaWindow = metaWindow;
  3. Paste this after them: =;
    Save and close the file.

  4. Open /usr/share/cinnamon/js/ui/windowAttentionHandler.js
    sudo subl /usr/share/cinnamon/js/ui/windowAttentionHandler.js

  5. Find the line:
    onWindowDemandsAttention : function(display, window) { 
  6. Paste this after it:
    if (window && !window.has_focus() && window.get_wm_class() && window.get_wm_class().indexOf("Skype") > -1) {     "window-list-item-demands-attention");    
  7. Save and close the file.

  8. Hit ALT+F2 and type r into the prompt. Cinnamon will be restarted.

If you've done everything correctly, new messages on Skype should highlight the window in the taskbar. You will have to redo this every time Cinnamon updates, so bookmark this page for easy access. Now, go forth and try it out with your favorite victim friend.