}
protected Binding getViewBinding(JScrollPane scrollPane, FormModel formModel, String formPropertyPath, Map context) {
JComponent view = (JComponent)scrollPane.getViewport().getView();
if (view == null) {
Binding viewBinding = viewBinderSelectionStrategy.selectBinder(defaultViewType, formModel, formPropertyPath)
.bind(formModel, formPropertyPath, context);
scrollPane.setViewportView(viewBinding.getControl());
return viewBinding;
}
Binding existingBinding = (Binding)view.getClientProperty(BINDING_CLIENT_PROPERTY_KEY);
if (existingBinding != null) {
return existingBinding;
}
return viewBinderSelectionStrategy.selectBinder(view.getClass(), formModel, formPropertyPath).bind(
view, formModel, formPropertyPath, context);