]>
Commit | Line | Data |
---|---|---|
ae8b679f ER |
1 | --- ./script.js 2009-03-12 01:44:39.267256244 +0200 |
2 | +++ ./script.js 2008-08-08 21:38:32.000000000 +0300 | |
3 | @@ -5581,13 +5581,16 @@ | |
4 | // Configurationl | |
5 | // | |
6 | LightboxOptions = Object.extend({ | |
7 | - fileLoadingImage: 'images/loading.gif', | |
8 | - fileBottomNavCloseImage: 'images/closelabel.gif', | |
9 | +// EDITED for Dokuwiki plugin | |
10 | + fileLoadingImage: 'lib/plugins/lightbox/images/loading.gif', | |
11 | +// fileLoadingImage: 'images/loading.gif', | |
12 | + fileBottomNavCloseImage: 'lib/plugins/lightbox/images/closelabel.gif', | |
13 | +// fileBottomNavCloseImage: 'images/closelabel.gif', | |
14 | ||
15 | overlayOpacity: 0.8, // controls transparency of shadow overlay | |
16 | ||
17 | animate: true, // toggles resizing animations | |
18 | - resizeSpeed: 7, // controls the speed of the image resizing animations (1=slowest and 10=fastest) | |
19 | + resizeSpeed: 10, // controls the speed of the image resizing animations (1=slowest and 10=fastest) | |
20 | ||
21 | borderSize: 10, //if you adjust the padding in the CSS, you will need to update this variable | |
22 | ||
23 | @@ -5723,7 +5726,10 @@ | |
24 | this.updateImageList = Prototype.emptyFunction; | |
25 | ||
26 | document.observe('click', (function(event){ | |
27 | - var target = event.findElement('a[rel^=lightbox]') || event.findElement('area[rel^=lightbox]'); | |
28 | + // EDITED for Dokuwiki | |
29 | + // TODO... | |
30 | + //var target = event.findElement('a[rel^=lightbox]') || event.findElement('area[rel^=lightbox]'); | |
31 | + var target = event.findElement('a[class^=media]:not([class~=mediafile])') || event.findElement('area[class^=media]:not([class~=mediafile])'); | |
32 | if (target) { | |
33 | event.stop(); | |
34 | this.start(target); | |
35 | @@ -5748,18 +5754,22 @@ | |
36 | this.imageArray = []; | |
37 | var imageNum = 0; | |
38 | ||
39 | - if ((imageLink.rel == 'lightbox')){ | |
40 | - // if image is NOT part of a set, add single image to imageArray | |
41 | - this.imageArray.push([imageLink.href, imageLink.title]); | |
42 | - } else { | |
43 | + // EDITED for Dokuwiki | |
44 | + // TODO... | |
45 | + //if ((imageLink.rel == 'lightbox')){ | |
46 | + // if image is NOT part of a set, add single image to imageArray | |
47 | + // this.imageArray.push([imageLink.href, imageLink.title]); | |
48 | + //} else { | |
49 | // if image is part of a set.. | |
50 | this.imageArray = | |
51 | - $$(imageLink.tagName + '[href][rel="' + imageLink.rel + '"]'). | |
52 | - collect(function(anchor){ return [anchor.href, anchor.title]; }). | |
53 | + //$$(imageLink.tagName + '[href][rel="' + imageLink.rel + '"]'). | |
54 | + $$(imageLink.tagName + '[href][class="media"]'). | |
55 | + //collect(function(anchor){ return [anchor.href, anchor.title]; }). | |
56 | + collect(function(anchor){ return [anchor.href, anchor.firstChild.getAttribute('title')]; }). | |
57 | uniq(); | |
58 | ||
59 | while (this.imageArray[imageNum][0] != imageLink.href) { imageNum++; } | |
60 | - } | |
61 | + //} | |
62 | ||
63 | // calculate top and left offset for the lightbox | |
64 | var arrayPageScroll = document.viewport.getScrollOffsets(); | |
65 | --- ./css/lightbox.css 2008-03-10 06:57:10.000000000 +0200 | |
66 | +++ ./css/lightbox.css 2008-08-07 23:47:50.000000000 +0300 | |
67 | @@ -10,11 +10,20 @@ | |
68 | #imageContainer>#hoverNav{ left: 0;} | |
69 | #hoverNav a{ outline: none;} | |
70 | ||
71 | -#prevLink, #nextLink{ width: 49%; height: 100%; background-image: url(data:image/gif;base64,AAAA); /* Trick IE into showing hover */ display: block; } | |
72 | +/* | |
73 | +Modif DOKUWIKI | |
74 | +#prevLink, #nextLink{ width: 49%; height: 100%; background-image: url(data:image/gif;base64,AAAA); \* Trick IE into showing hover \*display: block; } | |
75 | +*/ | |
76 | +#prevLink, #nextLink{ width: 49%; height: 100%; background: transparent url(images/blank.gif) no-repeat; /* Trick IE into showing hover */ display: block; } | |
77 | #prevLink { left: 0; float: left;} | |
78 | #nextLink { right: 0; float: right;} | |
79 | -#prevLink:hover, #prevLink:visited:hover { background: url(../images/prevlabel.gif) left 15% no-repeat; } | |
80 | -#nextLink:hover, #nextLink:visited:hover { background: url(../images/nextlabel.gif) right 15% no-repeat; } | |
81 | +/* | |
82 | +Modif DOKUWIKI | |
83 | +#prevLink:hover, #prevLink:visited:hover { background: url(../images/prev.gif) left 15% no-repeat; } | |
84 | +#nextLink:hover, #nextLink:visited:hover { background: url(../images/next.gif) right 15% no-repeat; } | |
85 | +*/ | |
86 | +#prevLink:hover, #prevLink:visited:hover { background: url(images/prev.gif) left 15% no-repeat; } | |
87 | +#nextLink:hover, #nextLink:visited:hover { background: url(images/next.gif) right 15% no-repeat; } | |
88 | ||
89 | #imageDataContainer{ font: 10px Verdana, Helvetica, sans-serif; background-color: #fff; margin: 0 auto; line-height: 1.4em; overflow: auto; width: 100% ; } | |
90 |