diff --git a/dom/webauthn/ScopedCredential.cpp b/dom/webauthn/ScopedCredential.cpp index 6f58a584c29b..09e3c1fff8ce 100644 --- a/dom/webauthn/ScopedCredential.cpp +++ b/dom/webauthn/ScopedCredential.cpp @@ -19,7 +19,7 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ScopedCredential) NS_INTERFACE_MAP_ENTRY(nsISupports) NS_INTERFACE_MAP_END -ScopedCredential::ScopedCredential(WebAuthentication* aParent) +ScopedCredential::ScopedCredential(nsPIDOMWindowInner* aParent) : mParent(aParent) , mType(ScopedCredentialType::ScopedCred) {} diff --git a/dom/webauthn/ScopedCredential.h b/dom/webauthn/ScopedCredential.h index 138337f28df4..47e450cb9c1f 100644 --- a/dom/webauthn/ScopedCredential.h +++ b/dom/webauthn/ScopedCredential.h @@ -27,13 +27,13 @@ public: NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ScopedCredential) public: - explicit ScopedCredential(WebAuthentication* aParent); + explicit ScopedCredential(nsPIDOMWindowInner* aParent); protected: ~ScopedCredential(); public: - WebAuthentication* + nsISupports* GetParentObject() const { return mParent; @@ -55,7 +55,7 @@ public: SetId(CryptoBuffer& aBuffer); private: - RefPtr mParent; + nsCOMPtr mParent; CryptoBuffer mIdBuffer; ScopedCredentialType mType; }; diff --git a/dom/webauthn/ScopedCredentialInfo.cpp b/dom/webauthn/ScopedCredentialInfo.cpp index 0b26a9c03006..fbe3472a2b00 100644 --- a/dom/webauthn/ScopedCredentialInfo.cpp +++ b/dom/webauthn/ScopedCredentialInfo.cpp @@ -19,7 +19,7 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ScopedCredentialInfo) NS_INTERFACE_MAP_ENTRY(nsISupports) NS_INTERFACE_MAP_END -ScopedCredentialInfo::ScopedCredentialInfo(WebAuthentication* aParent) +ScopedCredentialInfo::ScopedCredentialInfo(nsPIDOMWindowInner* aParent) : mParent(aParent) {} @@ -59,6 +59,5 @@ ScopedCredentialInfo::SetAttestation(RefPtr aAttestation) mAttestation = aAttestation; } - } // namespace dom } // namespace mozilla diff --git a/dom/webauthn/ScopedCredentialInfo.h b/dom/webauthn/ScopedCredentialInfo.h index c3bb71ebbd1e..cc7a952604ac 100644 --- a/dom/webauthn/ScopedCredentialInfo.h +++ b/dom/webauthn/ScopedCredentialInfo.h @@ -35,13 +35,13 @@ public: NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ScopedCredentialInfo) public: - explicit ScopedCredentialInfo(WebAuthentication* aParent); + explicit ScopedCredentialInfo(nsPIDOMWindowInner* aParent); protected: ~ScopedCredentialInfo(); public: - WebAuthentication* + nsISupports* GetParentObject() const { return mParent; @@ -63,7 +63,7 @@ public: SetAttestation(RefPtr); private: - RefPtr mParent; + nsCOMPtr mParent; RefPtr mAttestation; RefPtr mCredential; }; diff --git a/dom/webauthn/WebAuthnAssertion.cpp b/dom/webauthn/WebAuthnAssertion.cpp index 937d3299466b..f0c30659524b 100644 --- a/dom/webauthn/WebAuthnAssertion.cpp +++ b/dom/webauthn/WebAuthnAssertion.cpp @@ -19,7 +19,7 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(WebAuthnAssertion) NS_INTERFACE_MAP_ENTRY(nsISupports) NS_INTERFACE_MAP_END -WebAuthnAssertion::WebAuthnAssertion(WebAuthentication* aParent) +WebAuthnAssertion::WebAuthnAssertion(nsPIDOMWindowInner* aParent) : mParent(aParent) {} diff --git a/dom/webauthn/WebAuthnAssertion.h b/dom/webauthn/WebAuthnAssertion.h index 7d9fac9c0879..079f0b0370e8 100644 --- a/dom/webauthn/WebAuthnAssertion.h +++ b/dom/webauthn/WebAuthnAssertion.h @@ -33,13 +33,13 @@ public: NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(WebAuthnAssertion) public: - explicit WebAuthnAssertion(WebAuthentication* aParent); + explicit WebAuthnAssertion(nsPIDOMWindowInner* aParent); protected: ~WebAuthnAssertion(); public: - WebAuthentication* + nsPIDOMWindowInner* GetParentObject() const { return mParent; @@ -73,7 +73,7 @@ public: SetSignature(CryptoBuffer& aBuffer); private: - RefPtr mParent; + nsCOMPtr mParent; RefPtr mCredential; CryptoBuffer mAuthenticatorData; CryptoBuffer mClientData; diff --git a/dom/webauthn/WebAuthnAttestation.cpp b/dom/webauthn/WebAuthnAttestation.cpp index f5b23021d240..6504226bc7b5 100644 --- a/dom/webauthn/WebAuthnAttestation.cpp +++ b/dom/webauthn/WebAuthnAttestation.cpp @@ -19,7 +19,7 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(WebAuthnAttestation) NS_INTERFACE_MAP_ENTRY(nsISupports) NS_INTERFACE_MAP_END -WebAuthnAttestation::WebAuthnAttestation(WebAuthentication* aParent) +WebAuthnAttestation::WebAuthnAttestation(nsPIDOMWindowInner* aParent) : mParent(aParent) {} @@ -57,8 +57,6 @@ void WebAuthnAttestation::GetAttestation(JSContext* aCx, JS::MutableHandle aRetVal) const { - // JS::RootedObject obj(aCx); - // obj.set(); aRetVal.setObject(*mAttestation.ToUint8Array(aCx)); } diff --git a/dom/webauthn/WebAuthnAttestation.h b/dom/webauthn/WebAuthnAttestation.h index 24750653fe5f..6a2479b3236e 100644 --- a/dom/webauthn/WebAuthnAttestation.h +++ b/dom/webauthn/WebAuthnAttestation.h @@ -26,13 +26,13 @@ public: NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(WebAuthnAttestation) public: - explicit WebAuthnAttestation(WebAuthentication* aParent); + explicit WebAuthnAttestation(nsPIDOMWindowInner* aParent); protected: ~WebAuthnAttestation(); public: - WebAuthentication* + nsISupports* GetParentObject() const { return mParent; @@ -66,7 +66,7 @@ public: SetAttestation(CryptoBuffer& aBuffer); private: - RefPtr mParent; + nsCOMPtr mParent; nsString mFormat; CryptoBuffer mClientData; CryptoBuffer mAuthenticatorData;