323657 Fixing XULRunner bustage by moving nsMacUtils class to nsMacUtilsImpl. r=dbaron sr=dbaron

This commit is contained in:
mark%moxienet.com 2006-02-18 21:09:59 +00:00
parent 09d1584383
commit 6127078dc6
4 changed files with 16 additions and 16 deletions

View File

@ -72,7 +72,7 @@ REQUIRES += boehm
endif
ifeq ($(OS_ARCH),Darwin)
CPPSRCS += nsMacUtils.cpp
CPPSRCS += nsMacUtilsImpl.cpp
endif
EXPORTS = \

View File

@ -35,19 +35,19 @@
*
* ***** END LICENSE BLOCK ***** */
#include "nsMacUtils.h"
#include "nsMacUtilsImpl.h"
#include <CoreFoundation/CoreFoundation.h>
#include <fcntl.h>
#include <unistd.h>
#include <mach-o/fat.h>
NS_IMPL_ISUPPORTS1(nsMacUtils, nsIMacUtils)
NS_IMPL_ISUPPORTS1(nsMacUtilsImpl, nsIMacUtils)
/* readonly attribute boolean isUniversalBinary; */
// True when the main executable is a fat file supporting at least
// ppc and x86 (universal binary).
NS_IMETHODIMP nsMacUtils::GetIsUniversalBinary(PRBool *aIsUniversalBinary)
NS_IMETHODIMP nsMacUtilsImpl::GetIsUniversalBinary(PRBool *aIsUniversalBinary)
{
static PRBool sInitialized = PR_FALSE,
sIsUniversalBinary = PR_FALSE;

View File

@ -35,28 +35,28 @@
*
* ***** END LICENSE BLOCK ***** */
#ifndef nsMacUtils_h___
#define nsMacUtils_h___
#ifndef nsMacUtilsImpl_h___
#define nsMacUtilsImpl_h___
#include "nsIMacUtils.h"
class nsMacUtils : public nsIMacUtils
class nsMacUtilsImpl : public nsIMacUtils
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSIMACUTILS
nsMacUtils() {}
nsMacUtilsImpl() {}
private:
~nsMacUtils() {}
~nsMacUtilsImpl() {}
};
// Global singleton service
// 697BD3FD-43E5-41CE-AD5E-C339175C0818
#define NS_MACUTILS_CLASSNAME "Mac OS X Utilities"
#define NS_MACUTILS_CID \
#define NS_MACUTILSIMPL_CLASSNAME "Mac OS X Utilities"
#define NS_MACUTILSIMPL_CID \
{0x697BD3FD, 0x43E5, 0x41CE, {0xAD, 0x5E, 0xC3, 0x39, 0x17, 0x5C, 0x08, 0x18}}
#define NS_MACUTILS_CONTRACTID "@mozilla.org/xpcom/mac-utils;1"
#define NS_MACUTILSIMPL_CONTRACTID "@mozilla.org/xpcom/mac-utils;1"
#endif /* nsMacUtils_h___ */
#endif /* nsMacUtilsImpl_h___ */

View File

@ -131,7 +131,7 @@ NS_DECL_CLASSINFO(nsStringInputStream)
#endif
#ifdef XP_MACOSX
#include "nsMacUtils.h"
#include "nsMacUtilsImpl.h"
#endif
#include <locale.h>
@ -222,7 +222,7 @@ NS_GENERIC_AGGREGATED_CONSTRUCTOR_INIT(nsProperties, Init)
NS_GENERIC_FACTORY_CONSTRUCTOR(nsUUIDGenerator)
#ifdef XP_MACOSX
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMacUtils)
NS_GENERIC_FACTORY_CONSTRUCTOR(nsMacUtilsImpl)
#endif
static NS_METHOD
@ -419,7 +419,7 @@ static const nsModuleComponentInfo components[] = {
#endif
#ifdef XP_MACOSX
COMPONENT(MACUTILS, nsMacUtilsConstructor),
COMPONENT(MACUTILSIMPL, nsMacUtilsImplConstructor),
#endif
};