diff --git a/XSConsoleCurses.py b/XSConsoleCurses.py index e77ed1a..75705f9 100644 --- a/XSConsoleCurses.py +++ b/XSConsoleCurses.py @@ -279,10 +279,10 @@ def Snapshot(self): retVal.append(self.title) if self.hasBox: for i in range(1, self.ySize-1): - retVal.append(self.win.instr(i, 1, self.xSize-2)) + retVal.append(Lang(self.win.instr(i, 1, self.xSize-2))) else: for i in range(self.ySize): - retVal.append(self.win.instr(i, 0, self.xSize)) + retVal.append(Lang(self.win.instr(i, 0, self.xSize))) return retVal diff --git a/XSConsoleRemoteTest.py b/XSConsoleRemoteTest.py index 2f39506..a9288da 100644 --- a/XSConsoleRemoteTest.py +++ b/XSConsoleRemoteTest.py @@ -25,7 +25,7 @@ import xmlrpc.server class UnixSimpleXMLRPCRequestHandler(xmlrpc.server.SimpleXMLRPCRequestHandler): - # Python 2.7's SimpleXMLRPCRequestHandler enables Nagle's algorithm by default + # Python's SimpleXMLRPCRequestHandler enables Nagle's algorithm by default # which fails because we're working with Unix domain sockets so disable it. disable_nagle_algorithm = False diff --git a/plugins-base/XSFeatureSRCommon.py b/plugins-base/XSFeatureSRCommon.py index 83390de..5ec4e24 100644 --- a/plugins-base/XSFeatureSRCommon.py +++ b/plugins-base/XSFeatureSRCommon.py @@ -211,7 +211,7 @@ def UpdateFieldsINITIAL(self): pane.ResetFields() sr = HotAccessor().sr[self.srHandle] - srName = sr.name_label(None).encode('utf-8') + srName = Lang(sr.name_label(None)) if srName is None: pane.AddTitleField(Lang("The Virtual Machine is no longer present")) else: @@ -226,7 +226,7 @@ def UpdateFieldsCONFIRM(self): pane.ResetFields() sr = HotAccessor().sr[self.srHandle] - srName = sr.name_label(None).encode('utf-8') + srName = Lang(sr.name_label(None)) if srName is None: pane.AddTitleField(Lang("The Storage Repository is no longer present")) else: @@ -282,7 +282,7 @@ def Commit(self): Layout.Inst().PopDialogue() operationName = SRUtils.OperationName(self.operation) - srName = HotAccessor().sr[self.srHandle].name_label(Lang('')).encode('utf-8') + srName = Lang(HotAccessor().sr[self.srHandle].name_label(Lang(''))) messagePrefix = operationName + Lang(' operation on ') + srName + ' ' Layout.Inst().TransientBanner(messagePrefix+Lang('in progress...')) try: diff --git a/plugins-base/XSFeatureVMCommon.py b/plugins-base/XSFeatureVMCommon.py index 108938c..23d75f2 100644 --- a/plugins-base/XSFeatureVMCommon.py +++ b/plugins-base/XSFeatureVMCommon.py @@ -162,7 +162,7 @@ def UpdateFieldsINITIAL(self): pane.ResetFields() vm = HotAccessor().guest_vm[self.vmHandle] - vmName = vm.name_label(None).encode('utf-8') + vmName = Lang(vm.name_label(None)) if vmName is None: pane.AddTitleField(Lang("The Virtual Machine is no longer present")) else: @@ -183,7 +183,7 @@ def UpdateFieldsCONFIRM(self): pane.ResetFields() vm = HotAccessor().vm[self.vmHandle] - vmName = vm.name_label(None).encode('utf-8') + vmName = Lang(vm.name_label(None)) if vmName is None: pane.AddTitleField(Lang("The Virtual Machine is no longer present")) else: @@ -245,7 +245,7 @@ def Commit(self): Layout.Inst().PopDialogue() operationName = VMUtils.OperationName(self.operation) - vmName = HotAccessor().guest_vm[self.vmHandle].name_label(Lang('')).encode('utf-8') + vmName = HotAccessor().guest_vm[self.vmHandle].name_label(Lang('')) messagePrefix = operationName + Lang(' operation on ') + vmName + ' ' try: task = VMUtils.AsyncOperation(self.operation, self.vmHandle, *self.opParams)