Bug 1189090 - Rework the nsISupports implementation in the ScopeCheckingGetCallback and its subclasses; r=nsm

This commit is contained in:
Ehsan Akhgari 2015-07-29 21:56:30 -04:00
parent d3d99035d8
commit ced20cc4d7

View File

@ -69,8 +69,6 @@ class ScopeCheckingGetCallback : public nsINotificationStorageCallback
{
const nsString mScope;
public:
NS_DECL_ISUPPORTS
explicit ScopeCheckingGetCallback(const nsAString& aScope)
: mScope(aScope)
{}
@ -121,8 +119,6 @@ protected:
nsTArray<NotificationStrings> mStrings;
};
NS_IMPL_ISUPPORTS(ScopeCheckingGetCallback, nsINotificationStorageCallback)
class NotificationStorageCallback final : public ScopeCheckingGetCallback
{
public:
@ -190,7 +186,9 @@ NS_IMPL_CYCLE_COLLECTING_RELEASE(NotificationStorageCallback)
NS_IMPL_CYCLE_COLLECTION(NotificationStorageCallback, mWindow, mPromise);
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(NotificationStorageCallback)
NS_INTERFACE_MAP_END_INHERITING(ScopeCheckingGetCallback)
NS_INTERFACE_MAP_ENTRY(nsINotificationStorageCallback)
NS_INTERFACE_MAP_ENTRY(nsISupports)
NS_INTERFACE_MAP_END
class NotificationGetRunnable final : public nsRunnable
{
@ -1766,7 +1764,7 @@ class WorkerGetCallback final : public ScopeCheckingGetCallback
{
nsRefPtr<PromiseWorkerProxy> mPromiseProxy;
public:
NS_DECL_ISUPPORTS_INHERITED
NS_DECL_ISUPPORTS
WorkerGetCallback(PromiseWorkerProxy* aProxy, const nsAString& aScope)
: ScopeCheckingGetCallback(aScope), mPromiseProxy(aProxy)
@ -1808,7 +1806,7 @@ private:
{}
};
NS_IMPL_ISUPPORTS_INHERITED0(WorkerGetCallback, ScopeCheckingGetCallback)
NS_IMPL_ISUPPORTS(WorkerGetCallback, nsINotificationStorageCallback)
class WorkerGetRunnable final : public nsRunnable
{