Avoid sending messages of destroyed Engine
And app can call notifyColorsChanged() on a destroyed engine, which
would cause problems, given it doesn't have a surface anymore.
The same is true to visibility notification, where the engine can be
destroyed before it had the opportuinity of drawing its first frame (if
it had to load large assets for example)
Test: manually change wallpapers
Test: WallpaperServiceTest (both CTS and internal)
Fixes: 291053623
Change-Id: Iff83603695cff491f2045586d5b3f4658f7ae55a
3 files changed