Fix settings dialog offering ReferencePreviews when unavailable
- It is possible to make the patch smaller in case this makes it easier to backport it. Is this worth it?
- This code is not covered by any test. I think it's worth writing tests. Most of this code will stay, even after beta.