fix build bustage, nsIScriptContextOwner.h can't be found except on XP_MAC. Will land on other platforms eventually.

This commit is contained in:
beard%netscape.com 1999-03-24 07:16:41 +00:00
Родитель 381009c0a6
Коммит 0a6c31a062
2 изменённых файлов: 8 добавлений и 0 удалений

Просмотреть файл

@ -27,10 +27,12 @@
#include "nsFileSpec.h" #include "nsFileSpec.h"
#include "nsCOMPtr.h" #include "nsCOMPtr.h"
#if defined(OJI) && defined(XP_MAC)
#include "nsIDocument.h" #include "nsIDocument.h"
#include "nsIScriptContextOwner.h" #include "nsIScriptContextOwner.h"
#include "nsIScriptGlobalObject.h" #include "nsIScriptGlobalObject.h"
#include "nsIScriptObjectOwner.h" #include "nsIScriptObjectOwner.h"
#endif
#ifdef XP_PC #ifdef XP_PC
#include "windows.h" #include "windows.h"
@ -760,6 +762,7 @@ NS_IMETHODIMP nsPluginInstancePeerImpl::GetJSWindow(JSObject* *outJSWindow)
{ {
*outJSWindow = NULL; *outJSWindow = NULL;
nsresult rv = NS_ERROR_FAILURE; nsresult rv = NS_ERROR_FAILURE;
#if defined(OJI) && defined(XP_MAC)
nsIDocument* document = nsnull; nsIDocument* document = nsnull;
if (mOwner->GetDocument(&document) == NS_OK) { if (mOwner->GetDocument(&document) == NS_OK) {
nsIScriptContextOwner* contextOwner = document->GetScriptContextOwner(); nsIScriptContextOwner* contextOwner = document->GetScriptContextOwner();
@ -782,6 +785,7 @@ NS_IMETHODIMP nsPluginInstancePeerImpl::GetJSWindow(JSObject* *outJSWindow)
} }
NS_RELEASE(document); NS_RELEASE(document);
} }
#endif
return rv; return rv;
} }

Просмотреть файл

@ -27,10 +27,12 @@
#include "nsFileSpec.h" #include "nsFileSpec.h"
#include "nsCOMPtr.h" #include "nsCOMPtr.h"
#if defined(OJI) && defined(XP_MAC)
#include "nsIDocument.h" #include "nsIDocument.h"
#include "nsIScriptContextOwner.h" #include "nsIScriptContextOwner.h"
#include "nsIScriptGlobalObject.h" #include "nsIScriptGlobalObject.h"
#include "nsIScriptObjectOwner.h" #include "nsIScriptObjectOwner.h"
#endif
#ifdef XP_PC #ifdef XP_PC
#include "windows.h" #include "windows.h"
@ -760,6 +762,7 @@ NS_IMETHODIMP nsPluginInstancePeerImpl::GetJSWindow(JSObject* *outJSWindow)
{ {
*outJSWindow = NULL; *outJSWindow = NULL;
nsresult rv = NS_ERROR_FAILURE; nsresult rv = NS_ERROR_FAILURE;
#if defined(OJI) && defined(XP_MAC)
nsIDocument* document = nsnull; nsIDocument* document = nsnull;
if (mOwner->GetDocument(&document) == NS_OK) { if (mOwner->GetDocument(&document) == NS_OK) {
nsIScriptContextOwner* contextOwner = document->GetScriptContextOwner(); nsIScriptContextOwner* contextOwner = document->GetScriptContextOwner();
@ -782,6 +785,7 @@ NS_IMETHODIMP nsPluginInstancePeerImpl::GetJSWindow(JSObject* *outJSWindow)
} }
NS_RELEASE(document); NS_RELEASE(document);
} }
#endif
return rv; return rv;
} }