haiku/headers/private/app
Ingo Weinhold 6bfd06d1ff BRoster::Launch() eventually launches the application in question
in several steps:
1. early pre-registration with the registrar ("I wanna launch the
   app, make sure noone interferes.")
2. load the app image
3. finish pre-registration with the registrar ("I have launched
   the app, here is its team ID.")
4. start app main thread
5. send "on launch" messages to the app (argv, refs, others)

If the app is already running or being launched, 1. fails with a
conclusive error code and returns the team ID and the pre-registration
token of the app. Steps 2 - 4 are skipped and only the messages are
delivered using the team ID returned by 1.

This change fixes a race condition: The failed early pre-registration
request obviously cannot return the team ID, if the other thread
launching the app has not finished step 3 yet. Thus the argv/refs
message would not get delivered and Launch() would not return the
correct team ID.

Now we wait for the pre-registration to be finished in this case, using
the former _IsAppPreRegistered() mechanism, which already provided
such a waiting feature for one request. It has been extended to
accomodate an arbitrary number of waiting requests and renamed to
_IsAppRegistered().

This fixed bug #763.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@18728 a95241bf-73f2-0310-859d-f6bbb57e9c96
2006-08-31 17:54:16 +00:00
..
ApplicationPrivate.h * There is now a server_read_only_memory structure that is placed in a (surprise!) 2006-04-25 20:12:06 +00:00
AppMisc.h Introduced generalized versions of get_app_path() and get_app_ref() returning the path/ref for an arbitrary team. 2005-07-15 12:15:21 +00:00
AppServerLink.h * Added BString version of LinkReceiver::ReadString(). 2005-11-07 16:14:05 +00:00
AreaLink.h add newline to end of file 2003-04-14 01:56:41 +00:00
ClipboardPrivate.h Use new init_clipboard() function which initializes the global be_clipboard at libbe init time. 2005-01-13 00:50:26 +00:00
DesktopLink.h * Implemented AS_DIRECT_WINDOW_SET_FULLSCREEN so that it sets kWindowScreenFeel 2006-06-09 21:46:40 +00:00
LinkReceiver.h * BView::FillRegion() sends the BRegion data instead of decomposing 2006-04-01 16:56:10 +00:00
LinkSender.h Changed the meaning of the second parameter in AttachString(): it's now the maximum 2005-11-09 18:28:13 +00:00
LooperList.h gcc 3 fixes 2003-08-04 00:46:53 +00:00
MessagePrivate.h First steps at getting drag & drop to work properly. Simple drag & drop (draging Tracker items) should work now. Not sure about the negotiated version (with mimetype exchange). Fixed left behind drag bitmaps. Some cleanup. 2006-04-10 21:22:05 +00:00
MessageUtils.h Applied Michael's patch for MessageUtils.h - this is supposed to fix some 2006-03-13 11:52:28 +00:00
MessengerPrivate.h * reverted Adi's premature changes to BWindow and restored _DetermineTarget() and 2005-11-20 16:24:23 +00:00
PortLink.h Removed unused files like PortMessage.cpp/h and Session.cpp/h. 2005-11-02 12:55:20 +00:00
PortQueue.h Separated PortQueue and PortMessage into separate files. 2003-06-22 17:17:40 +00:00
RegistrarDefs.h BRoster::Launch() eventually launches the application in question 2006-08-31 17:54:16 +00:00
RegistrarThread.h Removed an old and inaccurate comment I just noticed. 2002-09-29 07:24:56 +00:00
RegistrarThreadManager.h Made kThreadLimit constant public 2002-10-04 04:22:08 +00:00
RosterPrivate.h BRoster::Launch() eventually launches the application in question 2006-08-31 17:54:16 +00:00
Server.h BServer now remembers whether the GUI context has already been initialized, so that InitGUIContext() can be invoked twice without harm. 2005-07-03 16:55:27 +00:00
ServerLink.h * Added LinkReceiver methods that return the length of the string. 2006-02-27 13:09:37 +00:00
ServerMemoryAllocator.h * There is now a server_read_only_memory structure that is placed in a (surprise!) 2006-04-25 20:12:06 +00:00
ServerProtocol.h * Implemented AS_DIRECT_WINDOW_SET_FULLSCREEN so that it sets kWindowScreenFeel 2006-06-09 21:46:40 +00:00
ServerReadOnlyMemory.h * Removed ColorSet, it's no longer needed or used. 2006-04-26 09:03:28 +00:00
SimpleMallocIO.h More optimization for Message2. It now uses a more lightweight BSimpleMallocIO instead of the full blown BMallocIO. This wastes less memory and reduces unnecessary overhead when unflattening. 2005-07-31 11:48:38 +00:00
TokenSpace.h Got rid of that unused and superfluous TokenSpace callback stuff. 2006-04-22 16:29:44 +00:00