From: Alexander Ebert Date: Thu, 16 Jun 2016 09:47:00 +0000 (+0200) Subject: Using consistent button labels X-Git-Tag: 3.0.0_Beta_1~1425^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=dd67c2d1f763f8ca9d966c69e27f3a6b6ee2b668;p=GitHub%2FWoltLab%2FWCF.git Using consistent button labels --- diff --git a/wcfsetup/install/files/lib/acp/form/BBCodeAddForm.class.php b/wcfsetup/install/files/lib/acp/form/BBCodeAddForm.class.php index a31c2d9322..64e480ce8b 100644 --- a/wcfsetup/install/files/lib/acp/form/BBCodeAddForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/BBCodeAddForm.class.php @@ -243,12 +243,12 @@ class BBCodeAddForm extends AbstractForm { if ($this->showButton && !I18nHandler::getInstance()->isPlainValue('buttonLabel')) { $bbcodeID = $returnValues['returnValues']->bbcodeID; - I18nHandler::getInstance()->save('buttonLabel', 'wcf.bbcode.buttonLabel'.$bbcodeID, 'wcf.bbcode', 1); + I18nHandler::getInstance()->save('buttonLabel', 'wcf.editor.button.button'.$bbcodeID, 'wcf.editor', 1); // update button label $bbcodeEditor = new BBCodeEditor($returnValues['returnValues']); $bbcodeEditor->update([ - 'buttonLabel' => 'wcf.bbcode.buttonLabel'.$bbcodeID + 'buttonLabel' => 'wcf.editor.button.button'.$bbcodeID ]); } diff --git a/wcfsetup/install/files/lib/acp/form/BBCodeEditForm.class.php b/wcfsetup/install/files/lib/acp/form/BBCodeEditForm.class.php index cf30c749b2..df848a24b6 100644 --- a/wcfsetup/install/files/lib/acp/form/BBCodeEditForm.class.php +++ b/wcfsetup/install/files/lib/acp/form/BBCodeEditForm.class.php @@ -79,13 +79,13 @@ class BBCodeEditForm extends BBCodeAddForm { AbstractForm::save(); if ($this->showButton) { - $this->buttonLabel = 'wcf.bbcode.buttonLabel'.$this->bbcode->bbcodeID; + $this->buttonLabel = 'wcf.editor.button.button'.$this->bbcode->bbcodeID; if (I18nHandler::getInstance()->isPlainValue('buttonLabel')) { I18nHandler::getInstance()->remove($this->buttonLabel); $this->buttonLabel = I18nHandler::getInstance()->getValue('buttonLabel'); } else { - I18nHandler::getInstance()->save('buttonLabel', $this->buttonLabel, 'wcf.bbcode', 1); + I18nHandler::getInstance()->save('buttonLabel', $this->buttonLabel, 'wcf.editor', 1); } } @@ -136,7 +136,7 @@ class BBCodeEditForm extends BBCodeAddForm { parent::readData(); if (empty($_POST)) { - I18nHandler::getInstance()->setOptions('buttonLabel', 1, $this->bbcode->buttonLabel, 'wcf.bbcode.buttonLabel\d+'); + I18nHandler::getInstance()->setOptions('buttonLabel', 1, $this->bbcode->buttonLabel, 'wcf.editor.button.button\d+'); $this->buttonLabel = $this->bbcode->buttonLabel; $this->attributes = BBCodeAttribute::getAttributesByBBCode($this->bbcode);