Developer forums (C::B DEVELOPMENT STRICTLY!) > Plugins development
Compile on demand plugin
Jenna:
--- Quote from: MortenMacFly on March 03, 2012, 01:34:14 pm ---
--- Quote from: ptDev on March 03, 2012, 12:52:56 pm ---how do I delay attaching the menus, if building the plugins menu is called from CodeBlocks through the cbPlugin interface?
--- End quote ---
I.e. storing the menu pointers and adjusting the menu after the startup complete event.
--- End quote ---
Another idea would be to add the possibility to make one plugin depend on another to be loaded.
That would (of course) require changes to the pluginmanager.
MortenMacFly:
--- Quote from: jens on March 03, 2012, 02:22:33 pm ---That would (of course) require changes to the pluginmanager.
--- End quote ---
My idea (a while back) was to have a plugin weight, which can be read from the plugin's manifest file. This way, a user can modify the load order if needed, it should be easy to implement and we can re-use code of the file weight for compilation units.
(I did it similar in another project of mine...)
oBFusCATed:
--- Quote from: jens on March 03, 2012, 02:22:33 pm ---Another idea would be to add the possibility to make one plugin depend on another to be loaded.
That would (of course) require changes to the pluginmanager.
--- End quote ---
+1 here.
Plugin-load-weight sounds like a hack/workaround/hard to maintain feature...
MortenMacFly:
--- Quote from: oBFusCATed on March 03, 2012, 06:51:33 pm ---Another idea would be to add the possibility to make one plugin depend on another to be loaded.
--- End quote ---
So what would be the base for the comparison then? The plugin's name, a GUID?
ptDev:
--- Quote from: MortenMacFly on March 03, 2012, 09:09:11 pm ---
--- Quote from: oBFusCATed on March 03, 2012, 06:51:33 pm ---Another idea would be to add the possibility to make one plugin depend on another to be loaded.
--- End quote ---
So what would be the base for the comparison then? The plugin's name, a GUID?
--- End quote ---
Would using the plugin's name for this be a bad idea?
One could allow a vector of strings of "dependencies" to be passed to a plugin, and plugin manager would make a check for each plugin being loaded, if all of its dependencies have already been loaded (by finding by name).
EDIT: Actually, scratch that. It's probably better to just list dependencies in the plugin manifest file.
Since most plugins do not need this, the required overhead at startup would actually still be acceptable.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version