Email Archive: perl-win32-gui-users (read-only) From: Peter Eisengrein <[EMAIL PROTECTED]> RE: AcceleratorTable 2001-02-05 08:34 I've never been able to get the -accel's to work either. Good luck, I am looking forward to seeing the resolution on this. -----Original Message----- From: Erick J. Bourgeois [mailto:[EMAIL PROTECTED] Sent: Saturday, February 03, 2001 10:00 AM To: perl-win32-gui-users@lists.sourceforge.net Subject: Re: [perl-win32-gui-users] AcceleratorTable The subs that you supplied do not respond to the keys either. Any more ideas? erick never stop questioning http://www.jeb.ca <http://www.jeb.ca> ----- Original Message ----- From: Peter Eisengrein I may be wrong, but I've found that you cannot call a _Click() directly (you actually have to Click on something). I'd try this with your subs: sub Open_Click { Open(); } sub Open { my $file=GUI::GetOpenFileName(-title=>"File To Open", -filter=>["*.*"],); } sub OpenHK_Click { Open; }
From: Erick J. Bourgeois <[EMAIL PROTECTED]> AcceleratorTable 2001-02-01 09:20 I'm working on an accelerator table and I have written this thus far, but it isn't responding to the keys: use Win32::GUI; $HotKey = new Win32::GUI::AcceleratorTable( "Ctrl-O" => "OpenHK", ); $Menu = Win32::GUI::MakeMenu( "&File" => "File", "> &Open Ctrl+O" => "Open", ); $MainWin = new Win32::GUI::Window( -name => "MainWin", -text => "Accelerator Table", -accel => $HotKey, -size => [200, 200], -pos => [70, 70], -menu => $Menu, ); $MainWin->Show(); Win32::GUI::Dialog(); sub MainWin_Terminate { $MainWin->Hide(); return -1; } sub Open_Click { my $file=GUI::GetOpenFileName(-title=>"File To Open", -filter=>["*.*"],); } sub OpenHK_Click { Open_Click(); } #------------EOF---------------# erick never stop questioning http://www.jeb.ca From: Peter Eisengrein <[EMAIL PROTECTED]> RE: AcceleratorTable 2001-02-02 14:00 I may be wrong, but I've found that you cannot call a _Click() directly (you actually have to Click on something). I'd try this with your subs: sub Open_Click { Open(); } sub Open { my $file=GUI::GetOpenFileName(-title=>"File To Open", -filter=>["*.*"],); } sub OpenHK_Click { Open; } -----Original Message----- From: Erick J. Bourgeois [mailto:[EMAIL PROTECTED] Sent: Thursday, February 01, 2001 12:18 PM To: perl-win32-gui-users@lists.sourceforge.net Subject: [perl-win32-gui-users] AcceleratorTable I'm working on an accelerator table and I have written this thus far, but it isn't responding to the keys: use Win32::GUI; $HotKey = new Win32::GUI::AcceleratorTable( "Ctrl-O" => "OpenHK", ); $Menu = Win32::GUI::MakeMenu( "&File" => "File", "> &Open Ctrl+O" => "Open", ); $MainWin = new Win32::GUI::Window( -name => "MainWin", -text => "Accelerator Table", -accel => $HotKey, -size => [200, 200], -pos => [70, 70], -menu => $Menu, ); $MainWin->Show(); Win32::GUI::Dialog(); sub MainWin_Terminate { $MainWin->Hide(); return -1; } sub Open_Click { my $file=GUI::GetOpenFileName(-title=>"File To Open", -filter=>["*.*"],); } sub OpenHK_Click { Open_Click(); } #------------EOF---------------# erick never stop questioning http://www.jeb.ca <http://www.jeb.ca> From: Erick J. Bourgeois <[EMAIL PROTECTED]> Re: AcceleratorTable 2001-02-03 08:03 The subs that you supplied do not respond to the keys either. Any more ideas? erick never stop questioning http://www.jeb.ca ----- Original Message ----- From: Peter Eisengrein I may be wrong, but I've found that you cannot call a _Click() directly (you actually have to Click on something). I'd try this with your subs: sub Open_Click { Open(); } sub Open { my $file=GUI::GetOpenFileName(-title=>"File To Open", -filter=>["*.*"],); } sub OpenHK_Click { Open; }
<<msg.gif>>