romannurik/muzei — pull request #120 by ianhanniballake (2014-12-18 23:21:13+00:00)
Title: Optimize when to create scaled watch face background

Previously, we would create the scaled image in onDraw the first time after a resize event or after a new image was loaded. However, by utilizing onSurfaceChanged we can retrieve the current width and height prior to onDraw, allowing us to move the scaling from onDraw(). This also allows us to handle the more common case of a new image being loaded and allows us to scale the new image on the background thread.