Known issue: the add-on keeps one global state to remember if the tab has already been colored or not. Of course, in the case when several tabs are to be highlighted, this is a problem. This is not so big an issue, since in this case:
If the tab should be colored but the state is not correct, the first click to the add-on button is without effect. Second click works as expected and opens the language selection popup.
If the tab should be reset (to no-color) but the state is not correct, the language selection pops up (instead of not showing), and a click will un-highlight tab contents, whatever language was selected. Next click will have status in order, and will act as expected.
Steps to reproduce, first case:
Open two tabs with raw text (without automatic highlighting).
Trigger highlighting on first tab.
Switch to second tab.
Try to trigger highlighting: first click on button should be without effect.
Second case is the same, but first highlight two tabs, then reset the first one, and try to reset the second one: clicking the button should open the language selection popup instead of immediately removing colors.
Users relying only on the automatic highlighting feature (and never clicking the button) should not be affected.
Possible workaround: maybe the background script could probe the tab to see if content script has been injected already. But I haven't been successful with this so far, background script seems to hang if it fails to connect to a content script. The issue will probably stay there for a while, until I find something better.
Known issue: the add-on keeps one global state to remember if the tab has already been colored or not. Of course, in the case when several tabs are to be highlighted, this is a problem. This is not so big an issue, since in this case:
If the tab should be colored but the state is not correct, the first click to the add-on button is without effect. Second click works as expected and opens the language selection popup.
If the tab should be reset (to no-color) but the state is not correct, the language selection pops up (instead of not showing), and a click will un-highlight tab contents, whatever language was selected. Next click will have status in order, and will act as expected.
Steps to reproduce, first case:
Second case is the same, but first highlight two tabs, then reset the first one, and try to reset the second one: clicking the button should open the language selection popup instead of immediately removing colors.
Users relying only on the automatic highlighting feature (and never clicking the button) should not be affected.
Possible workaround: maybe the background script could probe the tab to see if content script has been injected already. But I haven't been successful with this so far, background script seems to hang if it fails to connect to a content script. The issue will probably stay there for a while, until I find something better.