The plugin system dates to when Seashore tools were in windows. There is a plugin instance of each plugin to determine if the plugin can operate on the current document (validateMenuItem), and if the user activates the plugin, then another instance is created to execute the plugin - this avoids creating each plugin for every open document.
The problem is the SeaPlugins instance passed to each plugin multiplexes to the 'current document' so in some cases when the plugin is activate in one window, then user switches to another document and does a related 'color well' operation, the current document is affected - not the one that has the plugin activated.
The plugin system dates to when Seashore tools were in windows. There is a plugin instance of each plugin to determine if the plugin can operate on the current document (validateMenuItem), and if the user activates the plugin, then another instance is created to execute the plugin - this avoids creating each plugin for every open document.
The problem is the SeaPlugins instance passed to each plugin multiplexes to the 'current document' so in some cases when the plugin is activate in one window, then user switches to another document and does a related 'color well' operation, the current document is affected - not the one that has the plugin activated.