<%
  import org.exoplatform.web.application.JavascriptManager;

  def rcontext = _ctx.getRequestContext();
  JavascriptManager jsmanager = rcontext.getJavascriptManager();
  jsmanager.importJavascript('eXo.ks.KSUtils', '/ksResources/javascript/');
  jsmanager.importJavascript('eXo.ks.MaskLayerControl', '/ksResources/javascript/');
  jsmanager.addOnResizeJavascript('function(){eXo.ks.KSUtils.setMaskLayer("'+uicomponent.id+'");}');

  jsmanager.importJavascript('eXo.faq.UIAnswersPortlet','/faq/javascript/');
  jsmanager.addCustomizedOnLoadScript('eXo.faq.UIAnswersPortlet.loadActionScroll();');
  jsmanager.addOnResizeJavascript('eXo.faq.UIAnswersPortlet.reSizeImages');
%>
<div class="UIAnswersPortlet" id="$uicomponent.id">
  <div class="ParentMaskLayer">
    <div id="KSMaskLayer" class="KSMaskLayer"><span></span></div>
  </div>
  <%
    List children = uicomponent.getChildren() ;
    for(component in children) {
      if(component.isRendered()){
        uicomponent.renderChild(component.getClass()) ; 
      }
    }
  %>
</div>
<%
  jsmanager.addJavascript("setTimeout('eXo.faq.UIAnswersPortlet.init(\""+uicomponent.id+"\")', 500);");
%>