Bug 796938 - Remove GetDynamicScriptContext API. r=smaug
authorBobby Holley <bobbyholley@gmail.com>
Tue, 19 Aug 2014 12:02:08 -0700
changeset 214766 25fff355894f5c443be8e13ecb8428836b563ac2
parent 214765 129edf96797ef4ddec4a72e35a0d62a64ebe8e99
child 214767 587ef44dcc8e0ca642d0c616dcfa63766a01525f
push idunknown
push userunknown
push dateunknown
reviewerssmaug
bugs796938
milestone34.0a1
Bug 796938 - Remove GetDynamicScriptContext API. r=smaug
dom/base/nsJSUtils.cpp
dom/base/nsJSUtils.h
--- a/dom/base/nsJSUtils.cpp
+++ b/dom/base/nsJSUtils.cpp
@@ -58,22 +58,16 @@ nsJSUtils::GetStaticScriptContext(JSObje
 {
   nsIScriptGlobalObject *nativeGlobal = GetStaticScriptGlobal(aObj);
   if (!nativeGlobal)
     return nullptr;
 
   return nativeGlobal->GetScriptContext();
 }
 
-nsIScriptContext *
-nsJSUtils::GetDynamicScriptContext(JSContext *aContext)
-{
-  return GetScriptContextFromJSContext(aContext);
-}
-
 uint64_t
 nsJSUtils::GetCurrentlyRunningCodeInnerWindowID(JSContext *aContext)
 {
   if (!aContext)
     return 0;
 
   uint64_t innerWindowID = 0;
 
--- a/dom/base/nsJSUtils.h
+++ b/dom/base/nsJSUtils.h
@@ -27,18 +27,16 @@ class nsJSUtils
 public:
   static bool GetCallingLocation(JSContext* aContext, const char* *aFilename,
                                  uint32_t* aLineno);
 
   static nsIScriptGlobalObject *GetStaticScriptGlobal(JSObject* aObj);
 
   static nsIScriptContext *GetStaticScriptContext(JSObject* aObj);
 
-  static nsIScriptContext *GetDynamicScriptContext(JSContext *aContext);
-
   /**
    * Retrieve the inner window ID based on the given JSContext.
    *
    * @param JSContext aContext
    *        The JSContext from which you want to find the inner window ID.
    *
    * @returns uint64_t the inner window ID.
    */