ScreenSaverDefaults woes...
ScreenSaverDefaults woes...
- Subject: ScreenSaverDefaults woes...
- From: Phillip Hutchings <email@hidden>
- Date: Wed, 14 Jan 2004 16:14:46 +1300
I'm trying to give my screensaver preferences. It works fine with
everything except NSColor, for text and background colours.
I'm getting the colours from an NSColorWell in to an NSColor*, like
this:
NSColor *newTextColour = [textColour color];
NSColor *newBgColour = [backgroundColour color];
But when I try to synchronise the defaults, it crashes.
The problem is the NSColors are being released somewhere, I've logged
the retain counts from an NSLog() and I get this:
Retain Counts: newTextColour:4294967295 newBgColour:4294967295
Just after getting them.
Checking from the debugger, the type of the two NSColors is
NSCachedWhiteColor. Now, I know that at least one of those is set to
black, and I have no idea why I'm getting those and not an NSColor, as
the documentation suggests. I know they're both linked properly in IB.
Any ideas?
This is on 10.3, but the screensaver is supposed to work on 10.2 as
well.
--
Phillip Hutchings
email@hidden
http://www.sitharus.com/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.