From 5f8de423f190bbb79a62f804151bc24824fa32d8 Mon Sep 17 00:00:00 2001 From: "Matt A. Tobin" Date: Fri, 2 Feb 2018 04:16:08 -0500 Subject: Add m-esr52 at 52.6.0 --- dom/xml/test/old/books/bethlehem.gif | Bin 0 -> 5565 bytes dom/xml/test/old/books/bill.gif | Bin 0 -> 5022 bytes dom/xml/test/old/books/books.js | 97 +++++++++++++++++++++++++++++++++ dom/xml/test/old/books/books.xml | 103 +++++++++++++++++++++++++++++++++++ dom/xml/test/old/books/charing.gif | Bin 0 -> 5947 bytes dom/xml/test/old/books/classic.css | 78 ++++++++++++++++++++++++++ dom/xml/test/old/books/common.css | 43 +++++++++++++++ dom/xml/test/old/books/kerouac.gif | Bin 0 -> 50387 bytes dom/xml/test/old/books/list.css | 61 +++++++++++++++++++++ dom/xml/test/old/books/road.gif | Bin 0 -> 8004 bytes dom/xml/test/old/books/welville.gif | Bin 0 -> 4535 bytes 11 files changed, 382 insertions(+) create mode 100644 dom/xml/test/old/books/bethlehem.gif create mode 100644 dom/xml/test/old/books/bill.gif create mode 100644 dom/xml/test/old/books/books.js create mode 100644 dom/xml/test/old/books/books.xml create mode 100644 dom/xml/test/old/books/charing.gif create mode 100644 dom/xml/test/old/books/classic.css create mode 100644 dom/xml/test/old/books/common.css create mode 100644 dom/xml/test/old/books/kerouac.gif create mode 100644 dom/xml/test/old/books/list.css create mode 100644 dom/xml/test/old/books/road.gif create mode 100644 dom/xml/test/old/books/welville.gif (limited to 'dom/xml/test/old/books') diff --git a/dom/xml/test/old/books/bethlehem.gif b/dom/xml/test/old/books/bethlehem.gif new file mode 100644 index 000000000..db41f52fb Binary files /dev/null and b/dom/xml/test/old/books/bethlehem.gif differ diff --git a/dom/xml/test/old/books/bill.gif b/dom/xml/test/old/books/bill.gif new file mode 100644 index 000000000..4b00f890c Binary files /dev/null and b/dom/xml/test/old/books/bill.gif differ diff --git a/dom/xml/test/old/books/books.js b/dom/xml/test/old/books/books.js new file mode 100644 index 000000000..3e4a01d11 --- /dev/null +++ b/dom/xml/test/old/books/books.js @@ -0,0 +1,97 @@ + +// An inefficient, but effective bubble sort +function sort(collection, key) +{ + var i, j; + var count = collection.length; + var parent, child; + + for (i = count-1; i >= 0; i--) { + for (j = 1; j <= i; j++) { + if (collection[j-1][key] > collection[j][key]) { + // Move the item both in the local array and + // in the tree + child = collection[j]; + parent = child.parentNode; + + collection[j] = collection[j-1]; + collection[j-1] = child; + + parent.removeChild(child); + parent.insertBefore(child, collection[j]); + } + } + } +} + +// Set user properties on the nodes in the collection +// based on information found in its children. For example, +// make a property "Author" based on the content of the +// "Author" element found in the childNode list of the node. +// This makes later sorting more efficient +function collectInfo(nodes, propNames) +{ + var i, j, k; + var ncount = nodes.length; + var pcount = propNames.length; + + for (i = 0; i < ncount; i++) { + var node = nodes[i]; + var childNodes = node.childNodes; + var ccount = childNodes.length; + + for (j = 0; j < ccount; j++) { + var child = childNodes[j]; + + if (child.nodeType == Node.ELEMENT_NODE) { + var tagName = child.tagName; + + for (k = 0; k < pcount; k++) { + var prop = propNames[k]; + if (prop == tagName) { + node[prop] = child.firstChild.data; + } + } + } + } + } +} + +var enabled = true; +function toggleStyleSheet() +{ + if (enabled) { + document.styleSheets[2].disabled = true; + } + else { + document.styleSheets[2].disabled = false; + } + + enabled = !enabled; +} + +// XXX This is a workaround for a bug where +// changing the disabled state of a stylesheet can't +// be done in an event handler. For now, we do it +// in a zero-delay timeout. +function initiateToggle() +{ + setTimeout(toggleStyleSheet, 0); +} + +var sortableProps = new Array("Author", "Title", "ISBN"); +var books = new Array(); + +// We uppercase the tagName as a workaround for a bug +// that loses the original case of the tag. +var bookset = document.getElementsByTagName("Book"); + +// We need to create a "non-live" array to operate on. Since +// we'll be moving things around in this array, we can't use +// the read-only, live one returned by getElementsByTagName. +for (var i=0; i < bookset.length; i++) { + books[i] = bookset[i]; +} + +collectInfo(books, sortableProps); + diff --git a/dom/xml/test/old/books/books.xml b/dom/xml/test/old/books/books.xml new file mode 100644 index 000000000..2067487d8 --- /dev/null +++ b/dom/xml/test/old/books/books.xml @@ -0,0 +1,103 @@ + + + + + + + + + +
+ + + + + + + + + + + Amazon.com Search Results for: the keywords include "Road" +
+ + + + + + On the Road + Kerouac, Jack + 0140042598 + +On The Road, the most famous of Jack Kerouac's works, is not only the soul of the Beat movement and literature, but one of the most important novels of the century. Like nearly all of Kerouac's writing, On The Road is thinly fictionalized autobiography, filled with a cast made of Kerouac's real life friends, lovers, and fellow travelers. Narrated by Sal Paradise, one of Kerouac's alter-egos, On the Road is a cross-country bohemian odyssey that not only influenced writing in the years since its 1957 publication but penetrated into the deepest levels of American thought and culture. + + $12.95 + $10.36 + + + + + The Road Ahead + Gates, Bill + 666666666 + +In a study, the founder of Microsoft presents his vision for the future in which he sees the digital technologies of the coming years changing the way we buy, work, learn, and communicate. But he doesn't mention XML! + + $15.95 + $12.76 + + + + + The Road to Wellville + Boyle, T. Coraghessan + 0140167188 + +A snobbish wife and her henpecked husband travel to Dr. Kellogg's spa in turn-of-the-century Battle Creek, where the youth-crazed affluent succumb to quackery. By the author of East is East. + + $12.95 + $10.36 + + + + + AAA Road Atlas 1999 + A. A. A. + 1562512625 + +The definitive road atlas to the United States, Canada and Mexico. + + $9.95 + $9.95 + + + + + Bethlehem Road + Perry, Anne + 0449219143 + +He might be elegant, but there's no mistaking it--the gentleman tied to the lamppost on Westminster Bridge is definitely dead. Before Inspector Thomas Pitt can even speculate on why anyone should want to kill the eminent M.P., Sir Lockwood, a colleague of his, meets the same fate at the same spot. The public is outraged, and clever Charlotte Pitt, Thomas's well-born wife, helps her hard-pressed husband by scouting society's drawing rooms for clues to these appalling crimes. Meanwhile, another victim is being stalked.... + + $6.99 + $5.59 + + + + + 84 Charing Cross Road + Hanff, Helene + 0140143505 + +84, Charing Cross Road is a charming record of bibliophilia, cultural difference, and imaginative sympathy. For 20 years, an outspoken New York writer and a rather more restrained London bookseller carried on an increasingly touching correspondence... + + $9.95 + $7.96 + + + + + + +
diff --git a/dom/xml/test/old/books/charing.gif b/dom/xml/test/old/books/charing.gif new file mode 100644 index 000000000..9a63fb0b2 Binary files /dev/null and b/dom/xml/test/old/books/charing.gif differ diff --git a/dom/xml/test/old/books/classic.css b/dom/xml/test/old/books/classic.css new file mode 100644 index 000000000..1ebc92f6e --- /dev/null +++ b/dom/xml/test/old/books/classic.css @@ -0,0 +1,78 @@ + + +BookSet { + display: block; +} + +Book { + float: left; + display: block; + width: 300px; + background-color: #f1f1f1; + border: 1px solid #cccccc; + margin-right: 8px; + margin-top: 8px; +} + +BookCover { + display: inline; + float: left; + margin-right: 10px; + padding: 5px; + width: 100px; + height: 140px; +} + +Title { + display: block; + font-weight: bold; + color: blue; + text-decoration: underline; + cursor: pointer; +} + +Author { + display: block; + font-style: italic; +} + +Synopsis { + display: block; + overflow: scroll; + height: 100px; + width: 155px; + padding: 3px; + background-color: #ddddff; +} + + +ListPrice { + display: block; + text-align: right; + padding-right: 15px; + text-decoration: line-through; +} + + +Price { + display: block; + color: rgb(20,100,0); + text-align:right; + padding-right: 15px; + font-weight: bold; +} + + +Price:before { + content: "Our Price: "; +} + +ISBN { + display: block; + font-family: monospace; + font-size: 8pt; +} + + + + diff --git a/dom/xml/test/old/books/common.css b/dom/xml/test/old/books/common.css new file mode 100644 index 000000000..d63f09585 --- /dev/null +++ b/dom/xml/test/old/books/common.css @@ -0,0 +1,43 @@ +SearchResult { + display: block; + margin-top: 8px; + margin-left: 8px; +} + +Header { + width: 612px; + display: block; +} + +SearchTitle { + display: block; + width: 280px; + border-bottom: thin solid black; + padding-bottom: 6px; + margin-bottom: 12px; +} + +SearchTitle:first-line { + font-family: Verdana, Sans-Serif; + color: #cc6600; + font-size: 14pt; +} + +Toolbar { + font-family: Verdana, Sans-Serif; + float: right; + font-size: 7pt; + display: block; + border: ridge #ddddff 4px; + width: 220px; + margin-right: 0px; + text-align: center; +} + +Label { + font-weight: bold; +} + +input { + margin-top: 2px; +} \ No newline at end of file diff --git a/dom/xml/test/old/books/kerouac.gif b/dom/xml/test/old/books/kerouac.gif new file mode 100644 index 000000000..df2b371d0 Binary files /dev/null and b/dom/xml/test/old/books/kerouac.gif differ diff --git a/dom/xml/test/old/books/list.css b/dom/xml/test/old/books/list.css new file mode 100644 index 000000000..3b5d40891 --- /dev/null +++ b/dom/xml/test/old/books/list.css @@ -0,0 +1,61 @@ + +BookSet { + display: block; +} + +Book { + display: list-item; + float: none; + border: none; + background: inherit; +} + +BookCover { + display: none; +} + +Title { + display: block; + font-weight: bold; + color: blue; + text-decoration: underline; + cursor: pointer; +} + +Author { + display: block; + font-style: italic; +} + +Synopsis { + display: none; +} + + +ListPrice { + display: none; + text-align: right; + padding-right: 15px; + text-decoration: line-through; +} + + +Price { + display: block; + color: rgb(20,100,0); + font-weight: bold; + text-align:left; +} + + +Price:before { + content: "Our Price: "; +} + +ISBN { + display: block; + font-family: monospace; + font-size: 8pt; +} + + diff --git a/dom/xml/test/old/books/road.gif b/dom/xml/test/old/books/road.gif new file mode 100644 index 000000000..5ba7920c7 Binary files /dev/null and b/dom/xml/test/old/books/road.gif differ diff --git a/dom/xml/test/old/books/welville.gif b/dom/xml/test/old/books/welville.gif new file mode 100644 index 000000000..7ff24a99e Binary files /dev/null and b/dom/xml/test/old/books/welville.gif differ -- cgit v1.2.3