diff -r 734353e7d679 -r e92f0dd51979 Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesDefineGuardsDialog.py --- a/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesDefineGuardsDialog.py Sun Feb 23 15:24:28 2014 +0100 +++ b/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesDefineGuardsDialog.py Sun Feb 23 19:20:43 2014 +0100 @@ -17,7 +17,6 @@ from .Ui_HgQueuesDefineGuardsDialog import Ui_HgQueuesDefineGuardsDialog -import Preferences import UI.PixmapCache @@ -136,8 +135,7 @@ self.guardCombo.addItems(guardsList) self.guardCombo.setEditText("") - args = [] - args.append("qguard") + args = self.vcs.initCommand("qguard") if patch: args.append(patch) @@ -145,7 +143,6 @@ if self.__hgClient: output = self.__hgClient.runcommand(args)[0] else: - ioEncoding = Preferences.getSystem("IOEncoding") process = QProcess() process.setWorkingDirectory(self.__repodir) process.start('hg', args) @@ -153,8 +150,8 @@ if procStarted: finished = process.waitForFinished(30000) if finished and process.exitCode() == 0: - output = str(process.readAllStandardOutput(), ioEncoding, - 'replace').strip() + output = str(process.readAllStandardOutput(), + self.vcs.getEncoding(), 'replace').strip() if output: patchName, guards = output.split(":", 1) @@ -274,8 +271,7 @@ guard = itm.data(Qt.UserRole) + itm.text() guardsList.append(guard) - args = [] - args.append("qguard") + args = self.vcs.initCommand("qguard") args.append(self.patchNameLabel.text()) if guardsList: args.append("--") @@ -287,7 +283,6 @@ if self.__hgClient: error = self.__hgClient.runcommand(args)[1] else: - ioEncoding = Preferences.getSystem("IOEncoding") process = QProcess() process.setWorkingDirectory(self.__repodir) process.start('hg', args) @@ -296,9 +291,8 @@ finished = process.waitForFinished(30000) if finished: if process.exitCode() != 0: - error = str( - process.readAllStandardError(), ioEncoding, - 'replace') + error = str(process.readAllStandardError(), + self.vcs.getEncoding(), 'replace') else: E5MessageBox.warning( self,