I have an application that waits for the user to press a key and then executes a long running method that periodically updates the GUI.
sub keypress{
my $self = shift;
my $event = shift;
if ($event->GetKeyCode() == WXK_F12){
$self->doStuff();
}else{
$event -> Skip(0);
}
}
I would like to have the application ignore any keypresses that occur while the doStuff method is doing it's thing.
I tried setting a flag and wrapping the method call in a additional if statement but the kepress method is not entered until doStuff finishes.
I'm kind of new to wxwidgets and feel like I don't know what I don't know. Any suggestions on what to explore next would be greatly appreciated.