--- a/Frameworks/AIUtilities Framework/Source/AIAlternatingRowOutlineView.h Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIAlternatingRowOutlineView.h Thu Feb 02 00:40:15 2012 -0500
@@ -34,7 +34,7 @@
* Ignored if usesAlternatingRowBackgroundColors is NO.
-@property (readwrite, nonatomic, retain) NSColor *alternatingRowColor;
+@property (unsafe_unretained, readwrite, nonatomic) NSColor *alternatingRowColor; * @brief Whether the outlineView should draw its background
--- a/Frameworks/AIUtilities Framework/Source/AIAlternatingRowOutlineView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIAlternatingRowOutlineView.m Thu Feb 02 00:40:15 2012 -0500
@@ -59,17 +59,9 @@
[self setUsesAlternatingRowBackgroundColors:NO];
drawsGradientSelection = NO;
- alternatingRowColor = [[NSColor colorWithCalibratedRed:(237.0f/255.0f) green:(243.0f/255.0f) blue:(254.0f/255.0f) alpha:1.0f] retain];
+ alternatingRowColor = [NSColor colorWithCalibratedRed:(237.0f/255.0f) green:(243.0f/255.0f) blue:(254.0f/255.0f) alpha:1.0f];
- [alternatingRowColor release];
//Configuring ----------------------------------------------------------------------
- (void)setDrawsGradientSelection:(BOOL)inDrawsGradientSelection
@@ -87,8 +79,7 @@
- (void)setAlternatingRowColor:(NSColor *)color
if (color != alternatingRowColor) {
- [alternatingRowColor release];
- alternatingRowColor = [color retain];
+ alternatingRowColor = color; [self setNeedsDisplay:YES];
--- a/Frameworks/AIUtilities Framework/Source/AIArrayAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIArrayAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -35,7 +35,7 @@
arrayPath = [ownerBundle pathForResource:name ofType:@"plist"];
- return [[[NSArray alloc] initWithContentsOfFile:arrayPath] autorelease];
+ return [[NSArray alloc] initWithContentsOfFile:arrayPath]; - (NSComparisonResult)compare:(NSArray *)other
--- a/Frameworks/AIUtilities Framework/Source/AIAttributedStringAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIAttributedStringAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -43,7 +43,6 @@
[self appendAttributedString:tempString];
- (NSUInteger)replaceOccurrencesOfString:(NSString *)target withString:(NSString*)replacement options:(NSStringCompareOptions)opts range:(NSRange)searchRange
@@ -85,8 +84,6 @@
- [replacementString release];
return numberOfReplacements;
@@ -413,15 +410,15 @@
#define FONT_HEIGHT_STRING @"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789()"
+ (CGFloat)stringHeightForAttributes:(NSDictionary *)attributes
- NSAttributedString *string = [[[NSAttributedString alloc] initWithString:FONT_HEIGHT_STRING
- attributes:attributes] autorelease];
+ NSAttributedString *string = [[NSAttributedString alloc] initWithString:FONT_HEIGHT_STRING + attributes:attributes]; return [string heightWithWidth:1e7f];
+ (NSAttributedString *)stringWithString:(NSString *)inString
NSParameterAssert(inString != nil);
- return [[[NSAttributedString alloc] initWithString:inString] autorelease];
+ return [[NSAttributedString alloc] initWithString:inString]; + (NSAttributedString *)attributedStringWithString:(NSString *)inString linkRange:(NSRange)linkRange linkDestination:(id)inLink
@@ -434,7 +431,7 @@
NSParameterAssert(inLink != nil);
NSParameterAssert([inLink isKindOfClass:[NSURL class]]);
- NSMutableAttributedString *attributedString = [[[NSMutableAttributedString alloc] initWithString:inString] autorelease];
+ NSMutableAttributedString *attributedString = [[NSMutableAttributedString alloc] initWithString:inString]; //Throws NSInvalidArgumentException if the range is out-of-range.
[attributedString addAttribute:NSLinkAttributeName value:inLink range:linkRange];
@@ -451,7 +448,7 @@
NSParameterAssert([inLink isKindOfClass:[NSURL class]]);
NSDictionary *attributes = [NSDictionary dictionaryWithObject:inLink forKey:NSLinkAttributeName];
- return [[[self alloc] initWithString:inString attributes:attributes] autorelease];
+ return [[self alloc] initWithString:inString attributes:attributes]; - (CGFloat)heightWithWidth:(CGFloat)width
@@ -471,9 +468,6 @@
CGFloat height = [layoutManager usedRectForTextContainer:textContainer].size.height;
- [textContainer release];
- [layoutManager release];
@@ -502,7 +496,7 @@
* when the unarchiver is deallocated. We could rely upon autoreleasing the unarchiver, but it
* is cleaner to make the NSAttributedString autorelease itself.
- returnValue = (NSAttributedString *)[[[unarchiver decodeObject] retain] autorelease];
+ returnValue = (NSAttributedString *)[unarchiver decodeObject]; /* For reading previously stored NSData objects - we used to store them as RTF data, but that
@@ -510,11 +504,10 @@
* here isn't a speed problem. We previously used AIHTMLDecoder to handle Jaguar old-data unarchiving...
* but that's in Adium.framework and the cross over most certainly isn't worth it.
- returnValue = ([[[NSAttributedString alloc] initWithRTF:inData
- documentAttributes:nil] autorelease]);
+ returnValue = ([[NSAttributedString alloc] initWithRTF:inData + documentAttributes:nil]);
@@ -525,7 +518,7 @@
- (NSAttributedString *)attributedStringByConvertingAttachmentsToStrings
if ([self length] && [self containsAttachments]) {
- NSMutableAttributedString *newAttributedString = [[self mutableCopy] autorelease];
+ NSMutableAttributedString *newAttributedString = [self mutableCopy]; [newAttributedString convertAttachmentsToStringsUsingPlaceholder:AILocalizedString(@"<<Attachment>>", nil)];
return newAttributedString;
@@ -558,7 +551,7 @@
if (!newAttributedString) {
- newAttributedString = [[self mutableCopy] autorelease];
+ newAttributedString = [self mutableCopy]; currentAttributedString = newAttributedString;
@@ -590,7 +583,7 @@
- return (newAttributedString ? newAttributedString : [[self copy] autorelease]);
+ return (newAttributedString ? newAttributedString : [self copy]); - (NSAttributedString *)attributedStringByConvertingLinksToStrings
@@ -606,7 +599,7 @@
NSMutableAttributedString *str = [self mutableCopy];
[str addFormattingForLinks];
- return [str autorelease];
--- a/Frameworks/AIUtilities Framework/Source/AIAutoScrollView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIAutoScrollView.m Thu Feb 02 00:40:15 2012 -0500
@@ -68,8 +68,6 @@
[[NSNotificationCenter defaultCenter] removeObserver:self
name:NSViewFrameDidChangeNotification
//Auto Scrolling ---------------------------------------------------------------
--- a/Frameworks/AIUtilities Framework/Source/AIBezierPathAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIBezierPathAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -190,13 +190,13 @@
//these three return an autoreleased copy.
- (NSBezierPath *)bezierPathByFlippingHorizontally {
- return [[[self copy] autorelease] flipHorizontally];
+ return [[self copy] flipHorizontally]; - (NSBezierPath *)bezierPathByFlippingVertically {
- return [[[self copy] autorelease] flipVertically];
+ return [[self copy] flipVertically]; - (NSBezierPath *)bezierPathByScalingToSize:(NSSize)newSize {
- return [[[self copy] autorelease] scaleToSize:newSize];
+ return [[self copy] scaleToSize:newSize]; --- a/Frameworks/AIUtilities Framework/Source/AICharacterSetAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AICharacterSetAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -27,7 +27,7 @@
- (NSCharacterSet *)immutableCopy
- return [[NSCharacterSet characterSetWithBitmapRepresentation:[self bitmapRepresentation]] retain];
+ return [NSCharacterSet characterSetWithBitmapRepresentation:[self bitmapRepresentation]]; --- a/Frameworks/AIUtilities Framework/Source/AIColorAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIColorAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -72,7 +72,7 @@
//the rgb.txt file that comes with Mac OS X 10.3.8 contains 752 entries.
//we create 3 autoreleased objects for each one.
//best to not pollute our caller's autorelease pool.
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSMutableDictionary *mutableDict = [NSMutableDictionary dictionary];
@@ -135,14 +135,14 @@
} //for (unsigned i = 0; i < length; ++i)
//why not use -copy? because this is subclass-friendly.
//you can call this method on NSMutableDictionary and get a mutable dictionary back.
result = [[self alloc] initWithDictionary:mutableDict];
- return [result autorelease];
--- a/Frameworks/AIUtilities Framework/Source/AIColoredBoxView.h Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIColoredBoxView.h Thu Feb 02 00:40:15 2012 -0500
@@ -21,7 +21,7 @@
* View which draws, simply filling its bounds with a particular color.
@interface AIColoredBoxView : NSView {
+ NSColor *__unsafe_unretained color; @@ -29,6 +29,6 @@
* The <tt>NSColor</tt> to draw in the view
-@property (readwrite, nonatomic, retain) NSColor *color;
+@property (unsafe_unretained, readwrite, nonatomic) NSColor *color; --- a/Frameworks/AIUtilities Framework/Source/AIColoredBoxView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIColoredBoxView.m Thu Feb 02 00:40:15 2012 -0500
@@ -23,13 +23,6 @@
@implementation AIColoredBoxView
--- a/Frameworks/AIUtilities Framework/Source/AICompletingTextField.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AICompletingTextField.m Thu Feb 02 00:40:15 2012 -0500
@@ -76,14 +76,6 @@
- [impliedCompletionDictionary release];
//Sets the minimum string length required before completion kicks in
- (void)setMinStringLength:(int)length
@@ -98,10 +90,9 @@
//Set the strings that this field will use to auto-complete
- (void)setCompletingStrings:(NSArray *)strings
- stringSet = [[NSMutableSet setWithArray:strings] retain];
+ stringSet = [NSMutableSet setWithArray:strings]; - [impliedCompletionDictionary release]; impliedCompletionDictionary = nil;
+ impliedCompletionDictionary = nil; //Adds a string to the existing string list
@@ -223,8 +214,6 @@
NSArray *sortedArray = [possibleCompletions sortedArrayUsingSelector:@selector(compareLength:)];
- [possibleCompletions release];
if ([sortedArray count] > 0){
return [sortedArray objectAtIndex:0];
//When the AICompletingTextfield is modified to be able to provide multiple choices of completions, the entire array can be used later.
--- a/Frameworks/AIUtilities Framework/Source/AIDictionaryAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIDictionaryAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -109,8 +109,6 @@
NSLog(@"%s: Could not serialize. Error: \"%@\".", __PRETTY_FUNCTION__, retainedError);
[self validateAsPropertyList];
- if (retainedError) [retainedError release];
@@ -138,9 +136,8 @@
[mutable translate:translation add:addition remove:removal];
result = [[self class] dictionaryWithDictionary:mutable];
- result = [[self retain] autorelease];
@@ -207,7 +204,6 @@
NSMutableDictionary *mutableSelf = [self mutableCopy];
[mutableSelf intersectSetOfKeys:keys];
NSDictionary *result = [NSDictionary dictionaryWithDictionary:mutableSelf];
- (NSDictionary *)dictionaryWithDifferenceWithSetOfKeys:(NSSet *)keys
@@ -215,7 +211,6 @@
NSMutableDictionary *mutableSelf = [self mutableCopy];
[mutableSelf minusSetOfKeys:keys];
NSDictionary *result = [NSDictionary dictionaryWithDictionary:mutableSelf];
@@ -251,7 +246,6 @@
mutabilityOption:NSPropertyListMutableContainers
errorDescription:&error];
if (!dictionary && create) dictionary = [NSMutableDictionary dictionary];
@@ -276,8 +270,6 @@
//Add items that aren't in the removal set.
for (NSString *key in addition) {
if (!(removal && [removal containsObject:key])) {
--- a/Frameworks/AIUtilities Framework/Source/AIDockingWindow.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIDockingWindow.m Thu Feb 02 00:40:15 2012 -0500
@@ -80,7 +80,6 @@
[[NSNotificationCenter defaultCenter] removeObserver:self
name:NSWindowDidMoveNotification
//Watch the window move. If it gets near an edge, dock it to that edge
--- a/Frameworks/AIUtilities Framework/Source/AIFileManagerAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIFileManagerAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -153,11 +153,9 @@
- NSURL *folderURL = (NSURL *)CFURLCreateFromFSRef(kCFAllocatorSystemDefault, &folderRef);
+ NSURL *folderURL = (__bridge_transfer NSURL *)CFURLCreateFromFSRef(kCFAllocatorSystemDefault, &folderRef);
- [folderURL autorelease];
@@ -174,7 +172,7 @@
NSString *resolvedPath = nil;
- url = CFURLCreateWithFileSystemPath(/* allocator */ NULL, (CFStringRef)path,
+ url = CFURLCreateWithFileSystemPath(/* allocator */ NULL, (__bridge CFStringRef)path, kCFURLPOSIXPathStyle, /* isDir */ false);
@@ -184,7 +182,7 @@
&targetIsFolder, &wasAliased) == noErr && wasAliased) {
CFURLRef resolvedUrl = CFURLCreateFromFSRef(NULL, &fsRef);
- resolvedPath = [(NSString*)CFURLCopyFileSystemPath(resolvedUrl, kCFURLPOSIXPathStyle) autorelease];
+ resolvedPath = (__bridge_transfer NSString*)CFURLCopyFileSystemPath(resolvedUrl, kCFURLPOSIXPathStyle); @@ -192,7 +190,7 @@
- return (resolvedPath ? resolvedPath : [[path copy] autorelease]);
+ return (resolvedPath ? resolvedPath : [path copy]); --- a/Frameworks/AIUtilities Framework/Source/AIFlexibleLink.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIFlexibleLink.m Thu Feb 02 00:40:15 2012 -0500
@@ -23,19 +23,12 @@
if ((self = [super init])) {
trackingRect = inTrackingRect;
- title = [inTitle retain];
--- a/Frameworks/AIUtilities Framework/Source/AIFloater.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIFloater.m Thu Feb 02 00:40:15 2012 -0500
@@ -66,7 +66,7 @@
staticView = [[NSImageView alloc] initWithFrame:frame];
[staticView setImage:inImage];
[staticView setAutoresizingMask:(NSViewWidthSizable | NSViewHeightSizable)];
- [[panel contentView] addSubview:[staticView autorelease]];
+ [[panel contentView] addSubview:staticView]; @@ -98,11 +98,9 @@
- (IBAction)close:(id)sender
- [fadeAnimation stopAnimation]; [fadeAnimation release]; fadeAnimation = nil;
+ [fadeAnimation stopAnimation]; fadeAnimation = nil; - [panel release]; panel = nil;
- (void)setMaxOpacity:(CGFloat)inMaxOpacity
--- a/Frameworks/AIUtilities Framework/Source/AIGenericViewCell.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIGenericViewCell.m Thu Feb 02 00:40:15 2012 -0500
@@ -24,17 +24,10 @@
@implementation AIGenericViewCell
- [embeddedView release];
- (void)setEmbeddedView:(NSView *)inView
if (embeddedView != inView) {
- [embeddedView release];
- embeddedView = [inView retain];
@@ -42,7 +35,7 @@
- (id)copyWithZone:(NSZone *)zone
AIGenericViewCell *newCell = [super copyWithZone:zone];
- newCell->embeddedView = [embeddedView retain];
+ newCell->embeddedView = embeddedView; @@ -75,7 +68,7 @@
NSRect frame = [embeddedView frame];
NSRect usableFrame = NSMakeRect(0,0,frame.size.width,frame.size.height);
- image = [[[NSImage alloc] initWithSize:frame.size] autorelease];
+ image = [[NSImage alloc] initWithSize:frame.size]; [embeddedView setNeedsDisplay:YES];
[embeddedView drawRect:usableFrame];
@@ -89,7 +82,7 @@
NSRect subUsableFrame = NSMakeRect(0, 0, subFrame.size.width, subFrame.size.height);
- NSImage *subImage = [[[NSImage alloc] initWithSize:subFrame.size] autorelease];
+ NSImage *subImage = [[NSImage alloc] initWithSize:subFrame.size]; [subView drawRect:subUsableFrame];
--- a/Frameworks/AIUtilities Framework/Source/AIHostReachabilityMonitor.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIHostReachabilityMonitor.m Thu Feb 02 00:40:15 2012 -0500
@@ -90,18 +90,14 @@
[hostAndObserverListLock lock];
- [hosts release]; hosts = nil;
- [observers release]; observers = nil;
- [reachabilities release]; reachabilities = nil;
- [unconfiguredHostsAndObservers release]; unconfiguredHostsAndObservers = nil;
+ unconfiguredHostsAndObservers = nil; [hostAndObserverListLock unlock];
- [hostAndObserverListLock release];
[[NSNotificationCenter defaultCenter] removeObserver:self];
@@ -118,7 +114,6 @@
NSString *hostCopy = [host copy];
[self scheduleReachabilityMonitoringForHost:hostCopy
@@ -142,7 +137,7 @@
if ((!host) || ([host isEqualToString:[hosts objectAtIndex:i]])) {
[hosts removeObjectAtIndex:i];
[observers removeObjectAtIndex:i];
- SCNetworkReachabilityScheduleWithRunLoop((SCNetworkReachabilityRef)[reachabilities objectAtIndex:i],
+ SCNetworkReachabilityScheduleWithRunLoop((__bridge SCNetworkReachabilityRef)[reachabilities objectAtIndex:i], [reachabilities removeObjectAtIndex:i];
@@ -209,7 +204,7 @@
[hostAndObserverListLock lock];
- NSUInteger i = [reachabilities indexOfObjectIdenticalTo:(id)reachability];
+ NSUInteger i = [reachabilities indexOfObjectIdenticalTo:(__bridge id)reachability]; NSString *host = [hosts objectAtIndex:i];
id <AIHostReachabilityObserver> observer = [observers objectAtIndex:i];
@@ -221,7 +216,7 @@
if (![host isEqualToString:[hosts objectAtIndex:idx]])
- SCNetworkReachabilityRef otherReachability = (SCNetworkReachabilityRef)[reachabilities objectAtIndex:idx];
+ SCNetworkReachabilityRef otherReachability = (__bridge SCNetworkReachabilityRef)[reachabilities objectAtIndex:idx]; SCNetworkConnectionFlags flags;
if (SCNetworkReachabilityGetFlags(otherReachability, &flags)
@@ -261,7 +256,7 @@
(flags & kSCNetworkFlagsIsDirect) ? 'd' : '-');
- AIHostReachabilityMonitor *self = info;
+ AIHostReachabilityMonitor *self = (__bridge AIHostReachabilityMonitor *)info; [self reachabilityChanged:target];
@@ -272,7 +267,7 @@
static void hostResolvedCallback(CFHostRef theHost, CFHostInfoType typeInfo, const CFStreamError *error, void *info)
- NSDictionary *infoDict = info;
+ NSDictionary *infoDict = (__bridge NSDictionary *)info; AIHostReachabilityMonitor *self = [infoDict objectForKey:@"self"];
id observer = [infoDict objectForKey:@"observer"];
NSString *host = [infoDict objectForKey:@"host"];
@@ -293,7 +288,7 @@
// Only add 1 observer for IPv6 and one for IPv4.
BOOL addedIPv4 = NO, addedIPv6 = NO;
- for (NSData *saData in (NSArray *)addresses) {
+ for (NSData *saData in (__bridge NSArray *)addresses) { struct sockaddr *remoteAddr = (struct sockaddr *)saData.bytes;
if ((remoteAddr->sa_family == AF_INET && addedIPv4) || (remoteAddr->sa_family == AF_INET6 && addedIPv6)) {
@@ -308,7 +303,7 @@
SCNetworkReachabilityRef reachabilityRef;
SCNetworkReachabilityContext reachabilityContext = {
+ .info = (__bridge void *)self, .copyDescription = CFCopyDescription,
@@ -340,7 +335,7 @@
//Note that we succesfully configured for reachability notifications
- [self gotReachabilityRef:(SCNetworkReachabilityRef)[(NSObject *)reachabilityRef autorelease]
+ [self gotReachabilityRef:(SCNetworkReachabilityRef)reachabilityRef @@ -351,7 +346,7 @@
hostReachabilityChangedCallback(reachabilityRef,
+ (__bridge void *)self); /* Perform an immediate reachability check, since we've just scheduled checks for future changes
@@ -360,12 +355,12 @@
CFHostClientContext hostContext = {
- .info = [NSDictionary dictionaryWithObjectsAndKeys:
+ .info = (__bridge void *)([NSDictionary dictionaryWithObjectsAndKeys: reachabilityRef, @"reachabilityRef",
.copyDescription = CFCopyDescription,
@@ -391,9 +386,9 @@
//Call the reachability changed callback directly
- hostReachabilityChangedCallback((SCNetworkReachabilityRef)[infoDict objectForKey:@"reachabilityRef"],
+ hostReachabilityChangedCallback((__bridge SCNetworkReachabilityRef)[infoDict objectForKey:@"reachabilityRef"],
+ (__bridge void *)self); //No further need for this CFHost to be in our run loop
CFHostUnscheduleFromRunLoop(theHost,
@@ -419,7 +414,7 @@
[observers addObject:observer];
- [reachabilities addObject:(id)reachabilityRef];
+ [reachabilities addObject:(__bridge id)reachabilityRef]; //Remove from our unconfigured array
[self removeUnconfiguredHost:host
@@ -446,17 +441,17 @@
//Resolve the remote host domain name to an IP asynchronously
CFHostClientContext hostContext = {
- .info = [NSDictionary dictionaryWithObjectsAndKeys:
+ .info = (__bridge void *)([NSDictionary dictionaryWithObjectsAndKeys:
.copyDescription = CFCopyDescription,
CFHostRef host = CFHostCreateWithName(kCFAllocatorDefault,
- (CFStringRef)nodename);
+ (__bridge CFStringRef)nodename); @@ -573,7 +568,7 @@
static void localIPsChangedCallback(SCDynamicStoreRef store, CFArrayRef changedKeys, void *info)
- AIHostReachabilityMonitor *self = info;
+ AIHostReachabilityMonitor *self = (__bridge AIHostReachabilityMonitor *)info; /* Wait one second after receiving the callback, as it seems to be sent in some cases the middle of the change
* rather than after it is complete.
@@ -598,7 +593,7 @@
//Create the CFRunLoopSourceRef we will want to add to our run loop to have
//localIPsChangedCallback() called when the IP list changes
status = CreateIPAddressListChangeCallbackSCF(localIPsChangedCallback,
+ (__bridge void *)(self), &ipChangesRunLoopSourceRef);
@@ -645,7 +640,7 @@
NSEnumerator *enumerator;
SCNetworkReachabilityRef reachabilityRef;
enumerator = [reachabilities objectEnumerator];
- while ((reachabilityRef = (SCNetworkReachabilityRef)[enumerator nextObject])) {
+ while ((reachabilityRef = (__bridge SCNetworkReachabilityRef)[enumerator nextObject])) { SCNetworkReachabilityUnscheduleFromRunLoop(reachabilityRef,
@@ -665,9 +660,6 @@
[self addObserver:observer
- [oldObservers release];
--- a/Frameworks/AIUtilities Framework/Source/AIImageAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -42,7 +42,7 @@
image = [[NSImage alloc] initWithContentsOfFile:imagePath];
- return [image autorelease];
// Returns an image from the owners bundle with the specified name
@@ -129,7 +129,7 @@
NSSize size = [self size];
// Work with a temporary image so we don't modify self
- tempImage = [[[NSImage alloc] initWithSize:size] autorelease];
+ tempImage = [[NSImage alloc] initWithSize:size]; // Lock before drawing to the temporary image
@@ -307,7 +307,7 @@
NSSize size = [self size];
NSRect rect = NSMakeRect(0.0f, 0.0f, size.width, size.height);
- NSBitmapImageRep *bm = [[[NSBitmapImageRep alloc] initWithFocusedViewRect:rect] autorelease];
+ NSBitmapImageRep *bm = [[NSBitmapImageRep alloc] initWithFocusedViewRect:rect]; @@ -348,7 +348,7 @@
NSUInteger height = ((CGFloat)imageRep.pixelsWide - 100.0f)*ratio;
// Create a new rep with the lowered size
- NSBitmapImageRep *newImageRep = [[[NSBitmapImageRep alloc] initWithBitmapDataPlanes:NULL
+ NSBitmapImageRep *newImageRep = [[NSBitmapImageRep alloc] initWithBitmapDataPlanes:NULL bitsPerSample:imageRep.bitsPerSample
@@ -357,7 +357,7 @@
isPlanar:imageRep.isPlanar
colorSpaceName:NSCalibratedRGBColorSpace
bytesPerRow:imageRep.bytesPerRow
- bitsPerPixel:imageRep.bitsPerPixel] autorelease];
+ bitsPerPixel:imageRep.bitsPerPixel]; // Draw the old rep into the new rep
[NSGraphicsContext saveGraphicsState];
--- a/Frameworks/AIUtilities Framework/Source/AIImageButton.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageButton.m Thu Feb 02 00:40:15 2012 -0500
@@ -37,7 +37,7 @@
- (id)copyWithZone:(NSZone *)zone
AIImageButton *newButton = [super copyWithZone:zone];
- newButton->imageFloater = [imageFloater retain];
+ newButton->imageFloater = imageFloater; [newButton setCornerRadius:[self cornerRadius]];
@@ -46,9 +46,6 @@
[imageFloater close:nil];
- [imageFloater release];
@@ -84,7 +81,6 @@
[imageFloater close:nil];
- [imageFloater release];
@@ -103,7 +99,6 @@
[roundedImage unlockFocus];
[self setImage:roundedImage];
- [roundedImage release];
/* If the image would go off the right side of the screen from its origin, shift the origin left
@@ -114,7 +109,7 @@
- imageFloater = [[AIFloater newFloaterWithImage:bigImage styleMask:NSBorderlessWindowMask] retain];
+ imageFloater = [AIFloater newFloaterWithImage:bigImage styleMask:NSBorderlessWindowMask]; [imageFloater setMaxOpacity:1.0f];
[imageFloater moveFloaterToPoint:point];
[imageFloater setVisible:YES animate:NO];
@@ -145,7 +140,7 @@
if (!imageFloaterShouldBeOpen) {
[imageFloater close:nil];
- [imageFloater release]; imageFloater = nil;
--- a/Frameworks/AIUtilities Framework/Source/AIImageCollectionView.h Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageCollectionView.h Thu Feb 02 00:40:15 2012 -0500
@@ -28,10 +28,10 @@
@interface AIImageCollectionView : NSCollectionView {
- id <AIImageCollectionViewDelegate> delegate;
+ id <AIImageCollectionViewDelegate> __unsafe_unretained delegate; - IBOutlet NSArrayController *itemsController;
+ IBOutlet NSArrayController *__unsafe_unretained itemsController; NSInteger highlightStyle;
@@ -40,9 +40,9 @@
NSUInteger highlightedIndex;
-@property (readwrite, assign, nonatomic) id <AIImageCollectionViewDelegate> delegate;
+@property (readwrite, unsafe_unretained, nonatomic) id <AIImageCollectionViewDelegate> delegate; -@property (assign) IBOutlet NSArrayController *itemsController;
+@property (unsafe_unretained) IBOutlet NSArrayController *itemsController; @property (assign) NSInteger highlightStyle;
@property (assign) CGFloat highlightSize;
--- a/Frameworks/AIUtilities Framework/Source/AIImageCollectionView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageCollectionView.m Thu Feb 02 00:40:15 2012 -0500
@@ -69,20 +69,20 @@
highlightedIndex = NSNotFound;
- [self addTrackingArea:[[[NSTrackingArea alloc] initWithRect:[self bounds]
+ [self addTrackingArea:[[NSTrackingArea alloc] initWithRect:[self bounds] options:(NSTrackingMouseEnteredAndExited |
NSTrackingActiveInKeyWindow |
- userInfo:nil] autorelease]];
// Temporary solution, 1st tracking area will only report MouseMoved Events
- [self addTrackingArea:[[[NSTrackingArea alloc] initWithRect:[self bounds]
+ [self addTrackingArea:[[NSTrackingArea alloc] initWithRect:[self bounds] options:(NSTrackingMouseMoved |
NSTrackingActiveInKeyWindow |
- userInfo:nil] autorelease]];
// Track for item's selection changes
[self addObserver:self forKeyPath:@"selectionIndexes"
@@ -99,8 +99,6 @@
[self removeObserver:self forKeyPath:@"selectionIndexes"];
[self removeObserver:self forKeyPath:@"content"];
- (void)drawRect:(NSRect)dirtyRect
--- a/Frameworks/AIUtilities Framework/Source/AIImageDrawingAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageDrawingAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -84,7 +84,7 @@
// Proceed only if size or delta are changing
if ((NSEqualSizes(originalSize, size)) && (delta == 1.0) && !flipImage) {
- return [[self copy] autorelease];
@@ -151,9 +151,6 @@
// Write GIF Extension Blocks
[self writeGIFExtensionBlocksInData:GIFRepresentationData forRepresenation:(NSBitmapImageRep *)bestRep];
- //You must release before you re-allocate. The data is retained in an autorelease loop in the images array.
newImage = [[NSImage alloc] initWithData:GIFRepresentationData];
@@ -168,7 +165,7 @@
- return [newImage autorelease];
@@ -185,7 +182,7 @@
// Proceed only if size or delta are changing
if ((NSEqualSizes(originalSize, size)) && (delta == 1.0) && !flipImage) {
- return [[self copy] autorelease];
// Scale proportionally (rather than stretching to fit) if requested and needed
@@ -272,9 +269,6 @@
// Write GIF Extension Blocks
[self writeGIFExtensionBlocksInData:GIFRepresentationData forRepresenation:(NSBitmapImageRep *)bestRep];
- // Release before you re-allocate.
newImage = [[NSImage alloc] initWithData:GIFRepresentationData];
@@ -300,9 +294,7 @@
- return [newImage autorelease];
--- a/Frameworks/AIUtilities Framework/Source/AIImageTextCell.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageTextCell.m Thu Feb 02 00:40:15 2012 -0500
@@ -49,10 +49,7 @@
- [font release]; font = nil;
@@ -98,8 +95,7 @@
- (void)setFont:(NSFont *)inFont
- font = [inFont retain];
@@ -112,8 +108,7 @@
- (void)setSubString:(NSString *)inSubString
if (subString != inSubString) {
- subString = [inSubString retain];
+ subString = inSubString; @@ -422,8 +417,6 @@
[NSGraphicsContext restoreGraphicsState];
- [attributedMainString release];
NSAffineTransform *subStringTranslation = [NSAffineTransform transform];
@@ -432,7 +425,6 @@
[attributedSubString drawInRect:cellFrame];
- [attributedSubString release];
--- a/Frameworks/AIUtilities Framework/Source/AIImageViewWithImagePicker.h Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageViewWithImagePicker.h Thu Feb 02 00:40:15 2012 -0500
@@ -22,11 +22,11 @@
@class IKPictureTakerRecentPicture; // Private 10.5+ class
@interface AIImageViewWithImagePicker : NSImageView {
+ IBOutlet id __unsafe_unretained delegate; - id activeRecentPicture;
+ id __unsafe_unretained activeRecentPicture; BOOL presentPictureTakerAsSheet;
@@ -40,10 +40,10 @@
-@property (readwrite, assign, nonatomic) IBOutlet id delegate;
+@property (readwrite, unsafe_unretained, nonatomic) IBOutlet id delegate; -@property (retain) NSString *title;
-@property (assign) id activeRecentPicture;
+@property (unsafe_unretained) NSString *title; +@property (unsafe_unretained) id activeRecentPicture; @property (assign) BOOL usePictureTaker;
@property (assign) BOOL presentPictureTakerAsSheet;
@property (assign) BOOL shouldUpdateRecentRepository;
--- a/Frameworks/AIUtilities Framework/Source/AIImageViewWithImagePicker.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIImageViewWithImagePicker.m Thu Feb 02 00:40:15 2012 -0500
@@ -115,17 +115,12 @@
- [activeRecentPicture release];
- [pictureTaker release], pictureTaker = nil;
#pragma mark Getters and Setters
@@ -144,7 +139,7 @@
[pictureTaker setInputImage:inImage];
- [activeRecentPicture release], activeRecentPicture = nil;
+ activeRecentPicture = nil; @@ -156,8 +151,7 @@
- (void)setTitle:(NSString *)inTitle
- title = [inTitle retain];
[pictureTaker setTitle:title];
@@ -278,7 +272,6 @@
@@ -362,7 +355,7 @@
- (void)concludeDragOperation:(id <NSDraggingInfo>)sender
- NSImage *droppedImage = [[[NSImage alloc] initWithPasteboard:[sender draggingPasteboard]] autorelease];
+ NSImage *droppedImage = [[NSImage alloc] initWithPasteboard:[sender draggingPasteboard]]; @@ -447,7 +440,7 @@
NSData *imageData = (type ? [pb dataForType:type] : nil);
- NSImage *image = [[[NSImage alloc] initWithData:imageData] autorelease];
+ NSImage *image = [[NSImage alloc] initWithData:imageData]; NSSize imageSize = [image size];
@@ -551,7 +544,7 @@
- pictureTaker = [[IKPictureTaker pictureTaker] retain];
+ pictureTaker = [IKPictureTaker pictureTaker]; [pictureTaker setDelegate:self];
@@ -606,7 +599,7 @@
imageData = [NSData dataWithContentsOfURL:[[openPanel URLs] objectAtIndex:0]];
- image = (imageData ? [[[NSImage alloc] initWithData:imageData] autorelease] : nil);
+ image = (imageData ? [[NSImage alloc] initWithData:imageData] : nil); imageSize = (image ? [image size] : NSZeroSize);
if ((maxSize.width > 0 && imageSize.width > maxSize.width) ||
@@ -643,7 +636,7 @@
- (void)setRecentPictureAsImageInput:(IKPictureTakerRecentPicture *)recentPicture
if (activeRecentPicture != recentPicture) {
- [activeRecentPicture release]; activeRecentPicture = [recentPicture retain];
+ activeRecentPicture = recentPicture; //Update any open picture taker immediately.
--- a/Frameworks/AIUtilities Framework/Source/AIKeychain.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIKeychain.m Thu Feb 02 00:40:15 2012 -0500
@@ -83,14 +83,12 @@
+ (BOOL)unlockDefaultKeychainWithPassword:(NSString *)password error:(out NSError **)outError
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSData *data = [password dataUsingEncoding:NSUTF8StringEncoding];
NSAssert( UINT_MAX >= [data length], @"Attempting to send more data than Keychain can handle. Abort." );
OSStatus err = SecKeychainUnlock(/*keychain*/ NULL, (UInt32)[data length], [data bytes], /*usePassword*/ true);
@@ -104,6 +102,7 @@
+ (BOOL)allowsUserInteraction_error:(out NSError **)outError
@@ -211,13 +210,12 @@
if (!lastKnownDefaultKeychain ||
([lastKnownDefaultKeychain keychainRef] && (aKeychainRef != [lastKnownDefaultKeychain keychainRef]))) {
- [lastKnownDefaultKeychain release];
lastKnownDefaultKeychain = [[self alloc] init];
- return [[lastKnownDefaultKeychain retain] autorelease];
+ return lastKnownDefaultKeychain; NSLog(@"No default keychain!");
@@ -243,14 +241,13 @@
- [lastKnownDefaultKeychain release];
- lastKnownDefaultKeychain = [newDefaultKeychain retain];
+ lastKnownDefaultKeychain = newDefaultKeychain; + (AIKeychain *)keychainWithContentsOfFile:(NSString *)path error:(out NSError **)outError
- return [[[self alloc] initWithContentsOfFile:path error:outError] autorelease];
+ return [[self alloc] initWithContentsOfFile:path error:outError]; - (id)initWithContentsOfFile:(NSString *)path error:(out NSError **)outError
@@ -269,7 +266,6 @@
@@ -280,7 +276,7 @@
+ (AIKeychain *)keychainWithPath:(NSString *)path password:(NSString *)password promptUser:(BOOL)prompt initialAccess:(SecAccessRef)initialAccess error:(out NSError **)outError
- return [[[self alloc] initWithPath:path password:password promptUser:prompt initialAccess:initialAccess error:outError] autorelease];
+ return [[self alloc] initWithPath:path password:password promptUser:prompt initialAccess:initialAccess error:outError]; - (id)initWithPath:(NSString *)path password:(NSString *)password promptUser:(BOOL)prompt initialAccess:(SecAccessRef)initialAccess error:(out NSError **)outError
@@ -289,7 +285,7 @@
* ensure that the NSData that we create is an NSData.
*we create our own pool to ensure that both objects are released ASAP.
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
void *passwordBytes = NULL;
u_int32_t passwordLength = 0;
@@ -303,8 +299,6 @@
OSStatus err = SecKeychainCreate([path fileSystemRepresentation], passwordLength, passwordBytes, prompt, initialAccess, &keychainRef);
@@ -318,10 +312,9 @@
@@ -329,7 +322,7 @@
+ (AIKeychain *)keychainWithKeychainRef:(SecKeychainRef)newKeychainRef
- return [[[self alloc] initWithKeychainRef:newKeychainRef] autorelease];
+ return [[self alloc] initWithKeychainRef:newKeychainRef]; - (id)initWithKeychainRef:(SecKeychainRef)newKeychainRef
@@ -499,7 +492,7 @@
- (BOOL)unlockKeychainWithPassword:(NSString *)password error:(out NSError **)outError
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSData *data = [password dataUsingEncoding:NSUTF8StringEncoding];
@@ -507,8 +500,6 @@
NSAssert( UINT_MAX >= [data length], @"Attempting to send more data than Keychain can handle. Abort." );
OSStatus err = SecKeychainUnlock(keychainRef, (UInt32)[data length], [data bytes], /*usePassword*/ true);
@@ -523,6 +514,7 @@
@@ -573,7 +565,7 @@
NSParameterAssert(server != nil);
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSData *passwordData = [password dataUsingEncoding:NSUTF8StringEncoding];
@@ -606,8 +598,6 @@
(UInt32)[passwordData length], [passwordData bytes],
@@ -626,6 +616,7 @@
- (void)addInternetPassword:(NSString *)password forServer:(NSString *)server account:(NSString *)account protocol:(SecProtocolType)protocol error:(out NSError **)outError
@@ -850,7 +841,7 @@
SecKeychainItemRef item = NULL;
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
[self findInternetPasswordForServer:server
@@ -861,11 +852,10 @@
authenticationType:authType
- [(NSObject *)item autorelease]; //might as well.
//Retain this because of the autorelease pool.
- if (outError) *outError = [error retain];
+ if (outError) *outError = error; NSData *passwordData = [password dataUsingEncoding:NSUTF8StringEncoding];
NSAssert( UINT_MAX >= [passwordData length], @"Attempting to send more data than Keychain can handle. Abort." );
@@ -891,15 +881,13 @@
keychainRef, AIKEYCHAIN_ERROR_USERINFO_KEYCHAIN,
//Retain this because of the autorelease pool.
- error = [[NSError errorWithDomain:AIKEYCHAIN_ERROR_DOMAIN code:err userInfo:userInfo] retain];
+ error = [NSError errorWithDomain:AIKEYCHAIN_ERROR_DOMAIN code:err userInfo:userInfo]; } //if (!error) (findInternetPasswordForServer:...)
} //if (err == errSecDuplicateItem)
} //if (error) (addInternetPassword:...)
@@ -934,7 +922,7 @@
keychainItem:(out SecKeychainItemRef *)outKeychainItem
error:(out NSError **)outError
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
SecKeychainItemRef keychainItem = NULL;
@@ -968,13 +956,11 @@
- if (outError) *outError = [error retain];
+ if (outError) *outError = error; if (outKeychainItem) *outKeychainItem = keychainItem;
else if (keychainItem) CFRelease(keychainItem);
- if (outError) [*outError autorelease];
- (void)deleteInternetPasswordForServer:(NSString *)server account:(NSString *)account protocol:(SecProtocolType)protocol error:(out NSError **)outError
@@ -1002,7 +988,7 @@
NSParameterAssert(service != nil);
NSParameterAssert(account != nil);
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSData *passwordData = [password dataUsingEncoding:NSUTF8StringEncoding];
@@ -1019,8 +1005,6 @@
(UInt32)[passwordData length], [passwordData bytes],
@@ -1036,6 +1020,7 @@
- (NSString *)findGenericPasswordForService:(NSString *)service
@@ -1084,7 +1069,7 @@
account:(NSString *)account
error:(out NSError **)outError
- NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
SecKeychainItemRef keychainItem = NULL;
@@ -1116,7 +1101,7 @@
if (keychainItem) CFRelease(keychainItem);
--- a/Frameworks/AIUtilities Framework/Source/AILinkTextView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AILinkTextView.m Thu Feb 02 00:40:15 2012 -0500
@@ -51,7 +51,7 @@
- (void)_initLinkTextView
- linkTrackingController = [[AILinkTrackingController linkTrackingControllerForTextView:self] retain];
+ linkTrackingController = [AILinkTrackingController linkTrackingControllerForTextView:self]; [[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(frameDidChange:)
name:NSViewFrameDidChangeNotification
@@ -63,9 +63,6 @@
[[NSNotificationCenter defaultCenter] removeObserver:self];
- [linkTrackingController release];
//Pass clicks to the link tracking controller
@@ -121,7 +118,7 @@
NSEnumerator *enumerator;
- if (!menu) menu = [[[NSMenu alloc] init] autorelease];
+ if (!menu) menu = [[NSMenu alloc] init]; enumerator = [linkMenuItems reverseObjectEnumerator];
while ((menuItem = [enumerator nextObject])) {
--- a/Frameworks/AIUtilities Framework/Source/AILinkTrackingController.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AILinkTrackingController.m Thu Feb 02 00:40:15 2012 -0500
@@ -47,13 +47,13 @@
//Create a link tracking controller for any view
+ (id)linkTrackingControllerForView:(NSView *)inControlView withTextStorage:(NSTextStorage *)inTextStorage layoutManager:(NSLayoutManager *)inLayoutManager textContainer:(NSTextContainer *)inTextContainer
- return [[[self alloc] initForView:inControlView withTextStorage:inTextStorage layoutManager:inLayoutManager textContainer:inTextContainer] autorelease];
+ return [[self alloc] initForView:inControlView withTextStorage:inTextStorage layoutManager:inLayoutManager textContainer:inTextContainer]; //Create a tracking controller for a text view
+ (id)linkTrackingControllerForTextView:(NSTextView *)inTextView
- return [[[self alloc] initForView:inTextView withTextStorage:[inTextView textStorage] layoutManager:[inTextView layoutManager] textContainer:[inTextView textContainer]] autorelease];
+ return [[self alloc] initForView:inTextView withTextStorage:[inTextView textStorage] layoutManager:[inTextView layoutManager] textContainer:[inTextView textContainer]]; //Track links in the passed rect. Returns YES if links exist within our text. Pass a 0 width/height visible rect to stop any link tracking.
@@ -96,7 +96,7 @@
//Called when the mouse leaves the link
- (void)mouseExited:(NSEvent *)theEvent
- [self _setMouseOverLink:NO atPoint:NSMakePoint(0,0)];
+ [self _setMouseOverLink:nil atPoint:NSMakePoint(0,0)]; //Handle a mouse down. Returns NO if the mouse down event should continue to be processed
@@ -108,7 +108,7 @@
NSRectArray linkRects = nil;
- [self _setMouseOverLink:NO atPoint:NSMakePoint(0,0)]; //Remove any tooltips
+ [self _setMouseOverLink:nil atPoint:NSMakePoint(0,0)]; //Remove any tooltips //Find clicked char index
mouseLoc = [controlView convertPoint:[theEvent locationInWindow] fromView:nil];
@@ -236,12 +236,6 @@
[self _endCursorTracking];
- [hoveredString release];
//Begins cursor tracking, registering tracking rects for all our available links
@@ -299,15 +293,15 @@
visibleLinkRect = NSIntersectionRect(linkRect, visibleRect);
//Create a flexible link instance
- trackedLink = [[[AIFlexibleLink alloc] initWithTrackingRect:linkRect
+ trackedLink = [[AIFlexibleLink alloc] initWithTrackingRect:linkRect - title:[[textStorage string] substringWithRange:scanRange]] autorelease];
+ title:[[textStorage string] substringWithRange:scanRange]]; if (!linkArray) linkArray = [[NSMutableArray alloc] init];
[linkArray addObject:trackedLink];
//Install a tracking rect for the link (The userData of each tracking rect is the AIFlexibleLink it covers)
- trackingTag = [controlView addTrackingRect:visibleLinkRect owner:self userData:trackedLink assumeInside:NO];
+ trackingTag = [controlView addTrackingRect:visibleLinkRect owner:self userData:(__bridge void *)trackedLink assumeInside:NO]; [trackedLink setTrackingTag:trackingTag];
@@ -327,7 +321,7 @@
- [linkArray release]; linkArray = nil;
//Configure the mouse for being over a link or not
@@ -344,8 +338,8 @@
[[inHoveredLink title] caseInsensitiveCompare:[inHoveredLink url]] != NSOrderedSame &&
[[@"http://" stringByAppendingString:[inHoveredLink title]] caseInsensitiveCompare:[inHoveredLink url]] != NSOrderedSame) {
- [hoveredLink release]; hoveredLink = [inHoveredLink retain];
- [hoveredString release]; hoveredString = [[NSString stringWithFormat:@"%@", [hoveredLink url]] retain];
+ hoveredLink = inHoveredLink; + hoveredString = [NSString stringWithFormat:@"%@", [hoveredLink url]]; [AITooltipUtilities showTooltipWithString:hoveredString onWindow:nil atPoint:inPoint orientation:TooltipAbove]; //Show tooltip
@@ -356,8 +350,8 @@
[AITooltipUtilities showTooltipWithString:nil onWindow:nil atPoint:NSMakePoint(0,0) orientation:TooltipAbove]; //Hide the tooltip
- [hoveredLink release]; hoveredLink = nil;
- [hoveredString release]; hoveredString = nil;
@@ -398,11 +392,11 @@
- menuItemsArray = [[[NSMutableArray alloc] init] autorelease];
- menuItem = [[[NSMenuItem alloc] initWithTitle:COPY_LINK
+ menuItemsArray = [[NSMutableArray alloc] init]; + menuItem = [[NSMenuItem alloc] initWithTitle:COPY_LINK action:@selector(copyLink:)
- keyEquivalent:@""] autorelease];
[menuItem setRepresentedObject:linkURL];
[menuItemsArray addObject:menuItem];
@@ -413,7 +407,7 @@
//Copy the absolute URL to the clipboard
- (void)copyLink:(id)sender
- NSAttributedString *copyString = [[[NSAttributedString alloc] initWithString:[(NSURL *)[sender representedObject] absoluteString] attributes:nil] autorelease];
+ NSAttributedString *copyString = [[NSAttributedString alloc] initWithString:[(NSURL *)[sender representedObject] absoluteString] attributes:nil]; [[NSPasteboard generalPasteboard] declareTypes:[NSArray arrayWithObject:NSRTFPboardType] owner:nil];
[[NSPasteboard generalPasteboard] setData:[copyString RTFFromRange:NSMakeRange(0,[copyString length]) documentAttributes:nil] forType:NSRTFPboardType];
--- a/Frameworks/AIUtilities Framework/Source/AIMenuAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIMenuAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -25,7 +25,7 @@
[self addItem:theMenuItem];
- return [theMenuItem autorelease];
- (NSMenuItem *)addItemWithTitle:(NSString *)aString target:(id)target action:(SEL)aSelector keyEquivalent:(NSString *)charCode tag:(NSInteger)tag
@@ -36,7 +36,7 @@
[self addItem:theMenuItem];
- return [theMenuItem autorelease];
- (NSMenuItem *)addItemWithTitle:(NSString *)aString target:(id)target action:(SEL)aSelector keyEquivalent:(NSString *)charCode representedObject:(id)object
@@ -47,7 +47,7 @@
[self addItem:theMenuItem];
- return [theMenuItem autorelease];
@@ -128,11 +128,9 @@
NSMenu *menu = [self menu];
NSInteger idx = [menu indexOfItem:self];
[menu removeItemAtIndex:idx];
[self setKeyEquivalent:@""];
[menu insertItem:self atIndex:idx];
- (NSComparisonResult)titleCompare:(NSMenuItem *)inMenuItem
@@ -171,10 +169,10 @@
if (itemA == itemB) return;
- NSMenu *menuA = [[itemA retain] menu];
+ NSMenu *menuA = [itemA menu]; NSInteger indexA = menuA ? [menuA indexOfItem:itemA] : -1;
- NSMenu *menuB = [[itemB retain] menu];
+ NSMenu *menuB = [itemB menu]; NSInteger indexB = menuB ? [menuB indexOfItem:itemB] : -1;
if ((menuA == menuB) && (indexA < indexB)) {
@@ -208,16 +206,12 @@
NSMenuItem *primaryItem = [containingMenu itemAtIndex:(menuItemIndex-1)];
//Remove the primary item and readd it
[containingMenu removeItemAtIndex:(menuItemIndex-1)];
[containingMenu insertItem:primaryItem atIndex:(menuItemIndex-1)];
//Remove the alternate item and readd it
- [alternateItem retain];
[containingMenu removeItemAtIndex:menuItemIndex];
[containingMenu insertItem:alternateItem atIndex:menuItemIndex];
- [alternateItem release];
--- a/Frameworks/AIUtilities Framework/Source/AIMultiCellOutlineView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIMultiCellOutlineView.m Thu Feb 02 00:40:15 2012 -0500
@@ -46,19 +46,10 @@
//Cell used for content rows
- (void)setContentCell:(NSCell *)cell{
if (contentCell != cell) {
- contentCell = [cell retain];
contentRowHeight = [contentCell cellSize].height;
[self noteHeightOfRowsWithIndexesChanged:[NSIndexSet indexSetWithIndexesInRange:NSMakeRange(0, [self numberOfRows])]];
@@ -70,8 +61,7 @@
//Cell used for group rows
- (void)setGroupCell:(NSCell *)cell{
- groupCell = [cell retain];
groupRowHeight = [groupCell cellSize].height;
--- a/Frameworks/AIUtilities Framework/Source/AIMutableOwnerArray.h Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIMutableOwnerArray.h Thu Feb 02 00:40:15 2012 -0500
@@ -84,14 +84,14 @@
* @result The object with the highest priority, performing no other comparison
-@property (readonly, nonatomic) id objectValue;
+@property (unsafe_unretained, readonly, nonatomic) id objectValue; * @brief Greatest NSNumber value
* Assumes the \c AIMutableOwnerArray contains \c NSNumber instances
* @result Returns the greatest (highest value) contained \c NSNumber value.
-@property (readonly, nonatomic) NSNumber *numberValue;
+@property (unsafe_unretained, readonly, nonatomic) NSNumber *numberValue; * @brief Greatest integer value
@@ -112,7 +112,7 @@
* Assuming the \c AIMutableOwnerArray contains \c NSDate instances, returns the earliest one.
* @return Returns the earliest contained date.
-@property (readonly, nonatomic) NSDate *date;
+@property (unsafe_unretained, readonly, nonatomic) NSDate *date; * @brief Retrieve object by owner
@@ -151,7 +151,7 @@
* Retrieve an \c NSEnumerator for all objects in the \c AIMutableOwnerArray. Order is not guaranteed.
* @return Returns \c NSEnumerator for all objects.
-@property (readonly, nonatomic) NSEnumerator *objectEnumerator;
+@property (unsafe_unretained, readonly, nonatomic) NSEnumerator *objectEnumerator; * @brief Retrieve array of values
@@ -176,6 +176,6 @@
* to be notified with the \c AIMutableOwnerArray is modified.
* @param inDelegate The delegate
-@property (readwrite, nonatomic, assign) id delegate;
+@property (readwrite, nonatomic, unsafe_unretained) id delegate; --- a/Frameworks/AIUtilities Framework/Source/AIMutableOwnerArray.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIMutableOwnerArray.m Thu Feb 02 00:40:15 2012 -0500
@@ -51,7 +51,6 @@
@@ -66,7 +65,7 @@
[desc appendString:@">"];
- return [desc autorelease];
@@ -356,9 +355,9 @@
//Destroy our storage arrays
- [contentArray release]; contentArray = nil;
- [priorityArray release]; priorityArray = nil;
- [ownerArray release]; ownerArray = nil;
//Delegation -----------------------------------------------------------------------------------------
@@ -375,7 +374,7 @@
-- (NSUInteger)countByEnumeratingWithState:(NSFastEnumerationState *)state objects:(id *)stackbuf count:(NSUInteger)len;
+- (NSUInteger)countByEnumeratingWithState:(NSFastEnumerationState *)state objects:(id __unsafe_unretained [])stackbuf count:(NSUInteger)len; return [contentArray countByEnumeratingWithState:state objects:stackbuf count:len];
--- a/Frameworks/AIUtilities Framework/Source/AIMutableStringAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIMutableStringAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -20,8 +20,8 @@
+ (NSMutableString *)stringWithContentsOfASCIIFile:(NSString *)path
- return ([[[NSMutableString alloc] initWithData:[NSData dataWithContentsOfFile:path]
- encoding:NSASCIIStringEncoding] autorelease]);
+ return ([[NSMutableString alloc] initWithData:[NSData dataWithContentsOfFile:path] + encoding:NSASCIIStringEncoding]); - (NSMutableString*)mutableString
--- a/Frameworks/AIUtilities Framework/Source/AIOutlineView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIOutlineView.m Thu Feb 02 00:40:15 2012 -0500
@@ -298,7 +298,7 @@
[accessibilityActionNames addObject:NSAccessibilityPressAction];
[accessibilityActionNames addObject:NSAccessibilityShowMenuAction];
- return [accessibilityActionNames autorelease];
+ return accessibilityActionNames; --- a/Frameworks/AIUtilities Framework/Source/AIParagraphStyleAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIParagraphStyleAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -23,7 +23,7 @@
NSMutableParagraphStyle *paragraphStyle = [[NSParagraphStyle defaultParagraphStyle] mutableCopy];
[paragraphStyle setAlignment:alignment];
- return [paragraphStyle autorelease];
+ (NSMutableParagraphStyle *)styleWithAlignment:(NSTextAlignment)alignment lineBreakMode:(NSLineBreakMode)mode
@@ -32,7 +32,7 @@
[paragraphStyle setAlignment:alignment];
[paragraphStyle setLineBreakMode:mode];
- return [paragraphStyle autorelease];
--- a/Frameworks/AIUtilities Framework/Source/AIProgressDataUploader.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIProgressDataUploader.m Thu Feb 02 00:40:15 2012 -0500
@@ -78,7 +78,7 @@
delegate:(id <AIProgressDataUploaderDelegate>)delegate
- return [[[self alloc] initWithData:uploadData URL:url headers:headers delegate:delegate context:context] autorelease];
+ return [[self alloc] initWithData:uploadData URL:url headers:headers delegate:delegate context:context]; - (id)initWithData:(NSData *)inUploadData
@@ -88,11 +88,11 @@
if ((self = [super init])) {
- uploadData = [inUploadData retain];
+ uploadData = inUploadData;
- headers = [inHeaders retain];
@@ -100,12 +100,10 @@
- [url release]; url = nil;
- [headers release]; headers = nil;
- [uploadData release]; uploadData = nil;
- [returnedData release]; returnedData = nil;
@@ -117,22 +115,22 @@
CFHTTPMessageRef httpRequest = CFHTTPMessageCreateRequest(kCFAllocatorDefault,
+ (__bridge CFURLRef)url, for (NSString *headerKey in headers) {
CFHTTPMessageSetHeaderFieldValue(httpRequest,
- (CFStringRef)headerKey,
- (CFStringRef)[headers objectForKey:headerKey]);
+ (__bridge CFStringRef)headerKey, + (__bridge CFStringRef)[headers objectForKey:headerKey]); - CFHTTPMessageSetBody(httpRequest, (CFDataRef)uploadData);
+ CFHTTPMessageSetBody(httpRequest, (__bridge CFDataRef)uploadData); stream = CFReadStreamCreateForHTTPRequest(kCFAllocatorDefault, httpRequest);
CFStreamClientContext streamClientContext = {
+ (__bridge void *)(self), @@ -196,11 +194,11 @@
totalSize = [uploadData length];
- periodicTimer = [[NSTimer scheduledTimerWithTimeInterval:UPDATE_INTERVAL
+ periodicTimer = [NSTimer scheduledTimerWithTimeInterval:UPDATE_INTERVAL selector:@selector(updateProgress)
timeoutTimer = [[NSTimer alloc] initWithFireDate:[NSDate dateWithTimeIntervalSinceNow:TIMEOUT_INTERVAL]
interval:TIMEOUT_INTERVAL
@@ -221,7 +219,7 @@
- NSNumber *bytesWrittenPropertyNum = [NSMakeCollectable(CFReadStreamCopyProperty(stream, kCFStreamPropertyHTTPRequestBytesWrittenCount)) autorelease];
+ NSNumber *bytesWrittenPropertyNum = NSMakeCollectable(CFReadStreamCopyProperty(stream, kCFStreamPropertyHTTPRequestBytesWrittenCount)); NSInteger bytesWritten = [bytesWrittenPropertyNum integerValue];
if (bytesWritten > bytesSent) {
@@ -256,7 +254,7 @@
- AIProgressDataUploader *uploader = (AIProgressDataUploader *)info;
+ AIProgressDataUploader *uploader = (__bridge AIProgressDataUploader *)info; case kCFStreamEventHasBytesAvailable:
--- a/Frameworks/AIUtilities Framework/Source/AIRichTextCoercer.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIRichTextCoercer.m Thu Feb 02 00:40:15 2012 -0500
@@ -51,7 +51,7 @@
if([input isKindOfClass:[NSMutableAttributedString class]]) {
//The input string is mutable, so make a copy of the string.
- result = [[result copy] autorelease];
+ result = [result copy]; @@ -63,7 +63,7 @@
+ (id)coercePlainText:(NSString *)input toClass:(Class)class
if([class isSubclassOfClass:[NSAttributedString class]]) {
- return [[[class alloc] initWithString:input] autorelease];
+ return [[class alloc] initWithString:input]; --- a/Frameworks/AIUtilities Framework/Source/AIRolloverButton.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIRolloverButton.m Thu Feb 02 00:40:15 2012 -0500
@@ -44,8 +44,6 @@
[self removeTrackingRect:trackingTag];
#pragma mark Configuration
--- a/Frameworks/AIUtilities Framework/Source/AISendingTextView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AISendingTextView.m Thu Feb 02 00:40:15 2012 -0500
@@ -70,13 +70,6 @@
//If true we will invoke selector on target when a send key is pressed
@synthesize sendingEnabled;
--- a/Frameworks/AIUtilities Framework/Source/AISmoothTooltipTracker.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AISmoothTooltipTracker.m Thu Feb 02 00:40:15 2012 -0500
@@ -44,13 +44,13 @@
+ (AISmoothTooltipTracker *)smoothTooltipTrackerForView:(NSView *)inView withDelegate:(id <AISmoothTooltipTrackerDelegate>)inDelegate
- return [[[self alloc] initForView:inView withDelegate:inDelegate] autorelease];
+ return [[self alloc] initForView:inView withDelegate:inDelegate]; - (AISmoothTooltipTracker *)initForView:(NSView *)inView withDelegate:(id)inDelegate
if ((self = [super init])) {
- view = [inView retain];
tooltipLocation = NSZeroPoint;
@@ -91,9 +91,7 @@
[self _stopTrackingMouse];
- [view release]; view = nil;
- (void)setDelegate:(id <AISmoothTooltipTrackerDelegate>)inDelegate
@@ -228,11 +226,11 @@
if (!tooltipMouseLocationTimer) {
- tooltipMouseLocationTimer = [[NSTimer scheduledTimerWithTimeInterval:(1.0/TOOL_TIP_CHECK_INTERVAL)
+ tooltipMouseLocationTimer = [NSTimer scheduledTimerWithTimeInterval:(1.0/TOOL_TIP_CHECK_INTERVAL) selector:@selector(mouseMovementTimer:)
@@ -249,7 +247,7 @@
tooltipMouseLocationTimer = nil;
- [theTimer release]; theTimer = nil;
--- a/Frameworks/AIUtilities Framework/Source/AIStringAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIStringAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -163,11 +163,11 @@
+ (id)stringWithData:(NSData *)data encoding:(NSStringEncoding)encoding
- return [[[self alloc] initWithData:data encoding:encoding] autorelease];
+ return [[self alloc] initWithData:data encoding:encoding]; + (id)stringWithBytes:(const void *)inBytes length:(unsigned)inLength encoding:(NSStringEncoding)inEncoding
- return [[[self alloc] initWithBytes:inBytes length:inLength encoding:inEncoding] autorelease];
+ return [[self alloc] initWithBytes:inBytes length:inLength encoding:inEncoding]; @@ -203,7 +203,7 @@
NSRange range = NSMakeRange(0, 0);
outName = [self mutableCopy];
- CFStringLowercase((CFMutableStringRef)outName, /*locale*/ NULL);
+ CFStringLowercase((__bridge CFMutableStringRef)outName, /*locale*/ NULL); @@ -224,7 +224,7 @@
- return [outName autorelease];
#define BUNDLE_STRING @"$$BundlePath$$"
@@ -233,7 +233,7 @@
if ([self hasPrefix:BUNDLE_STRING]) {
return [[[[NSBundle mainBundle] bundlePath] stringByExpandingTildeInPath] stringByAppendingString:[self substringFromIndex:[BUNDLE_STRING length]]];
- return [[self copy] autorelease];
@@ -244,7 +244,7 @@
if ([self hasPrefix:bundlePath]) {
return [BUNDLE_STRING stringByAppendingString:[self substringFromIndex:[bundlePath length]]];
- return [[self copy] autorelease];
@@ -258,7 +258,7 @@
returnString = [[self substringToIndex:length-1] stringByAppendingString:[NSString ellipsis]];
//We don't need to truncate, so don't append an ellipsis
- returnString = [[self copy] autorelease];
+ returnString = [self copy]; @@ -280,7 +280,7 @@
[string replaceOccurrencesOfString:@"/" withString:@"-" options:NSLiteralSearch range:NSMakeRange(0, length)];
- return [string autorelease];
//- (NSString *)stringByEncodingURLEscapes
@@ -426,7 +426,7 @@
- return [[[NSString alloc] initWithBytes:destPtr length:destIndex encoding:NSASCIIStringEncoding] autorelease];
+ return [[NSString alloc] initWithBytes:destPtr length:destIndex encoding:NSASCIIStringEncoding]; //stringByDecodingURLEscapes
@@ -502,7 +502,7 @@
- return [[[NSString alloc] initWithBytes:destPtr length:destIndex encoding:NSASCIIStringEncoding] autorelease];
+ return [[NSString alloc] initWithBytes:destPtr length:destIndex encoding:NSASCIIStringEncoding]; @@ -546,11 +546,11 @@
- return [(NSString *)CFXMLCreateStringByEscapingEntities(kCFAllocatorDefault, (CFStringRef)self, (CFDictionaryRef)realEntities) autorelease];
+ return (__bridge_transfer NSString *)CFXMLCreateStringByEscapingEntities(kCFAllocatorDefault, (__bridge CFStringRef)self, (__bridge CFDictionaryRef)realEntities); - (NSString *)stringByUnescapingFromXMLWithEntities:(NSDictionary *)entities
- return [(NSString *)CFXMLCreateStringByUnescapingEntities(kCFAllocatorDefault, (CFStringRef)self, (CFDictionaryRef)entities) autorelease];
+ return (__bridge_transfer NSString *)CFXMLCreateStringByUnescapingEntities(kCFAllocatorDefault, (__bridge CFStringRef)self, (__bridge CFDictionaryRef)entities); @@ -743,10 +743,10 @@
uuid = CFUUIDCreate(NULL);
- uuidStr = (NSString *)CFUUIDCreateString(NULL, uuid);
+ uuidStr = (__bridge_transfer NSString *)CFUUIDCreateString(NULL, uuid); - return [uuidStr autorelease];
+ (NSString *)stringWithCGFloat:(CGFloat)f maxDigits:(NSUInteger)numDigits
@@ -779,7 +779,7 @@
if (!lineBreakCharacterSet) {
static const unichar lineBreakCharacters[numberOfLineBreakCharacters] = { LINE_FEED, FORM_FEED, CARRIAGE_RETURN, NEXT_LINE, LINE_SEPARATOR, PARAGRAPH_SEPARATOR };
- lineBreakCharacterSet = [[NSCharacterSet characterSetWithCharactersInString:[NSString stringWithCharacters:lineBreakCharacters length:numberOfLineBreakCharacters]] retain];
+ lineBreakCharacterSet = [NSCharacterSet characterSetWithCharactersInString:[NSString stringWithCharacters:lineBreakCharacters length:numberOfLineBreakCharacters]]; return lineBreakCharacterSet;
@@ -841,7 +841,7 @@
substringRange.length = lineBreakRange.location - searchRange.location;
[lines addObject:[self substringWithRange:substringRange]];
- if (separatorObj) [lines addObject:[[separatorObj copy] autorelease]];
+ if (separatorObj) [lines addObject:[separatorObj copy]]; searchRange.location = (lineBreakRange.location + lineBreakRange.length);
searchRange.length = selfLength - searchRange.location;
@@ -890,13 +890,13 @@
// reserved = ";" | "/" | "?" | ":" | "@" | "&" | "=" | "+" | "$" | ","
- NSString *string = (NSString *)CFURLCreateStringByAddingPercentEscapes(NULL,
+ NSString *string = (__bridge_transfer NSString *)CFURLCreateStringByAddingPercentEscapes(NULL, + (__bridge CFStringRef)self, (CFStringRef)@";/?:@&=+$",
- return [string autorelease];
--- a/Frameworks/AIUtilities Framework/Source/AIStringFormatter.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIStringFormatter.m Thu Feb 02 00:40:15 2012 -0500
@@ -27,14 +27,14 @@
+ (id)stringFormatterAllowingCharacters:(NSCharacterSet *)inCharacters length:(NSInteger)inLength caseSensitive:(BOOL)inCaseSensitive errorMessage:(NSString *)inErrorMessage
- return [[[self alloc] initAllowingCharacters:inCharacters length:inLength caseSensitive:inCaseSensitive errorMessage:inErrorMessage] autorelease];
+ return [[self alloc] initAllowingCharacters:inCharacters length:inLength caseSensitive:inCaseSensitive errorMessage:inErrorMessage]; - (id)initAllowingCharacters:(NSCharacterSet *)inCharacters length:(NSInteger)inLength caseSensitive:(BOOL)inCaseSensitive errorMessage:(NSString *)inErrorMessage
if ((self = [super init])) {
- errorMessage = [inErrorMessage retain];
- characters = [inCharacters retain];
+ errorMessage = inErrorMessage; + characters = inCharacters; caseSensitive = inCaseSensitive;
@@ -124,15 +124,4 @@
- [errorMessage release];
--- a/Frameworks/AIUtilities Framework/Source/AISystemNetworkDefaults.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AISystemNetworkDefaults.m Thu Feb 02 00:40:15 2012 -0500
@@ -84,19 +84,18 @@
- if ((proxyDict = (NSDictionary *)SCDynamicStoreCopyProxies(NULL))) {
- [proxyDict autorelease];
+ if ((proxyDict = (__bridge_transfer NSDictionary *)SCDynamicStoreCopyProxies(NULL))) { - enable = [[proxyDict objectForKey:(NSString *)enableKey] intValue];
+ enable = [[proxyDict objectForKey:(__bridge NSString *)enableKey] intValue]; - hostString = [proxyDict objectForKey:(NSString *)proxyKey];
+ hostString = [proxyDict objectForKey:(__bridge NSString *)proxyKey]; - portNum = [proxyDict objectForKey:(NSString *)portKey];
+ portNum = [proxyDict objectForKey:(__bridge NSString *)portKey]; @@ -131,7 +130,7 @@
NSString *pacFile = [proxyDict objectForKey:(NSString *)kSCPropNetProxiesProxyAutoConfigURLString];
- CFURLRef url = (CFURLRef)[NSURL URLWithString:[NSString stringWithFormat:@"http://%@", hostName ?: @"google.com"]];
+ CFURLRef url = (__bridge CFURLRef)[NSURL URLWithString:[NSString stringWithFormat:@"http://%@", hostName ?: @"google.com"]]; NSString *scriptStr = [NSString stringWithContentsOfURL:[NSURL URLWithString:pacFile] encoding:NSUTF8StringEncoding error:NULL];
@@ -143,7 +142,7 @@
CFRelease(CFNetworkCopyProxiesForURL(url, NULL));
- proxies = [(NSArray *)CFNetworkCopyProxiesForAutoConfigurationScript((CFStringRef)scriptStr, url, &error) autorelease];
+ proxies = (__bridge_transfer NSArray *)CFNetworkCopyProxiesForAutoConfigurationScript((__bridge CFStringRef)scriptStr, url, &error); CFStringRef description = CFErrorCopyDescription(error);
--- a/Frameworks/AIUtilities Framework/Source/AITextAttachmentAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AITextAttachmentAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -21,7 +21,7 @@
- (BOOL)consideredImageForHFSType:(OSType)HFSTypeCode
pathExtension:(NSString *)pathExtension
- NSMutableArray *imageFileTypes = [[[NSImage imageFileTypes] mutableCopy] autorelease];
+ NSMutableArray *imageFileTypes = [[NSImage imageFileTypes] mutableCopy]; NSArray *removeFileTypes = [NSArray arrayWithObjects:@"pdf", @"PDF", @"psd", @"PSD", @"'PDF '", nil];
[imageFileTypes removeObjectsInArray:removeFileTypes];
--- a/Frameworks/AIUtilities Framework/Source/AITextAttributes.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AITextAttributes.m Thu Feb 02 00:40:15 2012 -0500
@@ -35,19 +35,19 @@
//Creates a new instance of AITextAttributes
+ (id)textAttributesWithFontFamily:(NSString *)inFamilyName traits:(NSFontTraitMask)inTraits size:(NSInteger)inSize
- return [[[self alloc] initWithFontFamily:inFamilyName traits:inTraits size:inSize] autorelease];
+ return [[self alloc] initWithFontFamily:inFamilyName traits:inTraits size:inSize]; + (id)textAttributesWithDictionary:(NSDictionary *)inAttributes
- return [[[self alloc] initWithDictionary:inAttributes] autorelease];
+ return [[self alloc] initWithDictionary:inAttributes]; - (id)initWithFontFamily:(NSString *)inFamilyName traits:(NSFontTraitMask)inTraits size:(NSInteger)inSize
if ((self = [self init])) {
- fontFamilyName = [inFamilyName retain];
+ fontFamilyName = inFamilyName; fontTraitsMask = inTraits;
@@ -58,17 +58,16 @@
- (id)initWithDictionary:(NSDictionary *)inAttributes
if ((self = [self init])) {
dictionary = [inAttributes mutableCopy];
NSFont *font = [dictionary objectForKey:NSFontAttributeName];
- fontFamilyName = [[font familyName] retain];
+ fontFamilyName = [font familyName]; fontTraitsMask = [[NSFontManager sharedFontManager] traitsOfFont:font];
fontSize = [font pointSize];
- fontFamilyName = [@"Helvetica" retain];
+ fontFamilyName = @"Helvetica"; @@ -90,21 +89,12 @@
- [fontFamilyName release];
- (id)copyWithZone:(NSZone *)zone
AITextAttributes *newTextAttributes = [[AITextAttributes alloc] init];
newTextAttributes->dictionary = [dictionary mutableCopy];
- newTextAttributes->fontFamilyName = [fontFamilyName retain];
+ newTextAttributes->fontFamilyName = fontFamilyName; newTextAttributes->fontTraitsMask = fontTraitsMask;
newTextAttributes->fontSize = fontSize;
@@ -120,8 +110,7 @@
- (void)setFontFamily:(NSString *)inName
if (fontFamilyName != inName) {
- [fontFamilyName release];
- fontFamilyName = [inName retain];
+ fontFamilyName = inName; [dictionary removeObjectForKey:NSFontAttributeName];
@@ -317,7 +306,7 @@
- (void)resetFontAttributes
- [fontFamilyName release]; fontFamilyName = nil;
[dictionary removeObjectForKey:NSForegroundColorAttributeName];
[dictionary removeObjectForKey:NSBackgroundColorAttributeName];
@@ -364,7 +353,7 @@
paragraphStyle = [NSParagraphStyle defaultParagraphStyle];
- newParagraphStyle = [[paragraphStyle mutableCopy] autorelease];
+ newParagraphStyle = [paragraphStyle mutableCopy]; [newParagraphStyle setBaseWritingDirection:inDirection];
[dictionary setObject:newParagraphStyle forKey:NSParagraphStyleAttributeName];
--- a/Frameworks/AIUtilities Framework/Source/AITextViewWithPlaceholder.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AITextViewWithPlaceholder.m Thu Feb 02 00:40:15 2012 -0500
@@ -27,14 +27,13 @@
// NSDictionary *attributes;
// attributes = [NSDictionary dictionaryWithObjectsAndKeys:[NSColor grayColor], NSForegroundColorAttributeName, nil];
- [self setPlaceholder:[[[NSAttributedString alloc] initWithString:inPlaceholderString
- attributes:nil] autorelease]];
+ [self setPlaceholder:[[NSAttributedString alloc] initWithString:inPlaceholderString - (void)setPlaceholder:(NSAttributedString *)inPlaceholder
if (inPlaceholder != placeholder) {
NSMutableAttributedString *tempPlaceholder = [inPlaceholder mutableCopy];
[tempPlaceholder addAttribute:NSForegroundColorAttributeName value:[NSColor grayColor] range:NSMakeRange(0, [tempPlaceholder length])];
@@ -50,13 +49,6 @@
- (void)drawRect:(NSRect)rect
--- a/Frameworks/AIUtilities Framework/Source/AIToolbarTabView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIToolbarTabView.m Thu Feb 02 00:40:15 2012 -0500
@@ -38,11 +38,11 @@
- toolbarItems = [[NSMutableDictionary dictionary] retain];
+ toolbarItems = [NSMutableDictionary dictionary]; oldHeight = 100; //Height of the original tab view content
- NSToolbar *toolbar = [[[NSToolbar alloc] initWithIdentifier:@"ToolbarTabView"] autorelease];
+ NSToolbar *toolbar = [[NSToolbar alloc] initWithIdentifier:@"ToolbarTabView"]; [toolbar setDelegate:self];
[toolbar setAllowsUserCustomization:NO];
[toolbar setAutosavesConfiguration:NO];
@@ -51,15 +51,6 @@
[[self window] setToolbar:toolbar];
- [toolbarItems release];
//Toolbar --------------------------------------------------------------------------------------------------------------
//Install a toolbar item for each tab view item we contain
--- a/Frameworks/AIUtilities Framework/Source/AIToolbarUtilities.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIToolbarUtilities.m Thu Feb 02 00:40:15 2012 -0500
@@ -27,7 +27,7 @@
+ (NSToolbarItem *)toolbarItemWithIdentifier:(NSString *)identifier label:(NSString *)label paletteLabel:(NSString *)paletteLabel toolTip:(NSString *)toolTip target:(id)target settingSelector:(SEL)settingSelector itemContent:(id)itemContent action:(SEL)action menu:(NSMenu *)menu
- NSToolbarItem *item = [[[NSToolbarItem alloc] initWithItemIdentifier:identifier] autorelease];
+ NSToolbarItem *item = [[NSToolbarItem alloc] initWithItemIdentifier:identifier]; @@ -55,7 +55,7 @@
//We actually need an NSMenuItem here, so we construct one
- mItem = [[[NSMenuItem alloc] init] autorelease];
+ mItem = [[NSMenuItem alloc] init]; [mItem setSubmenu: menu];
[mItem setTitle: [menu title]];
[item setMenuFormRepresentation:mItem];
@@ -70,11 +70,11 @@
item = [theDict objectForKey:itemIdentifier];
- newItem = [[item copy] autorelease];
if ([item view] != NULL) {
if ([[item view] respondsToSelector:@selector(copyWithZone:)]) {
- [newItem setView:[[[item view] copy] autorelease]];
+ [newItem setView:[[item view] copy]]; /* For a toolbar only used in one window at a time, it's alright for a view to not allow copying.
--- a/Frameworks/AIUtilities Framework/Source/AITooltipUtilities.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AITooltipUtilities.m Thu Feb 02 00:40:15 2012 -0500
@@ -54,7 +54,7 @@
+ (void)showTooltipWithString:(NSString *)inString onWindow:(NSWindow *)inWindow atPoint:(NSPoint)inPoint orientation:(AITooltipOrientation)inOrientation
- [self showTooltipWithAttributedString:[[[NSAttributedString alloc] initWithString:inString] autorelease]
+ [self showTooltipWithAttributedString:[[NSAttributedString alloc] initWithString:inString] orientation:inOrientation];
@@ -109,7 +109,7 @@
!(inTitle == tooltipTitle) ||
!(inImage == tooltipImage)) { //we don't exist or something changed
- [tooltipTitle release]; tooltipTitle = [inTitle retain];
+ tooltipTitle = inTitle; [[textView_tooltipTitle textStorage] replaceCharactersInRange:NSMakeRange(0,[[textView_tooltipTitle textStorage] length])
@@ -118,7 +118,7 @@
[[textView_tooltipTitle textStorage] deleteCharactersInRange:NSMakeRange(0,[[textView_tooltipTitle textStorage] length])];
- [tooltipBody release]; tooltipBody = [inBody retain];
[[textView_tooltipBody textStorage] replaceCharactersInRange:NSMakeRange(0,[[textView_tooltipBody textStorage] length])
withAttributedString:tooltipBody];
@@ -126,7 +126,7 @@
[[textView_tooltipBody textStorage] deleteCharactersInRange:NSMakeRange(0,[[textView_tooltipBody textStorage] length])];
- [tooltipImage release]; tooltipImage = [inImage retain];
+ tooltipImage = inImage; imageOnRight = inImageOnRight;
[view_tooltipImage setImage:tooltipImage];
@@ -198,12 +198,10 @@
layoutManager = [[NSLayoutManager alloc] init];
[textStorage_tooltipTitle addLayoutManager:layoutManager];
- [layoutManager release];
container = [[NSTextContainer alloc] initWithContainerSize:NSMakeSize(TOOLTIP_MAX_WIDTH,10000000.0f)];
[container setLineFragmentPadding:1.0f]; //so widths will caclulate properly
[layoutManager addTextContainer:container];
textView_tooltipTitle = [[NSTextView alloc] initWithFrame:NSZeroRect textContainer:container];
[textView_tooltipTitle setSelectable:NO];
@@ -218,12 +216,10 @@
layoutManager = [[NSLayoutManager alloc] init];
[textStorage_tooltipBody addLayoutManager:layoutManager];
- [layoutManager release];
container = [[NSTextContainer alloc] initWithContainerSize:NSMakeSize(TOOLTIP_MAX_WIDTH,10000000.0f)];
[container setLineFragmentPadding:0.0f]; //so widths will caclulate properly
[layoutManager addTextContainer:container];
textView_tooltipBody = [[NSTextView alloc] initWithFrame:NSZeroRect textContainer:container];
[textView_tooltipBody setSelectable:NO];
@@ -267,18 +263,18 @@
+ (void)_reallyCloseTooltip
- [textView_tooltipBody release]; textView_tooltipBody = nil;
- [textView_tooltipTitle release]; textView_tooltipTitle = nil;
- [textStorage_tooltipBody release]; textStorage_tooltipBody = nil;
- [textStorage_tooltipTitle release]; textStorage_tooltipTitle = nil;
- [view_tooltipImage release]; view_tooltipImage = nil;
- [tooltipWindow release]; tooltipWindow = nil;
- [tooltipBody release]; tooltipBody = nil;
- [tooltipTitle release]; tooltipTitle = nil;
- [tooltipImage release]; tooltipImage = nil;
+ textView_tooltipBody = nil; + textView_tooltipTitle = nil; + textStorage_tooltipBody = nil; + textStorage_tooltipTitle = nil; + view_tooltipImage = nil; tooltipPoint = NSZeroPoint;
- [fadeOutAnimation release]; fadeOutAnimation = nil;
+ fadeOutAnimation = nil; @@ -293,7 +289,7 @@
static dispatch_once_t setTitleAndBodyMarginLineColor;
dispatch_once(&setTitleAndBodyMarginLineColor, ^{
- titleAndBodyMarginLineColor = [[[NSColor grayColor] colorWithAlphaComponent:.7f] retain];
+ titleAndBodyMarginLineColor = [[NSColor grayColor] colorWithAlphaComponent:.7f]; --- a/Frameworks/AIUtilities Framework/Source/AIVariableHeightOutlineView.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIVariableHeightOutlineView.m Thu Feb 02 00:40:15 2012 -0500
@@ -77,8 +77,6 @@
[[NSNotificationCenter defaultCenter] removeObserver:self];
@@ -338,8 +336,8 @@
//and then draw the cell into it at the regular size. This way the cell can overflow its bounds as normal and not
//spill outside the drag image.
rowRect = [self rectOfRow:firstRow];
- image = [[[NSImage alloc] initWithSize:NSMakeSize(rowRect.size.width,
- rowRect.size.height*count + [self intercellSpacing].height*(count-1))] autorelease];
+ image = [[NSImage alloc] initWithSize:NSMakeSize(rowRect.size.width, + rowRect.size.height*count + [self intercellSpacing].height*(count-1))]; //Draw (Since the OLV is normally flipped, we have to be flipped when drawing)
--- a/Frameworks/AIUtilities Framework/Source/AIVerticallyCenteredTextCell.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIVerticallyCenteredTextCell.m Thu Feb 02 00:40:15 2012 -0500
@@ -68,7 +68,7 @@
//Paragraph style for alignment and clipping
- NSMutableParagraphStyle *style = [[[NSParagraphStyle defaultParagraphStyle] mutableCopy] autorelease];
+ NSMutableParagraphStyle *style = [[NSParagraphStyle defaultParagraphStyle] mutableCopy]; [style setAlignment:[self alignment]];
[style setLineBreakMode:[self lineBreakMode]];
@@ -105,8 +105,6 @@
[attributedTitle drawInRect:cellFrame];
- [attributedTitle release];
--- a/Frameworks/AIUtilities Framework/Source/AIViewAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIViewAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -34,19 +34,18 @@
for (loop = 0;loop < [subviews count]; loop++) {
[[subviews objectAtIndex:loop] removeFromSuperview];
- (void)bringSubviewToFront:(NSView *)subview
- [self sortSubviewsUsingFunction:bringToFront context:subview];
+ [self sortSubviewsUsingFunction:bringToFront context:(__bridge void *)subview]; NSComparisonResult bringToFront(id itemA, id itemB, void *target)
+ if (itemA == (__bridge id)target) { return NSOrderedDescending;
- } else if (itemB == target) {
+ } else if (itemB == (__bridge id)target) { return NSOrderedAscending;
--- a/Frameworks/AIUtilities Framework/Source/JVMarkedScroller.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/JVMarkedScroller.m Thu Feb 02 00:40:15 2012 -0500
@@ -20,8 +20,8 @@
+__unsafe_unretained NSString *identifier; +__unsafe_unretained NSColor *color; @interface JVMarkedScroller (PRIVATE)
@@ -32,8 +32,8 @@
@implementation JVMarkedScroller
- (id) initWithFrame:(NSRect) frame {
if( ( self = [super initWithFrame:frame] ) ) {
- _marks = [[NSMutableSet set] retain];
- _shades = [[NSMutableArray array] retain];
+ _marks = [NSMutableSet set]; + _shades = [NSMutableArray array]; _nearestPreviousMark = NSNotFound;
_nearestNextMark = NSNotFound;
_currentMark = NSNotFound;
@@ -42,13 +42,8 @@
@@ -193,60 +188,59 @@
- (NSMenu *) menuForEvent:(NSEvent *) event {
- NSMenu *menu = [[[NSMenu alloc] initWithTitle:@""] autorelease];
+ NSMenu *menu = [[NSMenu alloc] initWithTitle:@""]; - item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear All Marks", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear all marks contextual menu item title" )
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear All Marks", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear all marks contextual menu item title" ) action:@selector( removeAllMarks )
- keyEquivalent:@""] autorelease];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Left", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here left contextual menu")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Left", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here left contextual menu") action:@selector( clearMarksHereLess: )
- keyEquivalent:@""] autorelease];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Right", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here right contextual menu")
- action:@selector( clearMarksHereGreater: ) keyEquivalent:@""]
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Right", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here right contextual menu") + action:@selector( clearMarksHereGreater: ) keyEquivalent:@""]; - item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Up", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here up contextual menu")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Up", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here up contextual menu") action:@selector( clearMarksHereLess: )
- keyEquivalent:@""] autorelease];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Down", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here up contextual menu")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Clear Marks from Here Down", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "clear marks from here up contextual menu") action:@selector( clearMarksHereGreater: )
- keyEquivalent:@""] autorelease];
[menu addItem:[NSMenuItem separatorItem]];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Previous Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to previous mark contextual menu")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Previous Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to previous mark contextual menu") action:@selector( jumpToPreviousMark: )
- keyEquivalent:@"["] autorelease];
[item setKeyEquivalentModifierMask:NSAlternateKeyMask | NSCommandKeyMask];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Next Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to next mark contextual menu")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Next Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to next mark contextual menu") action:@selector( jumpToNextMark: )
- keyEquivalent:@"]"] autorelease];
[item setKeyEquivalentModifierMask:NSAlternateKeyMask | NSCommandKeyMask];
- item = [[[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Focus Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to the mark where the last content the user saw ends")
+ item = [[NSMenuItem alloc] initWithTitle:AILocalizedStringFromTableInBundle( @"Jump to Focus Mark", nil, [NSBundle bundleWithIdentifier:AIUTILITIES_BUNDLE_ID], "jump to the mark where the last content the user saw ends") action:@selector( jumpToFocusMark: )
- keyEquivalent:@""] autorelease];
@@ -490,7 +484,7 @@
- (void) removeMarkWithIdentifier:(NSString *) identifier {
- NSEnumerator *e = [[[_marks copy] autorelease] objectEnumerator];
+ NSEnumerator *e = [[_marks copy] objectEnumerator]; while( ( obj = [e nextObject] ) ) {
@@ -504,7 +498,7 @@
- (void) removeMarksGreaterThan:(NSUInteger) location {
- NSEnumerator *enumerator = [[[_marks copy] autorelease] objectEnumerator];
+ NSEnumerator *enumerator = [[_marks copy] objectEnumerator]; while( ( obj = [enumerator nextObject] ) ) {
@@ -518,7 +512,7 @@
- (void) removeMarksLessThan:(NSUInteger) location {
- NSEnumerator *enumerator = [[[_marks copy] autorelease] objectEnumerator];
+ NSEnumerator *enumerator = [[_marks copy] objectEnumerator]; while( ( obj = [enumerator nextObject] ) ) {
@@ -532,7 +526,7 @@
- (void) removeMarksInRange:(NSRange) range {
- NSEnumerator *enumerator = [[[_marks copy] autorelease] objectEnumerator];
+ NSEnumerator *enumerator = [[_marks copy] objectEnumerator]; while( ( obj = [enumerator nextObject] ) ) {
--- a/Frameworks/AIUtilities Framework/Source/MVMenuButton.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/MVMenuButton.m Thu Feb 02 00:40:15 2012 -0500
@@ -50,20 +50,11 @@
[newButton setDrawsArrow:drawsArrow];
- [newButton setMenu:[[[self menu] copy] autorelease]];
+ [newButton setMenu:[[self menu] copy]];
//Configure ------------------------------------------------------------------------------------------------------------
//Control Size (Allows us to dynamically size for a small or big toolbar)
@@ -100,7 +91,7 @@
//Reset the popup arrow path cache, we'll need to re-calculate it for the new size
- [arrowPath release]; arrowPath = nil;
- (NSControlSize)controlSize
@@ -111,8 +102,7 @@
- (void)setImage:(NSImage *)inImage
if (bigImage != inImage) {
- bigImage = [inImage retain];
//Update our control size and the displayed image
@@ -164,7 +154,7 @@
NSRect frame = [self frame];
- arrowPath = [[NSBezierPath bezierPath] retain];
+ arrowPath = [NSBezierPath bezierPath]; if (controlSize == NSRegularControlSize) {
[arrowPath moveToPoint:NSMakePoint(NSWidth(frame)-9, NSHeight(frame)-5)];
--- a/Frameworks/AIUtilities Framework/Source/NSCalendarDate+ISO8601Unparsing.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/NSCalendarDate+ISO8601Unparsing.m Thu Feb 02 00:40:15 2012 -0500
@@ -43,7 +43,6 @@
NSString *dateFormat = [(includeTime ? @"%Y-%m-%dT%H:%M:%S" : @"%Y-%m-%d") prepareDateFormatWithTimeSeparator:timeSep];
NSDateFormatter *formatter = [[NSDateFormatter alloc] initWithDateFormat:dateFormat allowNaturalLanguage:NO];
NSString *str = [formatter stringForObjectValue:self];
NSInteger offset = [[self timeZone] secondsFromGMT];
offset /= 60; //bring down to minutes
@@ -107,7 +106,6 @@
NSDateFormatter *formatter = [[NSDateFormatter alloc] initWithDateFormat:[@"T%H:%M:%S%z" prepareDateFormatWithTimeSeparator:timeSep] allowNaturalLanguage:NO];
timeString = [formatter stringForObjectValue:self];
@@ -118,7 +116,6 @@
NSDateFormatter *formatter = [[NSDateFormatter alloc] initWithDateFormat:[@"T%H:%M:%S%z" prepareDateFormatWithTimeSeparator:timeSep] allowNaturalLanguage:NO];
timeString = [formatter stringForObjectValue:self];
@@ -169,7 +166,7 @@
- (NSString *)prepareDateFormatWithTimeSeparator:(unichar)timeSep {
NSString *dateFormat = self;
- NSMutableString *dateFormatMutable = [[dateFormat mutableCopy] autorelease];
+ NSMutableString *dateFormatMutable = [dateFormat mutableCopy]; [dateFormatMutable replaceOccurrencesOfString:@":"
withString:[NSString stringWithCharacters:&timeSep length:1U]
options:NSBackwardsSearch | NSLiteralSearch
--- a/Frameworks/AIUtilities Framework/Source/OWAddressBookAdditions.m Wed Jan 25 14:52:06 2012 -0500
+++ b/Frameworks/AIUtilities Framework/Source/OWAddressBookAdditions.m Thu Feb 02 00:40:15 2012 -0500
@@ -30,7 +30,7 @@
[result addObject:record];
- return [result autorelease];
--- a/xcconfigs/AIUtilities.framework.xcconfig Wed Jan 25 14:52:06 2012 -0500
+++ b/xcconfigs/AIUtilities.framework.xcconfig Thu Feb 02 00:40:15 2012 -0500
@@ -7,3 +7,4 @@
DYLIB_COMPATIBILITY_VERSION = 1
LD_DYLIB_INSTALL_NAME = @rpath/AIUtilities.framework/Versions/A/AIUtilities
+CLANG_ENABLE_OBJC_ARC = YES