diff options
author | treectrl <treectrl> | 2006-11-19 00:49:36 (GMT) |
---|---|---|
committer | treectrl <treectrl> | 2006-11-19 00:49:36 (GMT) |
commit | a6d60ba430fef31022994d5f0f4113ffaac567bd (patch) | |
tree | cb509db136228e26040bf13994dc86f48e01065d /library/filelist-bindings.tcl | |
parent | 7d51879c281d91b4d84a4c06b0dbe2568d4c10cf (diff) | |
download | tktreectrl-a6d60ba430fef31022994d5f0f4113ffaac567bd.zip tktreectrl-a6d60ba430fef31022994d5f0f4113ffaac567bd.tar.gz tktreectrl-a6d60ba430fef31022994d5f0f4113ffaac567bd.tar.bz2 |
Defined TreeCtrl::lassign if ::lassign doesn't exist and use it instead of the classic foreach hack.
Diffstat (limited to 'library/filelist-bindings.tcl')
-rw-r--r-- | library/filelist-bindings.tcl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/library/filelist-bindings.tcl b/library/filelist-bindings.tcl index a15f5c4..4062b6e 100644 --- a/library/filelist-bindings.tcl +++ b/library/filelist-bindings.tcl @@ -1,4 +1,4 @@ -# RCS: @(#) $Id: filelist-bindings.tcl,v 1.25 2006/11/05 06:43:28 treectrl Exp $ +# RCS: @(#) $Id: filelist-bindings.tcl,v 1.26 2006/11/19 00:49:36 treectrl Exp $ bind TreeCtrlFileList <Double-ButtonPress-1> { TreeCtrl::FileListEditCancel %W @@ -88,7 +88,7 @@ proc ::TreeCtrl::IsSensitive {T x y} { if {[lindex $id 0] ne "item" || [llength $id] != 6} { return 0 } - foreach {where item arg1 arg2 arg3 arg4} $id {} + lassign $id where item arg1 arg2 arg3 arg4 if {![$T item enabled $item]} { return 0 } @@ -126,7 +126,7 @@ proc ::TreeCtrl::FileListButton1 {T x y} { # Click in item } else { - foreach {where item arg1 arg2 arg3 arg4} $id {} + lassign $id where item arg1 arg2 arg3 arg4 switch $arg1 { button - line { |