adium 3065:d97028ea7927: Fix a warning about shadowing a local.
commits at adium.im
commits at adium.im
Thu Dec 24 02:55:18 UTC 2009
details: http://hg.adium.im/adium/rev/d97028ea7927
revision: 3065:d97028ea7927
author: Colin Barrett <colin at springsandstruts.com>
date: Wed Dec 23 16:31:04 2009 -1000
Fix a warning about shadowing a local.
Subject: adium 3066:d3613a0dcc6c: Fix a warning about shadowing a local.
details: http://hg.adium.im/adium/rev/d3613a0dcc6c
revision: 3066:d3613a0dcc6c
author: Colin Barrett <colin at springsandstruts.com>
date: Wed Dec 23 16:37:37 2009 -1000
Fix a warning about shadowing a local.
Subject: adium 3067:9f11c338dc7f: Fix a warning about shadowing a local.
details: http://hg.adium.im/adium/rev/9f11c338dc7f
revision: 3067:9f11c338dc7f
author: Colin Barrett <colin at springsandstruts.com>
date: Wed Dec 23 16:52:32 2009 -1000
Fix a warning about shadowing a local.
Subject: adium 3068:5d42a071bebd: Fix a warning about shadowing a local.
details: http://hg.adium.im/adium/rev/5d42a071bebd
revision: 3068:5d42a071bebd
author: Colin Barrett <colin at springsandstruts.com>
date: Wed Dec 23 16:53:01 2009 -1000
Fix a warning about shadowing a local.
Unfortunately introduce a conversion warning. Haven't yet figured out the best way to deal with those though.
diffs (99 lines):
diff -r 32fd9c61aa4b -r 5d42a071bebd Frameworks/Adium Framework/Source/AIAccountMenu.m
--- a/Frameworks/Adium Framework/Source/AIAccountMenu.m Wed Dec 23 21:01:25 2009 -0500
+++ b/Frameworks/Adium Framework/Source/AIAccountMenu.m Wed Dec 23 16:53:01 2009 -1000
@@ -251,7 +251,6 @@
if (includeDisabledAccountsMenu) {
NSMenu *disabledAccountMenu = [[NSMenu alloc] init];
- NSMenuItem *menuItem;
for (AIAccount *account in accounts) {
if (!account.enabled &&
@@ -279,7 +278,7 @@
format:AILocalizedString(@"%@",nil)];
- menuItem = [[NSMenuItem allocWithZone:[NSMenu menuZone]] initWithTitle:AILocalizedString(@"Add Account", nil)
+ NSMenuItem *menuItem = [[NSMenuItem allocWithZone:[NSMenu menuZone]] initWithTitle:AILocalizedString(@"Add Account", nil)
target:self
action:@selector(dummyAction:)
keyEquivalent:@""
@@ -290,7 +289,7 @@
}
if ([disabledAccountMenu numberOfItems]) {
- menuItem = [[NSMenuItem allocWithZone:[NSMenu menuZone]] initWithTitle:AILocalizedString(@"Disabled Accounts", nil)
+ NSMenuItem *menuItem = [[NSMenuItem allocWithZone:[NSMenu menuZone]] initWithTitle:AILocalizedString(@"Disabled Accounts", nil)
target:self
action:@selector(dummyAction:)
keyEquivalent:@""
diff -r 32fd9c61aa4b -r 5d42a071bebd Frameworks/Adium Framework/Source/AIAddressBookController.m
--- a/Frameworks/Adium Framework/Source/AIAddressBookController.m Wed Dec 23 21:01:25 2009 -0500
+++ b/Frameworks/Adium Framework/Source/AIAddressBookController.m Wed Dec 23 16:53:01 2009 -1000
@@ -1175,9 +1175,9 @@
* We don't make address book metacontacts actually persistent because then we would persist them even if the address
* book card were modified or deleted or if the user disabled "Conslidate contacts listed on the card."
*/
- NSDictionary *dict = [adium.preferenceController preferenceForKey:KEY_AB_TO_METACONTACT_DICT
+ NSDictionary *prefsDict = [adium.preferenceController preferenceForKey:KEY_AB_TO_METACONTACT_DICT
group:PREF_GROUP_ADDRESSBOOK];
- NSNumber *metaContactObjectID = [dict objectForKey:uniqueId];
+ NSNumber *metaContactObjectID = [prefsDict objectForKey:uniqueId];
if (metaContactObjectID)
metaContactHint = [adium.contactController metaContactWithObjectID:metaContactObjectID];
}
@@ -1194,12 +1194,12 @@
forKey:uniqueId];
if (metaContact != metaContactHint) {
//Keep track of the use of this metacontact for this address book card
- NSMutableDictionary *dict = [[[adium.preferenceController preferenceForKey:KEY_AB_TO_METACONTACT_DICT
+ NSMutableDictionary *prefsDict = [[[adium.preferenceController preferenceForKey:KEY_AB_TO_METACONTACT_DICT
group:PREF_GROUP_ADDRESSBOOK] mutableCopy] autorelease];
- if (!dict) dict = [NSMutableDictionary dictionary];
- [dict setObject:[metaContact objectID]
- forKey:uniqueId];
- [adium.preferenceController setPreference:dict
+ if (!prefsDict) prefsDict = [NSMutableDictionary dictionary];
+ [prefsDict setObject:[metaContact objectID]
+ forKey:uniqueId];
+ [adium.preferenceController setPreference:prefsDict
forKey:@"UniqueIDToMetaContactObjectIDDictionary"
group:PREF_GROUP_ADDRESSBOOK];
}
diff -r 32fd9c61aa4b -r 5d42a071bebd Frameworks/Adium Framework/Source/AIAuthorizationRequestsWindowController.m
--- a/Frameworks/Adium Framework/Source/AIAuthorizationRequestsWindowController.m Wed Dec 23 21:01:25 2009 -0500
+++ b/Frameworks/Adium Framework/Source/AIAuthorizationRequestsWindowController.m Wed Dec 23 16:53:01 2009 -1000
@@ -469,7 +469,8 @@
[tableView setNeedsDisplayInRect:[tableView rectOfRow:row]];
[tableView noteHeightOfRowsWithIndexesChanged:[NSIndexSet indexSetWithIndex:row]];
- [requiredHeightDict setObject:[NSNumber numberWithDouble:MIN(MAXIMUM_ROW_HEIGHT, MAX(MINIMUM_ROW_HEIGHT, combinedHeight))]
+ CGFloat bottomClampedRowHeight = MAX(MINIMUM_ROW_HEIGHT, combinedHeight);
+ [requiredHeightDict setObject:[NSNumber numberWithDouble:MIN(MAXIMUM_ROW_HEIGHT, bottomClampedRowHeight)]
forKey:[NSNumber numberWithInteger:row]];
}
}
diff -r 32fd9c61aa4b -r 5d42a071bebd Frameworks/Adium Framework/Source/AIMessageEntryTextView.m
--- a/Frameworks/Adium Framework/Source/AIMessageEntryTextView.m Wed Dec 23 21:01:25 2009 -0500
+++ b/Frameworks/Adium Framework/Source/AIMessageEntryTextView.m Wed Dec 23 16:53:01 2009 -1000
@@ -1644,14 +1644,14 @@
updateFilenames:NO];
//Now create an AITextAttachmentExtension pointing to it
- AITextAttachmentExtension *attachment = [[AITextAttachmentExtension alloc] init];
- [attachment setPath:destinationPath];
- [attachment setString:preferredName];
- [attachment setShouldSaveImageForLogging:YES];
+ AITextAttachmentExtension *textAttachment = [[AITextAttachmentExtension alloc] init];
+ [textAttachment setPath:destinationPath];
+ [textAttachment setString:preferredName];
+ [textAttachment setShouldSaveImageForLogging:YES];
//Insert an attributed string into the text at the current insertion point
- replacement = [self attributedStringWithTextAttachmentExtension:attachment];
- [attachment release];
+ replacement = [self attributedStringWithTextAttachmentExtension:textAttachment];
+ [textAttachment release];
//Remove the NSTextAttachment, replacing it the AITextAttachmentExtension
[attributedString replaceCharactersInRange:attachmentRange
More information about the commits
mailing list