зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1227015 P2 Move mScriptSpec from registration job into script job base. r=ehsan
This commit is contained in:
Родитель
48d0ba6249
Коммит
3e15fcaa7d
|
@ -968,13 +968,17 @@ protected:
|
||||||
class ServiceWorkerScriptJobBase : public ServiceWorkerJobBase
|
class ServiceWorkerScriptJobBase : public ServiceWorkerJobBase
|
||||||
{
|
{
|
||||||
protected:
|
protected:
|
||||||
|
const nsCString mScriptSpec;
|
||||||
|
|
||||||
ServiceWorkerScriptJobBase(ServiceWorkerJobQueue* aQueue,
|
ServiceWorkerScriptJobBase(ServiceWorkerJobQueue* aQueue,
|
||||||
ServiceWorkerJob::Type aJobType,
|
ServiceWorkerJob::Type aJobType,
|
||||||
ServiceWorkerUpdateFinishCallback* aCallback,
|
ServiceWorkerUpdateFinishCallback* aCallback,
|
||||||
ServiceWorkerRegistrationInfo* aRegistration,
|
ServiceWorkerRegistrationInfo* aRegistration,
|
||||||
ServiceWorkerInfo* aServiceWorkerInfo)
|
ServiceWorkerInfo* aServiceWorkerInfo,
|
||||||
|
const nsACString& aScriptSpec)
|
||||||
: ServiceWorkerJobBase(aQueue, aJobType, aCallback, aRegistration,
|
: ServiceWorkerJobBase(aQueue, aJobType, aCallback, aRegistration,
|
||||||
aServiceWorkerInfo)
|
aServiceWorkerInfo)
|
||||||
|
, mScriptSpec(aScriptSpec)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1051,7 +1055,8 @@ public:
|
||||||
ServiceWorkerRegistrationInfo* aRegistration,
|
ServiceWorkerRegistrationInfo* aRegistration,
|
||||||
ServiceWorkerInfo* aServiceWorkerInfo)
|
ServiceWorkerInfo* aServiceWorkerInfo)
|
||||||
: ServiceWorkerScriptJobBase(aQueue, Type::InstallJob, aCallback,
|
: ServiceWorkerScriptJobBase(aQueue, Type::InstallJob, aCallback,
|
||||||
aRegistration, aServiceWorkerInfo)
|
aRegistration, aServiceWorkerInfo,
|
||||||
|
EmptyCString())
|
||||||
{
|
{
|
||||||
MOZ_ASSERT(aRegistration);
|
MOZ_ASSERT(aRegistration);
|
||||||
}
|
}
|
||||||
|
@ -1182,7 +1187,6 @@ class ServiceWorkerRegisterJob final : public ServiceWorkerScriptJobBase,
|
||||||
friend class ContinueUpdateRunnable;
|
friend class ContinueUpdateRunnable;
|
||||||
|
|
||||||
nsCString mScope;
|
nsCString mScope;
|
||||||
nsCString mScriptSpec;
|
|
||||||
nsCOMPtr<nsIPrincipal> mPrincipal;
|
nsCOMPtr<nsIPrincipal> mPrincipal;
|
||||||
nsCOMPtr<nsILoadGroup> mLoadGroup;
|
nsCOMPtr<nsILoadGroup> mLoadGroup;
|
||||||
|
|
||||||
|
@ -1200,9 +1204,8 @@ public:
|
||||||
nsIPrincipal* aPrincipal,
|
nsIPrincipal* aPrincipal,
|
||||||
nsILoadGroup* aLoadGroup)
|
nsILoadGroup* aLoadGroup)
|
||||||
: ServiceWorkerScriptJobBase(aQueue, Type::RegisterJob, aCallback, nullptr,
|
: ServiceWorkerScriptJobBase(aQueue, Type::RegisterJob, aCallback, nullptr,
|
||||||
nullptr)
|
nullptr, aScriptSpec)
|
||||||
, mScope(aScope)
|
, mScope(aScope)
|
||||||
, mScriptSpec(aScriptSpec)
|
|
||||||
, mPrincipal(aPrincipal)
|
, mPrincipal(aPrincipal)
|
||||||
, mLoadGroup(aLoadGroup)
|
, mLoadGroup(aLoadGroup)
|
||||||
{
|
{
|
||||||
|
@ -1216,7 +1219,7 @@ public:
|
||||||
ServiceWorkerRegistrationInfo* aRegistration,
|
ServiceWorkerRegistrationInfo* aRegistration,
|
||||||
ServiceWorkerUpdateFinishCallback* aCallback)
|
ServiceWorkerUpdateFinishCallback* aCallback)
|
||||||
: ServiceWorkerScriptJobBase(aQueue, Type::UpdateJob, aCallback,
|
: ServiceWorkerScriptJobBase(aQueue, Type::UpdateJob, aCallback,
|
||||||
aRegistration, nullptr)
|
aRegistration, nullptr, EmptyCString())
|
||||||
{
|
{
|
||||||
AssertIsOnMainThread();
|
AssertIsOnMainThread();
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче