Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Meaning of explicit transactions
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Meaning of explicit transactions



I am trying to learn about the Core Animation framework.

One thing I am still a bit unclear about is the exact meaning of explicit transactions.

For instance, assume I've got the following code:

[CATransaction begin];
[CATransaction setValue: [NSNumber numberWithFloat: 2.0f] forKey: kCATransactionAnimationDuration ];
[currentLayer_ removeFromSuperlayer];
// make new currentLayer_ ...
[mainLayer_ addSublayer: currentLayer_ ];
[CATransaction commit];


Does that mean that *both* animations (the one for removeFromSuperlayer and the one for addSublayer)
are started at the point where 'CATransaction commit' is executed?
(with duration of 2 seconds)
Or does it mean that both animations just have a duration of 2 seconds, but each of them is started at the respective point in the code?


Best regards,
Gabriel.

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.