Quit plugins on exit
Plugins should have a chance to clean up after themselves when we are shutting down.
This commit is contained in:
parent
a31f4b609f
commit
9167e6441c
|
@ -65,4 +65,6 @@ def startup():
|
|||
|
||||
def shutdown():
|
||||
event.start("PREQUIT")
|
||||
import plugin
|
||||
plugin.quit()
|
||||
event.start("POSTQUIT")
|
||||
|
|
|
@ -22,6 +22,14 @@ def init():
|
|||
if p_dir == None:
|
||||
p_dir = path.plugin_dir()
|
||||
|
||||
def quit():
|
||||
global loaded
|
||||
for mod in loaded:
|
||||
try:
|
||||
loaded[mod].stop()
|
||||
except:
|
||||
pass
|
||||
|
||||
|
||||
def install_once(filepath):
|
||||
global install
|
||||
|
|
Loading…
Reference in New Issue