Cache params

This commit is contained in:
Suzanne Soy 2021-10-06 04:22:46 +01:00
parent 350fe5293b
commit 80b79e886a
2 changed files with 4 additions and 3 deletions

View File

@ -13,9 +13,9 @@ SearchResults.registerResultProvider('document',
SearchResults.registerResultProvider('toolbar',
getItemGroupsCached = lambda: __import__('ResultsToolbar').toolbarResultsProvider(),
getItemGroupsUncached = lambda: [])
SearchResults.registerResultProvider('toolbar',
getItemGroupsCached = lambda: [],
getItemGroupsUncached = lambda: __import__('ResultsPreferences').paramResultsProvider())
SearchResults.registerResultProvider('param',
getItemGroupsCached = lambda: __import__('ResultsPreferences').paramResultsProvider(),
getItemGroupsUncached = lambda: [])
SearchResults.registerResultHandler('refreshTools',
action = lambda nfo: __import__('ResultsRefreshTools').refreshToolsAction(nfo),

View File

@ -8,6 +8,7 @@ genericToolIcon = QtGui.QIcon(QtGui.QIcon(os.path.dirname(__file__) + '/Tango-To
def getParam(grpPath, type_, name):
return {
# TODO: use letter icon based on the type, as the preferences editor does
'icon': genericToolIcon,
'text': name,
'toolTip': '',