Update of /cvsroot/wpdev/xmlscripts/scripts/wolfpack
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28093/wolfpack
Modified Files:
utilities.py
Log Message:
- Replaced access to .events with the calls hasevent/addevent/removeevent in all relevant places.
Notice that addevent() is expected to add the event to the head of the list.
I recognized no situation (of those changed) where it would make a difference adding the event to the end of the list, so in those cases used addevent aswell.
- Fixed a copy&paste error in trap.py on removing the tags (pointed out by Incannus).
note: .events can now be made read only, bearing in mind that in doing so there is no way to make a distinction between adding an event at the top or at the end of the event list.
Index: utilities.py
===================================================================
RCS file: /cvsroot/wpdev/xmlscripts/scripts/wolfpack/utilities.py,v
retrieving revision 1.63
retrieving revision 1.64
diff -C2 -d -r1.63 -r1.64
*** utilities.py 21 Jul 2004 14:20:42 -0000 1.63
--- utilities.py 24 Aug 2004 18:10:31 -0000 1.64
***************
*** 601,608 ****
tocontainer( key, container )
container.settag( 'lock', rkeyid )
! if not 'lock' in container.events:
! events = container.events
! events[:0] = ['lock']
! container.events = events
return
--- 601,605 ----
tocontainer( key, container )
container.settag( 'lock', rkeyid )
! container.addevent( 'lock' )
return
|