On Fri, 26 Mar 2004 21:19:32 -0700
Adam Fedor <fedor@doc.com> wrote:
On Mar 25, 2004, at 4:49 PM, Chris B. Vetter wrote:
No, because this will set NSLanguages in NSGlobalDomain, not the
application's.
Perhaps you'll have to write your own NSUserDefaults method to do it.
I also think there is a bug in +[NSUserDefaults userLanguages] that
doesn't properly get the languages if they have been updated.
The problem isn't with setting the language and store it in the user's
defaults.
NSUserDefaults+setUserLanguages: writes into NSGlobalDomain, and
therefor will affect all applications and tools -- that's not what I
want.
So, instead I use
NSArray *array = [NSArray arrayWithObject: @"SomeLanguage"];
[userDefaults setObject: array forKey: @"NSLanguages"];
to write to the application's domain. It works insofar, that upon
restart "SomeLanguage" will be used instead of the default language set
in NSGlobalDomain.
However, what I'm _really_ trying to figure out is, why the change of
the language doesn't take effect right away.