DO NOT MERGE: Issue 2106: Live Preview Snapshot

This is a PR for issue #2106.
Same as above. In which scenarios the app wouldn't have a UIWindow instance?