зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1660555 - Make |AbortFollower| actually inherit from |nsISupports|. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D92323
This commit is contained in:
Родитель
1e16fcd4c3
Коммит
1be0ced0e4
|
@ -19,10 +19,8 @@ class AbortSignalImpl;
|
|||
|
||||
// This class must be implemented by objects who want to follow a
|
||||
// AbortSignalImpl.
|
||||
class AbortFollower {
|
||||
class AbortFollower : public nsISupports {
|
||||
public:
|
||||
NS_INLINE_DECL_PURE_VIRTUAL_REFCOUNTING
|
||||
|
||||
virtual void RunAbortAlgorithm() = 0;
|
||||
|
||||
void Follow(AbortSignalImpl* aSignal);
|
||||
|
|
|
@ -141,7 +141,7 @@ class AbortSignalProxy final : public AbortFollower {
|
|||
};
|
||||
|
||||
public:
|
||||
NS_INLINE_DECL_THREADSAFE_REFCOUNTING(AbortSignalProxy, override)
|
||||
NS_DECL_THREADSAFE_ISUPPORTS
|
||||
|
||||
AbortSignalProxy(AbortSignalImpl* aSignalImpl,
|
||||
nsIEventTarget* aMainThreadEventTarget)
|
||||
|
@ -180,6 +180,8 @@ class AbortSignalProxy final : public AbortFollower {
|
|||
}
|
||||
};
|
||||
|
||||
NS_IMPL_ISUPPORTS0(AbortSignalProxy)
|
||||
|
||||
class WorkerFetchResolver final : public FetchDriverObserver {
|
||||
// Thread-safe:
|
||||
RefPtr<PromiseWorkerProxy> mPromiseProxy;
|
||||
|
|
|
@ -122,8 +122,9 @@ nsresult ExtractByteStreamFromBody(const fetch::ResponseBodyInit& aBodyInit,
|
|||
template <class Derived>
|
||||
class FetchBody : public BodyStreamHolder, public AbortFollower {
|
||||
public:
|
||||
using BodyStreamHolder::AddRef;
|
||||
using BodyStreamHolder::Release;
|
||||
using BodyStreamHolder::QueryInterface;
|
||||
|
||||
NS_INLINE_DECL_REFCOUNTING_INHERITED(FetchBody, BodyStreamHolder)
|
||||
|
||||
bool GetBodyUsed(ErrorResult& aRv) const;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче