Seems like this event handler belongs in PreferencesManager.