зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1379243 P1 Make WorkerControlEventTarget implement nsISerialEventTarget. r=baku
This commit is contained in:
Родитель
9eedac7ef8
Коммит
5fe4521ee0
|
@ -1628,7 +1628,7 @@ public:
|
|||
|
||||
BEGIN_WORKERS_NAMESPACE
|
||||
|
||||
class WorkerControlEventTarget final : public nsIEventTarget
|
||||
class WorkerControlEventTarget final : public nsISerialEventTarget
|
||||
{
|
||||
mozilla::Mutex mMutex;
|
||||
WorkerPrivate* mWorkerPrivate;
|
||||
|
@ -1704,7 +1704,8 @@ public:
|
|||
NS_DECL_THREADSAFE_ISUPPORTS
|
||||
};
|
||||
|
||||
NS_IMPL_ISUPPORTS(WorkerControlEventTarget, nsIEventTarget)
|
||||
NS_IMPL_ISUPPORTS(WorkerControlEventTarget, nsIEventTarget,
|
||||
nsISerialEventTarget)
|
||||
|
||||
END_WORKERS_NAMESPACE
|
||||
|
||||
|
@ -5189,7 +5190,7 @@ WorkerPrivate::DispatchToMainThread(already_AddRefed<nsIRunnable> aRunnable,
|
|||
return mMainThreadEventTarget->Dispatch(runnable.forget(), aFlags);
|
||||
}
|
||||
|
||||
nsIEventTarget*
|
||||
nsISerialEventTarget*
|
||||
WorkerPrivate::ControlEventTarget()
|
||||
{
|
||||
return mWorkerControlEventTarget;
|
||||
|
|
|
@ -1461,7 +1461,7 @@ public:
|
|||
// Get an event target that will dispatch runnables as control runnables on
|
||||
// the worker thread. Implement nsICancelableRunnable if you wish to take
|
||||
// action on cancelation.
|
||||
nsIEventTarget*
|
||||
nsISerialEventTarget*
|
||||
ControlEventTarget();
|
||||
|
||||
private:
|
||||
|
|
Загрузка…
Ссылка в новой задаче