Skip to content
Browse files
Merge pull request #2808 from m-kuhn/proclogtitle
[processing] always translate debug messages tab title (fix #14287)
  • Loading branch information
alexbruy committed Feb 18, 2016
2 parents d8a5e0f + bcd3d92 commit f36214c56759d5716ab92e0d0cb24ce7256a5bae
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
@@ -83,7 +83,7 @@ def addToLog(msgtype, msg):
msgtypes = {ProcessingLog.LOG_ERROR: QgsMessageLog.CRITICAL,
ProcessingLog.LOG_INFO: QgsMessageLog.INFO,
ProcessingLog.LOG_WARNING: QgsMessageLog.WARNING, }
QgsMessageLog.logMessage(msg, "Processing", msgtypes[msgtype])
QgsMessageLog.logMessage(msg,"Processing"), msgtypes[msgtype])

@@ -137,6 +137,12 @@ def saveLog(fileName):
for entry in v:
f.write('%s|%s|%s\n' % (k,, entry.text))

def tr(string, context=''):
if context == '':
context = 'ProcessingLog'
return QCoreApplication.translate(context, string)

class LogEntry:

@@ -152,7 +152,7 @@ def popupError(self, error=None, url=None):
widget = iface.messageBar().createMessage('Connection problem', disambiguation),'Could not connect to scripts/models repository', disambiguation))
if error and url:
QgsMessageLog.logMessage("Network error code: {} on URL: {}").format(error, url), u"Processing", QgsMessageLog.CRITICAL)
QgsMessageLog.logMessage("Network error code: {} on URL: {}").format(error, url),"Processing"), QgsMessageLog.CRITICAL)
button = QPushButton(QCoreApplication.translate("Python", "View message log"), pressed=show_message_log)

0 comments on commit f36214c

Please sign in to comment.