From a9cabe918cdc152e97fd7b1189f6ac530e00ccb4 Mon Sep 17 00:00:00 2001 From: Mitchell Livingston Date: Thu, 10 Dec 2009 13:06:04 +0000 Subject: [PATCH] return to using a static NSUInteger for message index - even if never reset, it's never going to hit its max and this is much simpler --- macosx/MessageWindowController.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/macosx/MessageWindowController.m b/macosx/MessageWindowController.m index 799f46100..869c64e70 100644 --- a/macosx/MessageWindowController.m +++ b/macosx/MessageWindowController.m @@ -158,7 +158,7 @@ [fLock lock]; - NSUInteger currentIndex = [fMessages count] > 0 ? ([[[fMessages lastObject] objectForKey: @"Index"] unsignedIntegerValue] + 1) : 0; + static NSUInteger currentIndex = 0; NSScroller * scroller = [[fMessageTable enclosingScrollView] verticalScroller]; const BOOL shouldScroll = currentIndex == 0 || [scroller floatValue] == 1.0 || [scroller isHidden]