Preference window loads, but disappears immediately