[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
I'm still not really familiar with Allegro's internals yet and I don't
know Cocoa but in connection with trying to get rid of main mangling
I'm trying to understand this... any help would be appreciated.
Allegro's OS X stuff starts a new thread for the user's code, and the
main thread ends up in a while (1) loop, repeatedly calling stuff like
osx_event_handler(). Is this the right way to do it? It really seems
like that stuff should be called every iteration through the Allegro
user's main loop, rather than concurrent with that loop.
Should there really be an osx_event_handler function? Am I
misinterpreting the NSApplication documentation? My reading of
sendEvent is that the run method calls sendEvent itself... and then you
can override sendEvent if you want a different event handling, which is
what Allegro wants. But in osx_event_handler, it calls sendEvent
directly. I don't understand why.
Mike Benfield