Not able to get currently focused element
<p>I'm using a jquery autoresize plugin to resize my textarea</p>

<p>In the plugin i have something like this..</p>

<pre><code>(function($){   
    $.fn.autoResize = function(options, idToBeShown) {

    updateSize = function() {
      //shows the content underneath the textbox with a slidedown effect    
    },

    resetSize = function(event) {
      //Slide up and hide the contents underneath the textarea  
    },


  textarea
    .unbind('.dynSiz')
    .bind('keyup.dynSiz', updateSize)
    .bind('keydown.dynSiz', updateSize)
    .bind('focus',updateSize)   //slide's down when focused
    .bind('focusout',changeSize)    //Slide up and hide the contents underneath the textarea
    .bind('change.dynSiz', updateSize);



  });
</code></pre>

<p>My problem is when i click the area underneath the textarea the textarea should not slideUp but instead 
when i click anywhere in the body it should slide up..</p>

<p>So i did this..</p>

<pre><code>resetSize = function(event) {
//check the current focused element if it is the div area under text do do anything else slideup    
},
</code></pre>

<p>I'm not able to get the currently focused element</p>

<p>1) document.activeElement returns body</p>

<p>2) tried is(":focus");</p>

<p>3) is(":active")</p>

<p>Nothing works ... Note i have also added 'id' to the div element..</p>
