if (!isWidgetSupported(protocol)) {
return;
}
ItemsAttributes itemsAttributes = (ItemsAttributes) attributes;
// require AJAX script module
if ( itemsAttributes.getLoadAttributes() != null) {
require(WidgetScriptModules.BASE_AJAX, protocol, attributes);
}
boolean insideWidgetResponse = (itemsAttributes.getCount() != null);
if (!insideWidgetResponse) {
renderCloseForWidget(protocol, itemsAttributes);
} else {
renderCloseForResponse(protocol, itemsAttributes);