Question

I have made an live wallpaper. I want to change the bitmap of the wallpaper from the preference activity. I am initializing the bitmap within the constructors and callingcanvas.drawbitmap() into my main thread.

The bitmaps has been initializes once in the constructor. I want to change the bitmap in the preview screen too in the wallpaper.

Était-ce utile?

La solution

Give value to bitmap in a separate method and call it in your constructor. call it from onVisibilityChanged(boolean visible) for a change if it is visible before your draw method.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top