Skip to content
This repository has been archived by the owner on Aug 4, 2022. It is now read-only.

Commit

Permalink
Bug 1376981 - Label nsBindingManager::PostProcessAttachedQueueEvent (…
Browse files Browse the repository at this point in the history
…r=smaug)

MozReview-Commit-ID: G0xxNwtXsex
  • Loading branch information
bill-mccloskey committed Jul 3, 2017
1 parent 1278473 commit 882897a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions dom/xbl/nsBindingManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -351,11 +351,15 @@ nsBindingManager::AddToAttachedQueue(nsXBLBinding* aBinding)
void
nsBindingManager::PostProcessAttachedQueueEvent()
{
MOZ_ASSERT(NS_IsMainThread());
if (!mDocument) {
return;
}
mProcessAttachedQueueEvent =
NewRunnableMethod("nsBindingManager::DoProcessAttachedQueue",
this, &nsBindingManager::DoProcessAttachedQueue);
nsresult rv = NS_DispatchToCurrentThread(mProcessAttachedQueueEvent);
if (NS_SUCCEEDED(rv) && mDocument) {
nsresult rv = mDocument->EventTargetFor(TaskCategory::Other)->Dispatch(do_AddRef(mProcessAttachedQueueEvent));
if (NS_SUCCEEDED(rv)) {
mDocument->BlockOnload();
}
}
Expand Down

0 comments on commit 882897a

Please sign in to comment.