It could be that the code in the event handler is taking a long time to complete, which means Win32::GUI won't have a chance to update the GUI, and the program will appear to hang. This includes redrawing controls. So if a lengthy piece of code is executed when a button is pressed, it will remain pressed until the code returns to the dialog loop. One solution to this problem is to periodically call Win32::GUI::DoEvents() in your code to allow Win32::GUI to process any pending events. Example:
sub Button_Click { while(1){ # do something... Win32::GUI::DoEvents(); } return 1; }
In reply to Re^5: Release Button in Click
by kejohm
in thread Release Button in Click
by tcopeck
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |