On FadableImageSprite, we need to check for end-of-path fade in/fade out PRIOR to calling super, which chats with our sprite observers. Otherwise, those sprite observers might dispatch the sprite on a new fade which would then be immediately applied at full strength rather than applying slowly over the appropriate interval.
git-svn-id: svn+ssh://src.earth.threerings.net/nenya/trunk@776 ed5b42cb-e716-0410-a449-f6a68f950b19
This commit is contained in:
@@ -161,12 +161,12 @@ public class FadableImageSprite extends OrientableImageSprite
|
|||||||
@Override
|
@Override
|
||||||
public void pathCompleted (long timestamp)
|
public void pathCompleted (long timestamp)
|
||||||
{
|
{
|
||||||
super.pathCompleted(timestamp);
|
|
||||||
if (_fadeInDuration != -1) {
|
if (_fadeInDuration != -1) {
|
||||||
completeFadeIn();
|
completeFadeIn();
|
||||||
} else if (_fadeOutDuration != -1) {
|
} else if (_fadeOutDuration != -1) {
|
||||||
completeFadeOut();
|
completeFadeOut();
|
||||||
}
|
}
|
||||||
|
super.pathCompleted(timestamp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Completes the process of fading in. */
|
/** Completes the process of fading in. */
|
||||||
|
|||||||
Reference in New Issue
Block a user