currentBuffer.closeElement("select");
// Get widget attributes.
SelectAttributes selectAttributes = (SelectAttributes) attributes;
PropertyReference propertyReference = selectAttributes.getPropertyReference();
// Finally, render the JavaScript part.
StringBuffer scriptBuffer = new StringBuffer();
if (attributes.getId() != null) {
scriptBuffer.append("Widget.register(")
.append(createJavaScriptString(attributes.getId()))
.append(",");
addCreatedWidgetId(attributes.getId());
}
scriptBuffer.append("new Widget.Select(")
.append(createJavaScriptString(selectElement.getAttributeValue("id")))
.append(",{");
if (propertyReference != null) {
scriptBuffer.append("property:")
.append(createJavaScriptExpression(propertyReference));
addUsedWidgetId(propertyReference.getWidgetId());
}
scriptBuffer.append("})");
if (attributes.getId() != null) {