Created by: imirkin
Tested with WindowMaker. When switching to another workspace, minimizing, or rolling up the window, we get an UnmapNotify event, and a corresponding MapNotify event when the window appears on screen again.
Fixes #2675