Revision: 2547
          http://skim-app.svn.sourceforge.net/skim-app/?rev=2547&view=rev
Author:   hofman
Date:     2007-07-23 05:00:30 -0700 (Mon, 23 Jul 2007)

Log Message:
-----------
Sort note contents case insensitive and numerically, in case someone wants to 
label notes with some description including numbers.

Modified Paths:
--------------
    trunk/SKNotesDocument.m

Modified: trunk/SKNotesDocument.m
===================================================================
--- trunk/SKNotesDocument.m     2007-07-23 11:58:56 UTC (rev 2546)
+++ trunk/SKNotesDocument.m     2007-07-23 12:00:30 UTC (rev 2547)
@@ -253,9 +253,9 @@
         NSSortDescriptor *boundsSortDescriptor = [[[NSSortDescriptor alloc] 
initWithKey:@"bounds" ascending:ascending selector:@selector(boundsCompare:)] 
autorelease];
         NSMutableArray *sds = [NSMutableArray 
arrayWithObjects:pageIndexSortDescriptor, boundsSortDescriptor, nil];
         if ([tcID isEqualToString:@"type"]) {
-            [sds insertObject:[[[NSSortDescriptor alloc] 
initWithKey:@"noteType" ascending:YES] autorelease] atIndex:0];
+            [sds insertObject:[[[NSSortDescriptor alloc] 
initWithKey:@"noteType" ascending:YES 
selector:@selector(caseInsensitiveCompare:)] autorelease] atIndex:0];
         } else if ([tcID isEqualToString:@"note"]) {
-            [sds insertObject:[[[NSSortDescriptor alloc] 
initWithKey:@"contents" ascending:YES 
selector:@selector(caseInsensitiveCompare:)] autorelease] atIndex:0];
+            [sds insertObject:[[[NSSortDescriptor alloc] 
initWithKey:@"contents" ascending:YES 
selector:@selector(caseInsensitiveNumericCompare:)] autorelease] atIndex:0];
         } else if ([tcID isEqualToString:@"page"]) {
             if (oldTableColumn == nil)
                 ascending = NO;


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit

Reply via email to