Bug 1111076 - Get rid of nsIScriptContext::GC(). r=smaug
This commit is contained in:
@@ -2698,7 +2698,7 @@ nsGlobalWindow::SetNewDocument(nsIDocument* aDocument,
|
||||
newInnerWindow->mChromeEventHandler = mChromeEventHandler;
|
||||
}
|
||||
|
||||
mContext->GC(JS::gcreason::SET_NEW_DOCUMENT);
|
||||
nsJSContext::PokeGC(JS::gcreason::SET_NEW_DOCUMENT);
|
||||
mContext->DidInitializeContext();
|
||||
|
||||
// We wait to fire the debugger hook until the window is all set up and hooked
|
||||
@@ -2921,7 +2921,7 @@ nsGlobalWindow::DetachFromDocShell()
|
||||
mChromeEventHandler = nullptr; // force release now
|
||||
|
||||
if (mContext) {
|
||||
mContext->GC(JS::gcreason::SET_DOC_SHELL);
|
||||
nsJSContext::PokeGC(JS::gcreason::SET_DOC_SHELL);
|
||||
mContext = nullptr;
|
||||
}
|
||||
|
||||
|
||||
@@ -27,8 +27,8 @@ class nsIDOMWindow;
|
||||
class nsIURI;
|
||||
|
||||
#define NS_ISCRIPTCONTEXT_IID \
|
||||
{ 0x274840b6, 0x7349, 0x4798, \
|
||||
{ 0xbe, 0x24, 0xbd, 0x75, 0xa6, 0x46, 0x99, 0xb7 } }
|
||||
{ 0x901f0d5e, 0x217a, 0x45fa, \
|
||||
{ 0x9a, 0xca, 0x45, 0x0f, 0xe7, 0x2f, 0x10, 0x9a } }
|
||||
|
||||
class nsIOffThreadScriptReceiver;
|
||||
|
||||
@@ -67,14 +67,6 @@ public:
|
||||
*/
|
||||
virtual bool IsContextInitialized() = 0;
|
||||
|
||||
/**
|
||||
* For garbage collected systems, do a synchronous collection pass.
|
||||
* May be a no-op on other systems
|
||||
*
|
||||
* @return NS_OK if the method is successful
|
||||
*/
|
||||
virtual void GC(JS::gcreason::Reason aReason) = 0;
|
||||
|
||||
// SetProperty is suspect and jst believes should not be needed. Currenly
|
||||
// used only for "arguments".
|
||||
virtual nsresult SetProperty(JS::Handle<JSObject*> aTarget,
|
||||
@@ -134,4 +126,3 @@ public:
|
||||
NS_DEFINE_STATIC_IID_ACCESSOR(nsIOffThreadScriptReceiver, NS_IOFFTHREADSCRIPTRECEIVER_IID)
|
||||
|
||||
#endif // nsIScriptContext_h__
|
||||
|
||||
|
||||
@@ -2302,12 +2302,6 @@ nsJSContext::KillICCTimer()
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
nsJSContext::GC(JS::gcreason::Reason aReason)
|
||||
{
|
||||
PokeGC(aReason);
|
||||
}
|
||||
|
||||
class NotifyGCEndRunnable : public nsRunnable
|
||||
{
|
||||
nsString mMessage;
|
||||
|
||||
@@ -125,8 +125,6 @@ public:
|
||||
// Calling LikelyShortLivingObjectCreated() makes a GC more likely.
|
||||
static void LikelyShortLivingObjectCreated();
|
||||
|
||||
virtual void GC(JS::gcreason::Reason aReason) MOZ_OVERRIDE;
|
||||
|
||||
static uint32_t CleanupsSinceLastGC();
|
||||
|
||||
nsIScriptGlobalObject* GetCachedGlobalObject()
|
||||
|
||||
Reference in New Issue
Block a user