title: function call on update of component in jsf
body: <p>I have a Treenode inside a form</p>
  
  <pre><code>&lt;h:form id="form"&gt;
   &lt;p:panel styleClass="gridTree" id="gridTree" style="overflow:auto"&gt;
    &lt;p:tree value="#{permissionsBean.root}" var="node" dynamic="true" cache="true" id="permissionTree" &gt;  
     &lt;p:treeNode&gt;
      &lt;h:outputText value="#{node}"/&gt;  
     &lt;/p:treeNode&gt;
    &lt;/p:tree&gt; 
   &lt;/p:panel&gt;
  </code></pre>
  
  <p>To fix the height of the tree and add a scroll bar for the height i am changing the height in a script</p>
  
  <pre><code>$(document).ready(function(){
          var windowHeight = $(window).height();
          $('.gridTree').css('height',windowHeight-220+'px');
          $(window).resize(function () {
              windowHeight = $(window).height();
              $('.gridTree').css('height',windowHeight-220+'px');
          });
      });
  </code></pre>
  
  <p>Now I am updating the form from the change event of a select one menu <code>update="@form"</code> .This will remove the height which was set in the <strong>document.ready</strong> function. So how can call a javascript function that will set the height of tree when the component is updated?</p>