Update of /cvsroot/pywin32/pywin32/com/win32com/demos
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv18082/com/win32com/demos
Modified Files:
dump_clipboard.py ietoolbar.py
Log Message:
more moderizations merged from py3k work
Index: ietoolbar.py
===================================================================
RCS file: /cvsroot/pywin32/pywin32/com/win32com/demos/ietoolbar.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** ietoolbar.py 27 Nov 2008 05:58:17 -0000 1.4
--- ietoolbar.py 27 Nov 2008 09:33:22 -0000 1.5
***************
*** 71,79 ****
else:
full_fmt += fmt
! for name, val in kw.items():
self.__dict__[name] = val
def __setattr__(self, attr, val):
! if not attr.startswith("_") and not self.__dict__.has_key(attr):
raise AttributeError(attr)
self.__dict__[attr] = val
--- 71,79 ----
else:
full_fmt += fmt
! for name, val in kw.iteritems():
self.__dict__[name] = val
def __setattr__(self, attr, val):
! if not attr.startswith("_") and attr not in self.__dict__:
raise AttributeError(attr)
self.__dict__[attr] = val
Index: dump_clipboard.py
===================================================================
RCS file: /cvsroot/pywin32/pywin32/com/win32com/demos/dump_clipboard.py,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** dump_clipboard.py 8 Oct 2003 04:25:59 -0000 1.1
--- dump_clipboard.py 27 Nov 2008 09:33:22 -0000 1.2
***************
*** 12,16 ****
format_name_map[val]=f
! tymeds = [attr for attr in pythoncom.__dict__.keys() if attr.startswith("TYMED_")]
def DumpClipboard():
--- 12,16 ----
format_name_map[val]=f
! tymeds = [attr for attr in pythoncom.__dict__.iterkeys() if attr.startswith("TYMED_")]
def DumpClipboard():
|