Fixes highlighting when view is shifted. (examine, open, close)

Fixes #7697.
Also fixes a related SDL redraw problem #7574.