2009-01-26, 15:09
I've a new video plugin which gather files into a cache, which are parsed and then directory lists are populated, this ultimatly leads to a video to be played. which is fine. But, I'd like my 'cache' to be cleared when Plugin is finally closed.
This is easy to do from a script, as it starts once then exits, whereas a Plugin is launched and closed for each directory you move into. SO its difficult to know if the Plugin has finished of just being re-called.
Is there a way of detecting the Plugin has been closed (ie. you back out to the Video Plugins screen) so a single final clear of the cache can be done ?
On the point of the plugin 'launch and close' for each directory call - Is there away of retaining information in variables from one call to the next ?
I wish to maintain a urlopener, that has been previously initialised with a HTTP Basic Auth. and Cookie handlers, rather than having to re-init the urlopener each time Plugin is loaded because of the next directory call.
Hope that made some sense to someone?
cheers
BBB
This is easy to do from a script, as it starts once then exits, whereas a Plugin is launched and closed for each directory you move into. SO its difficult to know if the Plugin has finished of just being re-called.
Is there a way of detecting the Plugin has been closed (ie. you back out to the Video Plugins screen) so a single final clear of the cache can be done ?
On the point of the plugin 'launch and close' for each directory call - Is there away of retaining information in variables from one call to the next ?
I wish to maintain a urlopener, that has been previously initialised with a HTTP Basic Auth. and Cookie handlers, rather than having to re-init the urlopener each time Plugin is loaded because of the next directory call.
Hope that made some sense to someone?
cheers
BBB