PDA

View Full Version : [FIXED] HtmlEditor isValid bug - NullPointerException



andreym
24 Jul 2009, 2:24 AM
Hello!

When used setSourceEditMode(false) we get null pointer on form validation:

java.lang.NullPointerException: null
at com.extjs.gxt.ui.client.widget.form.HtmlEditor.getRawValue(HtmlEditor.java:633)
at com.extjs.gxt.ui.client.widget.form.Field.isValid(Field.java:516)

This is because sourceEdit button is not created but accessed:



if (sourceEditMode) {
toolbar.add(sourceEdit = createToggleButton(getImages().getSource(), getMessages().getSourceEditTipText(),
getMessages().getSourceEditTipTitle()));
toolbar.add(new SeparatorToolItem());
}

...

@Override
public String getRawValue() {
if (sourceEdit.isPressed()) {
-----

getValue() also doesn't work.

sven
24 Jul 2009, 3:09 AM
Fixed in SVN.