Make OS X "Hide" command work correctly