diff options
Diffstat (limited to 'library/ttk/treeview.tcl')
-rw-r--r-- | library/ttk/treeview.tcl | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/library/ttk/treeview.tcl b/library/ttk/treeview.tcl index 3ccb746..a5ebcb2 100644 --- a/library/ttk/treeview.tcl +++ b/library/ttk/treeview.tcl @@ -1,4 +1,4 @@ -# $Id: treeview.tcl,v 1.2 2006/12/18 19:33:14 jenglish Exp $ +# $Id: treeview.tcl,v 1.3 2008/01/06 19:16:12 jenglish Exp $ # # ttk::treeview widget bindings and utilities. # @@ -56,13 +56,7 @@ bind Treeview <Shift-ButtonPress-1> \ bind Treeview <Control-ButtonPress-1> \ { ttk::treeview::Select %W %x %y toggle } -# Standard mousewheel bindings: -# -bind Treeview <MouseWheel> { %W yview scroll [expr {- (%D / 120) * 4}] units } -if {[string equal "x11" [tk windowingsystem]]} { - bind Treeview <ButtonPress-4> { %W yview scroll -5 units } - bind Treeview <ButtonPress-5> { %W yview scroll 5 units } -} +ttk::copyBindings TtkScrollable Treeview ### Binding procedures. # @@ -163,7 +157,7 @@ proc ttk::treeview::Select {w x y op} { } } -## DoubleClick -- Double-ButtonPress-1 binding. +## DoubleClick -- Double-ButtonPress-1 binding. # proc ttk::treeview::DoubleClick {w x y} { if {[set row [$w identify row $x $y]] ne ""} { @@ -261,7 +255,7 @@ proc ttk::treeview::heading.release {w} { # ## SelectOp $w $item [ choose | extend | toggle ] -- -# Dispatch to appropriate selection operation +# Dispatch to appropriate selection operation # depending on current value of -selectmode. # proc ttk::treeview::SelectOp {w item op} { @@ -282,10 +276,10 @@ proc ttk::treeview::select.extend.browse {w item} { BrowseTo $w $item } ## -selectmode multiple: # -proc ttk::treeview::select.choose.extended {w item} { +proc ttk::treeview::select.choose.extended {w item} { BrowseTo $w $item } -proc ttk::treeview::select.toggle.extended {w item} { +proc ttk::treeview::select.toggle.extended {w item} { $w selection toggle $item } proc ttk::treeview::select.extend.extended {w item} { @@ -304,7 +298,7 @@ proc ttk::treeview::select.extend.extended {w item} { # in preorder traversal order. $item1 and $item2 may be # in either order. # -# NOTES: +# NOTES: # This routine is O(N) in the size of the tree. # There's probably a way to do this that's O(N) in the number # of items returned, but I'm not clever enough to figure it out. |