I am trying to create a little chrome extension with a toggleable icon ("active" and "inactive") and a pupup-page. The icon should be active, when the popup is shown and inactive, when the popup is hidden.
I am allready able to toggle the Icon on click using the background-script, just like in this answer.
But unfortunately this doesn't work, if you have a default_popup
-page, as the browser_action
catches the clickEvent
and the background-script does not get notified.
So my question is, how can i toggle the icon while using a default_popup
-page?
EDIT:
The problem i have is, that the chrome.browserAction.onClicked
method is not called, when you have a default_popup
(it is also said in the comments to this answer). So i need something else to get notified, if the extension was clicked or not...