# HG changeset patch
# User robcast
# Date 1098995159 -7200
# Node ID 58d9cbdfb0c9ce16c04563e0cba9382c55ece339
# Parent 6f88ad4b36e1ef4a59d7f42cc0a87a4ad26725c2
big autumn cleaning :-)
- finally digilib.jsp uses the new javascript code
- dito digicat.jsp
- all files corresponding to the old frontend moved into /oldskin
- all icons moved into /img
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/baselib.js
--- a/client/digitallibrary/baselib.js Thu Oct 28 22:25:58 2004 +0200
+++ b/client/digitallibrary/baselib.js Thu Oct 28 22:25:59 2004 +0200
@@ -17,16 +17,10 @@
Authors:
Christian Luginbuehl, 01.05.2003 (first version)
DW 24.03.2004 (Changed for digiLib in Zope)
- Robert Casties, 03.08.2004
+ Robert Casties, 27.10.2004
*/
-function identify() {
- // used for identifying a digilib instance
- // Relato uses that function - lugi
- return "Digilib 0.6";
-}
-
function getInt(n) {
// returns always an integer
n = parseInt(n);
@@ -579,8 +573,8 @@
return wsize;
}
-function openWin(url, title, params) {
+function openWin(url, name, params) {
// open browser window
- var ow = window.open(url, title, params);
+ var ow = window.open(url, name, params);
ow.focus();
}
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/dcMenu.html
--- a/client/digitallibrary/dcMenu.html Thu Oct 28 22:25:58 2004 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/dlMenu.html
--- a/client/digitallibrary/dlMenu.html Thu Oct 28 22:25:58 2004 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,100 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark1.gif
Binary file client/digitallibrary/mark1.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark2.gif
Binary file client/digitallibrary/mark2.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark3.gif
Binary file client/digitallibrary/mark3.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark4.gif
Binary file client/digitallibrary/mark4.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark5.gif
Binary file client/digitallibrary/mark5.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark6.gif
Binary file client/digitallibrary/mark6.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark7.gif
Binary file client/digitallibrary/mark7.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/mark8.gif
Binary file client/digitallibrary/mark8.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/navcat.html
--- a/client/digitallibrary/navcat.html Thu Oct 28 22:25:58 2004 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,50 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/navcat.js
--- a/client/digitallibrary/navcat.js Thu Oct 28 22:25:58 2004 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,188 +0,0 @@
-/*
-
-Copyright (C) 2003 WTWG, Uni Bern
-
-This program is free software; you can redistribute it and/or
-modify it under the terms of the GNU General Public License
-as published by the Free Software Foundation; either version 2
-of the License, or (at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
-
-Author: Christian Luginbuehl, 07.04.2004 , Version Alcatraz 0.6
-
-*/
-
-function identify() {
- return 'Digicat v0.3';
-}
-
-
-dcParams = new Object();
-
-function newParameter(name, value, defaultValue, detail) {
-
- if ( !dcParams[name] ) {
-
- dcParams[name] = new Object();
-
- dcParams[name].value = value;
- dcParams[name].defaultValue = defaultValue;
- dcParams[name].detail = detail;
-
- return dcParams[name];
-
- } else {
-
- alert("Fatal: An object with name '" + name + "' already exists - cannot recreate!");
- return false;
-
- }
-}
-
-function getParameter(name) {
-
- if ( dcParams[name] ) {
- return dcParams[name].value;
- } else {
- return false;
- }
-}
-
-
-
-function listParametersAsString() {
-
- var params = new Array();
-
- for ( param in dcParams ) {
- params.push(param);
- }
-
- return params.join(",");
-
-}
-
-
-function listParameters() {
-
- var params = new Array();
-
- for ( param in dcParams ) {
- params.push(param);
- }
-
- return params;
-
-}
-
-
-function init() {
-
- var fWidth = document.body ? document.body.clientWidth : innerWidth;
- var fHeight = document.body ? document.body.clientHeight : innerHeight;
-
- if (!dcParams.mo.value) {
- dcParams.mo.value = dcParams.mo.defaultValue;
- }
-
- var cells = dcParams.mo.value.split('x');
-
- var picWidth = (dcParams.dw.value != 0) ? dcParams.dw.value : Math.floor((fWidth-30)/cells[0])-2*cells[0]-1;
- var picHeight = (dcParams.dh.value != 0) ? dcParams.dh.value : picWidth;
-
- if (cells.length > 1) {
- picHeight = (dcParams.dh.value != 0) ? dcParams.dh.value : Math.floor(((fHeight-30)-12*cells[1])/cells[1])-2*cells[1]-1;
- } else {
- cells[1] = Math.ceil(dcParams.pt.value/cells[0]);
- }
-
- var cellWidth = parseInt(picWidth)+8;
- var cellHeight = parseInt(picHeight)+18;
-
- document.write('');
-
- for (var j = 0; j < cells[1]; j++) {
- document.write(' ');
- for (var i = 0; i < cells[0]; i++) {
- var idx = parseInt(dcParams.pn.value)+i+j*cells[0];
- var img = baseUrl + "/servlet/Scaler/?fn=" + dcParams.fn.value + "&pn=" + idx;
- img += "&dw=" + picWidth + "&dh=" + picHeight + "&mo=q0";
- document.write(' ');
- if (idx <= dcParams.pt.value) {
- document.write('  ' + idx);
- } else {
- document.write(' ');
- }
- document.write(' | ');
-
- }
- document.write('
');
- }
-
- document.write('
');
-}
-
-
-function load(i) {
- var link = baseUrl + "/digilib.jsp?fn=" + dcParams.fn.value + "&pn=" + i + "&lv=3";
-
- if (typeof(top.loadFocusedFrame) == 'function') {
- top.loadFocusedFrame(link);
- } else {
- var win = window.open(link, 'digilib');
- win.focus();
- }
-}
-
-
-function Backpage() {
-
- if (att[1] <= 1) {
- att[1] = 1;
- alert("You are already on the first page!");
- }
-
- att[1] = parseInt(att[1])-parseInt(att[2]*att[3]);
-
- if (att[1] < 1) {
- att[1] = 1;
- }
- loadThumbTable();
-}
-
-
-
-function Nextpage() {
-
- att[1] = parseInt(att[1])+parseInt(att[2]*att[3]);
- loadThumbTable();
-}
-
-
-// capturing keypresses for next and previous page
-// ascii-values of n = 110, b = 98
-function parseKeypress (event) {
- if (event.charCode == 110) {
- Nextpage();
- }
- if (event.charCode == 98) {
- Backpage();
- }
-}
-
-
-// initialize browser specific things (keypress caputring)
-function initScripts() {
- for (var f = 0; f < frames.length; f++) {
- frames[f].document.addEventListener('keypress', parseKeypress, true);
- }
- whichFrame.focus();
-}
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/navigation.js
--- a/client/digitallibrary/navigation.js Thu Oct 28 22:25:58 2004 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,723 +0,0 @@
-/*
-
-Copyright (C) 2003 WTWG, Uni Bern
-
-This program is free software; you can redistribute it and/or
-modify it under the terms of the GNU General Public License
-as published by the Free Software Foundation; either version 2
-of the License, or (at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
-
-Author: Christian Luginbuehl, 01.05.2003 , Version Alcatraz 0.4
-
-*/
-
-function identify() {
- return 'Digilib v0.6';
-}
-
-
-var ZOOMFACTOR = Math.sqrt(2);
-
-dlParams = new Object();
-
-function newParameter(name, value, defaultValue, detail) {
-
- if ( !dlParams[name] ) {
-
- dlParams[name] = new Object();
-
- dlParams[name].value = value;
- dlParams[name].defaultValue = defaultValue;
- dlParams[name].detail = detail;
-
- return dlParams[name];
-
- } else {
-
- alert("Fatal: An object with name '" + name + "' already exists - cannot recreate!");
- return false;
-
- }
-}
-
-function getParameter(name) {
-
- if ( dlParams[name] ) {
- return dlParams[name].value;
- } else {
- return false;
- }
-}
-
-
-
-function listParametersAsString() {
-
- var params = new Array();
-
- for ( param in dlParams ) {
- params.push(param);
- }
-
- return params.join(",");
-
-}
-
-
-function listParameters() {
-
- var params = new Array();
-
- for ( param in dlParams ) {
- params.push(param);
- }
-
- return params;
-
-}
-
-
-function init() {
-
- // give a name to the window containing digilib - this way one can test if there is already a
- // digilib-window open and replace the contents of it (ex. digicat)
- top.window.name = "digilib";
-
- placeMarks();
-
- if ( document.all ) {
- this.document.onkeypress = parseKeypress;
- } else if ( typeof(document.addEventListener) == "function" ) {
- this.document.addEventListener('keypress', parseKeypress, true);
- } else {
- window.captureEvents(Event.KEYDOWN);
- window.onkeydown = parseKeypress;
- }
-
- focus();
-}
-
-
-function display(detail) {
-
- var queryString = '';
-
- for ( param in dlParams ) {
-
- if ( dlParams[param].defaultValue != dlParams[param].value ) {
- if ( dlParams[param].detail <= detail ) {
- queryString += "&" + param + "=" + dlParams[param].value;
- } else {
- queryString += "&" + param + "=" + dlParams[param].defaultValue;
- }
- }
-
- }
-
- // window size
- var wwidth, wheight;
- if (self.innerHeight) // all except Explorer
- {
- wwidth = self.innerWidth;
- wheight = self.innerHeight;
- }
- else if (document.documentElement && document.documentElement.clientHeight)
- // Explorer 6 Strict Mode
- {
- wwidth = document.documentElement.clientWidth;
- wheight = document.documentElement.clientHeight;
- }
- else if (document.body) // other Explorers
- {
- wwidth = document.body.clientWidth;
- wheight = document.body.clientHeight;
- }
- queryString += "&dw=" + (wwidth-30) + "&dh=" + (wheight-30);
-
- queryString += "&lv=1";
-
- queryString = queryString.slice(1);
-
- location.href = location.protocol + "//" + location.host + location.pathname + "?" + queryString;
-
-}
-
-
-// constructor holding different values of a point
-function Point(evt) {
-
- if ( document.all ) {
-
- this.pageX = parseInt(document.body.scrollLeft+event.clientX);
- this.pageY = parseInt(document.body.scrollLeft+event.clientY);
-
- this.x = this.pageX-parseInt(document.all.lay1.style.left);
- this.y = this.pageY-parseInt(document.all.lay1.style.top);
-
- this.relX = cropFloat(parseFloat(dlParams.wx.value)+(dlParams.ww.value*this.x/document.all.lay1.offsetWidth));
- this.relY = cropFloat(parseFloat(dlParams.wy.value)+(dlParams.wh.value*this.y/document.all.lay1.offsetHeight));
-
- } else {
-
- this.pageX = parseInt(evt.pageX);
- this.pageY = parseInt(evt.pageY);
-
- if ( typeof(document.getElementById) == "function" ) {
-
- this.x = this.pageX-parseInt(document.getElementById("lay1").style.left);
- this.y = this.pageY-parseInt(document.getElementById("lay1").style.top);
-
- this.relX = cropFloat(parseFloat(dlParams.wx.value)+(dlParams.ww.value*this.x/document.pic.offsetWidth));
- this.relY = cropFloat(parseFloat(dlParams.wy.value)+(dlParams.wh.value*this.y/document.pic.offsetHeight));
-
- } else {
-
- this.x = this.pageX-document.lay1.left;
- this.y = this.pageY-document.lay1.top;
-
- this.relX = cropFloat(parseFloat(dlParams.wx.value)+(dlParams.ww.value*this.x/document.lay1.clip.width));
- this.relY = cropFloat(parseFloat(dlParams.wy.value)+(dlParams.wh.value*this.y/document.lay1.clip.height));
-
- }
-
- }
-
- return this;
-
-}
-
-
-function page(page, details) {
-
- if ( details == null ) {
- details = 1;
- }
-
- if ( page.indexOf('-') == 0 ) {
- if ( dlParams.pn.value > 1 ) {
- page = Math.max(parseInt(dlParams.pn.value) - parseInt(page.slice(1)), 1);
- dlParams.pn.value = page;
- display(details);
- } else {
- alert("You are already on the first page!");
- }
-
- } else if ( page.indexOf('+') == 0 ) {
- page = parseInt(dlParams.pn.value) + parseInt(page.slice(1));
- dlParams.pn.value = page;
- display(details);
- } else if ( page == parseInt(page) ) {
- dlParams.pn.value = parseInt(page);
- display(details);
- }
-
-}
-
-
-function digicat() {
-
- var url = baseUrl + "/digicat.jsp?" + dlParams.fn.value + "+" + dlParams.pn.value;
- win = window.open(url, "digicat");
- win.focus();
-
-}
-
-
-function ref() {
-
- var hyperlinkRef = baseUrl + "/digilib.jsp?";
- hyperlinkRef += dlParams.fn.value + "+" + dlParams.pn.value + "+" + dlParams.ws.value + "+";
- hyperlinkRef += dlParams.mo.value + "+" + dlParams.mk.value;
-
- if ( (dlParams.wx.value != 0) || (dlParams.wy.value != 0) || (dlParams.ww.value != 1) || (dlParams.wh.value != 1) ) {
- hyperlinkRef += "+" + dlParams.wx.value + "+" + dlParams.wy.value + "+" + dlParams.ww.value;
- hyperlinkRef += "+" + dlParams.wh.value;
- }
-
- return hyperlinkRef;
-
-}
-
-
-function ref(select) {
-
- if ( select == 0 ) {
- prompt("Link for LaTeX-documents", "\\href{" + ref() + "}{TEXT}");
- } else if ( select == 1 ) {
- prompt("Link for HTML-documents", ref());
- }
-}
-
-
-function mark() {
-
- if ( dlParams.mk.value.split(";").length > 7 ) {
- alert("Only 8 marks are possible at the moment!");
- return;
- }
-
- function markEvent(evt) {
-
- var point = new Point(evt);
-
- if ( dlParams.mk.value != '' ) {
- dlParams.mk.value += ';';
- }
-
- dlParams.mk.value += point.relX + '/' + point.relY;
-
- // stopping event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = null;
- } else if ( typeof(document.removeEventListener) == "function" ) {
- document.getElementById("lay1").removeEventListener("mousedown", markEvent, true);
- } else {
- document.lay1.releaseEvents(Event.MOUSEDOWN);
- }
-
- placeMarks();
-
- }
-
- // starting event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = markEvent;
- } else if ( typeof(document.addEventListener) == "function" ) {
- document.getElementById("lay1").addEventListener("mousedown", markEvent, true);
- } else {
- document.lay1.captureEvents(Event.MOUSEDOWN);
- document.lay1.onmousedown = markEvent;
- }
-}
-
-
-function placeMarks() {
-
- if ( dlParams.mk.value != '' ) {
-
- var mark = dlParams.mk.value.split(";");
- var mark_count = mark.length;
-
- // maximum of marks is 8
- // we do not report this error because this is already done in function 'mark'
- if ( mark_count > 8 ) mark_count = 8;
-
- var picWidth = (document.all) ? parseInt(document.all.lay1.offsetWidth) : (typeof(document.getElementById) == "function") ? parseInt(document.pic.offsetWidth) : parseInt(document.pic.clip.width);
- var picHeight = (document.all) ? parseInt(document.all.lay1.offsetHeight) : (typeof(document.getElementById) == "function") ? parseInt(document.pic.offsetHeight) : parseInt(document.pic.clip.height);
-
- // catch the cases where the picture had not been loaded already and
- // make a timeout so that the coordinates are calculated with the real dimensions
- if ( (document.pic.complete) || (picWidth > 30) ) {
-
- var xOffset = (document.all) ? parseInt(document.all.lay1.style.left) : (typeof(document.getElementById) == "function") ? parseInt(document.getElementById('lay1').style.left) : document.lay1.left;
- var yOffset = (document.all) ? parseInt(document.all.lay1.style.top) : (typeof(document.getElementById) == "function") ? parseInt(document.getElementById('lay1').style.top) : document.lay1.top;
-
- for (var i = 0; i < mark_count; i++) {
- mark[i] = mark[i].split("/");
-
- if ( (mark[i][0] >= dlParams.wx.value) && (mark[i][1] >= dlParams.wy.value) && (mark[i][0] <= (parseFloat(dlParams.wx.value) + parseFloat(dlParams.ww.value))) && (mark[i][1] <= (parseFloat(dlParams.wy.value) + parseFloat(dlParams.wh.value))) ) {
-
- mark[i][0] = parseInt(xOffset + picWidth * (mark[i][0] - dlParams.wx.value)/dlParams.ww.value);
- mark[i][1] = parseInt(yOffset + picHeight * (mark[i][1] - dlParams.wy.value)/dlParams.wh.value);
-
- if ( (document.all) || (typeof(document.getElementById) == "function") ) {
- // suboptimal to place -5 pixels and not half size of mark-image
- // should be changed in the future
- document.getElementById("dot" + i).style.left = mark[i][0]-5;
- document.getElementById("dot" + i).style.top = mark[i][1]-5;
- document.getElementById("dot" + i).style.visibility = "visible";
- } else {
- document.layers[i+1].moveTo(mark[i][0]-5, mark[i][1]-5);
- document.layers[i+1].visibility = "show";
- }
- }
- }
-
- } else {
- setTimeout("placeMarks()", 100);
- }
- }
-}
-
-
-function zoomPoint() {
-
- function zoomPointEvent(evt) {
-
- var point = new Point(evt);
-
- dlParams.wx.value = cropFloat(point.relX-0.5*dlParams.ww.value*(1/ZOOMFACTOR));
- dlParams.wy.value = cropFloat(point.relY-0.5*dlParams.wh.value*(1/ZOOMFACTOR));
-
- dlParams.ww.value = cropFloat(dlParams.ww.value*(1/ZOOMFACTOR));
- dlParams.wh.value = cropFloat(dlParams.wh.value*(1/ZOOMFACTOR));
-
- if ( dlParams.wx.value < 0 ) {
- dlParams.wx.value = 0;
- }
- if ( dlParams.wy.value < 0 ) {
- dlParams.wy.value = 0;
- }
- if ( dlParams.wx.value + dlParams.ww.value > 1 ) {
- dlParams.wx.value = 1 - dlParams.ww.value;
- }
- if ( dlParams.wy.value + dlParams.wh.value > 1 ) {
- dlParams.wy.value = 1 - dlParams.wh.value;
- }
-
- // stopping event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = null;
- } else if ( typeof(document.removeEventListener) == "function" ) {
- document.getElementById("lay1").removeEventListener("mousedown", zoomPointEvent, true);
- } else {
- document.lay1.releaseEvents(Event.MOUSEDOWN);
- }
-
- display(3);
- }
-
- // starting event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = zoomPointEvent;
- } else if ( typeof(document.addEventListener) == "function" ) {
- document.getElementById("lay1").addEventListener("mousedown", zoomPointEvent, true);
- } else {
- document.lay1.captureEvents(Event.MOUSEDOWN);
- document.lay1.onmousedown = zoomPointEvent;
- }
-}
-
-
-function zoomArea() {
- var state = 0;
- var pt1, pt2;
-
- function click(evt) {
-
- if (state == 0) {
- state = 1;
-
- pt1 = new Point(evt);
- pt2 = pt1;
-
- if ( document.all ) {
-
- document.all.eck1.style.left = pt1.pageX;
- document.all.eck1.style.top = pt1.pageY;
- document.all.eck2.style.left = pt2.pageX-12;
- document.all.eck2.style.top = pt1.pageY;
- document.all.eck3.style.left = pt1.pageX;
- document.all.eck3.style.top = pt2.pageY-12;
- document.all.eck4.style.left = pt2.pageX-12;
- document.all.eck4.style.top = pt2.pageY-12;
-
- document.all.eck1.style.visibility="visible";
- document.all.eck2.style.visibility="visible";
- document.all.eck3.style.visibility="visible";
- document.all.eck4.style.visibility="visible";
-
- document.all.lay1.onmousemove = move;
- document.all.eck4.onmousemove = move;
-
- } else if ( typeof(document.addEventListener) == "function" ) {
-
- document.getElementById("eck1").style.left = pt1.pageX;
- document.getElementById("eck1").style.top = pt1.pageY;
- document.getElementById("eck2").style.left = pt2.pageX-12;
- document.getElementById("eck2").style.top = pt1.pageY;
- document.getElementById("eck3").style.left = pt1.pageX;
- document.getElementById("eck3").style.top = pt2.pageY-12;
- document.getElementById("eck4").style.left = pt2.pageX-12;
- document.getElementById("eck4").style.top = pt2.pageY-12;
-
- document.getElementById("eck1").style.visibility="visible";
- document.getElementById("eck2").style.visibility="visible";
- document.getElementById("eck3").style.visibility="visible";
- document.getElementById("eck4").style.visibility="visible";
-
- document.getElementById("lay1").addEventListener("mousemove", move, true);
- document.getElementById("eck4").addEventListener("mousemove", move, true);
-
- } else {
-
- document.eck1.moveTo(pt1.pageX, pt1.pageY);
- document.eck2.moveTo(pt2.pageX-12, pt1.pageY);
- document.eck3.moveTo(pt1.pageX, pt2.pageY-12);
- document.eck4.moveTo(pt2.pageX-12, pt2.pageY-12);
-
- document.eck1.visibility="show";
- document.eck2.visibility="show";
- document.eck3.visibility="show";
- document.eck4.visibility="show";
-
- document.lay1.captureEvents(Event.MOUSEMOVE);
- document.eck4.captureEvents(Event.MOUSEMOVE);
- document.lay1.onmousemove = move;
- document.eck4.onmousemove = move;
-
- }
-
- } else {
-
- pt2 = new Point(evt);
-
- if ( document.all ) {
-
- document.all.eck1.visibility="hidden";
- document.all.eck2.visibility="hidden";
- document.all.eck3.visibility="hidden";
- document.all.eck4.visibility="hidden";
-
- document.all.lay1.onmousedown = null;
- document.all.eck4.onmousedown = null;
- document.all.lay1.onmousemove = null;
- document.all.eck4.onmousemove = null;
-
- } else if ( typeof(document.removeEventListener) == "function" ) {
-
- document.getElementById("eck1").style.visibility="hidden";
- document.getElementById("eck2").style.visibility="hidden";
- document.getElementById("eck3").style.visibility="hidden";
- document.getElementById("eck4").style.visibility="hidden";
-
- document.getElementById("lay1").removeEventListener("mousedown", click, true);
- document.getElementById("eck4").removeEventListener("mousedown", click, true);
- document.getElementById("lay1").removeEventListener("mousemove", move, true);
- document.getElementById("eck4").removeEventListener("mousemove", move, true);
-
- } else {
-
- document.eck1.visibility="hide";
- document.eck2.visibility="hide";
- document.eck3.visibility="hide";
- document.eck4.visibility="hide";
-
- document.lay1.releaseEvents(Event.MOUSEDOWN);
- document.eck4.releaseEvents(Event.MOUSEDOWN);
- document.lay1.releaseEvents(Event.MOUSEMOVE);
- document.eck4.releaseEvents(Event.MOUSEMOVE);
-
- }
-
- dlParams.wx.value = cropFloat(parseFloat(Math.min(pt1.relX, pt2.relX)));
- dlParams.wy.value = cropFloat(parseFloat(Math.min(pt1.relY, pt2.relY)));
-
- dlParams.ww.value = cropFloat(parseFloat(Math.abs(pt1.relX-pt2.relX)));
- dlParams.wh.value = cropFloat(parseFloat(Math.abs(pt1.relY-pt2.relY)));
-
- if ( (dlParams.ww.value != 0) && (dlParams.wh.value != 0) ) {
- display(3);
- }
- }
- }
-
- function move(evt) {
-
- pt2 = new Point(evt);
-
- var eck1_left = ((pt1.pageX < pt2.pageX) ? pt1.pageX : pt2.pageX);
- var eck1_top = ((pt1.pageY < pt2.pageY) ? pt1.pageY : pt2.pageY);
- var eck2_left = ((pt1.pageX < pt2.pageX) ? pt2.pageX : pt1.pageX)-12;;
- var eck2_top = ((pt1.pageY < pt2.pageY) ? pt1.pageY : pt2.pageY);
- var eck3_left = ((pt1.pageX < pt2.pageX) ? pt1.pageX : pt2.pageX);
- var eck3_top = ((pt1.pageY < pt2.pageY) ? pt2.pageY : pt1.pageY)-12;
- var eck4_left = ((pt1.pageX < pt2.pageX) ? pt2.pageX : pt1.pageX)-12;
- var eck4_top = ((pt1.pageY < pt2.pageY) ? pt2.pageY : pt1.pageY)-12;
-
- if ( document.all ) {
-
- document.all.eck1.style.left = eck1_left;
- document.all.eck1.style.top = eck1_top;
- document.all.eck2.style.left = eck2_left;
- document.all.eck2.style.top = eck2_top;
- document.all.eck3.style.left = eck3_left;
- document.all.eck3.style.top = eck3_top;
- document.all.eck4.style.left = eck4_left;
- document.all.eck4.style.top = eck4_top;
-
- } else if ( typeof(document.getElementById) == "function" ) {
-
- document.getElementById("eck1").style.left = eck1_left;
- document.getElementById("eck1").style.top = eck1_top;
- document.getElementById("eck2").style.left = eck2_left;
- document.getElementById("eck2").style.top = eck2_top;
- document.getElementById("eck3").style.left = eck3_left;
- document.getElementById("eck3").style.top = eck3_top;
- document.getElementById("eck4").style.left = eck4_left;
- document.getElementById("eck4").style.top = eck4_top;
-
- } else {
-
- document.eck1.moveTo(eck1_left, eck1_top);
- document.eck2.moveTo(eck2_left, eck2_top);
- document.eck3.moveTo(eck3_left, eck3_top);
- document.eck4.moveTo(eck4_left, eck4_top);
-
- }
- }
-
- // starting event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = click;
- document.all.eck4.onmousedown = click;
- } else if ( typeof(document.addEventListener) == "function" ) {
- document.getElementById("lay1").addEventListener("mousedown", click, true);
- document.getElementById("eck4").addEventListener("mousedown", click, true);
- } else {
- document.lay1.captureEvents(Event.MOUSEDOWN);
- document.eck4.captureEvents(Event.MOUSEDOWN);
- document.lay1.onmousedown = click;
- document.eck4.onmousedown = click;
- }
-}
-
-
-function zoomExtends() {
-
- dlParams.wx.value = 0.0;
- dlParams.wy.value = 0.0;
-
- dlParams.ww.value = 1.0;
- dlParams.wh.value = 1.0;
-
- display(3);
-
-}
-
-
-function zoomOut() {
-
- dlParams.wx.value = cropFloat(dlParams.wx.value-0.5*(dlParams.ww.value*(ZOOMFACTOR)-dlParams.ww.value));
- dlParams.wy.value = cropFloat(dlParams.wy.value-0.5*(dlParams.wh.value*(ZOOMFACTOR)-dlParams.wh.value));
-
- dlParams.ww.value = cropFloat(dlParams.ww.value*(ZOOMFACTOR));
- dlParams.wh.value = cropFloat(dlParams.wh.value*(ZOOMFACTOR));
-
- if ( dlParams.wx.value < 0 ) {
- dlParams.wx.value = 0;
- }
- if ( dlParams.wy.value < 0 ) {
- dlParams.wy.value = 0;
- }
- if ( dlParams.ww.value > 1 ) {
- dlParams.ww.value = 1;
- }
- if ( dlParams.wh.value > 1 ) {
- dlParams.wh.value = 1;
- }
- if ( dlParams.wx.value + dlParams.ww.value > 1 ) {
- dlParams.wx.value = 1 - dlParams.ww.value;
- }
- if ( dlParams.wy.value + dlParams.wh.value > 1 ) {
- dlParams.wy.value = 1 - dlParams.wh.value;
- }
-
- display(3);
-}
-
-
-function moveTo() {
-
- if ( (parseFloat(dlParams.ww.value) == 1.0) && (parseFloat(dlParams.wh.value) == 1.0) ) {
- alert("This function is only available when zoomed in!");
- return;
- }
-
- function moveToEvent(event) {
-
- var point = new Point(event);
-
- dlParams.wx.value = cropFloat(point.relX-0.5*dlParams.ww.value);
- dlParams.wy.value = cropFloat(point.relY-0.5*dlParams.wh.value);
-
- if ( dlParams.wx.value < 0 ) {
- dlParams.wx.value = 0;
- }
- if ( dlParams.wy.value < 0 ) {
- dlParams.wy.value = 0;
- }
- if ( dlParams.wx.value + dlParams.ww.value > 1 ) {
- dlParams.wx.value = 1 - dlParams.ww.value;
- }
- if ( dlParams.wy.value + dlParams.wh.value > 1 ) {
- dlParams.wy.value = 1 - dlParams.wh.value;
- }
-
- // stopping event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = null;
- } else if ( typeof(document.removeEventListener) == "function" ) {
- document.getElementById("lay1").removeEventListener("mousedown", moveToEvent, true);
- } else {
- document.lay1.releaseEvents(Event.MOUSEDOWN)
- }
-
- display(3);
- }
-
- // starting event capture
- if ( document.all ) {
- document.all.lay1.onmousedown = moveToEvent;
- } else if ( typeof(document.addEventListener) == "function" ) {
- document.getElementById("lay1").addEventListener("mousedown", moveToEvent, true);
- } else {
- document.lay1.captureEvents(Event.MOUSEDOWN);
- document.lay1.onmousedown = moveToEvent;
- }
-}
-
-
-function scale(factor) {
-
- dlParams.ws.value = cropFloat(factor);
- display(3);
-
-}
-
-
-// capturing keypresses for next and previous page
-function parseKeypress(evt) {
-
- if ( document.all ) {
-
- if ( event.keyCode == 110 ) {
- page('+1');
- }
- if ( event.keyCode == 98 ) {
- page('-1');
- }
-
- document.cancleBubble = true;
-
- } else {
-
- if ( evt.charCode == 110 ) {
- page('+1');
- } else if ( evt.charCode == 98 ) {
- page('-1');
- } else if ( evt.which == 110 ) {
- page('+1');
- } else if ( evt.which == 98 ) {
- // does not work currentlyfor Opera, because it catches the 'b'-key on it's own
- // have to change the key or find another way - luginbuehl
- page('-1');
- }
-
- }
-}
-
-
-// auxiliary function to crop senseless precicsion
-function cropFloat(tmp) {
- return parseInt(10000*tmp)/10000;
-}
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/oldskin/pageWin.html
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/client/digitallibrary/oldskin/pageWin.html Thu Oct 28 22:25:59 2004 +0200
@@ -0,0 +1,21 @@
+
+
+
+
+
+
+
+
+
+
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/olinks.gif
Binary file client/digitallibrary/olinks.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/orechts.gif
Binary file client/digitallibrary/orechts.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/ulinks.gif
Binary file client/digitallibrary/ulinks.gif has changed
diff -r 6f88ad4b36e1 -r 58d9cbdfb0c9 client/digitallibrary/urechts.gif
Binary file client/digitallibrary/urechts.gif has changed