add config option to select available languages

This commit is contained in:
j 2014-04-01 14:13:52 +00:00
parent 8d0373f879
commit ea2a5620f6
5 changed files with 5 additions and 1 deletions

View file

@ -629,6 +629,7 @@
{"id": "media", "title": "Media"} {"id": "media", "title": "Media"}
], ],
"language": "en", "language": "en",
"languages": ["ar", "el", "en", "hi"],
// fixme: should be renamed to annotationLayers // fixme: should be renamed to annotationLayers
"layers": [ "layers": [
{ {

View file

@ -646,6 +646,7 @@
{"id": "media", "title": "Media"} {"id": "media", "title": "Media"}
], ],
"language": "en", "language": "en",
"languages": ["ar", "el", "en", "hi"],
// fixme: should be renamed to annotationLayers // fixme: should be renamed to annotationLayers
"layers": [ "layers": [
{ {

View file

@ -520,6 +520,7 @@
{"id": "media", "title": "Media"} {"id": "media", "title": "Media"}
], ],
"language": "en", "language": "en",
"languages": ["ar", "el", "en", "hi"],
"layers": [ "layers": [
{ {
"id": "places", "id": "places",

View file

@ -442,6 +442,7 @@
{"id": "media", "title": "Media"} {"id": "media", "title": "Media"}
], ],
"language": "en", "language": "en",
"languages": ["ar", "el", "en", "hi"],
"layers": [ "layers": [
{ {
"id": "keywords", "id": "keywords",

View file

@ -190,7 +190,7 @@ pandora.ui.mainMenu = function() {
] }, ] },
{ id: 'locale', { id: 'locale',
title: Ox._('Language'), items: [ title: Ox._('Language'), items: [
{ group: 'setlocale', min: 1, max: 1, items: Object.keys(Ox.LOCALE_NAMES).map(function(locale) { { group: 'setlocale', min: 1, max: 1, items: pandora.site.languages.map(function(locale) {
return {id: locale, title: Ox.LOCALE_NAMES[locale], checked: ui.locale == locale} return {id: locale, title: Ox.LOCALE_NAMES[locale], checked: ui.locale == locale}
}) } }) }
] }, ] },