Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[Processing] Inform listeners when all algorithms have been loaded.
  • Loading branch information
radosuav committed Oct 6, 2014
1 parent 81089a1 commit 6f94e9d
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion python/plugins/processing/core/Processing.py
Expand Up @@ -151,7 +151,10 @@ def initialize():
ProcessingConfig.readSettings()
RenderingStyles.loadStyles()
Processing.loadFromProviders()


# Inform registered listeners that all providers' algorithms have been loaded
Processing.fireAlgsListHasChanged()

@staticmethod
def updateAlgsList():
"""Call this method when there has been any change that
Expand Down Expand Up @@ -182,6 +185,13 @@ def addAlgListListener(listener):
called for all registered listeners.
"""
Processing.listeners.append(listener)

@staticmethod
def removeAlgListListener(listener):
try:
Processing.listeners.remove(listener)
except:
pass

@staticmethod
def fireAlgsListHasChanged():
Expand Down

0 comments on commit 6f94e9d

Please sign in to comment.