зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1212288 - Make ImageContainer::AllocateProducerID callable on all threads; r=roc
This commit is contained in:
Родитель
daeb9f7f13
Коммит
724e8623c9
|
@ -673,12 +673,11 @@ ImageContainer::NotifyComposite(const ImageCompositeNotification& aNotification)
|
|||
}
|
||||
}
|
||||
|
||||
static ImageContainer::ProducerID sProducerID = 0;
|
||||
|
||||
ImageContainer::ProducerID
|
||||
ImageContainer::AllocateProducerID()
|
||||
{
|
||||
NS_ASSERTION(NS_IsMainThread(), "Should be on main thread.");
|
||||
// Callable on all threads.
|
||||
static Atomic<ImageContainer::ProducerID> sProducerID(0u);
|
||||
return ++sProducerID;
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче