Hi,
Is threaded behaviour for Firefox extension possible?
I mean to have a "thread" running per Firefox tab.
Just finished an extension that does something to a page in a Firefox window, but figured out that it would require some major restructuring to get the extension working if I wanted to run the extension logic in every tab.
Methinks I would have to schedule processing of every tab content in a round robin fashion besides keeping a track of the context of each tab so that once I pause processing a tab and go to another one, the context of the previous tab is saved when I once again come back to it.
Yes - I would have to turn my extension into a process scheduler!
I would rather offload that job to Firefox or the OS.
While I can spawn a new window for every page I process so that the extension has to work only on a single page, I would rather use tabs.
Altough I have started coding a GM script so that I get the "threading" for free, I was wondering if any one had a better idea?
Something like spawning a thread from the extension for every tab created so that each thread is localized and dedicated to each tab?