[PD-cvs] pd/src desire.tk,1.1.2.600.2.306,1.1.2.600.2.307
Mathieu Bouchard
matju at users.sourceforge.net
Tue Aug 7 17:29:46 CEST 2007
Update of /cvsroot/pure-data/pd/src
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8494
Modified Files:
Tag: desiredata
desire.tk
Log Message:
added shim [dex $hash $key] between the new index system and the old index system. (temporary)
Index: desire.tk
===================================================================
RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v
retrieving revision 1.1.2.600.2.306
retrieving revision 1.1.2.600.2.307
diff -C2 -d -r1.1.2.600.2.306 -r1.1.2.600.2.307
*** desire.tk 7 Aug 2007 08:04:55 -0000 1.1.2.600.2.306
--- desire.tk 7 Aug 2007 15:29:42 -0000 1.1.2.600.2.307
***************
*** 325,328 ****
--- 325,332 ----
puts values=[$h values]
puts list=[$h list]
+ $h unset foo
+ puts list=[$h list]
+ $h clear
+ puts list=[$h list]
foreach i {1 2 3 4} {puts "exists $i : [$h exists $i]"}
}
***************
*** 2133,2138 ****
set o [$@objectsel values]
mset {x1 y1 x2 y2} [$o bbox]
! # this should use callback...
! netsend [list .$self obj $x1 [expr $y2 + 10]] [list $self new_object_edit]
set @action chain_obj
}
--- 2137,2141 ----
set o [$@objectsel values]
mset {x1 y1 x2 y2} [$o bbox]
! netsend [list .$self obj $x1 [expr $y2+10]] [list $self new_object_edit]
set @action chain_obj
}
***************
*** 2759,2762 ****
--- 2762,2768 ----
}
+ # this is a shim between the client's new-style indices and the server's remaining old-style indices
+ proc dex {h k} {lsearch [lsort [$h keys]] $k}
+
# for undo; calls the server
def Canvas ins {i constructor} {
***************
*** 2765,2769 ****
set parts [lrange $parts 0 end-1]
foreach part $parts {netsend $part}
! netsend [concat [list .$self object_insert $i] $last] ;# bork bork bork
$@history add [list $self del $i]
}
--- 2771,2775 ----
set parts [lrange $parts 0 end-1]
foreach part $parts {netsend $part}
! netsend [concat [list .$self object_insert [dex $@objects $i]] $last] ;# bork bork bork
$@history add [list $self del $i]
}
***************
*** 2785,2789 ****
$meuh delete
}
! netsend [list .$self object_delete $o]
}
--- 2791,2795 ----
$meuh delete
}
! netsend [list .$self object_delete [dex $@objects $o]]
}
***************
*** 3659,3663 ****
def Canvas select_all {} {$@objectsel reinit [$objects list]}
! def Canvas deselect_all {} {$@objectsel clear}
def Canvas popup_help {} {$::main class_browser}
--- 3665,3669 ----
def Canvas select_all {} {$@objectsel reinit [$objects list]}
! def Canvas deselect_all {} {puts [$@objectsel list]; $@objectsel clear; puts [$@objectsel list]}
def Canvas popup_help {} {$::main class_browser}
***************
*** 3693,3697 ****
}
-
def Canvas disconnect {wire} {
set @keynav_tab_sel "wire"
--- 3699,3702 ----
***************
*** 3702,3706 ****
}
mset {from outlet to inlet} $wire
! netsend [list .$self disconnect $from $outlet $to $inlet]
$@history add [list $self connect $wire]
}
--- 3707,3711 ----
}
mset {from outlet to inlet} $wire
! netsend [list .$self disconnect [dex $@objects $from] $outlet [dex $@objects $to] $inlet]
$@history add [list $self connect $wire]
}
***************
*** 3708,3713 ****
mset {from outlet to inlet} $wire
switch $callback {
! none {netsend [list .$self connect $from $outlet $to $inlet]}
! default {netsend [list .$self connect $from $outlet $to $inlet] $callback}
}
$@history add [list $self disconnect $wire]
--- 3713,3718 ----
mset {from outlet to inlet} $wire
switch $callback {
! none {netsend [list .$self connect $from [dex $@objects $outlet] $to [dex $@objects $inlet]]}
! default {netsend [list .$self connect $from [dex $@objects $outlet] $to [dex $@objects $inlet]] $callback}
}
$@history add [list $self disconnect $wire]
More information about the Pd-cvs
mailing list