Z轴阴影: Z = elevation + translationZ
elevation 是静态值,是View在Z轴上的初始值
translationZ是动态值,是Z上的偏移变化
参考 http://*.com/questions/29367804/difference-between-elevation-and-translationz
That is because the actual Z value is the sum of the elevation
and the translationZ
In the docs the say elevation
is "base z depth of the view" and this is a static variable, while translationZ is dynamic.
So elevation
is your start value and for animations you should use translationZ
.