I offer the following improvements.
1) Clear arhives cache after calling ConfigurePacker(). Also don't forget to reread contents of any archive opened in panel when ConfigurePacker() called.
2) For many plugins archive cache is useless. Implement PK_CAPS_DONTCACHE flag.
3) Call GetPackerCaps() after calling ConfigurePacker(). Because plugin caps could be changed.
4) Call GetPackerCaps() each time plugin is loaded. Because plugin caps could be changed.
Improve interaction with plugins
Moderators: Hacker, petermad, Stefan2, white
1)+2)
I'm not a plugin developer, so I don't know this for sure: Is caching done by the plugin, or by TC? Because if it's done by TC, then it's not a plugin feature (not a PK_CAPS). But if such (plugin or TC) feature is possible, then I'm not against it.
3)+4)
The way I read the "WCX Writer's Reference", the plugin features which are determined via GetPackerCaps() are something that should only change after a installing a new version of the plugin. Anything else is handled by the plugin itself, via options stored by the plugin after ConfigurePacker() is called.
The existing PK_CAPS are not something that can change at runtime. Take for instance PK_CAPS_ENCRYPT: "Now I can encrypt your archives, now I can't - I forgot how to"? Doesn't make any sense.
I'm not a plugin developer, so I don't know this for sure: Is caching done by the plugin, or by TC? Because if it's done by TC, then it's not a plugin feature (not a PK_CAPS). But if such (plugin or TC) feature is possible, then I'm not against it.
3)+4)
The way I read the "WCX Writer's Reference", the plugin features which are determined via GetPackerCaps() are something that should only change after a installing a new version of the plugin. Anything else is handled by the plugin itself, via options stored by the plugin after ConfigurePacker() is called.
The existing PK_CAPS are not something that can change at runtime. Take for instance PK_CAPS_ENCRYPT: "Now I can encrypt your archives, now I can't - I forgot how to"? Doesn't make any sense.
aNDreas Bolotă
The truth always carries the ambiguity of the words used to express it. (Frank Herbert, God Emperor of Dune)
The truth always carries the ambiguity of the words used to express it. (Frank Herbert, God Emperor of Dune)
By TC.ND wrote:I'm not a plugin developer, so I don't know this for sure: Is caching done by the plugin, or by TC?
But after plugin reconfiguring some caps may change (e.g. PK_CAPS_HIDE). Also, if you use Multiarc you know that its caps are different for each packer tool (some archives may be modified, some allow to delete file(s) etc), and Multiarc allow to set caps from configuration dialog.ND wrote:The existing PK_CAPS are not something that can change at runtime. Take for instance PK_CAPS_ENCRYPT: "Now I can encrypt your archives, now I can't - I forgot how to"? Doesn't make any sense.