Skip to content
Snippets Groups Projects
Commit d1eb256f authored by gnaegi's avatar gnaegi
Browse files

OO-3444 fix i18n key setter for FormCancel

parent e3c314c3
No related branches found
No related tags found
No related merge requests found
......@@ -153,7 +153,7 @@ public class FormCancel extends FormItemImpl implements Disposable, Cancel {
* @see org.olat.core.gui.components.form.flexible.elements.Cancel#setI18nKey(java.lang.String)
*/
public void setI18nKey(String i18n) {
cancelLink.setTitle(i18n);
cancelLink.setCustomDisplayText(translator.translate(i18n));
}
/**
......
......@@ -24,6 +24,7 @@ import org.olat.core.gui.components.form.flexible.FormItemContainer;
import org.olat.core.gui.components.form.flexible.elements.MultipleSelectionElement;
import org.olat.core.gui.components.form.flexible.impl.FormBasicController;
import org.olat.core.gui.components.form.flexible.impl.FormLayoutContainer;
import org.olat.core.gui.components.form.flexible.impl.elements.FormCancel;
import org.olat.core.gui.control.Controller;
import org.olat.core.gui.control.Event;
import org.olat.core.gui.control.WindowControl;
......@@ -118,7 +119,8 @@ public class DisclaimerFormController extends FormBasicController {
formLayout.add(buttonLayout);
buttonLayout.setElementCssClass("o_sel_disclaimer_buttons");
uifactory.addFormSubmitButton(DCL_ACCEPT, NLS_DISCLAIMER_OK, buttonLayout);
uifactory.addFormCancelButton(NLS_DISCLAIMER_NOK, buttonLayout, ureq, getWindowControl());
FormCancel cancelButton = uifactory.addFormCancelButton(NLS_DISCLAIMER_NOK, buttonLayout, ureq, getWindowControl());
cancelButton.setI18nKey(NLS_DISCLAIMER_NOK);
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment