Skip to content

Commit

Permalink
[in-place] Fix locator filter for in-place when active layer changes
Browse files Browse the repository at this point in the history
Invalidate the locator results when active layer changes

Fix #20099 - Locator bar does not update the filter of algorithms according to active layer when using "ef"
  • Loading branch information
elpaso committed Oct 23, 2018
1 parent daf5394 commit 7ecd303
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions python/plugins/processing/ProcessingPlugin.py
Expand Up @@ -171,6 +171,8 @@ def __init__(self, iface):
QgsApplication.dataItemProviderRegistry().addProvider(self.item_provider)
self.locator_filter = AlgorithmLocatorFilter()
iface.registerLocatorFilter(self.locator_filter)
# Invalidate the locator filter for in-place when active layer changes
iface.currentLayerChanged.connect(lambda _: self.iface.invalidateLocatorResults())
self.edit_features_locator_filter = InPlaceAlgorithmLocatorFilter()
iface.registerLocatorFilter(self.edit_features_locator_filter)
Processing.initialize()
Expand Down

0 comments on commit 7ecd303

Please sign in to comment.