From c0b1d93d799e7016e09320d45009ec1f6b88d8d5 Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Thu, 1 Mar 2012 19:05:30 +0100 Subject: [PATCH] Adds language variable for i18n inputs --- wcfsetup/install/files/acp/templates/header.tpl | 1 + wcfsetup/install/files/js/WCF.js | 6 +++--- wcfsetup/install/lang/de.xml | 3 ++- wcfsetup/install/lang/en.xml | 1 + 4 files changed, 7 insertions(+), 4 deletions(-) diff --git a/wcfsetup/install/files/acp/templates/header.tpl b/wcfsetup/install/files/acp/templates/header.tpl index b4d0e0e140..36f65a50ca 100644 --- a/wcfsetup/install/files/acp/templates/header.tpl +++ b/wcfsetup/install/files/acp/templates/header.tpl @@ -66,6 +66,7 @@ 'wcf.global.page.previous': '{capture assign=pagePrevious}{lang}wcf.global.page.previous{/lang}{/capture}{@$pagePrevious|encodeJS}', 'wcf.global.button.collapsible': '{lang}wcf.global.button.collapsible{/lang}', 'wcf.global.button.disable': '{lang}wcf.global.button.disable{/lang}', + 'wcf.global.button.disabledI18n': '{lang}wcf.global.button.disabledI18n{/lang}', 'wcf.global.button.enable': '{lang}wcf.global.button.enable{/lang}', 'wcf.global.confirmation.cancel': '{lang}wcf.global.confirmation.cancel{/lang}', 'wcf.global.confirmation.confirm': '{lang}wcf.global.confirmation.confirm{/lang}', diff --git a/wcfsetup/install/files/js/WCF.js b/wcfsetup/install/files/js/WCF.js index 00779e0138..10e91bf646 100644 --- a/wcfsetup/install/files/js/WCF.js +++ b/wcfsetup/install/files/js/WCF.js @@ -1861,7 +1861,7 @@ WCF.MultipleLanguageInput.prototype = { _prepareElement: function(enableOnInit) { this._element.wrap('
'); var $wrapper = this._element.parent(); - var $button = $('

enable i18n

').prependTo($wrapper); + var $button = $('

' + WCF.Language.get('wcf.global.button.disabledI18n') + '

').prependTo($wrapper); $button.click($.proxy(this._enable, this)); WCF.CloseOverlayHandler.addCallback(this._element.wcfIdentify(), $.proxy(this._closeSelection, this)); @@ -1908,7 +1908,7 @@ WCF.MultipleLanguageInput.prototype = { // disable language input if (!this._forceSelection) { - $('
  • disable i18n
  • ').click($.proxy(this._disable, this)).appendTo(this._list); + $('
  • ' + WCF.Language.get('wcf.global.button.disabledI18n') + '
  • ').click($.proxy(this._disable, this)).appendTo(this._list); } } @@ -2004,7 +2004,7 @@ WCF.MultipleLanguageInput.prototype = { } // remove active marking - this._list.prev('.wcf-dropdownCaption').children('span').removeClass('active').text('enable i18n'); + this._list.prev('.wcf-dropdownCaption').children('span').removeClass('active').text(WCF.Language.get('wcf.global.button.disabledI18n')); this._closeSelection(); // update element value diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index 672c7f62ed..fe1bdd0a73 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -1,4 +1,4 @@ - + @@ -559,6 +559,7 @@ + diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index 83611a5b35..273585a419 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -526,6 +526,7 @@ + -- 2.20.1