Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sort descriptors of NSArrayController are lost (WAS: Re: NSArrayController, saving and reloading sort descriptors)



Thanks Aaron,

this indeed does the trick! Now I wonder if this is covered in any obvious way in any of the docs?

Cheers,
Knud

Am 16.03.2007 um 08:03 schrieb Aaron Tuller:

add this to your subclass:

- (id)reversedSortDescriptor
{
NSLog(@"reversed...");
id r = [super reversedSortDescriptor];
return [[[[self class] alloc] initWithKey:[r key] ascending:[r ascending] selector:[r selector]] autorelease];
}



and see if that helps.

-aaron


At 1:57 AM +0000 3/16/07, Knud Hinnerk Möller wrote:
Hi,

I made a little demo app [1] to isolate the problem I'm having with sort descriptors dissapearing from NSArrayControllers after those have been resorted (see previous mail in this thread). The program is self-explanatory - you'll see how the array controller's sort descriptor first is an instance of ThingyController and then magically an instance of NSSortDescriptor. I'd appreciate any help.

Cheers,
Knud

[1] http://sw.deri.org/~knud/demo/CoreDataTest.zip
-------------------------------------------------
Knud Möller, MA
+353 - 91 - 495086
Digital Enterprise Research Institute
  National University of Ireland, Galway
Institiúid Taighde na Fiontraíochta Digití
  Ollscoil na hÉireann, Gaillimh


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/mandelbaum% 40olywa.net


This email sent to email@hidden



------------------------------------------------- Knud Möller, MA +353 - 91 - 495086 Digital Enterprise Research Institute National University of Ireland, Galway Institiúid Taighde na Fiontraíochta Digití Ollscoil na hÉireann, Gaillimh


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/email@hidden

This email sent to email@hidden
References: 
 >Re: sort descriptors of NSArrayController are lost (WAS: Re: NSArrayController, saving and reloading sort descriptors) (From: Knud Hinnerk Möller <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.