diff --git a/content/xslt/src/base/Makefile.in b/content/xslt/src/base/Makefile.in index f44bf8bc4ad3..fd19ee924522 100644 --- a/content/xslt/src/base/Makefile.in +++ b/content/xslt/src/base/Makefile.in @@ -26,11 +26,12 @@ VPATH = @srcdir@ include $(DEPTH)/config/autoconf.mk -ifndef TX_EXE -MODULE = transformiix REQUIRES = string \ xpcom \ - unicharutil \ + $(NULL) +ifndef TX_EXE +MODULE = transformiix +REQUIRES += unicharutil \ dom \ content \ widget \ diff --git a/content/xslt/src/base/txError.h b/content/xslt/src/base/txError.h index bee429bc4f11..9f1a86101c03 100644 --- a/content/xslt/src/base/txError.h +++ b/content/xslt/src/base/txError.h @@ -44,43 +44,8 @@ * See nsError.h for details. */ -#ifdef TX_EXE - -#include "baseutils.h" - -typedef PRUint32 nsresult; - -#define NS_FAILED(_nsresult) ((_nsresult) & 0x80000000) -#define NS_SUCCEEDED(_nsresult) (!((_nsresult) & 0x80000000)) -#define NS_OK 0 -#define NS_ERROR_INVALID_POINTER ((nsresult) 0x80004003L) -#define NS_ERROR_NULL_POINTER NS_ERROR_INVALID_POINTER -#define NS_ERROR_UNEXPECTED ((nsresult) 0x8000ffffL) -#define NS_ERROR_NOT_IMPLEMENTED ((nsresult) 0x80004001L) -#define NS_ERROR_FAILURE ((nsresult) 0x80004005L) -#define NS_ERROR_OUT_OF_MEMORY ((nsresult) 0x8007000eL) -#define NS_ERROR_ILLEGAL_VALUE ((nsresult) 0x80070057L) -#define NS_ERROR_INVALID_ARG NS_ERROR_ILLEGAL_VALUE - -#define NS_ENSURE_TRUE(value, result) \ - do { \ - if (!(value)) { \ - return (result); \ - } \ - } while(0) - -#define NS_ENSURE_FALSE(value, result) \ - NS_ENSURE_TRUE(!(value), result) - -#define NS_ENSURE_SUCCESS(value, result) \ - NS_ENSURE_TRUE(NS_SUCCEEDED(value), result) - -#else // TX_EXE - #include "nsError.h" -#endif // TX_EXE - #define NS_ERROR_XPATH_EVAL_FAILED NS_ERROR_FAILURE #define NS_ERROR_XPATH_PARSE_FAILED NS_ERROR_FAILURE #define NS_ERROR_XPATH_INVALID_ARG NS_ERROR_INVALID_ARG diff --git a/content/xslt/src/base/txLog.h b/content/xslt/src/base/txLog.h index 1f8851ea710b..f9ae3a4f28ba 100644 --- a/content/xslt/src/base/txLog.h +++ b/content/xslt/src/base/txLog.h @@ -40,38 +40,6 @@ #ifndef TxLog_h__ #define TxLog_h__ -#ifdef TX_EXE - -#ifdef PR_LOGGING -#include - -#define PRLogModuleInfo void -#define PR_NewLogModule(_name) -#define PR_FREE_IF(_name) - -typedef enum PRLogModuleLevel { - PR_LOG_NONE = 0, /* nothing */ - PR_LOG_ALWAYS = 1, /* always printed */ - PR_LOG_ERROR = 2, /* error messages */ - PR_LOG_WARNING = 3, /* warning messages */ - PR_LOG_DEBUG = 4, /* debug messages */ - - PR_LOG_NOTICE = PR_LOG_DEBUG, /* notice messages */ - PR_LOG_WARN = PR_LOG_WARNING, /* warning messages */ - PR_LOG_MIN = PR_LOG_DEBUG, /* minimal debugging messages */ - PR_LOG_MAX = PR_LOG_DEBUG /* maximal debugging messages */ -} PRLogModuleLevel; - - -#define PR_LOG(_name, _level, _message) printf##_message - -#else - -#define PR_LOG(_name, _level, _message) - -#endif - -#else #include "prlog.h" #include "prmem.h" #endif @@ -103,5 +71,3 @@ public: #define TX_LG_DELETE #endif - -#endif diff --git a/content/xslt/src/main/Makefile.in b/content/xslt/src/main/Makefile.in index 4f44b72b24f1..60e5552fbf1e 100644 --- a/content/xslt/src/main/Makefile.in +++ b/content/xslt/src/main/Makefile.in @@ -35,7 +35,9 @@ SIMPLE_PROGRAMS += txXSLTMarkDriver$(BIN_SUFFIX) endif EXTRA_DEPS = $(LIBRARY) -REQUIRES = expat \ +REQUIRES = string \ + xpcom \ + expat \ $(NULL) OBJS =../base/ArrayList.$(OBJ_SUFFIX) \ @@ -131,6 +133,7 @@ CPP_PROG_LINK = 1 EXTRA_LIBS = \ $(LIB_PREFIX)tx.$(LIB_SUFFIX) \ + $(MOZ_COMPONENT_LIBS) \ $(NULL) SHARED_LIBRARY_LIBS = \ $(DIST)/lib/$(LIB_PREFIX)expat_s.$(LIB_SUFFIX) \ diff --git a/content/xslt/src/xml/Makefile.in b/content/xslt/src/xml/Makefile.in index ddc01e90780f..8825d65eac2b 100644 --- a/content/xslt/src/xml/Makefile.in +++ b/content/xslt/src/xml/Makefile.in @@ -26,11 +26,12 @@ VPATH = @srcdir@ include $(DEPTH)/config/autoconf.mk -ifndef TX_EXE MODULE = transformiix REQUIRES = string \ xpcom \ - dom \ + $(NULL) +ifndef TX_EXE +REQUIRES += dom \ content \ widget \ unicharutil \ diff --git a/content/xslt/src/xml/txDOM.h b/content/xslt/src/xml/txDOM.h index b524aff0e98b..ec493f27a771 100644 --- a/content/xslt/src/xml/txDOM.h +++ b/content/xslt/src/xml/txDOM.h @@ -39,7 +39,7 @@ #endif #include "List.h" -#include "TxString.h" +#include "txAtom.h" #include "baseutils.h" #ifndef NULL @@ -64,8 +64,6 @@ class ProcessingInstruction; class EntityReference; class DocumentType; -class txAtom; - /* * NULL string for use by Element::getAttribute() for when the attribute * specified by "name" does not exist, and therefore shoud be "NULL". diff --git a/content/xslt/src/xml/txXMLUtils.cpp b/content/xslt/src/xml/txXMLUtils.cpp index de61fd5f4553..88134f941944 100644 --- a/content/xslt/src/xml/txXMLUtils.cpp +++ b/content/xslt/src/xml/txXMLUtils.cpp @@ -145,10 +145,12 @@ MBool XMLUtils::isValidQName(const String& aName) **/ MBool XMLUtils::isWhitespace(const String& aText) { - PRUint32 size = aText.length(); - PRUint32 i; - for (i = 0; i < size; ++i) { - if (!isWhitespace(aText.charAt(i))) { + const nsAFlatString& text = aText.getConstNSString(); + nsAFlatString::const_char_iterator start, end; + text.BeginReading(start); + text.EndReading(end); + for ( ; start != end; ++start) { + if (!isWhitespace(*start)) { return MB_FALSE; } } diff --git a/content/xslt/src/xpath/Makefile.in b/content/xslt/src/xpath/Makefile.in index 7192c3698e3a..d4512671de41 100644 --- a/content/xslt/src/xpath/Makefile.in +++ b/content/xslt/src/xpath/Makefile.in @@ -26,11 +26,13 @@ VPATH = @srcdir@ include $(DEPTH)/config/autoconf.mk -ifndef TX_EXE MODULE = transformiix REQUIRES = string \ xpcom \ - dom \ + $(NULL) + +ifndef TX_EXE +REQUIRES += dom \ content \ widget \ xpconnect \ diff --git a/content/xslt/src/xslt/Makefile.in b/content/xslt/src/xslt/Makefile.in index 31113ade88a9..bca3278e87c7 100644 --- a/content/xslt/src/xslt/Makefile.in +++ b/content/xslt/src/xslt/Makefile.in @@ -28,11 +28,12 @@ include $(DEPTH)/config/autoconf.mk DIRS = functions util -ifndef TX_EXE MODULE = transformiix REQUIRES = string \ xpcom \ - dom \ + $(NULL) +ifndef TX_EXE +REQUIRES += dom \ content \ widget \ necko \