Editor with Layout View

Hello,

I have a problem with the dhtmlx Editor :

My configuration is the following :

  • i have a layout with one cell
  • the cell have two views : default view (def) and an other
  • the def view contains a form and this form contains a dhtmlx editor

The problem is when the other view is setActive and then, when I go back to the def view, the editor losts the text already writed, and the big problem : it is impossible to enter and write text in the editor.

Incompatibility with view layout, form and editor ?

Thank you in advance

Hello
Here is a function to switch to the default view:

[code]function f_v(t){

        if (t == curView) return;
        if (t != "def") {
            // leave view with form, save form's data
            form.forEachItem(function(id){
                if (form.getItemType(id) == "editor") formData[id] = form.getItemValue(id);
            });
        }
        dhxLayout.cells("a").view(t).setActive();
        curView = t;
        if (t == "def") {
            // switch to view with form, restore form's data
            for (var a in formData) {
                form.getEditor(a)._prepareContent(true);
                form.getEditor(a).setContent(formData[a]);
                formData[a] = null;
                delete formData[a];
            }
        }[/code]