Subject: | Wx windows are always inactive in Mac OS X 10.5.1 (Leopard) |
I cannot seem to get a Wx window to activate using Wx on Mac OS X 10.5.1 (Leopard). All
windows show up inactive, and I cannot interact with them at all. I tried SetTopWindow() to
no avail. I have a stock Mac OS X 10.5.1 install with no 3rd party extensions, running on an
Intel 15" MacBook Pro with 2 GB RAM. I tried both the Wx 0.74 which ships with Mac OS X
10.5.1, and the latest 0.80 distribution. Same effect on both.
Example code:
#!/usr/bin/perl
use strict;
use Wx;
package myApp ;
use base 'Wx::App';
sub OnInit { return(@_[0]) ;}
package myFrame ;
use base 'Wx::Frame';
use Wx qw( wxDEFAULT_FRAME_STYLE );
sub new {
my $app = shift ;
my( $frame ) = $app->SUPER::new( @_[0] , -1, 'wxPerl Test' ,
[100,100] , [400,300] ) ;
return( $frame ) ;
}
package main ;
use Wx ;
my $myApp = myApp->new() ;
my $win = myFrame->new() ;
$win->Show(1) ;
$myApp->SetTopWindow( $win ) ;
$myApp->MainLoop();
1;
# This is perl, v5.8.8 built for darwin-thread-multi-2level
# Darwin joebook 9.1.0 Darwin Kernel Version 9.1.0: Wed Oct 31 17:46:22 PDT 2007;
root:xnu-1228.0.2~1/RELEASE_I386 i386