[PD-cvs] pd/src desire.tk,1.1.2.600.2.313,1.1.2.600.2.314

Mathieu Bouchard matju at users.sourceforge.net
Tue Aug 7 21:49:33 CEST 2007


Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv6599

Modified Files:
      Tag: desiredata
	desire.tk 
Log Message:
fix selection-= and selection_wire-= about removing objects that already aren't in the table


Index: desire.tk
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v
retrieving revision 1.1.2.600.2.313
retrieving revision 1.1.2.600.2.314
diff -C2 -d -r1.1.2.600.2.313 -r1.1.2.600.2.314
*** desire.tk	7 Aug 2007 18:30:48 -0000	1.1.2.600.2.313
--- desire.tk	7 Aug 2007 19:49:28 -0000	1.1.2.600.2.314
***************
*** 2158,2169 ****
  def Canvas objects {} {return $@objects}
  #def Canvas wires {} {return $@wires}
! def Canvas selection {} {$@objectsel values}
! def Canvas selection= {objs} {$@objectsel clear; $self selection+= $objs}
! def Canvas selection+= {objs} {foreach obj $objs {$@objectsel set [$obj index] $obj}}
! def Canvas selection-= {objs} {foreach obj $objs {$@objectsel unset [$obj index]}}
! def Canvas selection_wire {} {$@wiresel values}
! def Canvas selection_wire= {objs} {$@wiresel clear; $self selection_wire+= $objs}
  def Canvas selection_wire+= {objs} {foreach obj $objs {$@wiresel set [$obj index] $obj}}
! def Canvas selection_wire-= {objs} {foreach obj $objs {$@wiresel unset [$obj index]}}
  
  def Canvas Object  {} {$self new_object obj}
--- 2158,2169 ----
  def Canvas objects {} {return $@objects}
  #def Canvas wires {} {return $@wires}
! def Canvas selection        {} {$@objectsel values}
! def Canvas selection=       {objs} {$@objectsel clear; $self selection+= $objs}
! def Canvas selection+=      {objs} {foreach obj $objs {$@objectsel set [$obj index] $obj}}
! def Canvas selection-=      {objs} {foreach obj $objs {set k [$obj index]; if {[$@objectsel exists $k]} {$@objectsel unset $k}}}
! def Canvas selection_wire   {} {$@wiresel values}
! def Canvas selection_wire=  {objs} {$@wiresel clear; $self selection_wire+= $objs}
  def Canvas selection_wire+= {objs} {foreach obj $objs {$@wiresel set [$obj index] $obj}}
! def Canvas selection_wire-= {objs} {foreach obj $objs {set k [$obj index]; if {[  $@wiresel exists $k]} {  $@wiresel unset $k}}}
  
  def Canvas Object  {} {$self new_object obj}





More information about the Pd-cvs mailing list