Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
my $top = new MainWindow();
my $tree = $top->ScrlTree();
$tree->bind(ref($tree), '<ButtonPress>', sub { die });
$top->bind(ref($tree), '<ButtonPress>', sub { die });
# Populate Tree...
MainLoop
For some reason this doesn't seem to work. It should die when I click the mouse on the tree, but it doesn't do anything at all. What is wrong?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
(tye)Re: Binding events in Tk
by tye (Sage) on Jan 14, 2001 at 06:02 UTC | |
by Anonymous Monk on Jan 14, 2001 at 09:59 UTC |