From 2cabd6fa68897ed13dfde031a034bbdb6c75a9b1 Mon Sep 17 00:00:00 2001 From: "Peter.VanderBeken%pandora.be" Date: Sat, 16 Sep 2000 20:53:08 +0000 Subject: [PATCH] Enabling XSLT hooks in layout in default build. Bug #42228. r=axel@pike.org, a=waterson@mozilla.org. git-svn-id: svn://10.0.0.236/trunk@79394 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/build/mac/BuildNGLayout.pl | 1 - mozilla/build/mac/BuildNGLayoutDebug.pl | 1 - mozilla/build/mac/NGLayoutBuildList.pm | 14 +---- .../content/base/public/nsIDocumentViewer.h | 4 -- mozilla/content/base/src/nsDocumentViewer.cpp | 10 +--- .../xml/document/public/nsIXMLDocument.h | 3 - mozilla/content/xml/document/src/Makefile.in | 8 +-- mozilla/content/xml/document/src/makefile.win | 3 - .../xml/document/src/nsXMLContentSink.cpp | 53 +++--------------- .../xml/document/src/nsXMLContentSink.h | 11 +--- .../content/xml/document/src/nsXMLDocument.h | 3 - mozilla/content/xsl/document/src/makefile.win | 3 - .../macbuild/transformiixPrefix.h | 3 + .../macbuild/transformiixPrefix_debug.h | 3 + .../source/xpath/NumberFunctionCall.cpp | 4 +- mozilla/layout/Makefile.in | 6 +- mozilla/layout/base/nsDocumentViewer.cpp | 10 +--- mozilla/layout/base/nsIDocumentViewer.h | 4 -- .../layout/base/public/nsIDocumentViewer.h | 4 -- mozilla/layout/base/src/nsDocumentViewer.cpp | 10 +--- mozilla/layout/build/Makefile.in | 7 +-- mozilla/layout/build/makefile.win | 2 - mozilla/layout/html/tests/makefile.win | 2 - mozilla/layout/macbuild/layoutIDL.mcp | Bin 84102 -> 82610 bytes mozilla/layout/makefile.win | 2 - .../xml/document/public/nsIXMLDocument.h | 3 - mozilla/layout/xml/document/src/Makefile.in | 8 +-- mozilla/layout/xml/document/src/makefile.win | 3 - .../xml/document/src/nsXMLContentSink.cpp | 53 +++--------------- .../xml/document/src/nsXMLContentSink.h | 11 +--- .../layout/xml/document/src/nsXMLDocument.h | 3 - mozilla/layout/xsl/document/src/makefile.win | 3 - mozilla/rdf/content/src/makefile.win | 4 -- 33 files changed, 39 insertions(+), 220 deletions(-) diff --git a/mozilla/build/mac/BuildNGLayout.pl b/mozilla/build/mac/BuildNGLayout.pl index 4f826a4c537..db1bb73d020 100644 --- a/mozilla/build/mac/BuildNGLayout.pl +++ b/mozilla/build/mac/BuildNGLayout.pl @@ -80,7 +80,6 @@ $options{jar_manifests} = 0; # use jar.mn files for resources, not MANIFE $options{jars} = 0; # build jar files # Don't change these (where should they go?) -$optiondefines{transformiix}{MOZ_XSL} = 1; $optiondefines{mathml}{MOZ_MATHML} = 1; $optiondefines{svg}{MOZ_SVG} = 1; diff --git a/mozilla/build/mac/BuildNGLayoutDebug.pl b/mozilla/build/mac/BuildNGLayoutDebug.pl index b762161452f..11bba766095 100644 --- a/mozilla/build/mac/BuildNGLayoutDebug.pl +++ b/mozilla/build/mac/BuildNGLayoutDebug.pl @@ -112,7 +112,6 @@ $options{jar_manifests} = 0; # use jar.mn files for resources, not MANIFE $options{jars} = 0; # build jar files # Don't change these (where should they go?) -$optiondefines{transformiix}{MOZ_XSL} = 1; $optiondefines{mathml}{MOZ_MATHML} = 1; $optiondefines{svg}{MOZ_SVG} = 1; diff --git a/mozilla/build/mac/NGLayoutBuildList.pm b/mozilla/build/mac/NGLayoutBuildList.pm index 1a5e557cfcf..2d7915f586c 100644 --- a/mozilla/build/mac/NGLayoutBuildList.pm +++ b/mozilla/build/mac/NGLayoutBuildList.pm @@ -1620,10 +1620,7 @@ sub BuildClientDist() _InstallFromManifest(":mozilla:layout:events:src:MANIFEST", "$distdirectory:layout:"); _InstallFromManifest(":mozilla:layout:xml:document:public:MANIFEST", "$distdirectory:layout:"); _InstallFromManifest(":mozilla:layout:xml:content:public:MANIFEST", "$distdirectory:layout:"); - if ($main::options{transformiix}) - { - _InstallFromManifest(":mozilla:layout:xsl:document:src:MANIFEST_IDL", "$distdirectory:idl:"); - } + _InstallFromManifest(":mozilla:layout:xsl:document:src:MANIFEST_IDL", "$distdirectory:idl:"); if ($main::options{svg}) { _InstallFromManifest(":mozilla:layout:svg:base:public:MANIFEST", "$distdirectory:layout:"); @@ -2426,14 +2423,7 @@ sub BuildLayoutProjects() BuildOneProject(":mozilla:gfx:macbuild:gfx.mcp", "gfx$D.shlb", 1, $main::ALIAS_SYM_FILES, 0); BuildOneProject(":mozilla:dom:macbuild:dom.mcp", "dom$D.shlb", 1, $main::ALIAS_SYM_FILES, 0); BuildOneProject(":mozilla:modules:plugin:macbuild:plugin.mcp", "plugin$D.shlb", 1, $main::ALIAS_SYM_FILES, 1); - if ($main::options{transformiix}) - { - BuildOneProject(":mozilla:layout:macbuild:layoutxsl.mcp", "layoutxsl$D.o", 0, 0, 0); - } - else - { - BuildOneProject(":mozilla:layout:macbuild:layoutxsl.mcp", "layoutxsl$D.o stub", 0, 0, 0); - } + BuildOneProject(":mozilla:layout:macbuild:layoutxsl.mcp", "layoutxsl$D.o", 0, 0, 0); if ($main::options{mathml}) { BuildOneProject(":mozilla:layout:macbuild:layoutmathml.mcp", "layoutmathml$D.o", 0, 0, 0); diff --git a/mozilla/content/base/public/nsIDocumentViewer.h b/mozilla/content/base/public/nsIDocumentViewer.h index 2587c200256..6a1cd1b2adb 100644 --- a/mozilla/content/base/public/nsIDocumentViewer.h +++ b/mozilla/content/base/public/nsIDocumentViewer.h @@ -28,9 +28,7 @@ class nsIDocument; class nsIPresContext; class nsIPresShell; class nsIStyleSheet; -#ifdef MOZ_XSL class nsITransformMediator; -#endif #define NS_IDOCUMENT_VIEWER_IID \ { 0xa6cf9057, 0x15b3, 0x11d2,{0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32}} @@ -55,9 +53,7 @@ public: NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult) = 0; -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator)=0; -#endif }; #endif /* nsIDocumentViewer_h___ */ diff --git a/mozilla/content/base/src/nsDocumentViewer.cpp b/mozilla/content/base/src/nsDocumentViewer.cpp index 3f6fb61b67f..2fdc26272c9 100644 --- a/mozilla/content/base/src/nsDocumentViewer.cpp +++ b/mozilla/content/base/src/nsDocumentViewer.cpp @@ -86,9 +86,7 @@ #include "nsIDOMFocusListener.h" #include "nsISelectionController.h" -#ifdef MOZ_XSL #include "nsITransformMediator.h" -#endif static NS_DEFINE_CID(kEventQueueService, NS_EVENTQUEUESERVICE_CID); @@ -215,9 +213,7 @@ public: NS_IMETHOD GetPresContext(nsIPresContext*& aResult); NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult); -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator); -#endif // nsIContentViewerEdit NS_DECL_NSICONTENTVIEWEREDIT @@ -266,11 +262,9 @@ protected: nsCOMPtr mDeviceContext; // ??? can't hurt, but... nsIView* mView; // [WEAK] cleaned up by view mgr - // the following six items are explicitly in this order + // the following seven items are explicitly in this order // so they will be destroyed in the reverse order (pinkerton, scc) -#ifdef MOZ_XSL nsCOMPtr mTransformMediator; -#endif nsCOMPtr mDocument; nsCOMPtr mWindow; // ??? should we really own it? nsCOMPtr mViewManager; @@ -1298,7 +1292,6 @@ void DocumentViewerImpl::DocumentReadyForPrinting() } } -#ifdef MOZ_XSL NS_IMETHODIMP DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) { @@ -1307,7 +1300,6 @@ DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) mTransformMediator = aMediator; return NS_OK; } -#endif #ifdef XP_MAC #pragma mark - diff --git a/mozilla/content/xml/document/public/nsIXMLDocument.h b/mozilla/content/xml/document/public/nsIXMLDocument.h index a88e1b724b9..a0a27ba374b 100644 --- a/mozilla/content/xml/document/public/nsIXMLDocument.h +++ b/mozilla/content/xml/document/public/nsIXMLDocument.h @@ -28,9 +28,6 @@ class nsIAtom; class nsICSSLoader; -#ifdef MOZ_XSL -class nsITransformMediator; -#endif #define NS_IXMLDOCUMENT_IID \ { 0xa6cf90ca, 0x15b3, 0x11d2, \ diff --git a/mozilla/content/xml/document/src/Makefile.in b/mozilla/content/xml/document/src/Makefile.in index 50e77d8a526..88e46e67dcc 100644 --- a/mozilla/content/xml/document/src/Makefile.in +++ b/mozilla/content/xml/document/src/Makefile.in @@ -43,13 +43,9 @@ include $(topsrcdir)/config/rules.mk DEFINES += -D_IMPL_NS_HTML -ifdef MOZ_XSL -INCLUDES += -I$(srcdir) -INCLUDES += -I$(srcdir)/../../../xsl/document/src -endif - - INCLUDES += \ + -I$(srcdir) \ + -I$(srcdir)/../../../xsl/document/src \ -I$(srcdir)/../../../html/base/src \ -I$(srcdir)/../../../html/document/src \ -I$(srcdir)/../../../html/content/src \ diff --git a/mozilla/content/xml/document/src/makefile.win b/mozilla/content/xml/document/src/makefile.win index e77b6342bb9..c80497632e3 100644 --- a/mozilla/content/xml/document/src/makefile.win +++ b/mozilla/content/xml/document/src/makefile.win @@ -25,9 +25,6 @@ LIBRARY_NAME=raptorxmldoc_s MODULE=raptor DEFINES=-D_IMPL_NS_HTML -DWIN32_LEAN_AND_MEAN -!if defined(MOZ_XSL) -DEFINES=$(DEFINES) -DMOZ_XSL -!endif CPPSRCS= \ nsXMLContentSink.cpp \ diff --git a/mozilla/content/xml/document/src/nsXMLContentSink.cpp b/mozilla/content/xml/document/src/nsXMLContentSink.cpp index 688c414f2f6..3d3b812511d 100644 --- a/mozilla/content/xml/document/src/nsXMLContentSink.cpp +++ b/mozilla/content/xml/document/src/nsXMLContentSink.cpp @@ -68,11 +68,9 @@ #include "prtime.h" #include "prlog.h" #include "prmem.h" -#ifdef MOZ_XSL #include "nsXSLContentSink.h" #include "nsParserCIID.h" #include "nsIDocumentViewer.h" -#endif // XXX misnamed header file, but oh well #include "nsHTMLTokens.h" @@ -80,16 +78,10 @@ static char kNameSpaceSeparator = ':'; static char kNameSpaceDef[] = "xmlns"; static char kStyleSheetPI[] = "xml-stylesheet"; - -#ifdef MOZ_XSL static char kXSLType[] = "text/xsl"; -#endif static NS_DEFINE_CID(kNameSpaceManagerCID, NS_NAMESPACEMANAGER_CID); - -#ifdef MOZ_XSL static NS_DEFINE_CID(kIOServiceCID, NS_IOSERVICE_CID); -#endif nsINameSpaceManager* nsXMLContentSink::gNameSpaceManager = nsnull; PRUint32 nsXMLContentSink::gRefCnt = 0; @@ -158,9 +150,7 @@ nsXMLContentSink::nsXMLContentSink() mInScript = PR_FALSE; mStyleSheetCount = 0; mCSSLoader = nsnull; -#ifdef MOZ_XSL mXSLTransformMediator = nsnull; -#endif } nsXMLContentSink::~nsXMLContentSink() @@ -229,25 +219,14 @@ nsXMLContentSink::Init(nsIDocument* aDoc, return aDoc->GetNodeInfoManager(*getter_AddRefs(mNodeInfoManager)); } -#ifndef MOZ_XSL - -NS_IMPL_ADDREF(nsXMLContentSink) -NS_IMPL_RELEASE(nsXMLContentSink) - -#else - NS_IMPL_THREADSAFE_ADDREF(nsXMLContentSink) NS_IMPL_THREADSAFE_RELEASE(nsXMLContentSink) -#endif - NS_INTERFACE_MAP_BEGIN(nsXMLContentSink) NS_INTERFACE_MAP_ENTRY(nsIXMLContentSink) NS_INTERFACE_MAP_ENTRY(nsIContentSink) -#ifdef MOZ_XSL NS_INTERFACE_MAP_ENTRY(nsIObserver) NS_INTERFACE_MAP_ENTRY(nsISupportsWeakReference) -#endif NS_INTERFACE_MAP_ENTRY(nsIStreamLoaderObserver) NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIXMLContentSink) NS_INTERFACE_MAP_END @@ -279,10 +258,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) mDocument->SetRootContent(mDocElement); -#ifndef MOZ_XSL - StartLayout(); - mDocument->EndLoad(); -#else nsresult rv; if (mXSLTransformMediator) { rv = SetupTransformMediator(); @@ -292,7 +267,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) StartLayout(); mDocument->EndLoad(); } -#endif // Drop our reference to the parser to get rid of a circular // reference. @@ -301,7 +275,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) return NS_OK; } -#ifdef MOZ_XSL // The observe method is called on completion of the transform. The nsISupports argument is an // nsIDOMElement interface to the root node of the output content model. NS_IMETHODIMP @@ -320,7 +293,7 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const mXSLTransformMediator->GetResultDocument(getter_AddRefs(resultDOMDoc)); nsCOMPtr resultDoc = do_QueryInterface(resultDOMDoc); - mDocument->EndLoad(); + nsCOMPtr sourceDoc = mDocument; NS_RELEASE(mDocument); mDocument = resultDoc; @@ -336,6 +309,10 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const // Reset the observer on the transform mediator mXSLTransformMediator->SetTransformObserver(nsnull); + + // Start the layout process + StartLayout(); + sourceDoc->EndLoad(); } else { @@ -350,11 +327,11 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const mXSLTransformMediator = nsnull; mDocument->SetRootContent(mDocElement); - } - // Start the layout process - StartLayout(); - mDocument->EndLoad(); + // Start the layout process + StartLayout(); + mDocument->EndLoad(); + } } return rv; } @@ -393,7 +370,6 @@ nsXMLContentSink::SetupTransformMediator() return rv; } -#endif NS_IMETHODIMP nsXMLContentSink::WillInterrupt(void) @@ -642,12 +618,8 @@ nsXMLContentSink::OpenContainer(const nsIParserNode& aNode) // For XSL, we need to wait till after the transform // to set the root content object. Hence, the following // ifndef. -#ifdef MOZ_XSL if (!mXSLTransformMediator) mDocument->SetRootContent(mDocElement); -#else - mDocument->SetRootContent(mDocElement); -#endif } else { nsCOMPtr parent = getter_AddRefs(GetCurrentContent()); @@ -975,7 +947,6 @@ static void SplitMimeType(const nsString& aValue, nsString& aType, nsString& aPa aType.StripWhitespace(); } -#ifdef MOZ_XSL nsresult nsXMLContentSink::CreateStyleSheetURL(nsIURI** aUrl, const nsAReadableString& aHref) @@ -1091,7 +1062,6 @@ nsXMLContentSink::ProcessXSLStyleLink(nsIContent* aElement, return rv; } -#endif nsresult nsXMLContentSink::ProcessCSSStyleLink(nsIContent* aElement, @@ -1188,13 +1158,8 @@ nsXMLContentSink::AddProcessingInstruction(const nsIParserNode& aNode) media.ToLowerCase(); } result = GetQuotedAttributeValue(text, NS_ConvertASCIItoUCS2("alternate"), alternate); -#ifndef MOZ_XSL - result = ProcessCSSStyleLink(node, href, alternate.EqualsWithConversion("yes"), - title, type, media); -#else result = ProcessStyleLink(node, href, alternate.EqualsWithConversion("yes"), title, type, media); -#endif } } diff --git a/mozilla/content/xml/document/src/nsXMLContentSink.h b/mozilla/content/xml/document/src/nsXMLContentSink.h index 9d4bc149f92..e536a551d6b 100644 --- a/mozilla/content/xml/document/src/nsXMLContentSink.h +++ b/mozilla/content/xml/document/src/nsXMLContentSink.h @@ -26,11 +26,9 @@ #include "nsIXMLContentSink.h" #include "nsIViewManager.h" #include "nsIScrollableView.h" -#ifdef MOZ_XSL #include "nsIObserver.h" #include "nsWeakReference.h" #include "nsITransformMediator.h" -#endif #include "nsIUnicharInputStream.h" #include "nsIStreamLoader.h" #include "nsISupportsArray.h" @@ -59,10 +57,8 @@ typedef enum { // XXX Till the parser knows a little bit more about XML, // this is a HTMLContentSink. class nsXMLContentSink : public nsIXMLContentSink, -#ifdef MOZ_XSL public nsIObserver, public nsSupportsWeakReference, -#endif public nsIStreamLoaderObserver { public: @@ -100,12 +96,10 @@ public: NS_IMETHOD AddNotation(const nsIParserNode& aNode); NS_IMETHOD AddEntityReference(const nsIParserNode& aNode); -#ifdef MOZ_XSL // nsIObserver NS_IMETHOD Observe(nsISupports *aSubject, const PRUnichar *aTopic, const PRUnichar *someData); -#endif NS_IMETHOD ResumeParsing(); NS_IMETHOD EvaluateScript(nsString& aScript, nsIURI *aScriptURI, PRUint32 aLineNo, const char* aVersion); @@ -139,7 +133,6 @@ protected: const nsString& aHref, PRBool aAlternate, const nsString& aTitle, const nsString& aType, const nsString& aMedia); -#ifdef MOZ_XSL nsresult ProcessStyleLink(nsIContent* aElement, const nsString& aHref, PRBool aAlternate, const nsString& aTitle, const nsString& aType, @@ -152,7 +145,7 @@ protected: nsresult CreateStyleSheetURL(nsIURI** aUrl, const nsAReadableString& aHref); nsresult LoadXSLStyleSheet(nsIURI* aUrl, const nsString& aType); nsresult SetupTransformMediator(); -#endif + nsresult AddText(const nsString& aString); static void @@ -190,9 +183,7 @@ protected: PRInt32 mStyleSheetCount; nsICSSLoader* mCSSLoader; nsCOMPtr mNodeInfoManager; -#ifdef MOZ_XSL nsCOMPtr mXSLTransformMediator; -#endif }; #endif // nsXMLContentSink_h__ diff --git a/mozilla/content/xml/document/src/nsXMLDocument.h b/mozilla/content/xml/document/src/nsXMLDocument.h index d4e38c9d05d..78a9f1e4c25 100644 --- a/mozilla/content/xml/document/src/nsXMLDocument.h +++ b/mozilla/content/xml/document/src/nsXMLDocument.h @@ -26,9 +26,6 @@ #include "nsMarkupDocument.h" #include "nsIXMLDocument.h" #include "nsIHTMLContentContainer.h" -#ifdef MOZ_XSL -#include "nsITransformMediator.h" -#endif class nsIParser; class nsIDOMNode; diff --git a/mozilla/content/xsl/document/src/makefile.win b/mozilla/content/xsl/document/src/makefile.win index 686f308444b..751c190e62e 100644 --- a/mozilla/content/xsl/document/src/makefile.win +++ b/mozilla/content/xsl/document/src/makefile.win @@ -25,9 +25,6 @@ LIBRARY_NAME=raptorxsldoc_s MODULE=raptor DEFINES=-D_IMPL_NS_HTML -DWIN32_LEAN_AND_MEAN -!if defined(MOZ_XSL) -DEFINES=$(DEFINES) -DMOZ_XSL -!endif XPIDLSRCS= .\nsIDocumentTransformer.idl \ $(NULL) diff --git a/mozilla/extensions/transformiix/macbuild/transformiixPrefix.h b/mozilla/extensions/transformiix/macbuild/transformiixPrefix.h index 0b68e738331..10483c004dd 100755 --- a/mozilla/extensions/transformiix/macbuild/transformiixPrefix.h +++ b/mozilla/extensions/transformiix/macbuild/transformiixPrefix.h @@ -25,3 +25,6 @@ */ #include "MacSharedPrefix.h" + +#define MOZ_XSL 1 +#define HAVE_RINT 1 diff --git a/mozilla/extensions/transformiix/macbuild/transformiixPrefix_debug.h b/mozilla/extensions/transformiix/macbuild/transformiixPrefix_debug.h index 088f325b1e8..def5643990b 100755 --- a/mozilla/extensions/transformiix/macbuild/transformiixPrefix_debug.h +++ b/mozilla/extensions/transformiix/macbuild/transformiixPrefix_debug.h @@ -25,3 +25,6 @@ */ #include "MacSharedPrefix_debug.h" + +#define MOZ_XSL 1 +#define HAVE_RINT 1 diff --git a/mozilla/extensions/transformiix/source/xpath/NumberFunctionCall.cpp b/mozilla/extensions/transformiix/source/xpath/NumberFunctionCall.cpp index 3337e201191..3540b5077a0 100644 --- a/mozilla/extensions/transformiix/source/xpath/NumberFunctionCall.cpp +++ b/mozilla/extensions/transformiix/source/xpath/NumberFunctionCall.cpp @@ -25,7 +25,7 @@ * Nisheeth Ranjan, nisheeth@netscape.com * -- implemented rint function, which was not available on Windows. * - * $Id: NumberFunctionCall.cpp,v 1.7 2000-07-11 09:47:37 axel%pike.org Exp $ + * $Id: NumberFunctionCall.cpp,v 1.8 2000-09-16 20:53:01 Peter.VanderBeken%pandora.be Exp $ */ /* @@ -65,7 +65,7 @@ NumberFunctionCall::NumberFunctionCall(short type) : FunctionCall() { } } //-- NumberFunctionCall -#if !defined(HAVE_RINT) && !defined(XP_MAC) +#if !defined(HAVE_RINT) static double rint(double r) { double integerPart = 0; diff --git a/mozilla/layout/Makefile.in b/mozilla/layout/Makefile.in index bce09667ffa..6e016e431dd 100644 --- a/mozilla/layout/Makefile.in +++ b/mozilla/layout/Makefile.in @@ -26,7 +26,7 @@ VPATH = @srcdir@ include $(DEPTH)/config/autoconf.mk -DIRS = base html xml xul xbl +DIRS = base html xml xul xbl xsl ifdef MOZ_MATHML DIRS += mathml @@ -36,10 +36,6 @@ ifdef MOZ_SVG DIRS += svg endif -ifdef MOZ_XSL -DIRS += xsl -endif - DIRS += events build ifdef ENABLE_TESTS diff --git a/mozilla/layout/base/nsDocumentViewer.cpp b/mozilla/layout/base/nsDocumentViewer.cpp index 3f6fb61b67f..2fdc26272c9 100644 --- a/mozilla/layout/base/nsDocumentViewer.cpp +++ b/mozilla/layout/base/nsDocumentViewer.cpp @@ -86,9 +86,7 @@ #include "nsIDOMFocusListener.h" #include "nsISelectionController.h" -#ifdef MOZ_XSL #include "nsITransformMediator.h" -#endif static NS_DEFINE_CID(kEventQueueService, NS_EVENTQUEUESERVICE_CID); @@ -215,9 +213,7 @@ public: NS_IMETHOD GetPresContext(nsIPresContext*& aResult); NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult); -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator); -#endif // nsIContentViewerEdit NS_DECL_NSICONTENTVIEWEREDIT @@ -266,11 +262,9 @@ protected: nsCOMPtr mDeviceContext; // ??? can't hurt, but... nsIView* mView; // [WEAK] cleaned up by view mgr - // the following six items are explicitly in this order + // the following seven items are explicitly in this order // so they will be destroyed in the reverse order (pinkerton, scc) -#ifdef MOZ_XSL nsCOMPtr mTransformMediator; -#endif nsCOMPtr mDocument; nsCOMPtr mWindow; // ??? should we really own it? nsCOMPtr mViewManager; @@ -1298,7 +1292,6 @@ void DocumentViewerImpl::DocumentReadyForPrinting() } } -#ifdef MOZ_XSL NS_IMETHODIMP DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) { @@ -1307,7 +1300,6 @@ DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) mTransformMediator = aMediator; return NS_OK; } -#endif #ifdef XP_MAC #pragma mark - diff --git a/mozilla/layout/base/nsIDocumentViewer.h b/mozilla/layout/base/nsIDocumentViewer.h index 2587c200256..6a1cd1b2adb 100644 --- a/mozilla/layout/base/nsIDocumentViewer.h +++ b/mozilla/layout/base/nsIDocumentViewer.h @@ -28,9 +28,7 @@ class nsIDocument; class nsIPresContext; class nsIPresShell; class nsIStyleSheet; -#ifdef MOZ_XSL class nsITransformMediator; -#endif #define NS_IDOCUMENT_VIEWER_IID \ { 0xa6cf9057, 0x15b3, 0x11d2,{0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32}} @@ -55,9 +53,7 @@ public: NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult) = 0; -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator)=0; -#endif }; #endif /* nsIDocumentViewer_h___ */ diff --git a/mozilla/layout/base/public/nsIDocumentViewer.h b/mozilla/layout/base/public/nsIDocumentViewer.h index 2587c200256..6a1cd1b2adb 100644 --- a/mozilla/layout/base/public/nsIDocumentViewer.h +++ b/mozilla/layout/base/public/nsIDocumentViewer.h @@ -28,9 +28,7 @@ class nsIDocument; class nsIPresContext; class nsIPresShell; class nsIStyleSheet; -#ifdef MOZ_XSL class nsITransformMediator; -#endif #define NS_IDOCUMENT_VIEWER_IID \ { 0xa6cf9057, 0x15b3, 0x11d2,{0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32}} @@ -55,9 +53,7 @@ public: NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult) = 0; -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator)=0; -#endif }; #endif /* nsIDocumentViewer_h___ */ diff --git a/mozilla/layout/base/src/nsDocumentViewer.cpp b/mozilla/layout/base/src/nsDocumentViewer.cpp index 3f6fb61b67f..2fdc26272c9 100644 --- a/mozilla/layout/base/src/nsDocumentViewer.cpp +++ b/mozilla/layout/base/src/nsDocumentViewer.cpp @@ -86,9 +86,7 @@ #include "nsIDOMFocusListener.h" #include "nsISelectionController.h" -#ifdef MOZ_XSL #include "nsITransformMediator.h" -#endif static NS_DEFINE_CID(kEventQueueService, NS_EVENTQUEUESERVICE_CID); @@ -215,9 +213,7 @@ public: NS_IMETHOD GetPresContext(nsIPresContext*& aResult); NS_IMETHOD CreateDocumentViewerUsing(nsIPresContext* aPresContext, nsIDocumentViewer*& aResult); -#ifdef MOZ_XSL NS_IMETHOD SetTransformMediator(nsITransformMediator* aMediator); -#endif // nsIContentViewerEdit NS_DECL_NSICONTENTVIEWEREDIT @@ -266,11 +262,9 @@ protected: nsCOMPtr mDeviceContext; // ??? can't hurt, but... nsIView* mView; // [WEAK] cleaned up by view mgr - // the following six items are explicitly in this order + // the following seven items are explicitly in this order // so they will be destroyed in the reverse order (pinkerton, scc) -#ifdef MOZ_XSL nsCOMPtr mTransformMediator; -#endif nsCOMPtr mDocument; nsCOMPtr mWindow; // ??? should we really own it? nsCOMPtr mViewManager; @@ -1298,7 +1292,6 @@ void DocumentViewerImpl::DocumentReadyForPrinting() } } -#ifdef MOZ_XSL NS_IMETHODIMP DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) { @@ -1307,7 +1300,6 @@ DocumentViewerImpl::SetTransformMediator(nsITransformMediator* aMediator) mTransformMediator = aMediator; return NS_OK; } -#endif #ifdef XP_MAC #pragma mark - diff --git a/mozilla/layout/build/Makefile.in b/mozilla/layout/build/Makefile.in index 7990bce9cf0..ad1b71d6aa5 100644 --- a/mozilla/layout/build/Makefile.in +++ b/mozilla/layout/build/Makefile.in @@ -59,6 +59,7 @@ SHARED_LIBRARY_LIBS = \ $(DIST)/lib/libgkhtmltable_s.$(LIB_SUFFIX) \ $(DIST)/lib/libgkxmlcon_s.$(LIB_SUFFIX) \ $(DIST)/lib/libgkxmldoc_s.$(LIB_SUFFIX) \ + $(DIST)/lib/libgkxsldoc_s.$(LIB_SUFFIX) \ $(DIST)/lib/libgkxulcon_s.$(LIB_SUFFIX) \ $(DIST)/lib/libgkxulbase_s.$(LIB_SUFFIX) \ $(DIST)/lib/libgkxbl_s.$(LIB_SUFFIX) \ @@ -85,12 +86,6 @@ SHARED_LIBRARY_LIBS += \ $(NSNULL) endif -ifdef MOZ_XSL -SHARED_LIBRARY_LIBS += \ - $(DIST)/lib/libgkxsldoc_s.$(LIB_SUFFIX) \ - $(NSNULL) -endif - EXTRA_DSO_LDOPTS = \ -L$(DIST)/bin \ $(EXTRA_DSO_LIBS) \ diff --git a/mozilla/layout/build/makefile.win b/mozilla/layout/build/makefile.win index da95f70b917..aa68a290e9c 100644 --- a/mozilla/layout/build/makefile.win +++ b/mozilla/layout/build/makefile.win @@ -72,9 +72,7 @@ LLIBS= \ $(DIST)\lib\raptorhtmltable_s.lib \ $(DIST)\lib\raptorxmlcontent_s.lib \ $(DIST)\lib\raptorxmldoc_s.lib \ -!if defined(MOZ_XSL) $(DIST)\lib\raptorxsldoc_s.lib \ -!endif $(DIST)\lib\raptorxulbase_s.lib \ $(DIST)\lib\raptorxulcontent_s.lib \ $(DIST)\lib\raptorxbl_s.lib \ diff --git a/mozilla/layout/html/tests/makefile.win b/mozilla/layout/html/tests/makefile.win index a0db14e21f6..6785fd7fb38 100644 --- a/mozilla/layout/html/tests/makefile.win +++ b/mozilla/layout/html/tests/makefile.win @@ -70,9 +70,7 @@ LLIBS= \ $(DIST)\lib\raptorsvgbase_s.lib \ $(DIST)\lib\raptorsvgcontent_s.lib \ !endif -!ifdef MOZ_XSL $(DIST)\lib\raptorxsldoc_s.lib \ -!endif $(DIST)\lib\img32$(VERSION_NUMBER).lib \ $(DIST)\lib\util.lib \ $(DIST)\lib\xpcom.lib \ diff --git a/mozilla/layout/macbuild/layoutIDL.mcp b/mozilla/layout/macbuild/layoutIDL.mcp index 5acc32b08747382f4b62630bbb0b82708d2b0d34..9c56fca9b747fce38dba29de4fe429dc78445042 100644 GIT binary patch delta 2798 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 azx*CBUIvJKY$KFQ+!jjZMzCDu=6?YMMkba3 diff --git a/mozilla/layout/makefile.win b/mozilla/layout/makefile.win index 7c291439ad6..353ba7d2461 100644 --- a/mozilla/layout/makefile.win +++ b/mozilla/layout/makefile.win @@ -27,9 +27,7 @@ DIRS= \ xml \ xul \ xbl \ -!if defined(MOZ_XSL) xsl \ -!endif !ifdef MOZ_MATHML mathml \ !endif diff --git a/mozilla/layout/xml/document/public/nsIXMLDocument.h b/mozilla/layout/xml/document/public/nsIXMLDocument.h index a88e1b724b9..a0a27ba374b 100644 --- a/mozilla/layout/xml/document/public/nsIXMLDocument.h +++ b/mozilla/layout/xml/document/public/nsIXMLDocument.h @@ -28,9 +28,6 @@ class nsIAtom; class nsICSSLoader; -#ifdef MOZ_XSL -class nsITransformMediator; -#endif #define NS_IXMLDOCUMENT_IID \ { 0xa6cf90ca, 0x15b3, 0x11d2, \ diff --git a/mozilla/layout/xml/document/src/Makefile.in b/mozilla/layout/xml/document/src/Makefile.in index 50e77d8a526..88e46e67dcc 100644 --- a/mozilla/layout/xml/document/src/Makefile.in +++ b/mozilla/layout/xml/document/src/Makefile.in @@ -43,13 +43,9 @@ include $(topsrcdir)/config/rules.mk DEFINES += -D_IMPL_NS_HTML -ifdef MOZ_XSL -INCLUDES += -I$(srcdir) -INCLUDES += -I$(srcdir)/../../../xsl/document/src -endif - - INCLUDES += \ + -I$(srcdir) \ + -I$(srcdir)/../../../xsl/document/src \ -I$(srcdir)/../../../html/base/src \ -I$(srcdir)/../../../html/document/src \ -I$(srcdir)/../../../html/content/src \ diff --git a/mozilla/layout/xml/document/src/makefile.win b/mozilla/layout/xml/document/src/makefile.win index e77b6342bb9..c80497632e3 100644 --- a/mozilla/layout/xml/document/src/makefile.win +++ b/mozilla/layout/xml/document/src/makefile.win @@ -25,9 +25,6 @@ LIBRARY_NAME=raptorxmldoc_s MODULE=raptor DEFINES=-D_IMPL_NS_HTML -DWIN32_LEAN_AND_MEAN -!if defined(MOZ_XSL) -DEFINES=$(DEFINES) -DMOZ_XSL -!endif CPPSRCS= \ nsXMLContentSink.cpp \ diff --git a/mozilla/layout/xml/document/src/nsXMLContentSink.cpp b/mozilla/layout/xml/document/src/nsXMLContentSink.cpp index 688c414f2f6..3d3b812511d 100644 --- a/mozilla/layout/xml/document/src/nsXMLContentSink.cpp +++ b/mozilla/layout/xml/document/src/nsXMLContentSink.cpp @@ -68,11 +68,9 @@ #include "prtime.h" #include "prlog.h" #include "prmem.h" -#ifdef MOZ_XSL #include "nsXSLContentSink.h" #include "nsParserCIID.h" #include "nsIDocumentViewer.h" -#endif // XXX misnamed header file, but oh well #include "nsHTMLTokens.h" @@ -80,16 +78,10 @@ static char kNameSpaceSeparator = ':'; static char kNameSpaceDef[] = "xmlns"; static char kStyleSheetPI[] = "xml-stylesheet"; - -#ifdef MOZ_XSL static char kXSLType[] = "text/xsl"; -#endif static NS_DEFINE_CID(kNameSpaceManagerCID, NS_NAMESPACEMANAGER_CID); - -#ifdef MOZ_XSL static NS_DEFINE_CID(kIOServiceCID, NS_IOSERVICE_CID); -#endif nsINameSpaceManager* nsXMLContentSink::gNameSpaceManager = nsnull; PRUint32 nsXMLContentSink::gRefCnt = 0; @@ -158,9 +150,7 @@ nsXMLContentSink::nsXMLContentSink() mInScript = PR_FALSE; mStyleSheetCount = 0; mCSSLoader = nsnull; -#ifdef MOZ_XSL mXSLTransformMediator = nsnull; -#endif } nsXMLContentSink::~nsXMLContentSink() @@ -229,25 +219,14 @@ nsXMLContentSink::Init(nsIDocument* aDoc, return aDoc->GetNodeInfoManager(*getter_AddRefs(mNodeInfoManager)); } -#ifndef MOZ_XSL - -NS_IMPL_ADDREF(nsXMLContentSink) -NS_IMPL_RELEASE(nsXMLContentSink) - -#else - NS_IMPL_THREADSAFE_ADDREF(nsXMLContentSink) NS_IMPL_THREADSAFE_RELEASE(nsXMLContentSink) -#endif - NS_INTERFACE_MAP_BEGIN(nsXMLContentSink) NS_INTERFACE_MAP_ENTRY(nsIXMLContentSink) NS_INTERFACE_MAP_ENTRY(nsIContentSink) -#ifdef MOZ_XSL NS_INTERFACE_MAP_ENTRY(nsIObserver) NS_INTERFACE_MAP_ENTRY(nsISupportsWeakReference) -#endif NS_INTERFACE_MAP_ENTRY(nsIStreamLoaderObserver) NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIXMLContentSink) NS_INTERFACE_MAP_END @@ -279,10 +258,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) mDocument->SetRootContent(mDocElement); -#ifndef MOZ_XSL - StartLayout(); - mDocument->EndLoad(); -#else nsresult rv; if (mXSLTransformMediator) { rv = SetupTransformMediator(); @@ -292,7 +267,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) StartLayout(); mDocument->EndLoad(); } -#endif // Drop our reference to the parser to get rid of a circular // reference. @@ -301,7 +275,6 @@ nsXMLContentSink::DidBuildModel(PRInt32 aQualityLevel) return NS_OK; } -#ifdef MOZ_XSL // The observe method is called on completion of the transform. The nsISupports argument is an // nsIDOMElement interface to the root node of the output content model. NS_IMETHODIMP @@ -320,7 +293,7 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const mXSLTransformMediator->GetResultDocument(getter_AddRefs(resultDOMDoc)); nsCOMPtr resultDoc = do_QueryInterface(resultDOMDoc); - mDocument->EndLoad(); + nsCOMPtr sourceDoc = mDocument; NS_RELEASE(mDocument); mDocument = resultDoc; @@ -336,6 +309,10 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const // Reset the observer on the transform mediator mXSLTransformMediator->SetTransformObserver(nsnull); + + // Start the layout process + StartLayout(); + sourceDoc->EndLoad(); } else { @@ -350,11 +327,11 @@ nsXMLContentSink::Observe(nsISupports *aSubject, const PRUnichar *aTopic, const mXSLTransformMediator = nsnull; mDocument->SetRootContent(mDocElement); - } - // Start the layout process - StartLayout(); - mDocument->EndLoad(); + // Start the layout process + StartLayout(); + mDocument->EndLoad(); + } } return rv; } @@ -393,7 +370,6 @@ nsXMLContentSink::SetupTransformMediator() return rv; } -#endif NS_IMETHODIMP nsXMLContentSink::WillInterrupt(void) @@ -642,12 +618,8 @@ nsXMLContentSink::OpenContainer(const nsIParserNode& aNode) // For XSL, we need to wait till after the transform // to set the root content object. Hence, the following // ifndef. -#ifdef MOZ_XSL if (!mXSLTransformMediator) mDocument->SetRootContent(mDocElement); -#else - mDocument->SetRootContent(mDocElement); -#endif } else { nsCOMPtr parent = getter_AddRefs(GetCurrentContent()); @@ -975,7 +947,6 @@ static void SplitMimeType(const nsString& aValue, nsString& aType, nsString& aPa aType.StripWhitespace(); } -#ifdef MOZ_XSL nsresult nsXMLContentSink::CreateStyleSheetURL(nsIURI** aUrl, const nsAReadableString& aHref) @@ -1091,7 +1062,6 @@ nsXMLContentSink::ProcessXSLStyleLink(nsIContent* aElement, return rv; } -#endif nsresult nsXMLContentSink::ProcessCSSStyleLink(nsIContent* aElement, @@ -1188,13 +1158,8 @@ nsXMLContentSink::AddProcessingInstruction(const nsIParserNode& aNode) media.ToLowerCase(); } result = GetQuotedAttributeValue(text, NS_ConvertASCIItoUCS2("alternate"), alternate); -#ifndef MOZ_XSL - result = ProcessCSSStyleLink(node, href, alternate.EqualsWithConversion("yes"), - title, type, media); -#else result = ProcessStyleLink(node, href, alternate.EqualsWithConversion("yes"), title, type, media); -#endif } } diff --git a/mozilla/layout/xml/document/src/nsXMLContentSink.h b/mozilla/layout/xml/document/src/nsXMLContentSink.h index 9d4bc149f92..e536a551d6b 100644 --- a/mozilla/layout/xml/document/src/nsXMLContentSink.h +++ b/mozilla/layout/xml/document/src/nsXMLContentSink.h @@ -26,11 +26,9 @@ #include "nsIXMLContentSink.h" #include "nsIViewManager.h" #include "nsIScrollableView.h" -#ifdef MOZ_XSL #include "nsIObserver.h" #include "nsWeakReference.h" #include "nsITransformMediator.h" -#endif #include "nsIUnicharInputStream.h" #include "nsIStreamLoader.h" #include "nsISupportsArray.h" @@ -59,10 +57,8 @@ typedef enum { // XXX Till the parser knows a little bit more about XML, // this is a HTMLContentSink. class nsXMLContentSink : public nsIXMLContentSink, -#ifdef MOZ_XSL public nsIObserver, public nsSupportsWeakReference, -#endif public nsIStreamLoaderObserver { public: @@ -100,12 +96,10 @@ public: NS_IMETHOD AddNotation(const nsIParserNode& aNode); NS_IMETHOD AddEntityReference(const nsIParserNode& aNode); -#ifdef MOZ_XSL // nsIObserver NS_IMETHOD Observe(nsISupports *aSubject, const PRUnichar *aTopic, const PRUnichar *someData); -#endif NS_IMETHOD ResumeParsing(); NS_IMETHOD EvaluateScript(nsString& aScript, nsIURI *aScriptURI, PRUint32 aLineNo, const char* aVersion); @@ -139,7 +133,6 @@ protected: const nsString& aHref, PRBool aAlternate, const nsString& aTitle, const nsString& aType, const nsString& aMedia); -#ifdef MOZ_XSL nsresult ProcessStyleLink(nsIContent* aElement, const nsString& aHref, PRBool aAlternate, const nsString& aTitle, const nsString& aType, @@ -152,7 +145,7 @@ protected: nsresult CreateStyleSheetURL(nsIURI** aUrl, const nsAReadableString& aHref); nsresult LoadXSLStyleSheet(nsIURI* aUrl, const nsString& aType); nsresult SetupTransformMediator(); -#endif + nsresult AddText(const nsString& aString); static void @@ -190,9 +183,7 @@ protected: PRInt32 mStyleSheetCount; nsICSSLoader* mCSSLoader; nsCOMPtr mNodeInfoManager; -#ifdef MOZ_XSL nsCOMPtr mXSLTransformMediator; -#endif }; #endif // nsXMLContentSink_h__ diff --git a/mozilla/layout/xml/document/src/nsXMLDocument.h b/mozilla/layout/xml/document/src/nsXMLDocument.h index d4e38c9d05d..78a9f1e4c25 100644 --- a/mozilla/layout/xml/document/src/nsXMLDocument.h +++ b/mozilla/layout/xml/document/src/nsXMLDocument.h @@ -26,9 +26,6 @@ #include "nsMarkupDocument.h" #include "nsIXMLDocument.h" #include "nsIHTMLContentContainer.h" -#ifdef MOZ_XSL -#include "nsITransformMediator.h" -#endif class nsIParser; class nsIDOMNode; diff --git a/mozilla/layout/xsl/document/src/makefile.win b/mozilla/layout/xsl/document/src/makefile.win index 686f308444b..751c190e62e 100644 --- a/mozilla/layout/xsl/document/src/makefile.win +++ b/mozilla/layout/xsl/document/src/makefile.win @@ -25,9 +25,6 @@ LIBRARY_NAME=raptorxsldoc_s MODULE=raptor DEFINES=-D_IMPL_NS_HTML -DWIN32_LEAN_AND_MEAN -!if defined(MOZ_XSL) -DEFINES=$(DEFINES) -DMOZ_XSL -!endif XPIDLSRCS= .\nsIDocumentTransformer.idl \ $(NULL) diff --git a/mozilla/rdf/content/src/makefile.win b/mozilla/rdf/content/src/makefile.win index 768dba16596..c5b9f8a8bba 100644 --- a/mozilla/rdf/content/src/makefile.win +++ b/mozilla/rdf/content/src/makefile.win @@ -24,10 +24,6 @@ MODULE=rdf LIBRARY_NAME=rdfcontent_s DEFINES=-D_IMPL_NS_DOM -!if defined(MOZ_XSL) -DEFINES=$(DEFINES) -DMOZ_XSL -!endif - LCFLAGS = \ $(LCFLAGS) \