Fix potential error notification during window cycling when there is no focused window.