[futurebasic] Re: [FB] CarbonInCocoa

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : May 2012 : Group Archive : Group : All Groups

From: Robert Purves <listrp@...>
Date: Tue, 1 May 2012 22:10:21 +1200
Robert Covington wrote:

> Robert Purves wrote:
> 
>>> Then fn buildWindow does not work...either is not being called, or, it's being called at a point where something else is not ready? Or...?
>>> Is that due to FBtoC's way  or order in creating the files to be run, or something more technical or ...?
>> 
>> That is due to
>>   [NSApp run];
>> which processes events until a 'terminate:' message is received (for example the user types Command-Q), at which point the application exits. Thus no subsequent code gets executed.
> 
> Ah. Thanks. I think I knew that last week but forgot it by this week. : ( 
> So in the "working" case ( Carbon first, Cocoa second, which does put up a Carbon window) ...how does
> 
> Do 
> HandleEvents
> until (gFBQuit)
> 
> ...factor in, since it seems to fire via the _kHICommandQuit hook? 

That code is never executed. The app just quits while sitting in [NSApp run];

Robert P.