I'm creating a small extension to some .net validation.

The outer box has a class of form-ctl, the input textbox has a class of input-ctl. As you can see the textbox is highlighted.
I've also created a function to remove validation based on a 'root' element.
In this case it would be form-ctl, called like this
resetValidation($(this).closest('.form-ctl'));Reset validation removes an error class for all input[type=text] within the root as well as resetting the dot.net validators.
I already gave a function that kicks in when closing a modal popup, using a button, but I'm trying to be a little sophisticated with the above which is not modal.
When clicking outside the box (.form-ctl), I would like to call reset validation. I would need to check if form control had focus - can this be done with a div?
Any ideas as to how this could be achieved?