2011-01-04 02:45:53 +00:00
|
|
|
#import "CATransactionGroup.h"
|
|
|
|
#import <Foundation/NSDictionary.h>
|
2020-05-11 15:52:05 +00:00
|
|
|
#import <Foundation/NSNumber.h>
|
|
|
|
#import <QuartzCore/CATransaction.h>
|
2011-01-04 02:45:53 +00:00
|
|
|
|
|
|
|
@implementation CATransactionGroup
|
|
|
|
|
2020-05-11 15:52:05 +00:00
|
|
|
- init {
|
|
|
|
_values = [[NSMutableDictionary alloc] init];
|
|
|
|
[_values setObject: [NSNumber numberWithFloat: 0.25]
|
|
|
|
forKey: kCATransactionAnimationDuration];
|
|
|
|
[_values setObject: [NSNumber numberWithBool: NO]
|
|
|
|
forKey: kCATransactionDisableActions];
|
|
|
|
// kCATransactionAnimationTimingFunction default is nil
|
|
|
|
// kCATransactionCompletionBlock default is nil
|
|
|
|
return self;
|
2011-01-04 02:45:53 +00:00
|
|
|
}
|
|
|
|
|
2020-05-11 15:52:05 +00:00
|
|
|
- valueForKey: (NSString *) key {
|
|
|
|
return [_values objectForKey: key];
|
2011-01-04 02:45:53 +00:00
|
|
|
}
|
|
|
|
|
2020-05-11 15:52:05 +00:00
|
|
|
- (void) setValue: value forKey: (NSString *) key {
|
|
|
|
[_values setObject: value forKey: key];
|
2011-01-04 02:45:53 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
@end
|