diff options
-rw-r--r-- | ext/tk/ChangeLog.tkextlib | 8 | ||||
-rw-r--r-- | ext/tk/lib/tkextlib/treectrl/tktreectrl.rb | 2 | ||||
-rw-r--r-- | ext/tk/sample/tkextlib/treectrl/demo.rb | 2 | ||||
-rw-r--r-- | ext/tk/sample/tkextlib/treectrl/random.rb | 9 |
4 files changed, 15 insertions, 6 deletions
diff --git a/ext/tk/ChangeLog.tkextlib b/ext/tk/ChangeLog.tkextlib index 6a5338ed17..98092f84c0 100644 --- a/ext/tk/ChangeLog.tkextlib +++ b/ext/tk/ChangeLog.tkextlib @@ -1,5 +1,13 @@ 2005-04-08 ocean <ocean@ruby-lang.org> + * lib/tkextlib/treectrl/tktreectrl.rb (selection_clear): fixed typo. + + * sample/tkextlib/treectrl/random.rb: node deselection now works. + + * sample/tkextlib/treectrl/demo.rb: fixed typo. (popup menu on column header) + +2005-04-08 ocean <ocean@ruby-lang.org> + * sample/tkextlib/treectrl/help.rb: fixed typo. (wrong color) 2005-04-08 ocean <ocean@ruby-lang.org> diff --git a/ext/tk/lib/tkextlib/treectrl/tktreectrl.rb b/ext/tk/lib/tkextlib/treectrl/tktreectrl.rb index 269711b22f..136666c4af 100644 --- a/ext/tk/lib/tkextlib/treectrl/tktreectrl.rb +++ b/ext/tk/lib/tkextlib/treectrl/tktreectrl.rb @@ -1302,7 +1302,7 @@ class Tk::TreeCtrl end def selection_clear(*args) # first, last - tk_send('selection', 'clear' *args) + tk_send('selection', 'clear', *args) self end diff --git a/ext/tk/sample/tkextlib/treectrl/demo.rb b/ext/tk/sample/tkextlib/treectrl/demo.rb index ec8698ec5b..e3d0180584 100644 --- a/ext/tk/sample/tkextlib/treectrl/demo.rb +++ b/ext/tk/sample/tkextlib/treectrl/demo.rb @@ -496,7 +496,7 @@ class TkTreeCtrl_demo @popup[:arrowside].value = w.column_cget(col, :arrowside) @popup[:arrowgravity].value = w.column_cget(col, :arrowgravity) @popup[:expand].value = w.column_cget(col, :expand) - @popup[:sqeeeze].value = w.column_cget(col, :squeeze) + @popup[:squeeze].value = w.column_cget(col, :squeeze) @popup[:justify].value = w.column_cget(col, :justify) @mHeader[w].popup(rootx, rooty) return diff --git a/ext/tk/sample/tkextlib/treectrl/random.rb b/ext/tk/sample/tkextlib/treectrl/random.rb index f9a38b0d8b..259cb1865f 100644 --- a/ext/tk/sample/tkextlib/treectrl/random.rb +++ b/ext/tk/sample/tkextlib/treectrl/random.rb @@ -100,7 +100,6 @@ def demoRandom(t) clicks = Tk::Clock.clicks (0...(random_N())).each{|i| item_i = items[i] - item_j = nil numChildren = t.item_numchildren(item_i) if numChildren > 0 if $Version_1_1_OrLater @@ -179,15 +178,17 @@ def randomButton1(t, x, y) id = t.identify(x, y) puts id.inspect @Priv['buttonMode'] = '' + + # Click outside any item if id.empty? - # Click outside any item + t.selection_clear + # Click in header elsif id[0] == 'header' - # Click in header Tk::TreeCtrl::BindCallback.buttonPress1(t, x, y) + # Click in item else - # Click in item where, item, arg1, arg2, arg3, arg4 = id case arg1 when 'button' |