You may implement hideView at the view levels for cleaning up each view. For global exit, you may use onAppFin, but that will be called only when the widget is completely removed from the memory, which is either when it is deleted from dock or it throws an out of memory error.
Thanks,
Vivek
QUOTE(SajuP @ 18 Nov 2011 9:21 PM)
Is there a global event which we can listen to know the widget has been closed (irrespective of which view was open) , this is to handle some cleanup stuff, for example stopping a timer when the widget is closed. The definition of closing a widget would include the user closing the widget but still has the dock up on the TV screen, or they just closed the whole yahoo widget dock while a view of my widget was open.