]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - jssource/src_files/include/javascript/overlibmws.js
Release 6.2.0beta4
[Github/sugarcrm.git] / jssource / src_files / include / javascript / overlibmws.js
1 /*
2 Artistic License 2.0
3
4 Copyright (c) 2000-2006, The Perl Foundation.
5
6 Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.
7 Preamble
8
9 This license establishes the terms under which a given free software Package may be copied, modified, distributed, and/or redistributed. The intent is that the Copyright Holder maintains some artistic control over the development of that Package while still keeping the Package available as open source and free software.
10
11 You are always permitted to make arrangements wholly outside of this license directly with the Copyright Holder of a given Package. If the terms of this license do not permit the full use that you propose to make of the Package, you should contact the Copyright Holder and seek a different licensing arrangement.
12 Definitions
13
14 "Copyright Holder" means the individual(s) or organization(s) named in the copyright notice for the entire Package.
15
16 "Contributor" means any party that has contributed code or other material to the Package, in accordance with the Copyright Holder's procedures.
17
18 "You" and "your" means any person who would like to copy, distribute, or modify the Package.
19
20 "Package" means the collection of files distributed by the Copyright Holder, and derivatives of that collection and/or of those files. A given Package may consist of either the Standard Version, or a Modified Version.
21
22 "Distribute" means providing a copy of the Package or making it accessible to anyone else, or in the case of a company or organization, to others outside of your company or organization.
23
24 "Distributor Fee" means any fee that you charge for Distributing this Package or providing support for this Package to another party. It does not mean licensing fees.
25
26 "Standard Version" refers to the Package if it has not been modified, or has been modified only in ways explicitly requested by the Copyright Holder.
27
28 "Modified Version" means the Package, if it has been changed, and such changes were not explicitly requested by the Copyright Holder.
29
30 "Original License" means this Artistic License as Distributed with the Standard Version of the Package, in its current version or as it may be modified by The Perl Foundation in the future.
31
32 "Source" form means the source code, documentation source, and configuration files for the Package.
33
34 "Compiled" form means the compiled bytecode, object code, binary, or any other form resulting from mechanical transformation or translation of the Source form.
35 Permission for Use and Modification Without Distribution
36
37 (1) You are permitted to use the Standard Version and create and use Modified Versions for any purpose without restriction, provided that you do not Distribute the Modified Version.
38 Permissions for Redistribution of the Standard Version
39
40 (2) You may Distribute verbatim copies of the Source form of the Standard Version of this Package in any medium without restriction, either gratis or for a Distributor Fee, provided that you duplicate all of the original copyright notices and associated disclaimers. At your discretion, such verbatim copies may or may not include a Compiled form of the Package.
41
42 (3) You may apply any bug fixes, portability changes, and other modifications made available from the Copyright Holder. The resulting Package will still be considered the Standard Version, and as such will be subject to the Original License.
43 Distribution of Modified Versions of the Package as Source
44
45 (4) You may Distribute your Modified Version as Source (either gratis or for a Distributor Fee, and with or without a Compiled form of the Modified Version) provided that you clearly document how it differs from the Standard Version, including, but not limited to, documenting any non-standard features, executables, or modules, and provided that you do at least ONE of the following:
46
47 (a) make the Modified Version available to the Copyright Holder of the Standard Version, under the Original License, so that the Copyright Holder may include your modifications in the Standard Version.
48 (b) ensure that installation of your Modified Version does not prevent the user installing or running the Standard Version. In addition, the Modified Version must bear a name that is different from the name of the Standard Version.
49 (c) allow anyone who receives a copy of the Modified Version to make the Source form of the Modified Version available to others under
50 (i) the Original License or
51 (ii) a license that permits the licensee to freely copy, modify and redistribute the Modified Version using the same licensing terms that apply to the copy that the licensee received, and requires that the Source form of the Modified Version, and of any works derived from it, be made freely available in that license fees are prohibited but Distributor Fees are allowed.
52 Distribution of Compiled Forms of the Standard Version or Modified Versions without the Source
53
54 (5) You may Distribute Compiled forms of the Standard Version without the Source, provided that you include complete instructions on how to get the Source of the Standard Version. Such instructions must be valid at the time of your distribution. If these instructions, at any time while you are carrying out such distribution, become invalid, you must provide new instructions on demand or cease further distribution. If you provide valid instructions or cease distribution within thirty days after you become aware that the instructions are invalid, then you do not forfeit any of your rights under this license.
55
56 (6) You may Distribute a Modified Version in Compiled form without the Source, provided that you comply with Section 4 with respect to the Source of the Modified Version.
57 Aggregating or Linking the Package
58
59 (7) You may aggregate the Package (either the Standard Version or Modified Version) with other packages and Distribute the resulting aggregation provided that you do not charge a licensing fee for the Package. Distributor Fees are permitted, and licensing fees for other components in the aggregation are permitted. The terms of this license apply to the use and Distribution of the Standard or Modified Versions as included in the aggregation.
60
61 (8) You are permitted to link Modified and Standard Versions with other works, to embed the Package in a larger work of your own, or to build stand-alone binary or bytecode versions of applications that include the Package, and Distribute the result without restriction, provided the result does not expose a direct interface to the Package.
62 Items That are Not Considered Part of a Modified Version
63
64 (9) Works (including, but not limited to, modules and scripts) that merely extend or make use of the Package, do not, by themselves, cause the Package to be a Modified Version. In addition, such works are not considered parts of the Package itself, and are not subject to the terms of this license.
65 General Provisions
66
67 (10) Any use, modification, and distribution of the Standard or Modified Versions is governed by this Artistic License. By using, modifying or distributing the Package, you accept this license. Do not use, modify, or distribute the Package, if you do not accept this license.
68
69 (11) If your Modified Version has been derived from a Modified Version made by someone other than you, you are nevertheless required to ensure that your Modified Version complies with the requirements of this license.
70
71 (12) This license does not grant you the right to use any trademark, service mark, tradename, or logo of the Copyright Holder.
72
73 (13) This license includes the non-exclusive, worldwide, free-of-charge patent license to make, have made, use, offer to sell, sell, import and otherwise transfer the Package with respect to any patent claims licensable by the Copyright Holder that are necessarily infringed by the Package. If you institute patent litigation (including a cross-claim or counterclaim) against any party alleging that the Package constitutes direct or contributory patent infringement, then this Artistic License to you shall terminate on the date that such litigation is filed.
74
75 (14) Disclaimer of Warranty: THE PACKAGE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS "AS IS' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES. THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR NON-INFRINGEMENT ARE DISCLAIMED TO THE EXTENT PERMITTED BY YOUR LOCAL LAW. UNLESS REQUIRED BY LAW, NO COPYRIGHT HOLDER OR CONTRIBUTOR WILL BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING IN ANY WAY OUT OF THE USE OF THE PACKAGE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
76 */
77
78
79 /*
80  Do not remove or change this notice.
81  overlibmws.js core module - Copyright Foteos Macrides 2002-2005. All rights reserved.
82    Initial: August 18, 2002 - Last Revised: June 8, 2005
83  This module is subject to the same terms of usage as for Erik Bosrup's overLIB,
84  though only a minority of the code and API now correspond with Erik's version.
85  See the overlibmws Change History and Command Reference via:
86
87         http://www.macridesweb.com/oltest/
88
89  Published under an open source license: http://www.macridesweb.com/oltest/license.html
90  Give credit on sites that use overlibmws and submit changes so others can use them as well.
91  You can get Erik's version via: http://www.bosrup.com/web/overlib/
92
93  * The name of the Copyright Holder may not be used to endorse or promote products derived 
94    from this software without specific prior written permission. 
95  * THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, 
96    INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR
97    A PARTICULAR PURPOSE. 
98 */
99
100 // PRE-INIT -- Ignore these lines, configuration is below.
101 var OLloaded=0,pmCnt=1,pMtr=new Array(),OLcmdLine=new Array(),OLrunTime=new Array(),OLv,OLudf,
102 OLpct=new Array("83%","67%","83%","100%","117%","150%","200%","267%"),OLrefXY,
103 OLbubblePI=0,OLcrossframePI=0,OLdebugPI=0,OLdraggablePI=0,OLexclusivePI=0,OLfilterPI=0,
104 OLfunctionPI=0,OLhidePI=0,OLiframePI=0,OLovertwoPI=0,OLscrollPI=0,OLshadowPI=0,OLprintPI=0;
105 if(typeof OLgateOK=='undefined')var OLgateOK=1;
106 var OLp1or2c='inarray,caparray,caption,closetext,right,left,center,autostatuscap,padx,pady,'
107 +'below,above,vcenter,donothing',OLp1or2co='nofollow,background,offsetx,offsety,fgcolor,'
108 +'bgcolor,cgcolor,textcolor,capcolor,width,wrap,wrapmax,height,border,base,status,autostatus,'
109 +'snapx,snapy,fixx,fixy,relx,rely,midx,midy,ref,refc,refp,refx,refy,fgbackground,bgbackground,'
110 +'cgbackground,fullhtml,capicon,textfont,captionfont,textsize,captionsize,timeout,delay,hauto,'
111 +'vauto,nojustx,nojusty,fgclass,bgclass,cgclass,capbelow,textpadding,textfontclass,'
112 +'captionpadding,captionfontclass,sticky,noclose,mouseoff,offdelay,closecolor,closefont,'
113 +'closesize,closeclick,closetitle,closefontclass,decode',OLp1or2o='text,cap,close,hpos,vpos,'
114 +'padxl,padxr,padyt,padyb',OLp1co='label',OLp1or2=OLp1or2co+','+OLp1or2o,OLp1=OLp1co+','+'frame';
115 OLregCmds(OLp1or2c+','+OLp1or2co+','+OLp1co);
116 function OLud(v){return eval('typeof ol_'+v+'=="undefined"')?1:0;}
117
118 // DEFAULT CONFIGURATION -- See overlibConfig.txt for descriptions
119 if(OLud('fgcolor'))var ol_fgcolor="#ccccff";
120 if(OLud('bgcolor'))var ol_bgcolor="#333399";
121 if(OLud('cgcolor'))var ol_cgcolor="#333399";
122 if(OLud('textcolor'))var ol_textcolor="#000000";
123 if(OLud('capcolor'))var ol_capcolor="#ffffff";
124 if(OLud('closecolor'))var ol_closecolor="#eeeeff";
125 if(OLud('textfont'))var ol_textfont="Verdana,Arial,Helvetica";
126 if(OLud('captionfont'))var ol_captionfont="Verdana,Arial,Helvetica";
127 if(OLud('closefont'))var ol_closefont="Verdana,Arial,Helvetica";
128 if(OLud('textsize'))var ol_textsize=1;
129 if(OLud('captionsize'))var ol_captionsize=1;
130 if(OLud('closesize'))var ol_closesize=1;
131 if(OLud('fgclass'))var ol_fgclass="";
132 if(OLud('bgclass'))var ol_bgclass="";
133 if(OLud('cgclass'))var ol_cgclass="";
134 if(OLud('textpadding'))var ol_textpadding=2;
135 if(OLud('textfontclass'))var ol_textfontclass="";
136 if(OLud('captionpadding'))var ol_captionpadding=2;
137 if(OLud('captionfontclass'))var ol_captionfontclass="";
138 if(OLud('closefontclass'))var ol_closefontclass="";
139 if(OLud('close'))var ol_close="Close";
140 if(OLud('closeclick'))var ol_closeclick=0;
141 if(OLud('closetitle'))var ol_closetitle="Click to Close";
142 if(OLud('text'))var ol_text="Default Text";
143 if(OLud('cap'))var ol_cap="";
144 if(OLud('capbelow'))var ol_capbelow=0;
145 if(OLud('background'))var ol_background="";
146 if(OLud('width'))var ol_width=200;
147 if(OLud('wrap'))var ol_wrap=0;
148 if(OLud('wrapmax'))var ol_wrapmax=0;
149 if(OLud('height'))var ol_height= -1;
150 if(OLud('border'))var ol_border=1;
151 if(OLud('base'))var ol_base=0;
152 if(OLud('offsetx'))var ol_offsetx=10;
153 if(OLud('offsety'))var ol_offsety=10;
154 if(OLud('sticky'))var ol_sticky=0;
155 if(OLud('nofollow'))var ol_nofollow=0;
156 if(OLud('noclose'))var ol_noclose=0;
157 if(OLud('mouseoff'))var ol_mouseoff=0;
158 if(OLud('offdelay'))var ol_offdelay=300;
159 if(OLud('hpos'))var ol_hpos=RIGHT;
160 if(OLud('vpos'))var ol_vpos=BELOW;
161 if(OLud('status'))var ol_status="";
162 if(OLud('autostatus'))var ol_autostatus=0;
163 if(OLud('snapx'))var ol_snapx=0;
164 if(OLud('snapy'))var ol_snapy=0;
165 if(OLud('fixx'))var ol_fixx= -1;
166 if(OLud('fixy'))var ol_fixy= -1;
167 if(OLud('relx'))var ol_relx=null;
168 if(OLud('rely'))var ol_rely=null;
169 if(OLud('midx'))var ol_midx=null;
170 if(OLud('midy'))var ol_midy=null;
171 if(OLud('ref'))var ol_ref="";
172 if(OLud('refc'))var ol_refc='UL';
173 if(OLud('refp'))var ol_refp='UL';
174 if(OLud('refx'))var ol_refx=0;
175 if(OLud('refy'))var ol_refy=0;
176 if(OLud('fgbackground'))var ol_fgbackground="";
177 if(OLud('bgbackground'))var ol_bgbackground="";
178 if(OLud('cgbackground'))var ol_cgbackground="";
179 if(OLud('padxl'))var ol_padxl=1;
180 if(OLud('padxr'))var ol_padxr=1;
181 if(OLud('padyt'))var ol_padyt=1;
182 if(OLud('padyb'))var ol_padyb=1;
183 if(OLud('fullhtml'))var ol_fullhtml=0;
184 if(OLud('capicon'))var ol_capicon="";
185 if(OLud('frame'))var ol_frame=self;
186 if(OLud('timeout'))var ol_timeout=0;
187 if(OLud('delay'))var ol_delay=0;
188 if(OLud('hauto'))var ol_hauto=0;
189 if(OLud('vauto'))var ol_vauto=0;
190 if(OLud('nojustx'))var ol_nojustx=0;
191 if(OLud('nojusty'))var ol_nojusty=0;
192 if(OLud('label'))var ol_label="";
193 if(OLud('decode'))var ol_decode=0;
194 // ARRAY CONFIGURATION - See overlibConfig.txt for descriptions.
195 if(OLud('texts'))var ol_texts=new Array("Text 0","Text 1");
196 if(OLud('caps'))var ol_caps=new Array("Caption 0","Caption 1");
197 // END CONFIGURATION -- Don't change anything below, all configuration is above.
198
199 // INIT -- Runtime variables.
200 var o3_text="",o3_cap="",o3_sticky=0,o3_nofollow=0,o3_background="",o3_noclose=0,o3_mouseoff=0,
201 o3_offdelay=300,o3_hpos=RIGHT,o3_offsetx=10,o3_offsety=10,o3_fgcolor="",o3_bgcolor="",
202 o3_cgcolor="",o3_textcolor="",o3_capcolor="",o3_closecolor="",o3_width=200,o3_wrap=0,
203 o3_wrapmax=0,o3_height= -1,o3_border=1,o3_base=0,o3_status="",o3_autostatus=0,o3_snapx=0,
204 o3_snapy=0,o3_fixx= -1,o3_fixy= -1,o3_relx=null,o3_rely=null,o3_midx=null,o3_midy=null,o3_ref="",
205 o3_refc='UL',o3_refp='UL',o3_refx=0,o3_refy=0,o3_fgbackground="",o3_bgbackground="",
206 o3_cgbackground="",o3_padxl=0,o3_padxr=0,o3_padyt=0,o3_padyb=0,o3_fullhtml=0,o3_vpos=BELOW,
207 o3_capicon="",o3_textfont="Verdana,Arial,Helvetica",o3_captionfont="",o3_closefont="",
208 o3_textsize=1,o3_captionsize=1,o3_closesize=1,o3_frame=self,o3_timeout=0,o3_delay=0,o3_hauto=0,
209 o3_vauto=0,o3_nojustx=0,o3_nojusty=0,o3_close="",o3_closeclick=0,o3_closetitle="",o3_fgclass="",
210 o3_bgclass="",o3_cgclass="",o3_textpadding=2,o3_textfontclass="",o3_captionpadding=2,
211 o3_captionfontclass="",o3_closefontclass="",o3_capbelow=0,o3_label="",o3_decode=0,
212 CSSOFF=DONOTHING,CSSCLASS=DONOTHING,OLdelayid=0,OLtimerid=0,OLshowid=0,OLndt=0,over=null,
213 OLfnRef="",OLhover=0,OLx=0,OLy=0,OLshowingsticky=0,OLallowmove=0,OLcC=null,
214 OLua=navigator.userAgent.toLowerCase(),
215 OLns4=(navigator.appName=='Netscape'&&parseInt(navigator.appVersion)==4),
216 OLns6=(document.getElementById)?1:0,
217 OLie4=(document.all)?1:0,
218 OLgek=(OLv=OLua.match(/gecko\/(\d{8})/i))?parseInt(OLv[1]):0,
219 OLmac=(OLua.indexOf('mac')>=0)?1:0,
220 OLsaf=(OLua.indexOf('safari')>=0)?1:0,
221 OLkon=(OLua.indexOf('konqueror')>=0)?1:0,
222 OLkht=(OLsaf||OLkon)?1:0,
223 OLopr=(OLua.indexOf('opera')>=0)?1:0,
224 OLop7=(OLopr&&document.createTextNode)?1:0;
225 if(OLopr){OLns4=OLns6=0;if(!OLop7)OLie4=0;}
226 var OLieM=((OLie4&&OLmac)&&!(OLkht||OLopr))?1:0,
227 OLie5=0,OLie55=0;if(OLie4&&!OLop7){
228 if((OLv=OLua.match(/msie (\d\.\d+)\.*/i))&&(OLv=parseFloat(OLv[1]))>=5.0){
229 OLie5=1;OLns6=0;if(OLv>=5.5)OLie55=1;}if(OLns6)OLie4=0;}
230 if(OLns4)window.onresize=function(){location.reload();}
231 var OLchkMh=1,OLdw;
232 if(OLns4||OLie4||OLns6)OLmh();
233 else{overlib=nd=cClick=OLpageDefaults=no_overlib;}
234
235 /*
236  PUBLIC FUNCTIONS
237 */
238 // Loads defaults then args into runtime variables.
239 function overlib(){
240 if(!(OLloaded&&OLgateOK))return;
241 if((OLexclusivePI)&&OLisExclusive(arguments))return true;
242 if(OLchkMh)OLmh();
243 if(OLndt&&!OLtimerid)OLndt=0;if(over)cClick();
244 OLload(OLp1or2);OLload(OLp1);
245 OLfnRef="";OLhover=0;
246 OLsetRunTimeVar();
247 OLparseTokens('o3_',arguments);
248 if(!(over=OLmkLyr()))return false;
249 if(o3_decode)OLdecode();
250 if(OLprintPI)OLchkPrint();
251 if(OLbubblePI)OLchkForBubbleEffect();
252 if(OLdebugPI)OLsetDebugCanShow();
253 if(OLshadowPI)OLinitShadow();
254 if(OLiframePI)OLinitIfs();
255 if(OLfilterPI)OLinitFilterLyr();
256 if(OLexclusivePI&&o3_exclusive&&o3_exclusivestatus!="")o3_status=o3_exclusivestatus;
257 else if(o3_autostatus==2&&o3_cap!="")o3_status=o3_cap;
258 else if(o3_autostatus==1&&o3_text!="")o3_status=o3_text;
259 if(!o3_delay){return OLmain();
260 }else{OLdelayid=setTimeout("OLmain()",o3_delay);
261 if(o3_status!=""){self.status=o3_status;return true;}
262 else if(!(OLop7&&event&&event.type=='mouseover'))return false;}
263 }
264
265 // Clears popups if appropriate
266 function nd(time){
267 if(OLloaded&&OLgateOK){if(!((OLexclusivePI)&&OLisExclusive())){
268 if(time&&over&&!o3_delay){if(OLtimerid>0)clearTimeout(OLtimerid);
269 OLtimerid=(OLhover&&o3_frame==self&&!OLcursorOff())?0:
270 setTimeout("cClick()",(o3_timeout=OLndt=time));}else{
271 if(!OLshowingsticky){OLallowmove=0;if(over)OLhideObject(over);}}}}
272 return false;
273 }
274
275 // Close function for stickies
276 function cClick(){
277 if(OLloaded&&OLgateOK){OLhover=0;if(over){
278 if(OLovertwoPI&&over==over2)cClick2();OLhideObject(over);OLshowingsticky=0;}}
279 return false;
280 }
281
282 // Sets page-specific defaults.
283 function OLpageDefaults(){
284 OLparseTokens('ol_',arguments);
285 }
286
287 // For unsupported browsers.
288 function no_overlib(){return false;}
289
290 /*
291  OVERLIB MAIN FUNCTION SET
292 */
293 function OLmain(){
294 o3_delay=0;
295 if(o3_frame==self){if(o3_noclose)OLoptMOUSEOFF(0);else if(o3_mouseoff)OLoptMOUSEOFF(1);}
296 if(o3_sticky)OLshowingsticky=1;OLdoLyr();OLallowmove=0;if(o3_timeout>0){
297 if(OLtimerid>0)clearTimeout(OLtimerid);OLtimerid=setTimeout("cClick()",o3_timeout);}
298 if(o3_ref){OLrefXY=OLgetRefXY(o3_ref);if(OLrefXY[0]==null){o3_ref="";o3_midx=0;o3_midy=0;}}
299 OLdisp(o3_status);if(OLdraggablePI)OLcheckDrag();
300 if(o3_status!="")return true;else if(!(OLop7&&event&&event.type=='mouseover'))return false;
301 }
302
303 // Loads o3_ variables
304 function OLload(c){var i,m=c.split(',');for(i=0;i<m.length;i++)eval('o3_'+m[i]+'=ol_'+m[i]);}
305
306 // Chooses LGF 
307 function OLdoLGF(){
308 return (o3_background!=''||o3_fullhtml)?OLcontentBackground(o3_text,o3_background,o3_fullhtml):
309 (o3_cap=="")?OLcontentSimple(o3_text):
310 (o3_sticky)?OLcontentCaption(o3_text,o3_cap,o3_close):OLcontentCaption(o3_text,o3_cap,'');
311 }
312
313 // Makes Layer
314 function OLmkLyr(id,f,z){
315 id=(id||'overDiv');f=(f||o3_frame);z=(z||1000);var fd=f.document,d=OLgetRefById(id,fd);
316 if(!d){if(OLns4)d=fd.layers[id]=new Layer(1024,f);else if(OLie4&&!document.getElementById){
317 fd.body.insertAdjacentHTML('BeforeEnd','<div id="'+id+'"></div>');d=fd.all[id];
318 }else{d=fd.createElement('div');if(d){d.id=id;fd.body.appendChild(d);}}if(!d)return null;
319 if(OLns4)d.zIndex=z;else{var o=d.style;o.position='absolute';o.visibility='hidden';o.zIndex=z;}}
320 return d;
321 }
322
323 // Creates and writes layer content
324 function OLdoLyr(){
325 if(o3_background==''&&!o3_fullhtml){
326 if(o3_fgbackground!='')o3_fgbackground=' background="'+o3_fgbackground+'"';
327 if(o3_bgbackground!='')o3_bgbackground=' background="'+o3_bgbackground+'"';
328 if(o3_cgbackground!='')o3_cgbackground=' background="'+o3_cgbackground+'"';
329 if(o3_fgcolor!='')o3_fgcolor=' bgcolor="'+o3_fgcolor+'"';
330 if(o3_bgcolor!='')o3_bgcolor=' bgcolor="'+o3_bgcolor+'"';
331 if(o3_cgcolor!='')o3_cgcolor=' bgcolor="'+o3_cgcolor+'"';
332 if(o3_height>0)o3_height=' height="'+o3_height+'"';else o3_height='';}
333 if(!OLns4)OLrepositionTo(over,(OLns6?20:0),0);var lyrHtml=OLdoLGF();
334 if(o3_sticky&&OLtimerid>0){clearTimeout(OLtimerid);OLtimerid=0;}
335 if(o3_wrap&&!o3_fullhtml){OLlayerWrite(lyrHtml);
336 o3_width=(OLns4?over.clip.width:over.offsetWidth);
337 if(OLns4&&o3_wrapmax<1)o3_wrapmax=o3_frame.innerWidth-40;
338 o3_wrap=0;if(o3_wrapmax>0&&o3_width>o3_wrapmax)o3_width=o3_wrapmax;lyrHtml=OLdoLGF();}
339 OLlayerWrite(lyrHtml);o3_width=(OLns4?over.clip.width:over.offsetWidth);
340 if(OLbubblePI)OLgenerateBubble(lyrHtml);
341 }
342
343 /*
344  LAYER GENERATION FUNCTIONS
345 */
346 // Makes simple table without caption
347 function OLcontentSimple(txt){
348 var t=OLbgLGF()+OLfgLGF(txt)+OLbaseLGF();
349 OLsetBackground('');return t;
350 }
351
352 // Makes table with caption and optional close link
353 function OLcontentCaption(txt,title,close){
354 var closing=(OLprintPI?OLprintCapLGF():''),closeevent='onmouseover',caption,t,
355 cC='javascript:return '+OLfnRef+(OLovertwoPI&&over==over2?'cClick2();':'cClick();');
356 if(o3_closeclick)closeevent=(o3_closetitle?'title="'+o3_closetitle+'" ':'')+'onclick';
357 if(o3_capicon!='')o3_capicon='<img src="'+o3_capicon+'" /> ';
358 if(close){closing+='<a href="'+cC+'" '
359 +closeevent+'="'+cC+'"'+(o3_closefontclass?'>':'>'+OLlgfUtil(0,'','span',o3_closecolor,o3_closefont,o3_closesize))+close
360 +(o3_closefontclass?'':OLlgfUtil(1,'','span'))+'</a>';}
361 caption='<table'+OLwd(0)+' border="0" cellpadding="'+o3_captionpadding+'" cellspacing="0"'
362 +(o3_cgclass?' class="'+o3_cgclass+'"':o3_cgcolor+o3_cgbackground)+'><tr><td'+OLwd(0)
363 +(o3_cgclass?' class="'+o3_cgclass+'">':'>')+(o3_captionfontclass?'<div class="'
364 +o3_captionfontclass+'">':''
365 +OLlgfUtil(0,'','',o3_capcolor,o3_captionfont,o3_captionsize))+o3_capicon+title
366 +OLlgfUtil(1,'','')+(o3_captionfontclass?'':'')+closing+'</div></td></tr></table>';
367 t=OLbgLGF()+(o3_capbelow?OLfgLGF(txt)+caption:caption+OLfgLGF(txt))+OLbaseLGF();
368 OLsetBackground('');return t;
369 }
370
371 // For BACKGROUND and FULLHTML commands
372 function OLcontentBackground(txt, image, hasfullhtml){
373 var t;if(hasfullhtml){t=txt;}else{t='<table'+OLwd(1)
374 +' border="0" cellpadding="0" cellspacing="0" '+'height="'+o3_height
375 +'"><tr><td colspan="3" height="'+o3_padyt+'"></td></tr><tr><td width="'
376 +o3_padxl+'"></td><td valign="top"'+OLwd(2)+'>'
377 +OLlgfUtil(0,o3_textfontclass,'div',o3_textcolor,o3_textfont,o3_textsize)+txt+
378 OLlgfUtil(1,'','div')+'</td><td width="'+o3_padxr+'"></td></tr><tr><td colspan="3" height="'
379 +o3_padyb+'"></td></tr></table>';}
380 OLsetBackground(image);return t;
381 }
382
383 // LGF utilities
384 function OLbgLGF(){
385 return '<table'+OLwd(1)+o3_height+' border="0" cellpadding="'+o3_border+'" cellspacing="0"'
386 +(o3_bgclass?' class="'+o3_bgclass+'"':o3_bgcolor+o3_bgbackground)+'><tr><td>';
387 }
388 function OLfgLGF(t){
389 return '<table'+OLwd(0)+o3_height+' border="0" cellpadding="'+o3_textpadding
390 +'" cellspacing="0"'+(o3_fgclass?' class="'+o3_fgclass+'"':o3_fgcolor+o3_fgbackground)
391 +'><tr><td valign="top"'+(o3_fgclass?' class="'+o3_fgclass+'"':'')+'>'
392 +OLlgfUtil(0,o3_textfontclass,'div',o3_textcolor,o3_textfont,o3_textsize)+t
393 +(OLprintPI?OLprintFgLGF():'')+OLlgfUtil(1,'','div')+'</td></tr></table>';
394 }
395 function OLlgfUtil(end,tfc,ele,col,fac,siz){
396 if(end)return ('</'+(OLns4?'font':ele)+'>');else return (tfc?'<div class="'+tfc+'">':
397 ('<'+(OLns4?'font color="'+col+'" face="'+OLquoteMultiNameFonts(fac)+'" size="'+siz:ele
398 +' style="color:'+col+';font-family:'+OLquoteMultiNameFonts(fac)+';font-size:'+siz+';'
399 +(ele=='span'?'text-decoration:underline;':''))+'">'));
400 }
401 function OLquoteMultiNameFonts(f){
402 var i,v,pM=f.split(',');
403 for(i=0;i<pM.length;i++){v=pM[i];v=v.replace(/^\s+/,'').replace(/\s+$/,'');
404 if(/\s/.test(v) && !/['"]/.test(v)){v="\'"+v+"\'";pM[i]=v;}}            //' extra quote is added for minification work around
405 return pM.join();
406 }
407 function OLbaseLGF(){
408 return ((o3_base>0&&!o3_wrap)?('<table width="100%" border="0" cellpadding="0" cellspacing="0"'
409 +(o3_bgclass?' class="'+o3_bgclass+'"':'')+'><tr><td height="'+o3_base
410 +'"></td></tr></table>'):'')+'</td></tr></table>';
411 }
412 function OLwd(a){
413 return(o3_wrap?'':' width="'+(!a?'100%':(a==1?o3_width:(o3_width-o3_padxl-o3_padxr)))+'"');
414 }
415
416 // Loads image into the div.
417 function OLsetBackground(i){
418 if(i==''){if(OLns4)over.background.src=null;
419 else{if(OLns6)over.style.width='';over.style.backgroundImage='none';}
420 }else{if(OLns4)over.background.src=i;
421 else{if(OLns6)over.style.width=o3_width+'px';over.style.backgroundImage='url('+i+')';}}
422 }
423
424 /*
425  HANDLING FUNCTIONS
426 */
427 // Displays layer
428 function OLdisp(s){
429 if(!OLallowmove){if(OLshadowPI)OLdispShadow();if(OLiframePI)OLdispIfs();OLplaceLayer();
430 if(OLndt)OLshowObject(over);else OLshowid=setTimeout("OLshowObject(over)",1);
431 OLallowmove=(o3_sticky||o3_nofollow)?0:1;}OLndt=0;if(s!="")self.status=s;
432 }
433
434 // Decides placement of layer.
435 function OLplaceLayer(){
436 var snp,X,Y,pgLeft,pgTop,pWd=o3_width,pHt,iWd=100,iHt=100,SB=0,LM=0,CX=0,TM=0,BM=0,CY=0,
437 o=OLfd(),nsb=(OLgek>=20010505&&!o3_frame.scrollbars.visible)?1:0;
438 if(!OLkht&&o&&o.clientWidth)iWd=o.clientWidth;
439 else if(o3_frame.innerWidth){SB=Math.ceil(1.4*(o3_frame.outerWidth-o3_frame.innerWidth));
440 if(SB>20)SB=20;iWd=o3_frame.innerWidth;}
441 pgLeft=(OLie4)?o.scrollLeft:o3_frame.pageXOffset;
442 if(OLie55&&OLfilterPI&&o3_filter&&o3_filtershadow)SB=CX=5;else
443 if((OLshadowPI)&&bkdrop&&o3_shadow&&o3_shadowx){SB+=((o3_shadowx>0)?o3_shadowx:0);
444 LM=((o3_shadowx<0)?Math.abs(o3_shadowx):0);CX=Math.abs(o3_shadowx);}
445 if(o3_ref!=""||o3_fixx> -1||o3_relx!=null||o3_midx!=null){
446 if(o3_ref!=""){X=OLrefXY[0];if(OLie55&&OLfilterPI&&o3_filter&&o3_filtershadow){
447 if(o3_refp=='UR'||o3_refp=='LR')X-=5;}
448 else if((OLshadowPI)&&bkdrop&&o3_shadow&&o3_shadowx){
449 if(o3_shadowx<0&&(o3_refp=='UL'||o3_refp=='LL'))X-=o3_shadowx;else
450 if(o3_shadowx>0&&(o3_refp=='UR'||o3_refp=='LR'))X-=o3_shadowx;}
451 }else{if(o3_midx!=null){
452 X=parseInt(pgLeft+((iWd-pWd-SB-LM)/2)+o3_midx);
453 }else{if(o3_relx!=null){
454 if(o3_relx>=0)X=pgLeft+o3_relx+LM;else X=pgLeft+o3_relx+iWd-pWd-SB;
455 }else{X=o3_fixx+LM;}}}
456 }else{
457 if(o3_hauto){
458 if(o3_hpos==LEFT&&OLx-pgLeft<iWd/2&&OLx-pWd-o3_offsetx<pgLeft+LM)o3_hpos=RIGHT;else
459 if(o3_hpos==RIGHT&&OLx-pgLeft>iWd/2&&OLx+pWd+o3_offsetx>pgLeft+iWd-SB)o3_hpos=LEFT;}
460 X=(o3_hpos==CENTER)?parseInt(OLx-((pWd+CX)/2)+o3_offsetx):
461 (o3_hpos==LEFT)?OLx-o3_offsetx-pWd:OLx+o3_offsetx;
462 if(o3_snapx>1){
463 snp=X % o3_snapx;
464 if(o3_hpos==LEFT){X=X-(o3_snapx+snp);}else{X=X+(o3_snapx-snp);}}}
465 if(!o3_nojustx&&X+pWd>pgLeft+iWd-SB)
466 X=iWd+pgLeft-pWd-SB;if(!o3_nojustx&&X-LM<pgLeft)X=pgLeft+LM;
467 pgTop=OLie4?o.scrollTop:o3_frame.pageYOffset;
468 if(!OLkht&&!nsb&&o&&o.clientHeight)iHt=o.clientHeight;
469 else if(o3_frame.innerHeight)iHt=o3_frame.innerHeight;
470 if(OLbubblePI&&o3_bubble)pHt=OLbubbleHt;else pHt=OLns4?over.clip.height:over.offsetHeight;
471 if((OLshadowPI)&&bkdrop&&o3_shadow&&o3_shadowy){TM=(o3_shadowy<0)?Math.abs(o3_shadowy):0;
472 if(OLie55&&OLfilterPI&&o3_filter&&o3_filtershadow)BM=CY=5;else
473 BM=(o3_shadowy>0)?o3_shadowy:0;CY=Math.abs(o3_shadowy);}
474 if(o3_ref!=""||o3_fixy> -1||o3_rely!=null||o3_midy!=null){
475 if(o3_ref!=""){Y=OLrefXY[1];if(OLie55&&OLfilterPI&&o3_filter&&o3_filtershadow){
476 if(o3_refp=='LL'||o3_refp=='LR')Y-=5;}else if((OLshadowPI)&&bkdrop&&o3_shadow&&o3_shadowy){
477 if(o3_shadowy<0&&(o3_refp=='UL'||o3_refp=='UR'))Y-=o3_shadowy;else
478 if(o3_shadowy>0&&(o3_refp=='LL'||o3_refp=='LR'))Y-=o3_shadowy;}
479 }else{if(o3_midy!=null){
480 Y=parseInt(pgTop+((iHt-pHt-CY)/2)+o3_midy);
481 }else{if(o3_rely!=null){
482 if(o3_rely>=0)Y=pgTop+o3_rely+TM;else Y=pgTop+o3_rely+iHt-pHt-BM;}else{
483 Y=o3_fixy+TM;}}}
484 }else{
485 if(o3_vauto){
486 if(o3_vpos==ABOVE&&OLy-pgTop<iHt/2&&OLy-pHt-o3_offsety<pgTop)o3_vpos=BELOW;else
487 if(o3_vpos==BELOW&&OLy-pgTop>iHt/2&&OLy+pHt+o3_offsety+((OLns4||OLkht)?17:0)>pgTop+iHt-BM)
488 o3_vpos=ABOVE;}Y=(o3_vpos==VCENTER)?parseInt(OLy-((pHt+CY)/2)+o3_offsety):
489 (o3_vpos==ABOVE)?OLy-(pHt+o3_offsety+BM):OLy+o3_offsety+TM;
490 if(o3_snapy>1){
491 snp=Y % o3_snapy;
492 if(pHt>0&&o3_vpos==ABOVE){Y=Y-(o3_snapy+snp);}else{Y=Y+(o3_snapy-snp);}}}
493 if(!o3_nojusty&&Y+pHt+BM>pgTop+iHt)Y=pgTop+iHt-pHt-BM;if(!o3_nojusty&&Y-TM<pgTop)Y=pgTop+TM;
494 OLrepositionTo(over,X,Y);
495 if(OLshadowPI)OLrepositionShadow(X,Y);if(OLiframePI)OLrepositionIfs(X,Y);
496 if(OLns6&&o3_frame.innerHeight){iHt=o3_frame.innerHeight;OLrepositionTo(over,X,Y);}
497 if(OLscrollPI)OLchkScroll(X-pgLeft,Y-pgTop);
498 }
499
500 // Chooses body or documentElement
501 function OLfd(f){
502 var fd=((f)?f:o3_frame).document,fdc=fd.compatMode,fdd=fd.documentElement;
503 return (!OLop7&&fdc&&fdc!='BackCompat'&&fdd&&fdd.clientWidth)?fd.documentElement:fd.body;
504 }
505
506 // Gets location of REFerence object
507 function OLgetRefXY(r){
508 var o=OLgetRef(r),ob=o,rXY=[o3_refx,o3_refy],of;
509 if(!o)return [null,null];
510 if(OLns4){if(typeof o.length!='undefined'&&o.length>1){
511 ob=o[0];rXY[0]+=o[0].x+o[1].pageX;rXY[1]+=o[0].y+o[1].pageY;
512 }else{if((o.toString().indexOf('Image')!= -1)||(o.toString().indexOf('Anchor')!= -1)){
513 rXY[0]+=o.x;rXY[1]+=o.y;}else{rXY[0]+=o.pageX;rXY[1]+=o.pageY;}}
514 }else{rXY[0]+=OLpageLoc(o,'Left');rXY[1]+=OLpageLoc(o,'Top');}
515 of=OLgetRefOffsets(ob);rXY[0]+=of[0];rXY[1]+=of[1];
516 return rXY;
517 }
518 function OLgetRef(l){var r=OLgetRefById(l);return (r)?r:OLgetRefByName(l);}
519
520 // Seeks REFerence by id
521 function OLgetRefById(l,d){
522 var r="",j;l=(l||'overDiv');d=(d||o3_frame.document);
523 if(OLie4&&d.all){return d.all[l];}else if(d.getElementById){return d.getElementById(l);
524 }else if(d.layers&&d.layers.length>0){if(d.layers[l])return d.layers[l];
525 for(j=0;j<d.layers.length;j++){r=OLgetRefById(l,d.layers[j].document);if(r)return r;}}
526 return null;
527 }
528
529 // Seeks REFerence by name (for img and a)
530 function OLgetRefByName(l,d){
531 var r=null,j;d=(d||o3_frame.document);
532 if(typeof d.images[l]!='undefined'&&d.images[l]){return d.images[l];
533 }else if(typeof d.anchors[l]!='undefined'&&d.anchors[l]){return d.anchors[l];
534 }else if(d.layers&&d.layers.length>0){
535 for(j=0;j<d.layers.length;j++){r=OLgetRefByName(l,d.layers[j].document);
536 if(r&&r.length>0)return r;else if(r)return [r,d.layers[j]];}}
537 return null;
538 }
539
540 // Gets layer vs REFerence offsets
541 function OLgetRefOffsets(o){
542 var c=o3_refc.toUpperCase(),p=o3_refp.toUpperCase(),W=0,H=0,pW=0,pH=0,of=[0,0];
543 pW=(OLbubblePI&&o3_bubble)?o3_width:OLns4?over.clip.width:over.offsetWidth;
544 pH=(OLbubblePI&&o3_bubble)?OLbubbleHt:OLns4?over.clip.height:over.offsetHeight;
545 if((!OLop7)&&o.toString().indexOf('Image')!= -1){W=o.width;H=o.height;
546 }else if((!OLop7)&&o.toString().indexOf('Anchor')!= -1){c=o3_refc='UL';}else{
547 W=(OLns4)?o.clip.width:o.offsetWidth;H=(OLns4)?o.clip.height:o.offsetHeight;}
548 if((OLns4||(OLns6&&OLgek))&&o.border){W+=2*parseInt(o.border);H+=2*parseInt(o.border);}
549 if(c=='UL'){of=(p=='UR')?[-pW,0]:(p=='LL')?[0,-pH]:(p=='LR')?[-pW,-pH]:[0,0];
550 }else if(c=='UR'){of=(p=='UR')?[W-pW,0]:(p=='LL')?[W,-pH]:(p=='LR')?[W-pW,-pH]:[W,0];
551 }else if(c=='LL'){of=(p=='UR')?[-pW,H]:(p=='LL')?[0,H-pH]:(p=='LR')?[-pW,H-pH]:[0,H];
552 }else if(c=='LR'){of=(p=='UR')?[W-pW,H]:(p=='LL')?[W,H-pH]:(p=='LR')?[W-pW,H-pH]:
553 [W,H];}
554 return of;
555 }
556
557 // Gets x or y location of object
558 function OLpageLoc(o,t){
559 var l=0;while(o.offsetParent&&o.offsetParent.tagName.toLowerCase()!='html'){
560 l+=o['offset'+t];o=o.offsetParent;}l+=o['offset'+t];
561 return l;
562
563
564 // Moves layer
565 function OLmouseMove(e){
566 var e=(e||event);
567 OLcC=(OLovertwoPI&&over2&&over==over2?cClick2:cClick);
568 OLx=(e.pageX||e.clientX+OLfd().scrollLeft);OLy=(e.pageY||e.clientY+OLfd().scrollTop);
569 if((OLallowmove&&over)&&(o3_frame==self||over==OLgetRefById())){
570 OLplaceLayer();if(OLhidePI)OLhideUtil(0,1,1,0,0,0);}
571 if(OLhover&&over&&o3_frame==self&&OLcursorOff())if(o3_offdelay<1)OLcC();else
572 {if(OLtimerid>0)clearTimeout(OLtimerid);OLtimerid=setTimeout("OLcC()",o3_offdelay);}
573 }
574
575 // Capture mouse and chain other scripts.
576 function OLmh(){
577 var fN,f,j,k,s,mh=OLmouseMove,w=(OLns4&&window.onmousemove),re=/function[ ]*(\w*)\(/;
578 OLdw=document;if(document.onmousemove||w){if(w)OLdw=window;f=OLdw.onmousemove.toString();
579 fN=f.match(re);if(!fN||fN[1]=='anonymous'||fN[1]=='OLmouseMove'){OLchkMh=0;return;}
580 if(fN[1])s=fN[1]+'(e)';else{j=f.indexOf('{');k=f.lastIndexOf('}')+1;s=f.substring(j,k);}
581 s+=';OLmouseMove(e);';mh=new Function('e',s);}
582 OLdw.onmousemove=mh;if(OLns4)OLdw.captureEvents(Event.MOUSEMOVE);
583 }
584
585 /*
586  PARSING
587 */
588 function OLparseTokens(pf,ar){
589 var i,v,md= -1,par=(pf!='ol_'),p=OLpar,q=OLparQuo,t=OLtoggle;OLudf=(par&&!ar.length?1:0);
590 for(i=0;i< ar.length;i++){if(md<0){if(typeof ar[i]=='number'){OLudf=(par?1:0);i--;}
591 else{switch(pf){case 'ol_':ol_text=ar[i];break;default:o3_text=ar[i];}}md=0;
592 }else{
593 if(ar[i]==INARRAY){OLudf=0;eval(pf+'text=ol_texts['+ar[++i]+']');continue;}
594 if(ar[i]==CAPARRAY){eval(pf+'cap=ol_caps['+ar[++i]+']');continue;}
595 if(ar[i]==CAPTION){q(ar[++i],pf+'cap');continue;}
596 if(Math.abs(ar[i])==STICKY){t(ar[i],pf+'sticky');continue;}
597 if(Math.abs(ar[i])==NOFOLLOW){t(ar[i],pf+'nofollow');continue;}
598 if(ar[i]==BACKGROUND){q(ar[++i],pf+'background');continue;}
599 if(Math.abs(ar[i])==NOCLOSE){t(ar[i],pf+'noclose');continue;}
600 if(Math.abs(ar[i])==MOUSEOFF){t(ar[i],pf+'mouseoff');continue;}
601 if(ar[i]==OFFDELAY){p(ar[++i],pf+'offdelay');continue;}
602 if(ar[i]==RIGHT||ar[i]==LEFT||ar[i]==CENTER){p(ar[i],pf+'hpos');continue;}
603 if(ar[i]==OFFSETX){p(ar[++i],pf+'offsetx');continue;}
604 if(ar[i]==OFFSETY){p(ar[++i],pf+'offsety');continue;}
605 if(ar[i]==FGCOLOR){q(ar[++i],pf+'fgcolor');continue;}
606 if(ar[i]==BGCOLOR){q(ar[++i],pf+'bgcolor');continue;}
607 if(ar[i]==CGCOLOR){q(ar[++i],pf+'cgcolor');continue;}
608 if(ar[i]==TEXTCOLOR){q(ar[++i],pf+'textcolor');continue;}
609 if(ar[i]==CAPCOLOR){q(ar[++i],pf+'capcolor');continue;}
610 if(ar[i]==CLOSECOLOR){q(ar[++i],pf+'closecolor');continue;}
611 if(ar[i]==WIDTH){p(ar[++i],pf+'width');continue;}
612 if(Math.abs(ar[i])==WRAP){t(ar[i],pf+'wrap');continue;}
613 if(ar[i]==WRAPMAX){p(ar[++i],pf+'wrapmax');continue;}
614 if(ar[i]==HEIGHT){p(ar[++i],pf+'height');continue;}
615 if(ar[i]==BORDER){p(ar[++i],pf+'border');continue;}
616 if(ar[i]==BASE){p(ar[++i],pf+'base');continue;}
617 if(ar[i]==STATUS){q(ar[++i],pf+'status');continue;}
618 if(Math.abs(ar[i])==AUTOSTATUS){v=pf+'autostatus';
619 eval(v+'=('+ar[i]+'<0)?('+v+'==2?2:0):('+v+'==1?0:1)');continue;}
620 if(Math.abs(ar[i])==AUTOSTATUSCAP){v=pf+'autostatus';
621 eval(v+'=('+ar[i]+'<0)?('+v+'==1?1:0):('+v+'==2?0:2)');continue;}
622 if(ar[i]==CLOSETEXT){q(ar[++i],pf+'close');continue;}
623 if(ar[i]==SNAPX){p(ar[++i],pf+'snapx');continue;}
624 if(ar[i]==SNAPY){p(ar[++i],pf+'snapy');continue;}
625 if(ar[i]==FIXX){p(ar[++i],pf+'fixx');continue;}
626 if(ar[i]==FIXY){p(ar[++i],pf+'fixy');continue;}
627 if(ar[i]==RELX){p(ar[++i],pf+'relx');continue;}
628 if(ar[i]==RELY){p(ar[++i],pf+'rely');continue;}
629 if(ar[i]==MIDX){p(ar[++i],pf+'midx');continue;}
630 if(ar[i]==MIDY){p(ar[++i],pf+'midy');continue;}
631 if(ar[i]==REF){q(ar[++i],pf+'ref');continue;}
632 if(ar[i]==REFC){q(ar[++i],pf+'refc');continue;}
633 if(ar[i]==REFP){q(ar[++i],pf+'refp');continue;}
634 if(ar[i]==REFX){p(ar[++i],pf+'refx');continue;}
635 if(ar[i]==REFY){p(ar[++i],pf+'refy');continue;}
636 if(ar[i]==FGBACKGROUND){q(ar[++i],pf+'fgbackground');continue;}
637 if(ar[i]==BGBACKGROUND){q(ar[++i],pf+'bgbackground');continue;}
638 if(ar[i]==CGBACKGROUND){q(ar[++i],pf+'cgbackground');continue;}
639 if(ar[i]==PADX){p(ar[++i],pf+'padxl');p(ar[++i],pf+'padxr');continue;}
640 if(ar[i]==PADY){p(ar[++i],pf+'padyt');p(ar[++i],pf+'padyb');continue;}
641 if(Math.abs(ar[i])==FULLHTML){t(ar[i],pf+'fullhtml');continue;}
642 if(ar[i]==BELOW||ar[i]==ABOVE||ar[i]==VCENTER){p(ar[i],pf+'vpos');continue;}
643 if(ar[i]==CAPICON){q(ar[++i],pf+'capicon');continue;}
644 if(ar[i]==TEXTFONT){q(ar[++i],pf+'textfont');continue;}
645 if(ar[i]==CAPTIONFONT){q(ar[++i],pf+'captionfont');continue;}
646 if(ar[i]==CLOSEFONT){q(ar[++i],pf+'closefont');continue;}
647 if(ar[i]==TEXTSIZE){q(ar[++i],pf+'textsize');continue;}
648 if(ar[i]==CAPTIONSIZE){q(ar[++i],pf+'captionsize');continue;}
649 if(ar[i]==CLOSESIZE){q(ar[++i],pf+'closesize');continue;}
650 if(ar[i]==TIMEOUT){p(ar[++i],pf+'timeout');continue;}
651 if(ar[i]==DELAY){p(ar[++i],pf+'delay');continue;}
652 if(Math.abs(ar[i])==HAUTO){t(ar[i],pf+'hauto');continue;}
653 if(Math.abs(ar[i])==VAUTO){t(ar[i],pf+'vauto');continue;}
654 if(Math.abs(ar[i])==NOJUSTX){t(ar[i],pf+'nojustx');continue;}
655 if(Math.abs(ar[i])==NOJUSTY){t(ar[i],pf+'nojusty');continue;}
656 if(Math.abs(ar[i])==CLOSECLICK){t(ar[i],pf+'closeclick');continue;}
657 if(ar[i]==CLOSETITLE){q(ar[++i],pf+'closetitle');continue;}
658 if(ar[i]==FGCLASS){q(ar[++i],pf+'fgclass');continue;}
659 if(ar[i]==BGCLASS){q(ar[++i],pf+'bgclass');continue;}
660 if(ar[i]==CGCLASS){q(ar[++i],pf+'cgclass');continue;}
661 if(ar[i]==TEXTPADDING){p(ar[++i],pf+'textpadding');continue;}
662 if(ar[i]==TEXTFONTCLASS){q(ar[++i],pf+'textfontclass');continue;}
663 if(ar[i]==CAPTIONPADDING){p(ar[++i],pf+'captionpadding');continue;}
664 if(ar[i]==CAPTIONFONTCLASS){q(ar[++i],pf+'captionfontclass');continue;}
665 if(ar[i]==CLOSEFONTCLASS){q(ar[++i],pf+'closefontclass');continue;}
666 if(Math.abs(ar[i])==CAPBELOW){t(ar[i],pf+'capbelow');continue;}
667 if(ar[i]==LABEL){q(ar[++i],pf+'label');continue;}
668 if(Math.abs(ar[i])==DECODE){t(ar[i],pf+'decode');continue;}
669 if(ar[i]==DONOTHING){continue;}
670 i=OLparseCmdLine(pf,i,ar);}}
671 if((OLfunctionPI)&&OLudf&&o3_function)o3_text=o3_function();
672 if(pf=='o3_')OLfontSize();
673 }
674 function OLpar(a,v){eval(v+'='+a);}
675 function OLparQuo(a,v){eval(v+"='"+OLescSglQt(a)+"'");}
676 function OLescSglQt(s){return s.toString().replace(/'/g,"\\'");}
677 function OLtoggle(a,v){eval(v+'=('+v+'==0&&'+a+'>=0)?1:0');}
678 function OLhasDims(s){return /[%\-a-z]+$/.test(s);}
679 function OLfontSize(){
680 var i;if(OLhasDims(o3_textsize)){if(OLns4)o3_textsize="2";}else
681 if(!OLns4){i=parseInt(o3_textsize);o3_textsize=(i>0&&i<8)?OLpct[i]:OLpct[0];}
682 if(OLhasDims(o3_captionsize)){if(OLns4)o3_captionsize="2";}else
683 if(!OLns4){i=parseInt(o3_captionsize);o3_captionsize=(i>0&&i<8)?OLpct[i]:OLpct[0];}
684 if(OLhasDims(o3_closesize)){if(OLns4)o3_closesize="2";}else
685 if(!OLns4){i=parseInt(o3_closesize);o3_closesize=(i>0&&i<8)?OLpct[i]:OLpct[0];}
686 if(OLprintPI)OLprintDims();
687 }
688 function OLdecode(){
689 var re=/%[0-9A-Fa-f]{2,}/,t=o3_text,c=o3_cap,u=unescape,d=!OLns4&&(!OLgek||OLgek>=20020826)
690 &&typeof decodeURIComponent?decodeURIComponent:u;if(typeof(window.TypeError)=='function'){
691 if(re.test(t)){eval(new Array('try{','o3_text=d(t);','}catch(e){','o3_text=u(t);',
692 '}').join('\n'))};if(c&&re.test(c)){eval(new Array('try{','o3_cap=d(c);','}catch(e){',
693 'o3_cap=u(c);','}').join('\n'))}}else{if(re.test(t))o3_text=u(t);if(c&&re.test(c))o3_cap=u(c);}
694 }
695
696 /*
697  LAYER FUNCTIONS
698 */
699 // Writes to layer
700 function OLlayerWrite(t){
701 t+="\n";
702 if(OLns4){over.document.write(t);over.document.close();
703 }else if(typeof over.innerHTML!='undefined'){if(OLieM)over.innerHTML='';over.innerHTML=t;
704 }else{range=o3_frame.document.createRange();range.setStartAfter(over);
705 domfrag=range.createContextualFragment(t);
706 while(over.hasChildNodes()){over.removeChild(over.lastChild);}
707 over.appendChild(domfrag);}
708 if(OLprintPI)over.print=o3_print?t:null;
709 }
710
711 // Makes object visible
712 function OLshowObject(o){
713 OLshowid=0;o=(OLns4)?o:o.style;
714 if(((OLfilterPI)&&!OLchkFilter(o))||!OLfilterPI)o.visibility="visible";
715 if(OLshadowPI)OLshowShadow();if(OLiframePI)OLshowIfs();if(OLhidePI)OLhideUtil(1,1,0);
716 }
717
718 // Hides object
719 function OLhideObject(o){
720 if(OLshowid>0){clearTimeout(OLshowid);OLshowid=0;}
721 if(OLtimerid>0)clearTimeout(OLtimerid);if(OLdelayid>0)clearTimeout(OLdelayid);
722 OLtimerid=0;OLdelayid=0;self.status="";o3_label=ol_label;
723 if(o3_frame!=self)o=OLgetRefById();
724 if(o){if(o.onmouseover)o.onmouseover=null;
725 if(OLscrollPI&&o==over)OLclearScroll();
726 if(OLdraggablePI)OLclearDrag();
727 if(OLfilterPI)OLcleanupFilter(o);if(OLshadowPI)OLhideShadow();
728 var os=(OLns4)?o:o.style;os.visibility="hidden";
729 if(OLhidePI&&o==over)OLhideUtil(0,0,1);if(OLiframePI)OLhideIfs(o);}
730 }
731
732 // Moves layer
733 function OLrepositionTo(o,xL,yL){
734         o=(OLns4)?o:o.style;
735         if(o.setAttribute) {
736                 o.setAttribute('left', OLns4?xL:xL+'px');
737                 o.setAttribute('top', OLns4?yL:yL+'px');
738         } else {
739                 o.left=(OLns4?xL:xL+'px');
740                 o.top=(OLns4?yL:yL+'px');
741         }
742 }
743
744 // Handle NOCLOSE-MOUSEOFF
745 function OLoptMOUSEOFF(c){
746 if(!c)o3_close="";
747 over.onmouseover=function(){OLhover=1;if(OLtimerid>0){clearTimeout(OLtimerid);OLtimerid=0;}}
748 }
749 function OLcursorOff(){
750 var o=(OLns4?over:over.style),pHt=OLns4?over.clip.height:over.offsetHeight,
751 left=parseInt(o.left),top=parseInt(o.top),
752 right=left+o3_width,bottom=top+((OLbubblePI&&o3_bubble)?OLbubbleHt:pHt);
753 if(OLx<left||OLx>right||OLy<top||OLy>bottom)return true;
754 return false;
755 }
756
757 /*
758  REGISTRATION
759 */
760 function OLsetRunTimeVar(){
761 if(OLrunTime.length)for(var k=0;k<OLrunTime.length;k++)OLrunTime[k]();
762 }
763 function OLparseCmdLine(pf,i,ar){
764 if(OLcmdLine.length){for(var k=0;k<OLcmdLine.length;k++){
765 var j=OLcmdLine[k](pf,i,ar);if(j>-1){i=j;break;}}}
766 return i;
767 }
768 function OLregCmds(c){
769 if(typeof c!='string')return;
770 var pM=c.split(',');pMtr=pMtr.concat(pM);
771 for(var i=0;i<pM.length;i++)eval(pM[i].toUpperCase()+'='+pmCnt++);
772 }
773 function OLregRunTimeFunc(f){
774 if(typeof f=='object')OLrunTime=OLrunTime.concat(f);
775 else OLrunTime[OLrunTime.length++]=f;
776 }
777 function OLregCmdLineFunc(f){
778 if(typeof f=='object')OLcmdLine=OLcmdLine.concat(f);
779 else OLcmdLine[OLcmdLine.length++]=f;
780 }
781
782 OLloaded=1;