GNOME Bugzilla – Bug 670092
some running favorites are lost after a shell restart
Last modified: 2012-02-24 12:23:16 UTC
When i restart g-s (like after an upgrade, or when doing extension development), i find that the dash is confused about some running "favorites" apps. i can reproduce easily with emacs. 1/ in the dash, search for emacs, add it as favorite. In my case, I get a purple icon (with a pen) named "GNU Emacs 23". 2/ click on that new favorite, you get an emacs window, all fine so far. I can move to another workspace, and click on that favorite again, it brings me to the already running emacs. 3/ restart g-s with alt-r and go to the dash. You see two purple icons now, one is the "GNU Emacs 23" favorite, the other is called "emacs" and represents the running window. I expect only one, like before the restart.
This means that the WM_CLASS for emacs doesn't match the desktop filename. If you're using Ubuntu, the bug for emacs is at https://bugs.launchpad.net/bugs/725988
Thanks for the hint, I fixed it in Ubuntu Precise.