MINOR Correct labels for "delete from draft" batch actions (#4420)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@90823 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2009-11-04 22:46:54 +00:00
parent feafb55f94
commit 38d179b2a3

View File

@ -1331,13 +1331,15 @@ JS;
*/
function LangSelector() {
$member = Member::currentUser();
$dropdown = new LanguageDropdownField(
$locales = singleton('SiteTree')->getAllowedLocalesForMember(Member::currentUser());
$localesMap = array();
if($locales) foreach($locales as $locale) {
$localesMap[$locale] = i18n::get_locale_name($locale);
}
$dropdown = new DropdownField(
'LangSelector',
'Language',
array(),
'SiteTree',
'Locale-English',
singleton('SiteTree')
$localesMap
);
$dropdown->setValue(Translatable::get_current_locale());
return $dropdown;