GlobalWindowImpl::QueryInterface(const nsIID& aIID, void** aInstancePtrResult)
NavigatorImpl::QueryInterface(const nsIID& aIID, void** aInstancePtrResult)
GlobalWindowImpl::QueryInterface(const nsIID& aIID,                                 void** aInstancePtrResult){  NS_PRECONDITION(nsnull != aInstancePtrResult, "null pointer");  if (nsnull == aInstancePtrResult) {    return NS_ERROR_NULL_POINTER;  }  if (aIID.Equals(kIScriptObjectOwnerIID)) {    *aInstancePtrResult = (void*) ((nsIScriptObjectOwner*)this);    AddRef();    return NS_OK;  }  if (aIID.Equals(kIScriptGlobalObjectIID)) {    *aInstancePtrResult = (void*) ((nsIScriptGlobalObject*)this);    AddRef();    return NS_OK;  }  if (aIID.Equals(kIDOMWindowIID)) {    *aInstancePtrResult = (void*) ((nsIDOMWindow*)this);    AddRef();    return NS_OK;  }  if (aIID.Equals(kISupportsIID)) {    *aInstancePtrResult = (void*)(nsISupports*)(nsIScriptGlobalObject*)this;    AddRef();    return NS_OK;  }  return NS_NOINTERFACE;}