From 387de8cf2e5a0d89632851ebaa2f66d5216b7808 Mon Sep 17 00:00:00 2001 From: Taras Glek Date: Thu, 8 Oct 2009 16:43:55 -0700 Subject: [PATCH] Backed out changeset e22bef491d84 --- browser/base/content/pageinfo/pageInfo.xul | 2 +- browser/installer/package-manifest.in | 9 +++++++++ browser/installer/removed-files.in | 9 --------- caps/tests/mochitest/test_bug423375.html | 2 +- dom/src/Makefile.in | 10 ++++++++++ dom/src/jar.mn | 2 -- layout/generic/Makefile.in | 7 +++++++ layout/generic/jar.mn | 3 --- layout/generic/nsImageFrame.cpp | 4 ++-- layout/mathml/Makefile.in | 3 +++ layout/mathml/jar.mn | 2 -- layout/mathml/mathml-css.pl | 2 +- layout/style/Makefile.in | 4 ++++ layout/style/jar.mn | 6 ------ layout/style/nsLayoutStylesheetCache.cpp | 6 +++--- layout/style/ua.css | 2 +- parser/htmlparser/src/nsExpatDriver.cpp | 6 +++--- parser/htmlparser/src/nsViewSourceHTML.cpp | 4 ++-- xpfe/appshell/src/nsAppShellService.cpp | 2 +- 19 files changed, 48 insertions(+), 37 deletions(-) delete mode 100644 dom/src/jar.mn delete mode 100644 layout/generic/jar.mn delete mode 100644 layout/mathml/jar.mn delete mode 100644 layout/style/jar.mn diff --git a/browser/base/content/pageinfo/pageInfo.xul b/browser/base/content/pageinfo/pageInfo.xul index 71533bbc2de4..a4e237f0d574 100644 --- a/browser/base/content/pageinfo/pageInfo.xul +++ b/browser/base/content/pageinfo/pageInfo.xul @@ -289,7 +289,7 @@ - + diff --git a/browser/installer/package-manifest.in b/browser/installer/package-manifest.in index 28a80ed7b9e4..37fcc044b5de 100644 --- a/browser/installer/package-manifest.in +++ b/browser/installer/package-manifest.in @@ -364,6 +364,11 @@ ; [Layout Engine Resources] ; Style Sheets, Graphics and other Resources used by the layout engine. +@BINPATH@/res/hiddenWindow.html +@BINPATH@/res/ua.css +@BINPATH@/res/html.css +@BINPATH@/res/quirk.css +@BINPATH@/res/forms.css @BINPATH@/res/EditorOverride.css @BINPATH@/res/contenteditable.css @BINPATH@/res/designmode.css @@ -387,7 +392,11 @@ @BINPATH@/res/table-remove-row.gif @BINPATH@/res/arrowd.gif @BINPATH@/res/grabber.gif +@BINPATH@/res/viewsource.css +@BINPATH@/res/mathml.css @BINPATH@/res/arrow.gif +@BINPATH@/res/loading-image.png +@BINPATH@/res/broken-image.png #ifdef XP_MACOSX @BINPATH@/res/cursors/* #endif diff --git a/browser/installer/removed-files.in b/browser/installer/removed-files.in index 763bf1f736a1..e776fce6b7a5 100644 --- a/browser/installer/removed-files.in +++ b/browser/installer/removed-files.in @@ -574,15 +574,6 @@ res/wincharset.properties res/maccharset.properties res/unixcharset.properties res/cmessage.txt -res/hiddenWindow.html -res/ua.css -res/html.css -res/quirk.css -res/forms.css -res/viewsource.css -res/mathml.css -res/loading-image.png -res/broken-image.png res/html/gopher-audio.gif res/html/gopher-binary.gif res/html/gopher-find.gif diff --git a/caps/tests/mochitest/test_bug423375.html b/caps/tests/mochitest/test_bug423375.html index fda3515ad384..b5c9f487446c 100644 --- a/caps/tests/mochitest/test_bug423375.html +++ b/caps/tests/mochitest/test_bug423375.html @@ -36,7 +36,7 @@ function tryLoad(url) is(tryLoad("chrome://global/content/mozilla.xhtml"), "denied", "content should have been prevented from loading chrome: URL"); -is(tryLoad("resource://gre-resources/html.css"), "denied", +is(tryLoad("resource://gre/res/html.css"), "denied", "content should have been prevented from loading resource: URL"); diff --git a/dom/src/Makefile.in b/dom/src/Makefile.in index 0c4fe11675a2..a11de4914e35 100644 --- a/dom/src/Makefile.in +++ b/dom/src/Makefile.in @@ -45,3 +45,13 @@ include $(DEPTH)/config/autoconf.mk DIRS = jsurl events storage offline json geolocation threads include $(topsrcdir)/config/rules.mk + +_FILES = \ + $(srcdir)/res/hiddenWindow.html \ + $(NULL) + +libs:: + $(INSTALL) $(_FILES) $(DIST)/bin/res + +install:: + $(SYSINSTALL) $(IFLAGS1) $(_FILES) $(DESTDIR)$(mozappdir)/res diff --git a/dom/src/jar.mn b/dom/src/jar.mn deleted file mode 100644 index 8febb2d5d7c5..000000000000 --- a/dom/src/jar.mn +++ /dev/null @@ -1,2 +0,0 @@ -toolkit.jar: - res/hiddenWindow.html (res/hiddenWindow.html) diff --git a/layout/generic/Makefile.in b/layout/generic/Makefile.in index 09e31b27bb32..e4ef005aa91b 100644 --- a/layout/generic/Makefile.in +++ b/layout/generic/Makefile.in @@ -143,6 +143,11 @@ RESOURCES_HTML = \ $(srcdir)/folder.png \ $(NULL) +RESOURCES = \ + $(srcdir)/broken-image.png \ + $(srcdir)/loading-image.png \ + $(NULL) + FORCE_STATIC_LIB = 1 include $(topsrcdir)/config/rules.mk @@ -170,8 +175,10 @@ endif libs:: $(INSTALL) $(RESOURCES_HTML) $(DIST)/bin/res/html + $(INSTALL) $(RESOURCES) $(DIST)/bin/res install:: $(SYSINSTALL) $(IFLAGS1) $(RESOURCES_HTML) $(DESTDIR)$(mozappdir)/res/html + $(SYSINSTALL) $(IFLAGS1) $(RESOURCES) $(DESTDIR)$(mozappdir)/res DEFINES += -D_IMPL_NS_LAYOUT diff --git a/layout/generic/jar.mn b/layout/generic/jar.mn deleted file mode 100644 index 3ef866fc1651..000000000000 --- a/layout/generic/jar.mn +++ /dev/null @@ -1,3 +0,0 @@ -toolkit.jar: - res/broken-image.png (broken-image.png) - res/loading-image.png (loading-image.png) diff --git a/layout/generic/nsImageFrame.cpp b/layout/generic/nsImageFrame.cpp index bc1202b1ec84..c637b7898297 100644 --- a/layout/generic/nsImageFrame.cpp +++ b/layout/generic/nsImageFrame.cpp @@ -1713,8 +1713,8 @@ nsresult nsImageFrame::LoadIcons(nsPresContext *aPresContext) { NS_ASSERTION(!gIconLoad, "called LoadIcons twice"); - NS_NAMED_LITERAL_STRING(loadingSrc,"resource://gre-resources/loading-image.png"); - NS_NAMED_LITERAL_STRING(brokenSrc,"resource://gre-resources/broken-image.png"); + NS_NAMED_LITERAL_STRING(loadingSrc,"resource://gre/res/loading-image.png"); + NS_NAMED_LITERAL_STRING(brokenSrc,"resource://gre/res/broken-image.png"); gIconLoad = new IconLoad(); if (!gIconLoad) diff --git a/layout/mathml/Makefile.in b/layout/mathml/Makefile.in index 91394b1166d0..f2b11b5e7182 100644 --- a/layout/mathml/Makefile.in +++ b/layout/mathml/Makefile.in @@ -96,6 +96,9 @@ FORCE_STATIC_LIB = 1 include $(topsrcdir)/config/rules.mk +libs:: + $(INSTALL) $(srcdir)/mathml.css $(DIST)/bin/res + font_properties = \ mathfontUnicode.properties \ mathfontSTIXNonUnicode.properties \ diff --git a/layout/mathml/jar.mn b/layout/mathml/jar.mn deleted file mode 100644 index bf801803199f..000000000000 --- a/layout/mathml/jar.mn +++ /dev/null @@ -1,2 +0,0 @@ -toolkit.jar: - res/mathml.css (mathml.css) diff --git a/layout/mathml/mathml-css.pl b/layout/mathml/mathml-css.pl index 18c9388c9099..9be376383365 100644 --- a/layout/mathml/mathml-css.pl +++ b/layout/mathml/mathml-css.pl @@ -12,7 +12,7 @@ if (!($css =~ m|\@import.*mathml\.css|)) { # since bad end of lines cause troubles on some platforms # do a little perl magic for dos2{unix or mac} here - $css =~ s#(\@import[^\@]+\;)(\cM?)(\n\cM?\n)#$1$2\n\@import url\(resource://gre-resources/mathml\.css\);$2$3#; + $css =~ s#(\@import[^\@]+\;)(\cM?)(\n\cM?\n)#$1$2\n\@import url\(resource://gre/res/mathml\.css\);$2$3#; open(UA, ">$ua"); print UA $css; close(UA); diff --git a/layout/style/Makefile.in b/layout/style/Makefile.in index 40527b0e07e2..045ccdad6355 100644 --- a/layout/style/Makefile.in +++ b/layout/style/Makefile.in @@ -156,6 +156,10 @@ LOCAL_INCLUDES = \ $(NULL) _FILES = \ + ua.css \ + html.css \ + quirk.css \ + viewsource.css \ arrow.gif \ arrowd.gif \ contenteditable.css \ diff --git a/layout/style/jar.mn b/layout/style/jar.mn deleted file mode 100644 index bdd52b2a829f..000000000000 --- a/layout/style/jar.mn +++ /dev/null @@ -1,6 +0,0 @@ -toolkit.jar: - res/ua.css (ua.css) - res/html.css (html.css) - res/quirk.css (quirk.css) - res/viewsource.css (viewsource.css) - res/forms.css (forms.css) diff --git a/layout/style/nsLayoutStylesheetCache.cpp b/layout/style/nsLayoutStylesheetCache.cpp index 2fe84c5d77e7..42d00558eedb 100644 --- a/layout/style/nsLayoutStylesheetCache.cpp +++ b/layout/style/nsLayoutStylesheetCache.cpp @@ -102,7 +102,7 @@ nsLayoutStylesheetCache::FormsSheet() if (!gStyleCache->mFormsSheet) { nsCOMPtr sheetURI; NS_NewURI(getter_AddRefs(sheetURI), - NS_LITERAL_CSTRING("resource://gre-resources/forms.css")); + NS_LITERAL_CSTRING("resource://gre/res/forms.css")); // forms.css needs access to unsafe rules if (sheetURI) @@ -179,13 +179,13 @@ nsLayoutStylesheetCache::nsLayoutStylesheetCache() // And make sure that we load our UA sheets. No need to do this // per-profile, since they're profile-invariant. nsCOMPtr uri; - NS_NewURI(getter_AddRefs(uri), "resource://gre-resources/ua.css"); + NS_NewURI(getter_AddRefs(uri), "resource://gre/res/ua.css"); if (uri) { LoadSheet(uri, mUASheet, PR_TRUE); } NS_ASSERTION(mUASheet, "Could not load ua.css"); - NS_NewURI(getter_AddRefs(uri), "resource://gre-resources/quirk.css"); + NS_NewURI(getter_AddRefs(uri), "resource://gre/res/quirk.css"); if (uri) { LoadSheet(uri, mQuirkSheet, PR_TRUE); } diff --git a/layout/style/ua.css b/layout/style/ua.css index 65d946ab7787..e6cf8a45d215 100644 --- a/layout/style/ua.css +++ b/layout/style/ua.css @@ -34,7 +34,7 @@ * * ***** END LICENSE BLOCK ***** */ -@import url(resource://gre-resources/html.css); +@import url(resource://gre/res/html.css); @import url(chrome://global/content/xul.css); @namespace parsererror url(http://www.mozilla.org/newlayout/xml/parsererror.xml); diff --git a/parser/htmlparser/src/nsExpatDriver.cpp b/parser/htmlparser/src/nsExpatDriver.cpp index 87b8c0a57234..f3b1d52c9014 100644 --- a/parser/htmlparser/src/nsExpatDriver.cpp +++ b/parser/htmlparser/src/nsExpatDriver.cpp @@ -290,9 +290,9 @@ static const nsCatalogData kCatalogTable[] = { { "-//W3C//DTD XHTML 1.0 Strict//EN", "xhtml11.dtd", nsnull }, { "-//W3C//DTD XHTML 1.0 Frameset//EN", "xhtml11.dtd", nsnull }, { "-//W3C//DTD XHTML Basic 1.0//EN", "xhtml11.dtd", nsnull }, - { "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN", "mathml.dtd", "resource://gre-resources/res/mathml.css" }, - { "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN", "mathml.dtd", "resource://gre-resources/mathml.css" }, - { "-//W3C//DTD MathML 2.0//EN", "mathml.dtd", "resource://gre-resources/mathml.css" }, + { "-//W3C//DTD XHTML 1.1 plus MathML 2.0//EN", "mathml.dtd", "resource://gre/res/mathml.css" }, + { "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN", "mathml.dtd", "resource://gre/res/mathml.css" }, + { "-//W3C//DTD MathML 2.0//EN", "mathml.dtd", "resource://gre/res/mathml.css" }, { "-//WAPFORUM//DTD XHTML Mobile 1.0//EN", "xhtml11.dtd", nsnull }, { nsnull, nsnull, nsnull } }; diff --git a/parser/htmlparser/src/nsViewSourceHTML.cpp b/parser/htmlparser/src/nsViewSourceHTML.cpp index b9a4be2b3663..843c93efb902 100644 --- a/parser/htmlparser/src/nsViewSourceHTML.cpp +++ b/parser/htmlparser/src/nsViewSourceHTML.cpp @@ -281,7 +281,7 @@ CViewSourceHTML::WillBuildModel(const CParserContext& aParserContext, fprintf(gDumpFile, "Source of: "); fputs(NS_ConvertUTF16toUTF8(mFilename).get(), gDumpFile); fprintf(gDumpFile, "\n"); - fprintf(gDumpFile, "\n"); + fprintf(gDumpFile, "\n"); fprintf(gDumpFile, "\n"); fprintf(gDumpFile, "\n"); fprintf(gDumpFile, "\n"); @@ -371,7 +371,7 @@ NS_IMETHODIMP CViewSourceHTML::BuildModel(nsITokenizer* aTokenizer, AddAttrToNode(theNode, theAllocator, NS_LITERAL_STRING("href"), - NS_LITERAL_STRING("resource://gre-resources/viewsource.css")); + NS_LITERAL_STRING("resource://gre/res/viewsource.css")); mSink->AddLeaf(theNode); } diff --git a/xpfe/appshell/src/nsAppShellService.cpp b/xpfe/appshell/src/nsAppShellService.cpp index 4dcc94a3df9c..23a0bf420f2b 100644 --- a/xpfe/appshell/src/nsAppShellService.cpp +++ b/xpfe/appshell/src/nsAppShellService.cpp @@ -77,7 +77,7 @@ #include "nsIUnicodeDecoder.h" // Default URL for the hidden window, can be overridden by a pref on Mac -#define DEFAULT_HIDDENWINDOW_URL "resource://gre-resources/hiddenWindow.html" +#define DEFAULT_HIDDENWINDOW_URL "resource://gre/res/hiddenWindow.html" class nsIAppShell;