Originally Posted by Torhal
Out of curiosity - why aren't you just using the supported WoW languages? Swedish isn't one of those...
|
I'm using client locale to determine a
default language, but that doesn't mean the user is satisfied with that layout. For example, as a Swedish player, I'd like to use our extended alphabet, since I can't write properly without it. There's no Swedish client, but there should definitely be a Swedish keyboard layout. The naming convention (English instead of enUS) is simply because I can use the table keys for easier dropdown creation in the config, plus it's a lot cleaner than using localization codes.
Lua Code:
function Keyboard:LoadSettings()
if not ConsolePortKeyboardSettings then
local locale = GetLocale()
ConsolePortKeyboardSettings = {
Layout = Language[Language.Default[locale]] or Language.English,
Language = Language.Default[locale],
}
end
end