Android: overridePendingTransition Animation Background Color
Trying to use overridePendingTransition to apply custom animations to my activity changes. The problem is that my themed app uses colored backgrounds in the activities, and while animating a black background is visible while one view scales out and another scales in.
I would 开发者_开发技巧like to know if it is possible to specify the default background color here, and also if I can make it skinnable.
Any help would be greatly appreciated.
Thanks, Josh
The animations you supply are only window animations -- they describe how to move the entire window/activity surfaces. There is no concept of a background or other such thing, just 2d transformations (and alpha fades) being applied to the entire window surface.
Further, you need to be careful when creating such animations that when you put them together the two windows are always entirely covering the screen, because there is nothing behind your application to provide a background. Thus any such animation typically needs to involve one of the windows remaining opaque if another is fading, and if they are moving they need to do so in a way that the always cover the screen as it done with the default slide left/right animation.
精彩评论