(v7) deprecated Form writeThrough only?

We still have Form objects in our v6 app that I’ve converted to v7. I know Form is deprecated, but haven’t gotten to replacing it yet. What I see now is that TextFields in a Form write through to the backing BeanItem by default, even if I set setBuffered(true) on text fields in my form factory.

So if someone edits a field that describes their user info (for example), then clicks away to some other part of the UI without clicking save, that new info is stored in the object describing the user and so shows up in other parts of the UI. Similarly, discard() isn’t working since the info has already been written through to the BeanItem.

While I’m working to replace our forms, is there any easy change I can make to have the existing ones still work in the meantime?


p.s. Along those lines, the TextField JavaDocs say “Since TextField extends AbstractField it implements the Buffered interface. A TextField is in write-through mode by default, so com.vaadin.ui.AbstractField#setWriteThrough(boolean) must be called to enable buffering.” But there is no setWriteThrough in AbstractField.

In case anyone else is looking for a lazy shortcut like me (heh), I couldn’t find any combination of setting buffered and immediate that made the old Form work again. Am switching things over now to properly use FormLayout and FieldGroup.

I see that
has already been filed for the setWriteThrough javadoc issue.