Leser: 2
|< 1 2 >| | 15 Einträge, 2 Seiten |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/usr/bin/perl
use strict;
use warnings 'all';
use Tk;
my $mw = tkinit();
my $menu = $mw->Menu(-type => "menubar");
$mw->configure(-menu => $menu);
$menu->cascade(-label => "~Datei");
my $balloon = $mw->Balloon(-initwait => 1);
$balloon->attach($menu, -msg => ["Menü: Datei"]);
MainLoop;
__END__
1
2
3
4
5
6
7
8
9
10
11
12
13
14
--- Tixish/Balloon.pm (revision 1074)
+++ Tixish/Balloon.pm (local)
@@ -256,6 +256,11 @@ sub grabBad {
return 0 if $g->isa('Tk::Menu');
return 0 if $g eq $client;
+ # Ignore grab check if $w is the balloon itself.
+ # XXX Why is this necessary? Is it possible to remove the grabBad
+ # condition in SwitchToClient altogether?
+ return 0 if $w->isa(__PACKAGE__);
+
# The grab is OK if $client is a decendant of $g. Use the internal Tcl/Tk
# pathname (yes, it's cheating, but it's legal).
|< 1 2 >| | 15 Einträge, 2 Seiten |