summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXisco Fauli <anistenis@gmail.com>2012-11-26 20:26:29 +0100
committerXisco Fauli <anistenis@gmail.com>2012-11-26 23:39:45 +0100
commitc279c575950b08e45f5f1d9c7935716a76d67139 (patch)
tree90599a89d8577c86819867c89c9ff270e2bf10bf
parent944a7aa48aefdcafddcc75a5bfff68eeb6d4e343 (diff)
pywizards: No need to use unicodedata here
Change-Id: I30eb17dd740978e2ce03ada0ec11a4db65205f41
-rw-r--r--wizards/com/sun/star/wizards/common/Desktop.py2
-rw-r--r--wizards/com/sun/star/wizards/common/Resource.py2
-rw-r--r--wizards/com/sun/star/wizards/text/TextDocument.py4
-rw-r--r--wizards/com/sun/star/wizards/text/TextFieldHandler.py5
-rw-r--r--wizards/com/sun/star/wizards/ui/WizardDialog.py4
5 files changed, 7 insertions, 10 deletions
diff --git a/wizards/com/sun/star/wizards/common/Desktop.py b/wizards/com/sun/star/wizards/common/Desktop.py
index 49880ac82643..6dfe1ee477bf 100644
--- a/wizards/com/sun/star/wizards/common/Desktop.py
+++ b/wizards/com/sun/star/wizards/common/Desktop.py
@@ -51,7 +51,7 @@ class Desktop(object):
@classmethod
def getDispatcher(self, xMSF, xFrame, _stargetframe, oURL):
try:
- oURLArray = range(1)
+ oURLArray = list(range(1))
oURLArray[0] = oURL
xDispatch = xFrame.queryDispatch(oURLArray[0], _stargetframe, ALL)
return xDispatch
diff --git a/wizards/com/sun/star/wizards/common/Resource.py b/wizards/com/sun/star/wizards/common/Resource.py
index 52eb40f826e7..450565e15f48 100644
--- a/wizards/com/sun/star/wizards/common/Resource.py
+++ b/wizards/com/sun/star/wizards/common/Resource.py
@@ -50,7 +50,7 @@ class Resource(object):
def getResArray(self, nID, iCount):
try:
- ResArray = range(iCount)
+ ResArray = list(range(iCount))
i = 0
while i < iCount:
ResArray[i] = getResText(nID + i)
diff --git a/wizards/com/sun/star/wizards/text/TextDocument.py b/wizards/com/sun/star/wizards/text/TextDocument.py
index 41d7fbf2a032..da9761da0948 100644
--- a/wizards/com/sun/star/wizards/text/TextDocument.py
+++ b/wizards/com/sun/star/wizards/text/TextDocument.py
@@ -86,7 +86,7 @@ class TextDocument(object):
_moduleIdentifier.Identifier)
# load the document into a blank frame
xDesktop = Desktop.getDesktop(xMSF)
- loadArgs = range(1)
+ loadArgs = list(range(1))
loadArgs[0] = "Model"
loadArgs[0] = -1
loadArgs[0] = self.xTextDocument
@@ -244,7 +244,7 @@ class TextDocument(object):
auxList = []
allItems = self.xTextDocument.findAll(sd)
- for i in range(allItems.Count):
+ for i in list(range(allItems.Count)):
auxList.append(allItems.getByIndex(i))
return auxList
diff --git a/wizards/com/sun/star/wizards/text/TextFieldHandler.py b/wizards/com/sun/star/wizards/text/TextFieldHandler.py
index f6f251e3a125..dfb4d0bd47da 100644
--- a/wizards/com/sun/star/wizards/text/TextFieldHandler.py
+++ b/wizards/com/sun/star/wizards/text/TextFieldHandler.py
@@ -17,7 +17,6 @@
#
import traceback
import time
-import unicodedata
from ..common.PropertyNames import PropertyNames
from com.sun.star.util import DateTime
@@ -105,9 +104,7 @@ class TextFieldHandler(object):
if xPropertySet.PropertySetInfo.hasPropertyByName(
_PropertyName):
oValue = xPropertySet.getPropertyValue(_PropertyName)
- sValue = unicodedata.normalize(
- 'NFKD', oValue).encode('ascii','ignore')
- if sValue == _aPropertyValue:
+ if oValue == _aPropertyValue:
return xProperty
return None
except KeyError:
diff --git a/wizards/com/sun/star/wizards/ui/WizardDialog.py b/wizards/com/sun/star/wizards/ui/WizardDialog.py
index c5f000c89bb0..370a4c30eb6a 100644
--- a/wizards/com/sun/star/wizards/ui/WizardDialog.py
+++ b/wizards/com/sun/star/wizards/ui/WizardDialog.py
@@ -161,7 +161,7 @@ class WizardDialog(UnoDialog2):
def getRoadmapItemByID(self, _ID):
try:
getByIndex = self.oRoadmap.getByIndex
- for i in range(self.oRoadmap.Count):
+ for i in list(range(self.oRoadmap.Count)):
CurRoadmapItem = getByIndex(i)
CurID = int(Helper.getUnoPropertyValue(CurRoadmapItem, "ID"))
if CurID == _ID:
@@ -339,7 +339,7 @@ class WizardDialog(UnoDialog2):
def enablefromStep(self, _iStep, _bDoEnable):
if _iStep <= self.nMaxStep:
- for i in range(_iStep, self.nMaxStep):
+ for i in list(range(_iStep, self.nMaxStep)):
self.setStepEnabled(i, _bDoEnable)
enableFinishButton(_bDoEnable)
if not _bDoEnable: