On 23 Nov 2009, at 13:33, Ariel Feinerman wrote:

Hi,
there is instance of NSDictionary to storage graphics attributes (full
screen, buffers` sizes, resolution),
my question is can I change value for, example, key "fullscreen"
somewhere in my progam?

From the NSDictionary Class Reference:

"An instance of NSDictionary is an immutable dictionary: you establish its entries when it’s created and cannot modify them afterward. An instance of NSMutableDictionary is a mutable dictionary: you can add or delete entries at any time, and the object automatically allocates memory as needed."

Use an NSMutableDictionary and invoke e.g.

[myMutableDictionary setObject: [NSNumber numberWithBool: fstate] forKey: @"fullscreen"];

This replaces a previous entry with the same key.

Regards
Klaus

_______________________________________________

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

Reply via email to