On Apr 28, 2011, at 04:42, Vyacheslav Karamov wrote: > P.S. But I still can't understand why frame saving code doesn't work from > [NSWindow close]
It doesn't work because NSValue objects aren't valid in a property list, which is what the user defaults are. That's why, if you can't using the window's autosave name for some reason, you use NSStringFromRect() instead, as was already suggested. Another alternative is to use a NSData object, whose data is an archive (via NSKeyedArchiver encodeRectForKey:, most easily) of the frame. You use an archive so that architecture (word size/endianness) issues are taken care of for you automatically. _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please 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/archive%40mail-archive.com This email sent to arch...@mail-archive.com