Plugins/VcsPlugins/vcsSubversion/SvnDialog.py

changeset 12
1d8dd9706f46
parent 0
de9c2efb9d02
child 13
1af94a91f439
equal deleted inserted replaced
11:b0996e4a289e 12:1d8dd9706f46
10 import os 10 import os
11 11
12 from PyQt4.QtCore import * 12 from PyQt4.QtCore import *
13 from PyQt4.QtGui import * 13 from PyQt4.QtGui import *
14 14
15 from Ui_SvnDialog import Ui_SvnDialog 15 from .Ui_SvnDialog import Ui_SvnDialog
16 16
17 import Preferences 17 import Preferences
18 18
19 class SvnDialog(QDialog, Ui_SvnDialog): 19 class SvnDialog(QDialog, Ui_SvnDialog):
20 """ 20 """
154 154
155 It reads the output of the process, formats it and inserts it into 155 It reads the output of the process, formats it and inserts it into
156 the contents pane. 156 the contents pane.
157 """ 157 """
158 if self.proc is not None: 158 if self.proc is not None:
159 s = unicode(self.proc.readAllStandardOutput()) 159 s = str(self.proc.readAllStandardOutput(),
160 Preferences.getSystem("IOEncoding"),
161 'replace')
160 self.resultbox.insertPlainText(s) 162 self.resultbox.insertPlainText(s)
161 self.resultbox.ensureCursorVisible() 163 self.resultbox.ensureCursorVisible()
162 if not self.__hasAddOrDelete and len(s) > 0: 164 if not self.__hasAddOrDelete and len(s) > 0:
163 # check the output 165 # check the output
164 for l in s.split(os.linesep): 166 for l in s.split(os.linesep):
173 It reads the error output of the process and inserts it into the 175 It reads the error output of the process and inserts it into the
174 error pane. 176 error pane.
175 """ 177 """
176 if self.proc is not None: 178 if self.proc is not None:
177 self.errorGroup.show() 179 self.errorGroup.show()
178 s = unicode(self.proc.readAllStandardError()) 180 s = str(self.proc.readAllStandardError(),
181 Preferences.getSystem("IOEncoding"),
182 'replace')
179 self.errors.insertPlainText(s) 183 self.errors.insertPlainText(s)
180 self.errors.ensureCursorVisible() 184 self.errors.ensureCursorVisible()
181 185
182 def on_passwordCheckBox_toggled(self, isOn): 186 def on_passwordCheckBox_toggled(self, isOn):
183 """ 187 """

eric ide

mercurial