diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp index 3a99ed8604d..0b9ac998111 100644 --- a/dom/base/nsGlobalWindow.cpp +++ b/dom/base/nsGlobalWindow.cpp @@ -584,6 +584,20 @@ DialogValueHolder::Get(nsIPrincipal* aSubject, nsIVariant** aResult) return NS_OK; } +void +DialogValueHolder::Get(JSContext* aCx, JS::Handle aScope, + nsIPrincipal* aSubject, + JS::MutableHandle aResult, + mozilla::ErrorResult& aError) +{ + if (aSubject->Subsumes(mOrigin)) { + aError = nsContentUtils::XPConnect()->VariantToJS(aCx, aScope, + mValue, aResult); + } else { + aResult.setUndefined(); + } +} + namespace mozilla { namespace dom { extern uint64_t diff --git a/dom/base/nsGlobalWindow.h b/dom/base/nsGlobalWindow.h index a05668c857e..1952d4eb18c 100644 --- a/dom/base/nsGlobalWindow.h +++ b/dom/base/nsGlobalWindow.h @@ -267,15 +267,7 @@ public: , mValue(aValue) {} nsresult Get(nsIPrincipal* aSubject, nsIVariant** aResult); void Get(JSContext* aCx, JS::Handle aScope, nsIPrincipal* aSubject, - JS::MutableHandle aResult, mozilla::ErrorResult& aError) - { - if (aSubject->Subsumes(mOrigin)) { - aError = nsContentUtils::XPConnect()->VariantToJS(aCx, aScope, - mValue, aResult); - } else { - aResult.setUndefined(); - } - } + JS::MutableHandle aResult, mozilla::ErrorResult& aError); private: virtual ~DialogValueHolder() {}