OSDN Git Service

[Magnifier-78] Fix shadow on first draw
authorMihai Popa <popam@google.com>
Tue, 26 Feb 2019 18:01:37 +0000 (18:01 +0000)
committerMihai Popa <popam@google.com>
Tue, 26 Feb 2019 18:01:37 +0000 (18:01 +0000)
commit6bf0b2f65625b99f0b2d4bdabce241c96b8d6fb3
tree107b1f24d1cb2991fa12f935b89bb207f3dfe920
parentd3af535583b240ff8a2b4b5cd4dc726e4b308062
[Magnifier-78] Fix shadow on first draw

The CL fixes the light source position when the magnifier is first
drawn. Before this CL, the source position was set only after the
magnifier was drawn for the first time, causing an incorrect shadow for
the first draw. This was noticeable if the magnifier was trigerred and
not moved (the shadow was updated and started looking fine when the
magnifier was moved and a new draw happened).

Bug: none
Test: manual testing
Change-Id: Iabdd34430a5def3608197294cf694c5045a7d8d3
core/java/android/widget/Magnifier.java