Don't add click listener to close prefs box until prefs box is opened.