Hi,
I think I’ve found an interesting issue, when you set a SourceCodeEditor to disabled, it won’t “accept” setValue command, I mean the contents won’t be set to the control.
Steps to reproduce:
- Create SourceCodeEditor
- Disable it by using .setEnabled(false)
- Set the content of it by using .setValue(“somecontent”)
- the value won’t be set, if enable it, it will be empty as well
Expected behavior:
It should set the content value regardless of enabled/disabled state, so on “one screen” browse/edit screens users would see the contents, without the immediate ability of editing it
xml part:
<sourceCodeEditor id="scriptEditor"
handleTabKey="true"
mode="Groovy"
showGutter="true"
width="100%"/>
controller part:
....
@Inject
private SourceCodeEditor scriptEditor
....
scriptEditor.setEnabled(false)
scriptEditor.setValue(somescript)
....