mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
[processing] fixes for issues with 3rd party providers being loaded and unloaded
This commit is contained in:
parent
b0a9a84cee
commit
61e26fd8f3
@ -112,9 +112,12 @@ class Processing:
|
||||
"""
|
||||
try:
|
||||
provider.unload()
|
||||
Processing.providers.remove(provider)
|
||||
algList.remove(provider.getName())
|
||||
del Processing.actions[provider.getName()]
|
||||
for p in Processing.providers:
|
||||
if p.getName() == provider.getName():
|
||||
Processing.providers.remove(p)
|
||||
algList.removeProvider(provider.getName())
|
||||
if provider.getName() in Processing.actions:
|
||||
del Processing.actions[provider.getName()]
|
||||
for act in provider.contextMenuActions:
|
||||
Processing.contextMenuActions.remove(act)
|
||||
except:
|
||||
@ -131,7 +134,7 @@ class Processing:
|
||||
|
||||
@staticmethod
|
||||
def initialize():
|
||||
if Processing.providers:
|
||||
if "model" in [p.getName() for p in Processing.providers]:
|
||||
return
|
||||
# Add the basic providers
|
||||
for c in AlgorithmProvider.__subclasses__():
|
||||
|
@ -45,7 +45,8 @@ class AlgorithmList(QObject):
|
||||
if p.getName() == providerName:
|
||||
self.providers.remove(p)
|
||||
break
|
||||
self.algs.remove(providerName)
|
||||
if providerName in self.algs:
|
||||
del self.algs[providerName]
|
||||
self.providerRemoved.emit(providerName)
|
||||
|
||||
def reloadProvider(self, providerName):
|
||||
|
Loading…
x
Reference in New Issue
Block a user