adium-1.4 3163:03ee59ce5bcf: Made debug logging less noisy here
commits at adium.im
commits at adium.im
Sat Oct 30 07:03:14 UTC 2010
details: http://hg.adium.im/adium-1.4/rev/03ee59ce5bcf
revision: 3163:03ee59ce5bcf
author: Evan Schoenberg
date: Sat Oct 30 01:57:58 2010 -0500
Made debug logging less noisy here
Subject: adium-1.4 3164:a5e6a0a2bba3: Removed temporary debug logging
details: http://hg.adium.im/adium-1.4/rev/a5e6a0a2bba3
revision: 3164:a5e6a0a2bba3
author: Evan Schoenberg
date: Sat Oct 30 01:58:17 2010 -0500
Removed temporary debug logging
Subject: adium-1.4 3165:f524212f94f7: Typo fix in a comment
details: http://hg.adium.im/adium-1.4/rev/f524212f94f7
revision: 3165:f524212f94f7
author: Evan Schoenberg
date: Sat Oct 30 02:00:50 2010 -0500
Typo fix in a comment
Subject: adium-1.4 3166:8fc0082821be: Another typo fix in a comment
details: http://hg.adium.im/adium-1.4/rev/8fc0082821be
revision: 3166:8fc0082821be
author: Evan Schoenberg
date: Sat Oct 30 02:01:24 2010 -0500
Another typo fix in a comment
Subject: adium-1.4 3167:f2c01853e0f3: Removed another debug log
details: http://hg.adium.im/adium-1.4/rev/f2c01853e0f3
revision: 3167:f2c01853e0f3
author: Evan Schoenberg
date: Sat Oct 30 02:01:49 2010 -0500
Removed another debug log
Subject: adium-1.4 3168:9fcc0b9d4889: Huge optimization: Respect the clipRect when drawing the contact list. If you have 1000 contacts, of whom 20 are visible, we now draw 20, not 1000. Wow. Just wow. This also prevents needing to load usericons from disk for the 980 contacts for the unseeen display... though that is less useful given #14440 (the contacts menu in the status menu item loads 'em all anyways)
details: http://hg.adium.im/adium-1.4/rev/9fcc0b9d4889
revision: 3168:9fcc0b9d4889
author: Evan Schoenberg
date: Sat Oct 30 02:03:05 2010 -0500
Huge optimization: Respect the clipRect when drawing the contact list. If you have 1000 contacts, of whom 20 are visible, we now draw 20, not 1000. Wow. Just wow. This also prevents needing to load usericons from disk for the 980 contacts for the unseeen display... though that is less useful given #14440 (the contacts menu in the status menu item loads 'em all anyways)
diffs (126 lines):
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/AIUtilities Framework/Source/AIVariableHeightOutlineView.m
--- a/Frameworks/AIUtilities Framework/Source/AIVariableHeightOutlineView.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/AIUtilities Framework/Source/AIVariableHeightOutlineView.m Sat Oct 30 02:03:05 2010 -0500
@@ -231,12 +231,18 @@
}
- (void)drawRow:(NSInteger)row clipRect:(NSRect)rect
-{
+{
if (row >= 0 && row < [self numberOfRows]) { //Somebody keeps calling this method with row = numberOfRows, which is wrong.
+
+ /* Most important optimization ever:
+ * Only draw if some part of this row's rect is in the clip rect */
+ if (NSIntersectsRect([self rectOfRow:row], rect) == FALSE)
+ return;
+
NSArray *tableColumns = [self tableColumns];
id item = [self itemAtRow:row];
unsigned tableColumnIndex, count = [tableColumns count];
-
+
for (tableColumnIndex = 0 ; tableColumnIndex < count ; tableColumnIndex++) {
NSTableColumn *tableColumn;
NSRect cellFrame;
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/Adium Framework/Source/AIAbstractListController.m
--- a/Frameworks/Adium Framework/Source/AIAbstractListController.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/Adium Framework/Source/AIAbstractListController.m Sat Oct 30 02:03:05 2010 -0500
@@ -581,11 +581,6 @@
{
AIListObject *object = [notification object];
- static int listObjectAttributesChangedNum = 0;
- NSLog(@"listObjectAttributeChangesComplete #%i: %@ [%@]",
- ++listObjectAttributesChangedNum,
- object, [[notification userInfo] objectForKey:@"Keys"]);
-
//Redraw the modified object (or the whole list, if object is nil)
if (object) {
for (AIProxyListObject *proxyObject in [[object.proxyObjects copy] autorelease]) {
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/Adium Framework/Source/AIAbstractListObjectMenu.m
--- a/Frameworks/Adium Framework/Source/AIAbstractListObjectMenu.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/Adium Framework/Source/AIAbstractListObjectMenu.m Sat Oct 30 02:03:05 2010 -0500
@@ -64,8 +64,8 @@
/*!
* @brief Returns a menu containing our menu items
*
- * Remember that menu items can only be in one menu at a time, so if you use this functions you cannot do anything
- * manually the menu items
+ * Remember that menu items can only be in one menu at a time, so if you use this function you cannot do anything
+ * manually with the menu items
*/
- (NSMenu *)menu
{
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/Adium Framework/Source/AIContactMenu.m
--- a/Frameworks/Adium Framework/Source/AIContactMenu.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/Adium Framework/Source/AIContactMenu.m Sat Oct 30 02:03:05 2010 -0500
@@ -317,7 +317,7 @@
[inModifiedKeys containsObject:@"IdleSince"] ||
[inModifiedKeys containsObject:@"StatusType"]) {
- //Note that this will return nil if we don't ahve a menu item for inObject
+ //Note that this will return nil if we don't have a menu item for inObject
NSMenuItem *menuItem = [self existingMenuItemForContact:(AIListContact *)inObject];
//Update the changed menu item (or rebuild the entire menu if this item should be removed or added)
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/Adium Framework/Source/AIContactObserverManager.m
--- a/Frameworks/Adium Framework/Source/AIContactObserverManager.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/Adium Framework/Source/AIContactObserverManager.m Sat Oct 30 02:03:05 2010 -0500
@@ -147,8 +147,6 @@
[self.delayedUpdateTimer invalidate]; self.delayedUpdateTimer = nil;
- NSLog(@"endListObjectNotificationsDelaysImmediately");
-
[self _performDelayedUpdates:nil];
/* After immediately performing updates as requested, go back to delaying until inactivity if that was the
@@ -165,7 +163,6 @@
//know when they have finished connecting but still want to mute events.
- (void)delayListObjectNotificationsUntilInactivity
{
- NSLog(@"*** Begin grouping delay ***");
if (!delayedUpdateTimer) {
updatesAreDelayedUntilInactivity = YES;
self.delayedUpdateTimer = [NSTimer scheduledTimerWithTimeInterval:UPDATE_CLUMP_INTERVAL
@@ -255,7 +252,6 @@
nil)];
if (!shouldDelay) {
- NSLog(@"Immediate ListObject_AttributeChangesComplete for %@", inObject);
/* Note that we completed 1 or more delayed attribute changes */
[[NSNotificationCenter defaultCenter] postNotificationName:ListObject_AttributeChangesComplete
object:inObject
@@ -269,9 +265,6 @@
{
BOOL updatesOccured = (delayedStatusChanges || delayedAttributeChanges || delayedContactChanges);
- static int updatesDone = 0;
- NSLog(@"_performDelayedUpdates %p: %i", timer, ++updatesDone);
-
//Send out global attribute & status changed notifications (to cover any delayed updates)
if (updatesOccured) {
BOOL shouldSort = NO;
@@ -317,9 +310,7 @@
if (delayedUpdateTimer && (quietDelayedUpdatePeriodsRemaining-- <= 0)) {
[delayedUpdateTimer invalidate];
self.delayedUpdateTimer = nil;
- updatesAreDelayedUntilInactivity = NO;
-
- NSLog(@"The delayedUpdateTimer has EXPIRED");
+ updatesAreDelayedUntilInactivity = NO;
}
}
diff -r cbd40f45797a -r 9fcc0b9d4889 Frameworks/Adium Framework/Source/AIUserIcons.m
--- a/Frameworks/Adium Framework/Source/AIUserIcons.m Fri Oct 29 23:47:23 2010 -0500
+++ b/Frameworks/Adium Framework/Source/AIUserIcons.m Sat Oct 30 02:03:05 2010 -0500
@@ -422,7 +422,7 @@
proportionally:YES
allowAnimation:YES];
#ifdef AIUSERICON_DEBUG
- AILogWithSignature(@"%@ regenerated (cache? %i; listIconCache was %@)",inObject, cache, listIconCache);
+ AILogWithSignature(@"%@ regenerated (cache? %i)",inObject, cache);
#endif
if (cache) {
More information about the commits
mailing list