@Override
protected void encodeCustomContent(FacesContext context, PopupLayer popupLayer) throws IOException {
final EventEditorDialog dialog = (EventEditorDialog) popupLayer;
final TimetableView timetableView = (TimetableView) dialog.getParent();
TimetableEditingOptions editingOptions = timetableView.getEditingOptions();
final boolean useResourceSeparationMode = (Boolean) timetableView.getAttributes().
get(TimeScaleTableRenderer.USE_RESOURCE_SEPARATION_MODE_ATTR) && (editingOptions != null && editingOptions.isEventResourceEditable());
final boolean eventDurationEditable = (editingOptions != null && editingOptions.isEventDurationEditable());
final UIComponent[][] components = new UIComponent[][]{
{
createLabelComponent(context, dialog, "nameLabel", dialog.getNameLabel()),
getNameField(context, dialog)
},