setTransform on a Component and Animation


#1

I’m setting a AffineTransform::rotation on a label, at some point i’m doing a ComponentAnimator::fadeOut

the call to fadeOut cancels the AffineTrasnform (rotates the label to it’s non-rotated position), is this normal behavior ?
Is there some other way i can do rotation+fade on a component.


#2

i guess the proxy component that ComponentAnimator uses just needs to also copy the affinetransform from the source component?


#3

yeah but is there a way to get access to the created proxy component ?


#4

no, sorry, i meant it’s probably just an oversight in the actual implementation


#5

Yes, the animation stuff was written long before transforms came along. I guess it just needs a little tweak:

ProxyComponent (Component& component) : image (component.createComponentSnapshot (component.getLocalBounds())) { setBounds (component.getBounds()); setTransform (component.getTransform()); ...etc