PauseForUser blocking old style button action procedure
I have some ancient code that unfortunately uses PauseForUser to create a modal-ish dialog. I fear that the 'tricky and potentially fragile code inside Igor' (DisplayHelpTopic "Pause For User") is not playing nicely with my code.
Let's say I have PauseForUser Panel1
Panel1 contains a button ("done") with an old style button action procedure that kills Panel1.
The button action procedure doesn't run unless I halt procedure execution with the command-period keystroke. For most users Igor will appear to be locked.
Has my code been broken in a recent (or not so recent) update? What is the best way (short of recoding to get rid of pauseforuser) to make a quick fix?
System Information:
IGORVERS:8.03
BUILD:33347
OS:Macintosh OS X
OSVERSION:10.14.3
IGORFILEVERSION:8.03B01
It seems that updating to a structure-based function solves the issue. I'd still welcome any insight from WM, though. Are old-style control procedures no longer supported? Should I root out any old style control procedures in case something else breaks?
March 25, 2019 at 09:19 am - Permalink
Wow. You got the nightly build at just the wrong moment! At 33332 I fixed a reentrancy problem with old-style action procs. At 33355 I fixed the fix when it was reported to block PauseForUser using a control panel with old-style action procs.
So get the latest nightly build and it should work fine.
While all the old stuff should continue to work, and if I break it I'll fix it, it is best to use the new style. But in complex code, if it ain't broke don't fix it. Changing to new-style can be a lot of work.
March 25, 2019 at 10:17 am - Permalink