There is this nice bug that an application crashes when quitting in fullscreen mode on the Captain for Xojo versions lower than 2015r3. For a dot release I can’t bring my app to the latest version. So I thought I’d simply exit fullscreen on quitting:
Function IsFullScreen(w as Window) As Boolean
Const NSFullScreenWindowMask = 16384
declare function mStyleMask lib "AppKit" selector "styleMask" ( ref as integer ) as integer
Return Bitwise.BitAnd( mstyleMask( w.handle ), NSFullScreenWindowMask ) = NSFullScreenWindowMask
[code]Function Quit() As Boolean
if XojoVersion < 2015.3 and isFullScreen(self) then
dim w as new NSWindowMBS(self)
In a project with just this code the app crashes on quit. That’s Xojo 2014r2. I’ve set a breakpoint at the first line of the Quit MenuHandler and the breakpoint isn’t reached.
I can tell you that with thousands of users, many of whom have upgraded to El Capitan, I have only had one report of this to date.
I cannot recreate this on my own El Capitan machine.
The scope of the problem is this, assuming you have used 2015 to build…
-have upgraded to El Capitan
-who use Fullscreen (I personally never do, for example)
-leave the app fullscreen until they quit
-have whatever configuration causes the crash.
I dont think this is a widespread problem, or a large one.
Sadly, it took a different post in this forum to find out that this problem was known, but only to beta testers of Xojo.
In the beta group, having discussed it, I have no doubt that those people assumed it was more widely known.
Michel’s visible=false suggestion seems to be the simple and elegant workaround.
Unfortunately I didn’t know about it until the last Yosemite beta and, as far as I remember, I was the first to create a bug report about it. It either isn’t something many users run into in practice or didn’t cause enough problems for anyone to report a bug.