mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Merge missed nsChromeRegistry change from m-c and fix busted content-process XPCOM/chromium event loop.
This commit is contained in:
parent
58d5c92c00
commit
2877589e40
@ -198,7 +198,7 @@ nsChromeRegistryChrome::Init()
|
||||
}
|
||||
}
|
||||
|
||||
nsCOMPtr<nsIObserverService> obsService (do_GetService("@mozilla.org/observer-service;1"));
|
||||
nsCOMPtr<nsIObserverService> obsService = mozilla::services::GetObserverService();
|
||||
if (obsService) {
|
||||
obsService->AddObserver(this, "command-line-startup", PR_TRUE);
|
||||
obsService->AddObserver(this, "profile-initial-state", PR_TRUE);
|
||||
|
@ -442,7 +442,8 @@ class MessageLoopForUI : public MessageLoop {
|
||||
#ifdef CHROMIUM_MOZILLA_BUILD
|
||||
Type type = loop->type();
|
||||
DCHECK(type == MessageLoop::TYPE_UI ||
|
||||
type == MessageLoop::TYPE_MOZILLA_UI);
|
||||
type == MessageLoop::TYPE_MOZILLA_UI ||
|
||||
type == MessageLoop::TYPE_MOZILLA_CHILD);
|
||||
#else
|
||||
DCHECK_EQ(MessageLoop::TYPE_UI, loop->type());
|
||||
#endif
|
||||
|
@ -347,8 +347,19 @@ XRE_InitChildProcess(int aArgc,
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
|
||||
MessageLoop::Type uiLoopType;
|
||||
switch (aProcess) {
|
||||
case GeckoProcessType_Content:
|
||||
// Content processes need the XPCOM/chromium frankenventloop
|
||||
uiLoopType = MessageLoop::TYPE_MOZILLA_CHILD;
|
||||
break;
|
||||
default:
|
||||
uiLoopType = MessageLoop::TYPE_UI;
|
||||
break;
|
||||
}
|
||||
|
||||
// Associate this thread with a UI MessageLoop
|
||||
MessageLoopForUI uiMessageLoop;
|
||||
MessageLoop uiMessageLoop(uiLoopType);
|
||||
{
|
||||
nsAutoPtr<ProcessChild> process;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user