Plugins/VcsPlugins/vcsSubversion/SvnDiffDialog.py

branch
Py2 comp.
changeset 3484
645c12de6b0c
parent 3178
f25fc1364c88
parent 3190
a9a94491c4fd
child 3591
2f2a4a76dd22
--- a/Plugins/VcsPlugins/vcsSubversion/SvnDiffDialog.py	Sun Mar 30 22:00:14 2014 +0200
+++ b/Plugins/VcsPlugins/vcsSubversion/SvnDiffDialog.py	Thu Apr 03 23:05:31 2014 +0200
@@ -10,8 +10,8 @@
 
 from __future__ import unicode_literals
 try:
-    str = unicode    # __IGNORE_WARNING__
-except (NameError):
+    str = unicode
+except NameError:
     pass
 
 import os
@@ -182,8 +182,8 @@
             self.inputGroup.hide()
             E5MessageBox.critical(
                 self,
-                self.trUtf8('Process Generation Error'),
-                self.trUtf8(
+                self.tr('Process Generation Error'),
+                self.tr(
                     'The process {0} could not be started. '
                     'Ensure, that it is in the search path.'
                 ).format('svn'))
@@ -200,7 +200,7 @@
         
         if self.paras == 0:
             self.contents.insertPlainText(
-                self.trUtf8('There is no difference.'))
+                self.tr('There is no difference.'))
             return
             
         self.buttonBox.button(QDialogButtonBox.Save).setEnabled(True)
@@ -213,8 +213,8 @@
         self.contents.setTextCursor(tc)
         self.contents.ensureCursorVisible()
         
-        self.filesCombo.addItem(self.trUtf8("<Start>"), 0)
-        self.filesCombo.addItem(self.trUtf8("<End>"), -1)
+        self.filesCombo.addItem(self.tr("<Start>"), 0)
+        self.filesCombo.addItem(self.tr("<End>"), -1)
         for oldFile, newFile, pos in sorted(self.__fileSeparators):
             if oldFile != newFile:
                 self.filesCombo.addItem(
@@ -372,9 +372,9 @@
         
         fname, selectedFilter = E5FileDialog.getSaveFileNameAndFilter(
             self,
-            self.trUtf8("Save Diff"),
+            self.tr("Save Diff"),
             fname,
-            self.trUtf8("Patch Files (*.diff)"),
+            self.tr("Patch Files (*.diff)"),
             None,
             E5FileDialog.Options(E5FileDialog.DontConfirmOverwrite))
         
@@ -389,9 +389,9 @@
         if QFileInfo(fname).exists():
             res = E5MessageBox.yesNo(
                 self,
-                self.trUtf8("Save Diff"),
-                self.trUtf8("<p>The patch file <b>{0}</b> already exists."
-                            " Overwrite it?</p>").format(fname),
+                self.tr("Save Diff"),
+                self.tr("<p>The patch file <b>{0}</b> already exists."
+                        " Overwrite it?</p>").format(fname),
                 icon=E5MessageBox.Warning)
             if not res:
                 return
@@ -404,8 +404,8 @@
             f.close()
         except IOError as why:
             E5MessageBox.critical(
-                self, self.trUtf8('Save Diff'),
-                self.trUtf8(
+                self, self.tr('Save Diff'),
+                self.tr(
                     '<p>The patch file <b>{0}</b> could not be saved.'
                     '<br>Reason: {1}</p>')
                 .format(fname, str(why)))

eric ide

mercurial