how can I close instance of chrome extension by clicking browserAction button..? : **how can I close instance of chrome extension by clicking browserAction button..?**

I am working on chrome extension, in which I want to activate the extension by clicking on browserAction button and when I click it again I want to close the actual instance of that extension so that I can start it again fresh by clicking browserAction icon again.