Skip to content

Commit

Permalink
hsw12_gui.pm: fix focusFollowsMouse on aqua
Browse files Browse the repository at this point in the history
workaround for Tcl::pTk 0.92: call Tcl command
`tk_focusFollowsMouse` directly
  • Loading branch information
chrstphrchvz committed Jun 24, 2018
1 parent 40a3a17 commit bfdfcf4
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion Perl/hsw12_gui.pm
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ use Data::Dumper;
use IO::File;
use Fcntl;
use File::Basename;
use Module::Loaded;

####################
# global variables #
Expand Down Expand Up @@ -416,7 +417,13 @@ sub create_main_window {
#################
# set autofocus #
#################
$self->{gui}->{main}->focusFollowsMouse;
# Workaround for Tcl::pTk 0.92
if (is_loaded('Tcl::pTk')) {
$self->{gui}->{main}->interp->icall('tk_focusFollowsMouse');
}
else {
$self->{gui}->{main}->focusFollowsMouse;
}

###############
# set appname #
Expand Down

0 comments on commit bfdfcf4

Please sign in to comment.