Page 1 of 1

After update XCode: "nextEventMatchingMask should only..."

Posted: Sun Jan 27, 2019 9:10 pm
by Lebostein
After updating XCode to version 9.2 I get error messages while compiling PureBasic programs:
"nextEventMatchingMask should only be called from the Main Thread!" for example in a line with ResizeGadget()...

What is going on?

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Sun Jan 27, 2019 9:34 pm
by mk-soft
I thing you must update your PB-Version
Please specify the MacOS and PB version

Link: viewtopic.php?f=28&t=66778&hilit=nextEventMatchingMask

Link 2: viewtopic.php?f=12&t=47588&hilit=nextEv ... 05#p496485

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Sun Jan 27, 2019 11:28 pm
by Lebostein
I use the current version.

PureBasic 5.70 LTS (MacOS X - x64)
macOS Sierra 10.12.6
XCode 9.2

(XCode 9.3 requires macOS 10.13.x)

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Mon Jan 28, 2019 12:30 am
by mk-soft
All codes the same fault?

Have you an example code.

I am working with Mojave and my virtual machine with High Sierra is at time not ready.

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Mon Jan 28, 2019 4:17 pm
by Fred
If you can post a small code demonstrating the issue, it could help. Do you use WaitWindowEvent() in a thread ?

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Tue Feb 05, 2019 12:32 pm
by Lebostein
I think I have it. I had some ResizeGadget() commands inside a thread. It seems that causes that error messages... no problem for the old XCode, but for the new

Re: After update XCode: "nextEventMatchingMask should only..

Posted: Tue Feb 05, 2019 1:40 pm
by mk-soft
Always change gadgets from MainScrope... Never from threads.

Your this i have the module ThreadToGUI. Show signature...