Skip to content

Commit

Permalink
[Processing] Translate alg names in menu and options dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
arnaud-morvan committed Jun 23, 2016
1 parent 36e7f92 commit 9edab1e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/gui/ConfigDialog.py
Expand Up @@ -207,7 +207,7 @@ def fillTreeUsingProviders(self):
groupItem.setEditable(False)

for alg in provider.algs:
algItem = QStandardItem(alg.name)
algItem = QStandardItem(alg.i18n_name or alg.name)
algItem.setIcon(icon)
algItem.setEditable(False)
try:
Expand Down
4 changes: 2 additions & 2 deletions python/plugins/processing/gui/menus.py
Expand Up @@ -155,7 +155,7 @@ def removeMenus():


def addAlgorithmEntry(alg, menuName, submenuName, actionText=None, icon=None, addButton=False):
action = QAction(icon or alg.getIcon(), actionText or alg.name, iface.mainWindow())
action = QAction(icon or alg.getIcon(), actionText or alg.i18n_name or alg.name, iface.mainWindow())
action.triggered.connect(lambda: _executeAlgorithm(alg))
action.setObjectName("mProcessingUserMenu_%s" % alg.commandLineName())

Expand Down Expand Up @@ -232,6 +232,6 @@ def getMenu(name, parent):

def findAction(actions, alg, actionText=None):
for action in actions:
if action.text() in [actionText, alg.name]:
if action.text() in [actionText, alg.i18n_name, alg.name]:
return action
return None

0 comments on commit 9edab1e

Please sign in to comment.