mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 19:35:51 +00:00
parent
0cdc5f46fe
commit
7863bcb388
@ -28,19 +28,19 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef _IMPL_NS_COM
|
#ifdef _IMPL_NS_COM
|
||||||
#if defined(XP_PC) && !defined(XP_OS2)
|
#if defined(XP_WIN)
|
||||||
#define NS_COM _declspec(dllexport)
|
#define NS_COM _declspec(dllexport)
|
||||||
#elif defined(XP_MAC)
|
#elif defined(XP_MAC)
|
||||||
#define NS_COM __declspec(export)
|
#define NS_COM __declspec(export)
|
||||||
#else /* !XP_PC */
|
#else /* !XP_WIN */
|
||||||
#define NS_COM
|
#define NS_COM
|
||||||
#endif /* !XP_PC */
|
#endif /* !XP_WIN */
|
||||||
#else /* !_IMPL_NS_COM */
|
#else /* !_IMPL_NS_COM */
|
||||||
#if defined(XP_PC) && !defined(XP_OS2)
|
#if defined(XP_WIN)
|
||||||
#define NS_COM _declspec(dllimport)
|
#define NS_COM _declspec(dllimport)
|
||||||
#else /* !XP_PC */
|
#else /* !XP_WIN */
|
||||||
#define NS_COM
|
#define NS_COM
|
||||||
#endif /* !XP_PC */
|
#endif /* !XP_WIN */
|
||||||
#endif /* !_IMPL_NS_COM */
|
#endif /* !_IMPL_NS_COM */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -111,7 +111,7 @@
|
|||||||
#define NS_CALLBACK_(_type, _name) _type (* _name)
|
#define NS_CALLBACK_(_type, _name) _type (* _name)
|
||||||
#define NS_CALLBACK(_name) nsresult (* _name)
|
#define NS_CALLBACK(_name) nsresult (* _name)
|
||||||
|
|
||||||
#endif /* !XP_PC */
|
#endif /* !XP_WIN */
|
||||||
|
|
||||||
/* use these functions to associate get/set methods with a
|
/* use these functions to associate get/set methods with a
|
||||||
C++ member variable
|
C++ member variable
|
||||||
|
@ -264,7 +264,7 @@ NS_ErrorAccordingToNSPR();
|
|||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
#if defined(XP_PC) && !defined(XP_OS2)
|
#if defined(XP_WIN)
|
||||||
#pragma warning(disable: 4251) // 'nsCOMPtr<class nsIInputStream>' needs to have dll-interface to be used by clients of class 'nsInputStream'
|
#pragma warning(disable: 4251) // 'nsCOMPtr<class nsIInputStream>' needs to have dll-interface to be used by clients of class 'nsInputStream'
|
||||||
#pragma warning(disable: 4275) // non dll-interface class 'nsISupports' used as base for dll-interface class 'nsIRDFNode'
|
#pragma warning(disable: 4275) // non dll-interface class 'nsISupports' used as base for dll-interface class 'nsIRDFNode'
|
||||||
#endif
|
#endif
|
||||||
|
@ -65,7 +65,7 @@
|
|||||||
* To maintain binary compatibility of nsISupports with nsIUnknown, we are
|
* To maintain binary compatibility of nsISupports with nsIUnknown, we are
|
||||||
* doing this ifdeffing.
|
* doing this ifdeffing.
|
||||||
*/
|
*/
|
||||||
#if defined(XP_PC) && !defined(XP_OS2) && PR_BYTES_PER_LONG == 4
|
#if defined(XP_WIN) && PR_BYTES_PER_LONG == 4
|
||||||
typedef unsigned long nsrefcnt;
|
typedef unsigned long nsrefcnt;
|
||||||
#else
|
#else
|
||||||
typedef PRUint32 nsrefcnt;
|
typedef PRUint32 nsrefcnt;
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
#include "nsIEventQueueService.h"
|
#include "nsIEventQueueService.h"
|
||||||
#include "nsString.h"
|
#include "nsString.h"
|
||||||
|
|
||||||
#if defined(XP_PC) && !defined(XP_OS2)
|
#if defined(XP_WIN)
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
#define NS_MEMORY_FLUSHER_THREAD
|
#define NS_MEMORY_FLUSHER_THREAD
|
||||||
#elif defined(XP_MAC)
|
#elif defined(XP_MAC)
|
||||||
@ -336,7 +336,7 @@ nsMemoryImpl::HeapMinimize(PRBool aImmediate)
|
|||||||
NS_IMETHODIMP
|
NS_IMETHODIMP
|
||||||
nsMemoryImpl::IsLowMemory(PRBool *result)
|
nsMemoryImpl::IsLowMemory(PRBool *result)
|
||||||
{
|
{
|
||||||
#if defined(XP_PC) && !defined(XP_OS2)
|
#if defined(XP_WIN)
|
||||||
MEMORYSTATUS stat;
|
MEMORYSTATUS stat;
|
||||||
GlobalMemoryStatus(&stat);
|
GlobalMemoryStatus(&stat);
|
||||||
*result = ((float)stat.dwAvailPageFile / stat.dwTotalPageFile) < 0.1;
|
*result = ((float)stat.dwAvailPageFile / stat.dwTotalPageFile) < 0.1;
|
||||||
|
@ -65,7 +65,7 @@
|
|||||||
* To maintain binary compatibility of nsISupports with nsIUnknown, we are
|
* To maintain binary compatibility of nsISupports with nsIUnknown, we are
|
||||||
* doing this ifdeffing.
|
* doing this ifdeffing.
|
||||||
*/
|
*/
|
||||||
#if defined(XP_PC) && !defined(XP_OS2) && PR_BYTES_PER_LONG == 4
|
#if defined(XP_WIN) && PR_BYTES_PER_LONG == 4
|
||||||
typedef unsigned long nsrefcnt;
|
typedef unsigned long nsrefcnt;
|
||||||
#else
|
#else
|
||||||
typedef PRUint32 nsrefcnt;
|
typedef PRUint32 nsrefcnt;
|
||||||
|
Loading…
Reference in New Issue
Block a user