[pywin32-checkins] pywin32/com/win32com/servers dictionary.py, 1.4, 1.5
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2008-12-04 03:18:37
|
Update of /cvsroot/pywin32/pywin32/com/win32com/servers In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv22614/win32com/servers Modified Files: dictionary.py Log Message: remove all support for NeedUnicodeConversions in a b/w compat way Index: dictionary.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/com/win32com/servers/dictionary.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** dictionary.py 27 Nov 2008 04:15:21 -0000 1.4 --- dictionary.py 4 Dec 2008 03:18:32 -0000 1.5 *************** *** 32,36 **** """ - import string import pythoncom from win32com.server import util, policy --- 32,35 ---- *************** *** 43,50 **** from winerror import S_OK - UnicodeType = pywintypes.UnicodeType - StringType = types.StringType - - class DictionaryPolicy(policy.BasicWrapPolicy): ### BasicWrapPolicy looks for this --- 42,45 ---- *************** *** 79,86 **** key = args[0] ! if type(key) == UnicodeType: pass ! elif type(key) == StringType: ! key = pywintypes.Unicode(key) else: ### the nArgErr thing should be 0-based, not reversed... sigh --- 74,81 ---- key = args[0] ! if type(key) == unicode: pass ! elif type(key) == str: ! key = unicode(key) else: ### the nArgErr thing should be 0-based, not reversed... sigh *************** *** 124,129 **** ### this is a copy of MappedWrapPolicy._getidsofnames_ ... ! # Note: these names will always be StringType ! name = string.lower(names[0]) try: return (self._name_to_dispid_[name],) --- 119,123 ---- ### this is a copy of MappedWrapPolicy._getidsofnames_ ... ! name = names[0].lower() try: return (self._name_to_dispid_[name],) |