A;adido Wotlk Futura Implementacion y Varios arreglos en js
This commit is contained in:
@@ -0,0 +1,68 @@
|
||||
/*
|
||||
Locale class
|
||||
*/
|
||||
|
||||
var LOCALE_ENUS = 0;
|
||||
var LOCALE_FRFR = 2;
|
||||
var LOCALE_DEDE = 3;
|
||||
var LOCALE_ZHCN = 4;
|
||||
var LOCALE_ESES = 6;
|
||||
var LOCALE_RURU = 8;
|
||||
|
||||
var Locale = {
|
||||
|
||||
current: {},
|
||||
|
||||
// All
|
||||
locales: {
|
||||
6: { // Spanish
|
||||
id: LOCALE_ESES,
|
||||
name: 'eses',
|
||||
domain: 'es',
|
||||
description: 'Espa' + String.fromCharCode(241) + 'ol'
|
||||
}
|
||||
},
|
||||
|
||||
getAll: function() {
|
||||
var result = [];
|
||||
|
||||
for (var id in Locale.locales) {
|
||||
result.push(Locale.locales[id]);
|
||||
}
|
||||
|
||||
return result;
|
||||
},
|
||||
|
||||
getAllByName: function() {
|
||||
var result = Locale.getAll();
|
||||
|
||||
result.sort(function(a, b) {
|
||||
return $WH.strcmp(a.description, b.description);
|
||||
});
|
||||
|
||||
return result;
|
||||
},
|
||||
|
||||
getId: function() {
|
||||
return Locale.current.id;
|
||||
},
|
||||
|
||||
getName: function() {
|
||||
var localeId = Locale.getId();
|
||||
|
||||
return Locale.locales[localeId].name;
|
||||
},
|
||||
|
||||
get: function() {
|
||||
var localeId = Locale.getId();
|
||||
|
||||
return Locale.locales[localeId];
|
||||
},
|
||||
|
||||
set: function(localeId) {
|
||||
$.extend(Locale.current, Locale.locales[localeId]);
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
Locale.set(LOCALE_ESES); // Default
|
||||
Reference in New Issue
Block a user