Zbavíme se závislosti na Log4J, který se stejně nepoužívá.
1 //\//////////////////////////////////////////////////////////////////////////////////
2 //\ overLIB 3.50 -- This notice must remain untouched at all times.
3 //\ Copyright Erik Bosrup 1998-2001. All rights reserved.
5 //\ By Erik Bosrup (erik@bosrup.com). Last modified 2001-08-28.
6 //\ Portions by Dan Steinman (dansteinman.com). Additions by other people are
7 //\ listed on the overLIB homepage.
9 //\ Get the latest version at http://www.bosrup.com/web/overlib/
11 //\ This script is published under an open source license. Please read the license
12 //\ agreement online at: http://www.bosrup.com/web/overlib/license.html
13 //\ If you have questions regarding the license please contact erik@bosrup.com.
15 //\ This script library was originally created for personal use. By request it has
16 //\ later been made public. This is free software. Do not sell this as your own
17 //\ work, or remove this copyright notice. For full details on copying or changing
18 //\ this script please read the license agreement at the link above.
20 //\ Please give credit on sites that use overLIB and submit changes of the script
21 //\ so other people can use them as well. This script is free to use, don't abuse.
22 //\//////////////////////////////////////////////////////////////////////////////////
26 ////////////////////////////////////////////////////////////////////////////////////
28 // Don't touch these. :)
29 ////////////////////////////////////////////////////////////////////////////////////
50 var AUTOSTATUSCAP = 21;
57 var FGBACKGROUND = 28;
58 var BGBACKGROUND = 29;
59 var PADX = 30; // PADX2 out
60 var PADY = 31; // PADY2 out
83 var TEXTFONTCLASS = 56;
84 var CAPTIONFONTCLASS = 57;
85 var CLOSEFONTCLASS = 58;
89 var TEXTSIZEUNIT = 62;
90 var TEXTDECORATION = 63;
93 var CAPTIONSIZEUNIT = 66;
94 var CAPTIONDECORATION = 67;
95 var CAPTIONSTYLE = 68;
96 var CAPTIONWEIGHT = 69;
97 var CLOSESIZEUNIT = 70;
98 var CLOSEDECORATION = 71;
100 var CLOSEWEIGHT = 73;
103 ////////////////////////////////////////////////////////////////////////////////////
104 // DEFAULT CONFIGURATION
105 // You don't have to change anything here if you don't want to. All of this can be
106 // changed on your html page or through an overLIB call.
107 ////////////////////////////////////////////////////////////////////////////////////
109 // Main background color (the large area)
110 // Usually a bright color (white, yellow etc)
111 if (typeof ol_fgcolor == 'undefined') { var ol_fgcolor = "#CCCCFF";}
113 // Border color and color of caption
114 // Usually a dark color (black, brown etc)
115 if (typeof ol_bgcolor == 'undefined') { var ol_bgcolor = "#333399";}
118 // Usually a dark color
119 if (typeof ol_textcolor == 'undefined') { var ol_textcolor = "#000000";}
121 // Color of the caption text
122 // Usually a bright color
123 if (typeof ol_capcolor == 'undefined') { var ol_capcolor = "#FFFFFF";}
125 // Color of "Close" when using Sticky
126 // Usually a semi-bright color
127 if (typeof ol_closecolor == 'undefined') { var ol_closecolor = "#9999FF";}
129 // Font face for the main text
130 if (typeof ol_textfont == 'undefined') { var ol_textfont = "Verdana,Arial,Helvetica";}
132 // Font face for the caption
133 if (typeof ol_captionfont == 'undefined') { var ol_captionfont = "Verdana,Arial,Helvetica";}
135 // Font face for the close text
136 if (typeof ol_closefont == 'undefined') { var ol_closefont = "Verdana,Arial,Helvetica";}
138 // Font size for the main text
139 // When using CSS this will be very small.
140 if (typeof ol_textsize == 'undefined') { var ol_textsize = "1";}
142 // Font size for the caption
143 // When using CSS this will be very small.
144 if (typeof ol_captionsize == 'undefined') { var ol_captionsize = "1";}
146 // Font size for the close text
147 // When using CSS this will be very small.
148 if (typeof ol_closesize == 'undefined') { var ol_closesize = "1";}
150 // Width of the popups in pixels
151 // 100-300 pixels is typical
152 if (typeof ol_width == 'undefined') { var ol_width = "200";}
154 // How thick the ol_border should be in pixels
155 // 1-3 pixels is typical
156 if (typeof ol_border == 'undefined') { var ol_border = "1";}
158 // How many pixels to the right/left of the cursor to show the popup
159 // Values between 3 and 12 are best
160 if (typeof ol_offsetx == 'undefined') { var ol_offsetx = 10;}
162 // How many pixels to the below the cursor to show the popup
163 // Values between 3 and 12 are best
164 if (typeof ol_offsety == 'undefined') { var ol_offsety = 10;}
166 // Default text for popups
167 // Should you forget to pass something to overLIB this will be displayed.
168 if (typeof ol_text == 'undefined') { var ol_text = "Default Text"; }
171 // You should leave this blank or you will have problems making non caps popups.
172 if (typeof ol_cap == 'undefined') { var ol_cap = ""; }
174 // Decides if sticky popups are default.
175 // 0 for non, 1 for stickies.
176 if (typeof ol_sticky == 'undefined') { var ol_sticky = 0; }
178 // Default background image. Better left empty unless you always want one.
179 if (typeof ol_background == 'undefined') { var ol_background = ""; }
181 // Text for the closing sticky popups.
182 // Normal is "Close".
183 if (typeof ol_close == 'undefined') { var ol_close = "Close"; }
185 // Default vertical alignment for popups.
186 // It's best to leave RIGHT here. Other options are LEFT and CENTER.
187 if (typeof ol_hpos == 'undefined') { var ol_hpos = RIGHT; }
189 // Default status bar text when a popup is invoked.
190 if (typeof ol_status == 'undefined') { var ol_status = ""; }
192 // If the status bar automatically should load either text or caption.
193 // 0=nothing, 1=text, 2=caption
194 if (typeof ol_autostatus == 'undefined') { var ol_autostatus = 0; }
196 // Default height for popup. Often best left alone.
197 if (typeof ol_height == 'undefined') { var ol_height = -1; }
199 // Horizontal grid spacing that popups will snap to.
200 // 0 makes no grid, anything else will cause a snap to that grid spacing.
201 if (typeof ol_snapx == 'undefined') { var ol_snapx = 0; }
203 // Vertical grid spacing that popups will snap to.
204 // 0 makes no grid, andthing else will cause a snap to that grid spacing.
205 if (typeof ol_snapy == 'undefined') { var ol_snapy = 0; }
207 // Sets the popups horizontal position to a fixed column.
208 // Anything above -1 will cause fixed position.
209 if (typeof ol_fixx == 'undefined') { var ol_fixx = -1; }
211 // Sets the popups vertical position to a fixed row.
212 // Anything above -1 will cause fixed position.
213 if (typeof ol_fixy == 'undefined') { var ol_fixy = -1; }
215 // Background image for the popups inside.
216 if (typeof ol_fgbackground == 'undefined') { var ol_fgbackground = ""; }
218 // Background image for the popups frame.
219 if (typeof ol_bgbackground == 'undefined') { var ol_bgbackground = ""; }
221 // How much horizontal left padding text should get by default when BACKGROUND is used.
222 if (typeof ol_padxl == 'undefined') { var ol_padxl = 1; }
224 // How much horizontal right padding text should get by default when BACKGROUND is used.
225 if (typeof ol_padxr == 'undefined') { var ol_padxr = 1; }
227 // How much vertical top padding text should get by default when BACKGROUND is used.
228 if (typeof ol_padyt == 'undefined') { var ol_padyt = 1; }
230 // How much vertical bottom padding text should get by default when BACKGROUND is used.
231 if (typeof ol_padyb == 'undefined') { var ol_padyb = 1; }
233 // If the user by default must supply all html for complete popup control.
234 // Set to 1 to activate, 0 otherwise.
235 if (typeof ol_fullhtml == 'undefined') { var ol_fullhtml = 0; }
237 // Default vertical position of the popup. Default should normally be BELOW.
238 // ABOVE only works when HEIGHT is defined.
239 if (typeof ol_vpos == 'undefined') { var ol_vpos = BELOW; }
241 // Default height of popup to use when placing the popup above the cursor.
242 if (typeof ol_aboveheight == 'undefined') { var ol_aboveheight = 0; }
244 // Default icon to place next to the popups caption.
245 if (typeof ol_caption == 'undefined') { var ol_capicon = ""; }
247 // Default frame. We default to current frame if there is no frame defined.
248 if (typeof ol_frame == 'undefined') { var ol_frame = self; }
250 // Default timeout. By default there is no timeout.
251 if (typeof ol_timeout == 'undefined') { var ol_timeout = 0; }
253 // Default javascript funktion. By default there is none.
254 if (typeof ol_function == 'undefined') { var ol_function = Function(); }
256 // Default timeout. By default there is no timeout.
257 if (typeof ol_delay == 'undefined') { var ol_delay = 0; }
259 // If overLIB should decide the horizontal placement.
260 if (typeof ol_hauto == 'undefined') { var ol_hauto = 0; }
262 // If overLIB should decide the vertical placement.
263 if (typeof ol_vauto == 'undefined') { var ol_vauto = 0; }
267 // If the user has to click to close stickies.
268 if (typeof ol_closeclick == 'undefined') { var ol_closeclick = 0; }
270 // This variable determines if you want to use CSS or inline definitions.
271 // CSSOFF=no CSS CSSSTYLE=use CSS inline styles CSSCLASS=use classes
272 if (typeof ol_css == 'undefined') { var ol_css = CSSOFF; }
274 // Main background class (eqv of fgcolor)
275 // This is only used if CSS is set to use classes (ol_css = CSSCLASS)
276 if (typeof ol_fgclass == 'undefined') { var ol_fgclass = ""; }
278 // Frame background class (eqv of bgcolor)
279 // This is only used if CSS is set to use classes (ol_css = CSSCLASS)
280 if (typeof ol_bgclass == 'undefined') { var ol_bgclass = ""; }
283 // This is only used if CSS is set to use classes (ol_css = CSSCLASS)
284 if (typeof ol_textfontclass == 'undefined') { var ol_textfontclass = ""; }
286 // Caption font class
287 // This is only used if CSS is set to use classes (ol_css = CSSCLASS)
288 if (typeof ol_captionfontclass == 'undefined') { var ol_captionfontclass = ""; }
291 // This is only used if CSS is set to use classes (ol_css = CSSCLASS)
292 if (typeof ol_closefontclass == 'undefined') { var ol_closefontclass = ""; }
294 // Unit to be used for the text padding above
295 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
296 // Options include "px", "%", "in", "cm" and more
297 if (typeof ol_padunit == 'undefined') { var ol_padunit = "px";}
299 // Unit to be used for height of popup
300 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
301 // Options include "px", "%", "in", "cm" and more
302 if (typeof ol_heightunit == 'undefined') { var ol_heightunit = "px";}
304 // Unit to be used for width of popup
305 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
306 // Options include "px", "%", "in", "cm" and more
307 if (typeof ol_widthunit == 'undefined') { var ol_widthunit = "px";}
309 // Font size unit for the main text
310 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
311 if (typeof ol_textsizeunit == 'undefined') { var ol_textsizeunit = "px";}
313 // Decoration of the main text ("none", "underline", "line-through" or "blink")
314 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
315 if (typeof ol_textdecoration == 'undefined') { var ol_textdecoration = "none";}
317 // Font style of the main text ("normal" or "italic")
318 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
319 if (typeof ol_textstyle == 'undefined') { var ol_textstyle = "normal";}
321 // Font weight of the main text ("normal", "bold", "bolder", "lighter", ect.)
322 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
323 if (typeof ol_textweight == 'undefined') { var ol_textweight = "normal";}
325 // Font size unit for the caption
326 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
327 if (typeof ol_captionsizeunit == 'undefined') { var ol_captionsizeunit = "px";}
329 // Decoration of the caption ("none", "underline", "line-through" or "blink")
330 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
331 if (typeof ol_captiondecoration == 'undefined') { var ol_captiondecoration = "none";}
333 // Font style of the caption ("normal" or "italic")
334 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
335 if (typeof ol_captionstyle == 'undefined') { var ol_captionstyle = "normal";}
337 // Font weight of the caption ("normal", "bold", "bolder", "lighter", ect.)
338 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
339 if (typeof ol_captionweight == 'undefined') { var ol_captionweight = "bold";}
341 // Font size unit for the close text
342 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
343 if (typeof ol_closesizeunit == 'undefined') { var ol_closesizeunit = "px";}
345 // Decoration of the close text ("none", "underline", "line-through" or "blink")
346 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
347 if (typeof ol_closedecoration == 'undefined') { var ol_closedecoration = "none";}
349 // Font style of the close text ("normal" or "italic")
350 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
351 if (typeof ol_closestyle == 'undefined') { var ol_closestyle = "normal";}
353 // Font weight of the close text ("normal", "bold", "bolder", "lighter", ect.)
354 // Only used if CSS inline styles are being used (ol_css = CSSSTYLE)
355 if (typeof ol_closeweight == 'undefined') { var ol_closeweight = "normal";}
359 ////////////////////////////////////////////////////////////////////////////////////
360 // ARRAY CONFIGURATION
361 // You don't have to change anything here if you don't want to. The following
362 // arrays can be filled with text and html if you don't wish to pass it from
364 ////////////////////////////////////////////////////////////////////////////////////
367 if (typeof ol_texts == 'undefined') { var ol_texts = new Array("Text 0", "Text 1"); }
369 // Array with captions.
370 if (typeof ol_caps == 'undefined') { var ol_caps = new Array("Caption 0", "Caption 1"); }
373 ////////////////////////////////////////////////////////////////////////////////////
375 // Don't change anything below this line, all configuration is above.
376 ////////////////////////////////////////////////////////////////////////////////////
384 ////////////////////////////////////////////////////////////////////////////////////
386 ////////////////////////////////////////////////////////////////////////////////////
388 // Runtime variables init. Used for runtime only, don't change, not for config!
392 var o3_background = "";
393 var o3_close = "Close";
399 var o3_textcolor = "";
400 var o3_capcolor = "";
401 var o3_closecolor = "";
405 var o3_autostatus = 0;
411 var o3_fgbackground = "";
412 var o3_bgbackground = "";
419 var o3_aboveheight = 0;
421 var o3_textfont = "Verdana,Arial,Helvetica";
422 var o3_captionfont = "Verdana,Arial,Helvetica";
423 var o3_closefont = "Verdana,Arial,Helvetica";
424 var o3_textsize = "1";
425 var o3_captionsize = "1";
426 var o3_closesize = "1";
430 var o3_allowmove = 0;
431 var o3_function = Function();
436 var o3_closeclick = 0;
441 var o3_textfontclass = "";
442 var o3_captionfontclass = "";
443 var o3_closefontclass = "";
444 var o3_padunit = "px";
445 var o3_heightunit = "px";
446 var o3_widthunit = "px";
447 var o3_textsizeunit = "px";
448 var o3_textdecoration = "";
449 var o3_textstyle = "";
450 var o3_textweight = "";
451 var o3_captionsizeunit = "px";
452 var o3_captiondecoration = "";
453 var o3_captionstyle = "";
454 var o3_captionweight = "";
455 var o3_closesizeunit = "px";
456 var o3_closedecoration = "";
457 var o3_closestyle = "";
458 var o3_closeweight = "";
462 // Display state variables
466 var o3_showingsticky = 0;
467 var o3_removecounter = 0;
473 // Decide browser version
474 var ns4 = (document.layers)? true:false;
475 var ns6 = (document.getElementById)? true:false;
476 var ie4 = (document.all)? true:false;
479 // Microsoft Stupidity Check(tm).
481 if ((navigator.userAgent.indexOf('MSIE 5') > 0) || (navigator.userAgent.indexOf('MSIE 6') > 0)) {
490 // Capture events, alt. diffuses the overlib function.
491 if ( (ns4) || (ie4) || (ns6)) {
492 document.onmousemove = mouseMove
493 if (ns4) document.captureEvents(Event.MOUSEMOVE)
495 overlib = no_overlib;
501 // Fake function for 3.0 users.
502 function no_overlib() {
508 ////////////////////////////////////////////////////////////////////////////////////
510 ////////////////////////////////////////////////////////////////////////////////////
513 // overlib(arg0, ..., argN)
514 // Loads parameters into global runtime variables.
517 // Load defaults to runtime.
520 o3_sticky = ol_sticky;
521 o3_background = ol_background;
524 o3_offsetx = ol_offsetx;
525 o3_offsety = ol_offsety;
526 o3_fgcolor = ol_fgcolor;
527 o3_bgcolor = ol_bgcolor;
528 o3_textcolor = ol_textcolor;
529 o3_capcolor = ol_capcolor;
530 o3_closecolor = ol_closecolor;
532 o3_border = ol_border;
533 o3_status = ol_status;
534 o3_autostatus = ol_autostatus;
535 o3_height = ol_height;
540 o3_fgbackground = ol_fgbackground;
541 o3_bgbackground = ol_bgbackground;
546 o3_fullhtml = ol_fullhtml;
548 o3_aboveheight = ol_aboveheight;
549 o3_capicon = ol_capicon;
550 o3_textfont = ol_textfont;
551 o3_captionfont = ol_captionfont;
552 o3_closefont = ol_closefont;
553 o3_textsize = ol_textsize;
554 o3_captionsize = ol_captionsize;
555 o3_closesize = ol_closesize;
556 o3_timeout = ol_timeout;
557 o3_function = ol_function;
561 o3_closeclick = ol_closeclick;
564 o3_fgclass = ol_fgclass;
565 o3_bgclass = ol_bgclass;
566 o3_textfontclass = ol_textfontclass;
567 o3_captionfontclass = ol_captionfontclass;
568 o3_closefontclass = ol_closefontclass;
569 o3_padunit = ol_padunit;
570 o3_heightunit = ol_heightunit;
571 o3_widthunit = ol_widthunit;
572 o3_textsizeunit = ol_textsizeunit;
573 o3_textdecoration = ol_textdecoration;
574 o3_textstyle = ol_textstyle;
575 o3_textweight = ol_textweight;
576 o3_captionsizeunit = ol_captionsizeunit;
577 o3_captiondecoration = ol_captiondecoration;
578 o3_captionstyle = ol_captionstyle;
579 o3_captionweight = ol_captionweight;
580 o3_closesizeunit = ol_closesizeunit;
581 o3_closedecoration = ol_closedecoration;
582 o3_closestyle = ol_closestyle;
583 o3_closeweight = ol_closeweight;
586 // Special for frame support, over must be reset...
587 if ( (ns4) || (ie4) || (ns6) ) {
589 if (ns4) over = o3_frame.document.overDiv
590 if (ie4) over = o3_frame.overDiv.style
591 if (ns6) over = o3_frame.document.getElementById("overDiv");
595 // What the next argument is expected to be.
600 for (i = 0; i < ar.length; i++) {
603 // Arg is maintext, unless INARRAY
604 if (ar[i] == INARRAY) {
605 o3_text = ol_texts[ar[++i]];
612 // Note: NS4 doesn't like switch cases with vars.
613 if (ar[i] == INARRAY) { o3_text = ol_texts[ar[++i]]; continue; }
614 if (ar[i] == CAPARRAY) { o3_cap = ol_caps[ar[++i]]; continue; }
615 if (ar[i] == STICKY) { o3_sticky = 1; continue; }
616 if (ar[i] == BACKGROUND) { o3_background = ar[++i]; continue; }
617 if (ar[i] == NOCLOSE) { o3_close = ""; continue; }
618 if (ar[i] == CAPTION) { o3_cap = ar[++i]; continue; }
619 if (ar[i] == CENTER || ar[i] == LEFT || ar[i] == RIGHT) { o3_hpos = ar[i]; continue; }
620 if (ar[i] == OFFSETX) { o3_offsetx = ar[++i]; continue; }
621 if (ar[i] == OFFSETY) { o3_offsety = ar[++i]; continue; }
622 if (ar[i] == FGCOLOR) { o3_fgcolor = ar[++i]; continue; }
623 if (ar[i] == BGCOLOR) { o3_bgcolor = ar[++i]; continue; }
624 if (ar[i] == TEXTCOLOR) { o3_textcolor = ar[++i]; continue; }
625 if (ar[i] == CAPCOLOR) { o3_capcolor = ar[++i]; continue; }
626 if (ar[i] == CLOSECOLOR) { o3_closecolor = ar[++i]; continue; }
627 if (ar[i] == WIDTH) { o3_width = ar[++i]; continue; }
628 if (ar[i] == BORDER) { o3_border = ar[++i]; continue; }
629 if (ar[i] == STATUS) { o3_status = ar[++i]; continue; }
630 if (ar[i] == AUTOSTATUS) { o3_autostatus = 1; continue; }
631 if (ar[i] == AUTOSTATUSCAP) { o3_autostatus = 2; continue; }
632 if (ar[i] == HEIGHT) { o3_height = ar[++i]; o3_aboveheight = ar[i]; continue; } // Same param again.
633 if (ar[i] == CLOSETEXT) { o3_close = ar[++i]; continue; }
634 if (ar[i] == SNAPX) { o3_snapx = ar[++i]; continue; }
635 if (ar[i] == SNAPY) { o3_snapy = ar[++i]; continue; }
636 if (ar[i] == FIXX) { o3_fixx = ar[++i]; continue; }
637 if (ar[i] == FIXY) { o3_fixy = ar[++i]; continue; }
638 if (ar[i] == FGBACKGROUND) { o3_fgbackground = ar[++i]; continue; }
639 if (ar[i] == BGBACKGROUND) { o3_bgbackground = ar[++i]; continue; }
640 if (ar[i] == PADX) { o3_padxl = ar[++i]; o3_padxr = ar[++i]; continue; }
641 if (ar[i] == PADY) { o3_padyt = ar[++i]; o3_padyb = ar[++i]; continue; }
642 if (ar[i] == FULLHTML) { o3_fullhtml = 1; continue; }
643 if (ar[i] == BELOW || ar[i] == ABOVE) { o3_vpos = ar[i]; continue; }
644 if (ar[i] == CAPICON) { o3_capicon = ar[++i]; continue; }
645 if (ar[i] == TEXTFONT) { o3_textfont = ar[++i]; continue; }
646 if (ar[i] == CAPTIONFONT) { o3_captionfont = ar[++i]; continue; }
647 if (ar[i] == CLOSEFONT) { o3_closefont = ar[++i]; continue; }
648 if (ar[i] == TEXTSIZE) { o3_textsize = ar[++i]; continue; }
649 if (ar[i] == CAPTIONSIZE) { o3_captionsize = ar[++i]; continue; }
650 if (ar[i] == CLOSESIZE) { o3_closesize = ar[++i]; continue; }
651 if (ar[i] == FRAME) { opt_FRAME(ar[++i]); continue; }
652 if (ar[i] == TIMEOUT) { o3_timeout = ar[++i]; continue; }
653 if (ar[i] == FUNCTION) { opt_FUNCTION(ar[++i]); continue; }
654 if (ar[i] == DELAY) { o3_delay = ar[++i]; continue; }
655 if (ar[i] == HAUTO) { o3_hauto = (o3_hauto == 0) ? 1 : 0; continue; }
656 if (ar[i] == VAUTO) { o3_vauto = (o3_vauto == 0) ? 1 : 0; continue; }
657 if (ar[i] == CLOSECLICK) { o3_closeclick = (o3_closeclick == 0) ? 1 : 0; continue; }
658 if (ar[i] == CSSOFF) { o3_css = ar[i]; continue; }
659 if (ar[i] == CSSSTYLE) { o3_css = ar[i]; continue; }
660 if (ar[i] == CSSCLASS) { o3_css = ar[i]; continue; }
661 if (ar[i] == FGCLASS) { o3_fgclass = ar[++i]; continue; }
662 if (ar[i] == BGCLASS) { o3_bgclass = ar[++i]; continue; }
663 if (ar[i] == TEXTFONTCLASS) { o3_textfontclass = ar[++i]; continue; }
664 if (ar[i] == CAPTIONFONTCLASS) { o3_captionfontclass = ar[++i]; continue; }
665 if (ar[i] == CLOSEFONTCLASS) { o3_closefontclass = ar[++i]; continue; }
666 if (ar[i] == PADUNIT) { o3_padunit = ar[++i]; continue; }
667 if (ar[i] == HEIGHTUNIT) { o3_heightunit = ar[++i]; continue; }
668 if (ar[i] == WIDTHUNIT) { o3_widthunit = ar[++i]; continue; }
669 if (ar[i] == TEXTSIZEUNIT) { o3_textsizeunit = ar[++i]; continue; }
670 if (ar[i] == TEXTDECORATION) { o3_textdecoration = ar[++i]; continue; }
671 if (ar[i] == TEXTSTYLE) { o3_textstyle = ar[++i]; continue; }
672 if (ar[i] == TEXTWEIGHT) { o3_textweight = ar[++i]; continue; }
673 if (ar[i] == CAPTIONSIZEUNIT) { o3_captionsizeunit = ar[++i]; continue; }
674 if (ar[i] == CAPTIONDECORATION) { o3_captiondecoration = ar[++i]; continue; }
675 if (ar[i] == CAPTIONSTYLE) { o3_captionstyle = ar[++i]; continue; }
676 if (ar[i] == CAPTIONWEIGHT) { o3_captionweight = ar[++i]; continue; }
677 if (ar[i] == CLOSESIZEUNIT) { o3_closesizeunit = ar[++i]; continue; }
678 if (ar[i] == CLOSEDECORATION) { o3_closedecoration = ar[++i]; continue; }
679 if (ar[i] == CLOSESTYLE) { o3_closestyle = ar[++i]; continue; }
680 if (ar[i] == CLOSEWEIGHT) { o3_closeweight = ar[++i]; continue; }
687 o3_delayid = setTimeout("overlib350()", o3_delay);
699 // Clears popups if appropriate
701 if ( o3_removecounter >= 1 ) { o3_showingsticky = 0 };
702 if ( (ns4) || (ie4) || (ns6) ) {
703 if ( o3_showingsticky == 0 ) {
705 if (over != null) hideObject(over);
720 ////////////////////////////////////////////////////////////////////////////////////
721 // OVERLIB 3.50 FUNCTION
722 ////////////////////////////////////////////////////////////////////////////////////
725 // This function decides what it is we want to display and how we want it done.
726 function overlib350() {
728 // Make layer content
731 if (o3_background != "" || o3_fullhtml) {
732 // Use background instead of box.
733 layerhtml = ol_content_background(o3_text, o3_background, o3_fullhtml);
735 // They want a popup box.
737 // Prepare popup background
738 if (o3_fgbackground != "" && o3_css == CSSOFF) {
739 o3_fgbackground = "BACKGROUND=\""+o3_fgbackground+"\"";
741 if (o3_bgbackground != "" && o3_css == CSSOFF) {
742 o3_bgbackground = "BACKGROUND=\""+o3_bgbackground+"\"";
745 // Prepare popup colors
746 if (o3_fgcolor != "" && o3_css == CSSOFF) {
747 o3_fgcolor = "BGCOLOR=\""+o3_fgcolor+"\"";
749 if (o3_bgcolor != "" && o3_css == CSSOFF) {
750 o3_bgcolor = "BGCOLOR=\""+o3_bgcolor+"\"";
753 // Prepare popup height
754 if (o3_height > 0 && o3_css == CSSOFF) {
755 o3_height = "HEIGHT=" + o3_height;
760 // Decide which kinda box.
763 layerhtml = ol_content_simple(o3_text);
768 layerhtml = ol_content_caption(o3_text, o3_cap, o3_close);
771 layerhtml = ol_content_caption(o3_text, o3_cap, "");
776 // We want it to stick!
778 o3_showingsticky = 1;
779 o3_removecounter = 0;
783 layerWrite(layerhtml);
785 // Prepare status bar
786 if (o3_autostatus > 0) {
788 if (o3_autostatus > 1) {
793 // When placing the layer the first time, even stickies may be moved.
796 // Initiate a timer for timeout
797 if (o3_timeout > 0) {
798 if (o3_timerid > 0) clearTimeout(o3_timerid);
799 o3_timerid = setTimeout("cClick()", o3_timeout);
805 // Stickies should stay where they are.
816 ////////////////////////////////////////////////////////////////////////////////////
817 // LAYER GENERATION FUNCTIONS
818 ////////////////////////////////////////////////////////////////////////////////////
820 // Makes simple table without caption
821 function ol_content_simple(text) {
822 if (o3_css == CSSCLASS) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 class=\""+o3_bgclass+"\"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 class=\""+o3_fgclass+"\"><TR><TD VALIGN=TOP><FONT class=\""+o3_textfontclass+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
823 if (o3_css == CSSSTYLE) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 style=\"background-color: "+o3_bgcolor+"; height: "+o3_height+o3_heightunit+";\"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 style=\"color: "+o3_fgcolor+"; background-color: "+o3_fgcolor+"; height: "+o3_height+o3_heightunit+";\"><TR><TD VALIGN=TOP><FONT style=\"font-family: "+o3_textfont+"; color: "+o3_textcolor+"; font-size: "+o3_textsize+o3_textsizeunit+"; text-decoration: "+o3_textdecoration+"; font-weight: "+o3_textweight+"; font-style:"+o3_textstyle+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
824 if (o3_css == CSSOFF) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 "+o3_bgcolor+" "+o3_height+"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 "+o3_fgcolor+" "+o3_fgbackground+" "+o3_height+"><TR><TD VALIGN=TOP><FONT FACE=\""+o3_textfont+"\" COLOR=\""+o3_textcolor+"\" SIZE=\""+o3_textsize+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
833 // Makes table with caption and optional close link
834 function ol_content_caption(text, title, close) {
836 closeevent = "onMouseOver";
838 if (o3_closeclick == 1) closeevent = "onClick";
839 if (o3_capicon != "") o3_capicon = "<IMG SRC=\""+o3_capicon+"\"> ";
842 if (o3_css == CSSCLASS) closing = "<TD ALIGN=RIGHT><A HREF=\"/\" "+closeevent+"=\"return cClick();\" class=\""+o3_closefontclass+"\">"+close+"</A></TD>";
843 if (o3_css == CSSSTYLE) closing = "<TD ALIGN=RIGHT><A HREF=\"/\" "+closeevent+"=\"return cClick();\" style=\"color: "+o3_closecolor+"; font-family: "+o3_closefont+"; font-size: "+o3_closesize+o3_closesizeunit+"; text-decoration: "+o3_closedecoration+"; font-weight: "+o3_closeweight+"; font-style:"+o3_closestyle+";\">"+close+"</A></TD>";
844 if (o3_css == CSSOFF) closing = "<TD ALIGN=RIGHT><A HREF=\"/\" "+closeevent+"=\"return cClick();\"><FONT COLOR=\""+o3_closecolor+"\" FACE=\""+o3_closefont+"\" SIZE=\""+o3_closesize+"\">"+close+"</FONT></A></TD>";
847 if (o3_css == CSSCLASS) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 class=\""+o3_bgclass+"\"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=0 CELLSPACING=0><TR><TD><FONT class=\""+o3_captionfontclass+"\">"+o3_capicon+title+"</FONT></TD>"+closing+"</TR></TABLE><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 class=\""+o3_fgclass+"\"><TR><TD VALIGN=TOP><FONT class=\""+o3_textfontclass+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
848 if (o3_css == CSSSTYLE) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 style=\"background-color: "+o3_bgcolor+"; background-image: url("+o3_bgbackground+"); height: "+o3_height+o3_heightunit+";\"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=0 CELLSPACING=0><TR><TD><FONT style=\"font-family: "+o3_captionfont+"; color: "+o3_capcolor+"; font-size: "+o3_captionsize+o3_captionsizeunit+"; font-weight: "+o3_captionweight+"; font-style: "+o3_captionstyle+";\">"+o3_capicon+title+"</FONT></TD>"+closing+"</TR></TABLE><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 style=\"color: "+o3_fgcolor+"; background-color: "+o3_fgcolor+"; height: "+o3_height+o3_heightunit+";\"><TR><TD VALIGN=TOP><FONT style=\"font-family: "+o3_textfont+"; color: "+o3_textcolor+"; font-size: "+o3_textsize+o3_textsizeunit+"; text-decoration: "+o3_textdecoration+"; font-weight: "+o3_textweight+"; font-style:"+o3_textstyle+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
849 if (o3_css == CSSOFF) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING="+o3_border+" CELLSPACING=0 "+o3_bgcolor+" "+o3_bgbackground+" "+o3_height+"><TR><TD><TABLE WIDTH=100% BORDER=0 CELLPADDING=0 CELLSPACING=0><TR><TD><B><FONT COLOR=\""+o3_capcolor+"\" FACE=\""+o3_captionfont+"\" SIZE=\""+o3_captionsize+"\">"+o3_capicon+title+"</FONT></B></TD>"+closing+"</TR></TABLE><TABLE WIDTH=100% BORDER=0 CELLPADDING=2 CELLSPACING=0 "+o3_fgcolor+" "+o3_fgbackground+" "+o3_height+"><TR><TD VALIGN=TOP><FONT COLOR=\""+o3_textcolor+"\" FACE=\""+o3_textfont+"\" SIZE=\""+o3_textsize+"\">"+text+"</FONT></TD></TR></TABLE></TD></TR></TABLE>";
855 // Sets the background picture, padding and lots more. :)
856 function ol_content_background(text, picture, hasfullhtml) {
860 if (o3_css == CSSCLASS) txt = "<TABLE WIDTH="+o3_width+o3_widthunit+" BORDER=0 CELLPADDING=0 CELLSPACING=0 HEIGHT="+o3_height+o3_heightunit+"><TR><TD COLSPAN=3 HEIGHT="+o3_padyt+o3_padunit+"></TD></TR><TR><TD WIDTH="+o3_padxl+o3_padunit+"></TD><TD VALIGN=TOP WIDTH="+(o3_width-o3_padxl-o3_padxr)+o3_padunit+"><FONT class=\""+o3_textfontclass+"\">"+text+"</FONT></TD><TD WIDTH="+o3_padxr+o3_padunit+"></TD></TR><TR><TD COLSPAN=3 HEIGHT="+o3_padyb+o3_padunit+"></TD></TR></TABLE>";
861 if (o3_css == CSSSTYLE) txt = "<TABLE WIDTH="+o3_width+o3_widthunit+" BORDER=0 CELLPADDING=0 CELLSPACING=0 HEIGHT="+o3_height+o3_heightunit+"><TR><TD COLSPAN=3 HEIGHT="+o3_padyt+o3_padunit+"></TD></TR><TR><TD WIDTH="+o3_padxl+o3_padunit+"></TD><TD VALIGN=TOP WIDTH="+(o3_width-o3_padxl-o3_padxr)+o3_padunit+"><FONT style=\"font-family: "+o3_textfont+"; color: "+o3_textcolor+"; font-size: "+o3_textsize+o3_textsizeunit+";\">"+text+"</FONT></TD><TD WIDTH="+o3_padxr+o3_padunit+"></TD></TR><TR><TD COLSPAN=3 HEIGHT="+o3_padyb+o3_padunit+"></TD></TR></TABLE>";
862 if (o3_css == CSSOFF) txt = "<TABLE WIDTH="+o3_width+" BORDER=0 CELLPADDING=0 CELLSPACING=0 HEIGHT="+o3_height+"><TR><TD COLSPAN=3 HEIGHT="+o3_padyt+"></TD></TR><TR><TD WIDTH="+o3_padxl+"></TD><TD VALIGN=TOP WIDTH="+(o3_width-o3_padxl-o3_padxr)+"><FONT FACE=\""+o3_textfont+"\" COLOR=\""+o3_textcolor+"\" SIZE=\""+o3_textsize+"\">"+text+"</FONT></TD><TD WIDTH="+o3_padxr+"></TD></TR><TR><TD COLSPAN=3 HEIGHT="+o3_padyb+"></TD></TR></TABLE>";
864 set_background(picture);
868 // Loads a picture into the div.
869 function set_background(pic) {
871 if (ie4) over.backgroundImage = "none";
872 if (ns6) over.style.backgroundImage = "none";
875 over.background.src = pic;
877 over.backgroundImage = "url("+pic+")";
879 over.style.backgroundImage = "url("+pic+")";
886 ////////////////////////////////////////////////////////////////////////////////////
887 // HANDLING FUNCTIONS
888 ////////////////////////////////////////////////////////////////////////////////////
891 // Displays the popup
892 function disp(statustext) {
893 if ( (ns4) || (ie4) || (ns6) ) {
894 if (o3_allowmove == 0) {
901 if (statustext != "") {
902 self.status = statustext;
906 // Decides where we want the popup.
907 function placeLayer() {
910 // HORIZONTAL PLACEMENT
915 winoffset = (ie4) ? o3_frame.document.body.scrollLeft : o3_frame.pageXOffset;
916 if (ie4) iwidth = o3_frame.document.body.clientWidth;
917 if (ns4) iwidth = o3_frame.innerWidth; // was screwed in mozilla, fixed now?
918 if (ns6) iwidth = o3_frame.outerWidth;
920 // If HAUTO, decide what to use.
922 if ( (o3_x - winoffset) > ((eval(iwidth)) / 2)) {
930 if (o3_hpos == CENTER) { // Center
931 placeX = o3_x+o3_offsetx-(o3_width/2);
933 if (o3_hpos == RIGHT) { // Right
934 placeX = o3_x+o3_offsetx;
935 if ( (eval(placeX) + eval(o3_width)) > (winoffset + iwidth) ) {
936 placeX = iwidth + winoffset - o3_width;
937 if (placeX < 0) placeX = 0;
940 if (o3_hpos == LEFT) { // Left
941 placeX = o3_x-o3_offsetx-o3_width;
942 if (placeX < winoffset) placeX = winoffset;
947 var snapping = placeX % o3_snapx;
948 if (o3_hpos == LEFT) {
949 placeX = placeX - (o3_snapx + snapping);
952 placeX = placeX + (o3_snapx - snapping);
954 if (placeX < winoffset) placeX = winoffset;
960 // VERTICAL PLACEMENT
965 scrolloffset = (ie4) ? o3_frame.document.body.scrollTop : o3_frame.pageYOffset;
967 // If VAUTO, decide what to use.
969 if (ie4) iheight = o3_frame.document.body.clientHeight;
970 if (ns4) iheight = o3_frame.innerHeight;
971 if (ns6) iheight = o3_frame.outerHeight;
973 iheight = (eval(iheight)) / 2;
974 if ( (o3_y - scrolloffset) > iheight) {
983 if (o3_vpos == ABOVE) {
984 if (o3_aboveheight == 0) {
985 var divref = (ie4) ? o3_frame.document.all['overDiv'] : over;
986 o3_aboveheight = (ns4) ? divref.clip.height : divref.offsetHeight;
989 placeY = o3_y - (o3_aboveheight + o3_offsety);
990 if (placeY < scrolloffset) placeY = scrolloffset;
993 placeY = o3_y + o3_offsety;
998 var snapping = placeY % o3_snapy;
1000 if (o3_aboveheight > 0 && o3_vpos == ABOVE) {
1001 placeY = placeY - (o3_snapy + snapping);
1003 placeY = placeY + (o3_snapy - snapping);
1006 if (placeY < scrolloffset) placeY = scrolloffset;
1011 // Actually move the object.
1012 repositionTo(over, placeX, placeY);
1017 function mouseMove(e) {
1018 if ( (ns4) || (ns6) ) {o3_x=e.pageX; o3_y=e.pageY;}
1019 if (ie4) {o3_x=event.x; o3_y=event.y;}
1020 if (ie5) {o3_x=event.x+o3_frame.document.body.scrollLeft; o3_y=event.y+o3_frame.document.body.scrollTop;}
1022 if (o3_allowmove == 1) {
1027 // The Close onMouseOver function for stickies
1030 o3_showingsticky = 0;
1036 // Makes sure target frame has overLIB
1037 function compatibleframe(frameid) {
1039 if (typeof frameid.document.overDiv =='undefined') return false;
1041 if (typeof frameid.document.all["overDiv"] =='undefined') return false;
1043 if (frameid.document.getElementById('overDiv') == null) return false;
1051 ////////////////////////////////////////////////////////////////////////////////////
1053 ////////////////////////////////////////////////////////////////////////////////////
1056 // Writes to a layer
1057 function layerWrite(txt) {
1061 var lyr = o3_frame.document.overDiv.document
1066 o3_frame.document.all["overDiv"].innerHTML = txt
1068 range = o3_frame.document.createRange();
1069 range.setStartBefore(over);
1070 domfrag = range.createContextualFragment(txt);
1071 while (over.hasChildNodes()) {
1072 over.removeChild(over.lastChild);
1074 over.appendChild(domfrag);
1078 // Make an object visible
1079 function showObject(obj) {
1080 if (ns4) obj.visibility = "show";
1081 else if (ie4) obj.visibility = "visible";
1082 else if (ns6) obj.style.visibility = "visible";
1086 function hideObject(obj) {
1087 if (ns4) obj.visibility = "hide";
1088 else if (ie4) obj.visibility = "hidden";
1089 else if (ns6) obj.style.visibility = "hidden";
1091 if (o3_timerid > 0) clearTimeout(o3_timerid);
1092 if (o3_delayid > 0) clearTimeout(o3_delayid);
1099 function repositionTo(obj,xL,yL) {
1100 if ( (ns4) || (ie4) ) {
1104 obj.style.left = xL + "px";
1105 obj.style.top = yL+ "px";
1113 ////////////////////////////////////////////////////////////////////////////////////
1115 ////////////////////////////////////////////////////////////////////////////////////
1118 // Defines which frame we should point to.
1119 function opt_FRAME(frm) {
1120 o3_frame = compatibleframe(frm) ? frm : ol_frame;
1122 if ( (ns4) || (ie4 || (ns6)) ) {
1123 if (ns4) over = o3_frame.document.overDiv;
1124 if (ie4) over = o3_frame.overDiv.style;
1125 if (ns6) over = o3_frame.document.getElementById("overDiv");
1131 // Calls an external function
1132 function opt_FUNCTION(callme) {
1140 //end (For internal purposes.)
1141 ////////////////////////////////////////////////////////////////////////////////////
1142 // OVERLIB 2 COMPATABILITY FUNCTIONS
1143 // If you aren't upgrading you can remove the below section.
1144 ////////////////////////////////////////////////////////////////////////////////////
1146 // Converts old 0=left, 1=right and 2=center into constants.
1147 function vpos_convert(d) {
1162 function dts(d,text) {
1163 o3_hpos = vpos_convert(d);
1164 overlib(text, o3_hpos, CAPTION, "");
1168 function dtc(d,text, title) {
1169 o3_hpos = vpos_convert(d);
1170 overlib(text, CAPTION, title, o3_hpos);
1174 function stc(d,text, title) {
1175 o3_hpos = vpos_convert(d);
1176 overlib(text, CAPTION, title, o3_hpos, STICKY);
1179 // Simple popup right
1180 function drs(text) {
1184 // Caption popup right
1185 function drc(text, title) {
1189 // Sticky caption right
1190 function src(text,title) {
1194 // Simple popup left
1195 function dls(text) {
1199 // Caption popup left
1200 function dlc(text, title) {
1204 // Sticky caption left
1205 function slc(text,title) {
1209 // Simple popup center
1210 function dcs(text) {
1214 // Caption popup center
1215 function dcc(text, title) {
1219 // Sticky caption center
1220 function scc(text,title) {