Fails safely if no overlay nor theme is available. Fixes #853.
Merge pull request #874 from pgiraud/mobile_no_overlay

Fails safely if no overlay nor theme is available. Fixes #853.