mime-version: 1.0
date: Wed, 3 Apr 2013 14:54:53 +0100
x-mimeole: Produced By Microsoft MimeOLE V6.1.7601.17609
from: "Saved by Windows Internet Explorer 8"
subject: James Hyde
content-type: multipart/related;
	type="multipart/alternative";
	boundary="----=_NextPart_000_0000_01CE307B.330E2A00"






This is a multi-part message in MIME format.

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: image/png
content-transfer-encoding: base64
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/bookmark_home.png

iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJ
bWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdp
bj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6
eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEz
NDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJo
dHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlw
dGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAv
IiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RS
ZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpD
cmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNl
SUQ9InhtcC5paWQ6MDVDNTYwRDI2QjIwMTFERkFEODFGQTVEMjVBNjQzOUUiIHhtcE1NOkRvY3Vt
ZW50SUQ9InhtcC5kaWQ6MDVDNTYwRDM2QjIwMTFERkFEODFGQTVEMjVBNjQzOUUiPiA8eG1wTU06
RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowNUM1NjBEMDZCMjAxMURGQUQ4
MUZBNUQyNUE2NDM5RSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowNUM1NjBEMTZCMjAxMURG
QUQ4MUZBNUQyNUE2NDM5RSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1w
bWV0YT4gPD94cGFja2V0IGVuZD0iciI/PlZkwlcAAAJwSURBVHjajFNLaFNRED3v5iVp82IrKVUa
W6Gf0A9BW7GILkSKBQs2gp9uXPjLSroQtIgiIpKq0IIIXbhy5a5+QEFBXBXBDyriTooRrKG1TfN7
ycvL713vXJuQYFEPDHfezJyZeXPnAmvgnNeIgHdmr4+TkL4WZheioAoM60BRFCJHAtvtfHSbnZJE
vK1bJ4LB4KzL5QriH5CVv571l0K+Bh7qauAfj7cVyGbkCtzv94eqO1XXIUf2d9vw4OUC6z1/Qxqf
TV9WR/a4cW+4D6vpEvtr5c+ne6yp7ib+8O4MLxaLUkif7PTwdycHa2ayNqsq8pl+fsvnkYR8Pl8j
ZLvW7uFzYwM1SZRy27vbNTx/9Q29E5N4pN5GLLmCQwfi6GkC7jz2oGC4cUq7hPc3r2BooANfYjrG
5+a3gLJ9OLHDut7RKKvEEjnuPabyznEb/xS3eFb0ufkI413jdh5bzciYC20b+YvAriJx1R8LUcwu
RJXBi5PYGTiKBo2h0etAarGI78txeJJxtPmasRiOw+22o294RP7zm6mrNr1kpeQgGGMTuq6bqVSK
FwoFnkgk/pgB2cq+RDKZJQ4lUu/7m8vLw8WSQCQCnecO70M4vASbw4bWlkbMPHmNTCYDTdNgGEZl
/Gza3lpZZSJTQMYwsPRzBQdbltFdjEBcZYVMZ/X1serFdjgcMqDOWScdeb2Enk1OeVVlMnVX8xbC
4fBvhTGFKtXX1yOXM+FSVQz1e9C1wQlVZZUOstmsjK0kEIPTSBGOnGVZpgg0RYsm2d7Om3pWc0ZJ
tyxuptNp6ROg2LwwuyjTgJBR+sD/g3hJIU9/CTAA/Q57kSvgyI8AAAAASUVORK5CYII=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: base64
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/workflow/images/dashboard.png?r=7.0.1

iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJ
bWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdp
bj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6
eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEz
NDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJo
dHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlw
dGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAv
IiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RS
ZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpD
cmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNl
SUQ9InhtcC5paWQ6RjJENThDMUM1NEVEMTFERjk0OUFFNUU4QUU4NkI1MDIiIHhtcE1NOkRvY3Vt
ZW50SUQ9InhtcC5kaWQ6RjJENThDMUQ1NEVEMTFERjk0OUFFNUU4QUU4NkI1MDIiPiA8eG1wTU06
RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDpGMkQ1OEMxQTU0RUQxMURGOTQ5
QUU1RThBRTg2QjUwMiIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDpGMkQ1OEMxQjU0RUQxMURG
OTQ5QUU1RThBRTg2QjUwMiIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1w
bWV0YT4gPD94cGFja2V0IGVuZD0iciI/PgKCztwAAAIzSURBVHjanFJLaBNRFD0zqQtjxFBMFBWt
H1BSUEigfkAoNCoGQ9CKG5ddCZVWqB8QxIUfKmoRqiu1gS6kSBcq/hqqFdwYMUjVqMWKghabNGnM
pJPpJPOu770arU1b1AuXO3PnnnPPeW8UIsLUqFq5eldod/0VBVDFe9GyrK4bnXuTicTzqbMVEuCt
beAlJJ4XOedhRyAYPNTchMXuhXJo8PMXZLVcdP0W/52sUSxhb32K9V1ThIJl1Rt7jnc/2gYQBsKt
eP2yH4zxQUWRk8SISyEoC1zYc+qy7J2ur4t8jUe3V5ToYkO6rLpvH9w8JZCnMkkuybl8uQVJEHmD
v4vU9AQvztZOOy4siswbBnekQFVUWMzC2tsT39XZdgmgAD15FoMvsB/97wZhEePn8/vm1NnAjDFo
YzoOn2xF0L8VNRs84Dcq+zMSjH7X8OrtexDfbLPZcOZiO0ZHhnGssQG6kQfjxELFjATDySTqAiFc
DXciPvAB59vacKLlIBz2uXw7l8+TJimQUpd6anp45X0mCl241E52p4vWrKsm/84gWbyf1TRKZTI0
kk5TIpUigfnjFqTnn4fW3HgAD+7dReThfXTf7MKYrqPAvXdwVbmcDppjL7cgZJWk8Y0Id1xH7+M+
rKhaDrNQgFUsSvDRliZs3uQrJygdzrgxDtM04ZjvgNfrnfAsf0kFWRPofRqFu9L5i0D8qb7KJauO
8OrBv0U8PfTxnCAI2Z1uF/4j9Ezi2w8BBgDknBt/wRtgBgAAAABJRU5ErkJggg==

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: image/png
content-transfer-encoding: base64
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/icons/bookmarks_16.png

iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJ
bWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdp
bj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6
eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEz
NDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJo
dHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlw
dGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAv
IiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RS
ZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpD
cmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNl
SUQ9InhtcC5paWQ6MEEyQTkzMjQ2MDEzMTFERjgxOURENzI3MERDNDU0MTkiIHhtcE1NOkRvY3Vt
ZW50SUQ9InhtcC5kaWQ6MEEyQTkzMjU2MDEzMTFERjgxOURENzI3MERDNDU0MTkiPiA8eG1wTU06
RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDowQTJBOTMyMjYwMTMxMURGODE5
REQ3MjcwREM0NTQxOSIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDowQTJBOTMyMzYwMTMxMURG
ODE5REQ3MjcwREM0NTQxOSIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1w
bWV0YT4gPD94cGFja2V0IGVuZD0iciI/Pg0PvYQAAAJsSURBVHjalFFLTBNRFD3TTn80xQ8hjQmJ
HwSroKIJMZJgBY0koolG8bMxQV26MppoIgtl60YTNS5YiHHLAvxsNBpNQAHRRVuEVj6plJZKLUyH
zgzTed5XW0OwGL3JyZ03991zzzsXjDEUwvkaWAkdK9XzMGHlOFfjrT97YZfQ9Jc7hQmoyUrpcsOp
wxbK1/6bgOKM90Tzxuq67WJ13c49RNjwzwR0eROfuv/kIQsMCd6mdVxFO/13FyIQyKg2yhsIFYRt
7vVl9kaSfvB0vZUl+2DEP6PnUUB79TqpLahI0Z0gwU+YJNznbnc9uNGqBAbf6YuayrJhDDAjcZUZ
40eYPljFxrpa2ETgPUtMhYyBZ536rQNFaeq7w7fAFXDDOmubG4+1tl2y2awZsORHCCkaMBdBpL8f
0ZE0BAWYiYG9HYEaBe51fGJX+BPMQ9Ms0/3wZnckOF4uz/3w7KhWRMyPQpBjiPp8kBMLcBQx6Brw
ZhhqWMVtar7+2wMuI2eemVJ/+929NaU2yTTtC0KVNLjsDKnvgG8YmR4/XlDz0YJboEKGUiw6HGWB
518wG1FhFDOoDmCBKpIMg+rTy7cgLjtXzQ5OmGSdwVEBJs0g414F0VgEiuzZYZ4/1rjkCW6bGaHN
Ljg1F7RgGCQcfYR9nnKsXqvA0juFGJ3Lcmp/KRAEgasQW7Zit9MCsz+JeCqOJ71hPP42D3lLCUrS
Oi46RBy3CSielFBJPWPUw0kMbpydo7IEtYqA5MtxtH+Ywtd5FaX03z2bhsM3g6GUhqdrnBAVHeFQ
AhGqcelMyBmZzxzmJd/5yE5bko0cAX4KMADvxTbtsH68UAAAAABJRU5ErkJggg==

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/css/com/hyperwave/dialogs/dialog.css?cachekeY=515488b2-en

.hw_dialog_container {
	FONT: 12px/140% Arial, Helvetica, Verdana, sans-serif; COLOR: #001628
}
.hw_dialog_container * {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; PADDING-TOP: 0px
}
.hw_dialog_layout_top {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_top > DIV {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_bottom {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_bottom > DIV {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_main {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_main > DIV {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_layout_content {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_container {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_dialog_container {
	POSITION: static
}
.hw_dialog_layout_top {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_top > DIV {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_bottom {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_bottom > DIV {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_main {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_main > DIV {
	BACKGROUND: url(../../../../images/bg_popup-2.png) no-repeat
}
.hw_dialog_layout_top {
	MARGIN: -14px 0px 0px -14px; BACKGROUND-POSITION: left top; HEIGHT: =
14px
}
.hw_dialog_layout_top > DIV {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 14px; PADDING-RIGHT: 14px; =
BACKGROUND-POSITION: right top; PADDING-TOP: 0px
}
.hw_dialog_layout_top {
	MARGIN-TOP: -42px; HEIGHT: 42px
}
.hw_dialog_layout_top > DIV {
	HEIGHT: 42px
}
DIV[name=3DIframeDialog] .hw_dialog_layout_top {
	MARGIN-TOP: -14px; HEIGHT: 14px
}
DIV[name=3DIframeDialog].hw_dialog_layout_top > DIV {
	HEIGHT: 14px
}
.hw_dialog_layout_top H1 {
	COLOR: #fff; FONT-SIZE: 16px; PADDING-TOP: 14px
}
DIV[name=3DIframePopupDialog] {
	MARGIN-TOP: 50px
}
DIV[name=3DIframePopupDialog] .hw_dialog_container {
	TOP: 50px
}
DIV[name=3DIframePopupDialog] .hw_dialog_layout_top {
	BACKGROUND-IMAGE: url(../../../../images/bg_popup_alternate.png)
}
DIV[name=3DIframePopupDialog] .hw_dialog_layout_top {
	MARGIN-TOP: -55px; HEIGHT: 55px
}
DIV[name=3DIframePopupDialog] .hw_dialog_layout_top > DIV {
	MARGIN-TOP: 13px
}
.hw_dialog_layout_main {
	MARGIN: 0px -14px; BACKGROUND-POSITION: left -10px
}
.hw_dialog_layout_main > DIV {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 14px; PADDING-RIGHT: 14px; =
BACKGROUND-POSITION: right -10px; PADDING-TOP: 0px
}
.hw_dialog_layout_bottom {
	MARGIN: 0px 0px 0px -14px; BACKGROUND-POSITION: left bottom; HEIGHT: =
14px; TOP: 100%
}
.hw_dialog_layout_bottom > DIV {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 14px; PADDING-RIGHT: 14px; =
BACKGROUND-POSITION: right bottom; PADDING-TOP: 0px
}
[name=3DButtons].hw_dialog_layout_bottom {
	HEIGHT: 50px
}
[name=3DButtons].hw_dialog_layout_bottom > DIV {
	HEIGHT: 40px; PADDING-TOP: 10px
}
.hw_dialog_layout_content {
	POSITION: relative; BACKGROUND: =
url(../../../../images/bg_popup_content.png); OVERFLOW: auto; =
-moz-border-radius: 3px; -webkit-border-radius: 3px
}
DIV[name=3DMessage] .hw_dialog_layout_content {
	BACKGROUND-IMAGE: url(../../../../images/bg_popup_content_dark.png); =
COLOR: #fff
}
DIV[name=3DConfirm] .hw_dialog_layout_content {
	BACKGROUND-IMAGE: url(../../../../images/bg_popup_content_dark.png); =
COLOR: #fff
}
DIV[name=3DMessage] {
	MAX-HEIGHT: 200px
}
DIV[name=3DMessage] * {
	MAX-HEIGHT: 200px
}
DIV[name=3DPrompt] {
	MAX-HEIGHT: 200px
}
DIV[name=3DPrompt] * {
	MAX-HEIGHT: 200px
}
DIV[name=3DConfirm] {
	MAX-HEIGHT: 200px
}
DIV[name=3DConfirm] * {
	MAX-HEIGHT: 200px
}
.hw_dialog_layout_content IFRAME {
	WIDTH: 100%; BACKGROUND: white; HEIGHT: 100%
}
.hw_dialog_content {
	PADDING-BOTTOM: 12px; PADDING-LEFT: 12px; PADDING-RIGHT: 12px; =
PADDING-TOP: 12px
}
.hw_dialog_message {
	BORDER-BOTTOM: #ffe05e 1px solid; PADDING-BOTTOM: 0px; LIST-STYLE-TYPE: =
none; MIN-HEIGHT: 48px; PADDING-LEFT: 70px; PADDING-RIGHT: 12px; =
BACKGROUND: no-repeat 11px 12px; LIST-STYLE-IMAGE: none; PADDING-TOP: =
12px
}
.hw_dialog_message LI {
	PADDING-BOTTOM: 0.7em
}
.hw_dialog_message LI:first-line {
	FONT-WEIGHT: bold
}
DIV[name=3DINFO] .hw_dialog_message {
	BACKGROUND-IMAGE: url(../../../../images/icon_info_large.png)
}
DIV[name=3DWARNING] .hw_dialog_message {
	BACKGROUND-IMAGE: url(../../../../images/icon_warning.png)
}
DIV[name=3DERROR] .hw_dialog_message {
	BACKGROUND-IMAGE: url(../../../../images/icon_error.png)
}
DIV[name=3DPrompt] .hw_dialog_content:first-line {
	FONT-WEIGHT: bold
}
DIV[name=3DConfirm] .hw_dialog_content:first-line {
	FONT-WEIGHT: bold
}
.hw_dialog_prompt {
	MARGIN: 1em 0px; WIDTH: 98%; CLEAR: both
}
DIV[name=3DMessage] .hw_dialog_message {
	BORDER-BOTTOM: medium none
}
DIV[name=3DConfirm] .hw_dialog_content {
	PADDING-BOTTOM: 12px; MIN-HEIGHT: 48px; PADDING-LEFT: 70px; =
PADDING-RIGHT: 12px; BACKGROUND: =
url(../../../../images/icon_question.png) no-repeat 11px 12px; =
PADDING-TOP: 12px
}
.hw_dialog_button {
	LINE-HEIGHT: 23px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; BACKGROUND: no-repeat 0px 0px; HEIGHT: 23px; =
COLOR: #fff; CURSOR: pointer; FONT-WEIGHT: bold; TEXT-DECORATION: none
}
.hw_dialog_button SPAN {
	LINE-HEIGHT: 23px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; BACKGROUND: no-repeat 0px 0px; HEIGHT: 23px; =
COLOR: #fff; CURSOR: pointer; FONT-WEIGHT: bold; TEXT-DECORATION: none
}
.hw_dialog_button {
	MIN-WIDTH: 60px; PADDING-LEFT: 10px; FLOAT: left; MARGIN-RIGHT: 15px
}
.hw_dialog_button SPAN {
	POSITION: relative; MIN-WIDTH: 6em; TEXT-ALIGN: center; PADDING-RIGHT: =
5px; DISPLAY: block; BACKGROUND-POSITION: 100% 0px; FLOAT: none; =
MARGIN-LEFT: -7px; RIGHT: -4px
}
[name=3DPRIMARY].hw_dialog_button {
	BACKGROUND-IMAGE: url(../../../../images/bg_button.png)
}
[name=3DPRIMARY].hw_dialog_button SPAN {
	BACKGROUND-IMAGE: url(../../../../images/bg_button.png)
}
[name=3DSECONDARY].hw_dialog_button {
	BACKGROUND-IMAGE: url(../../../../images/bg_button_secondary.png)
}
[name=3DSECONDARY].hw_dialog_button SPAN {
	BACKGROUND-IMAGE: url(../../../../images/bg_button_secondary.png)
}
.hw_dialog_button:hover {
	BACKGROUND-POSITION: 0px -50px
}
.hw_dialog_button:hover SPAN {
	BACKGROUND-POSITION: 100% -50px
}
.hw_dialog_button:active {
	BACKGROUND-POSITION: 0px -100px
}
.hw_dialog_button:active SPAN {
	BACKGROUND-POSITION: 100% -100px
}
* + HTML .hw_dialog_button:active {
	BACKGROUND-POSITION: 0px 0px
}
* + HTML .hw_dialog_button:active SPAN {
	BACKGROUND-POSITION: 100% 0px
}
DIV[name=3DPopupDialog] {
	BORDER-BOTTOM: #94b9dc 1px solid; FILTER: =
progid:DXImageTransform.Microsoft.Shadow(color=3D#bed6ed,direction=3D120,=
 strength=3D3); BORDER-LEFT: #94b9dc 1px solid; BACKGROUND: #fff; =
BORDER-TOP: #94b9dc 1px solid; BORDER-RIGHT: #94b9dc 1px solid; =
-moz-border-radius: 3px; -webkit-border-radius: 3px; border-radius: 3px; =
-moz-box-shadow: 0 1px 15px #407397; -webkit-box-shadow: 0 1px 15px =
#407397
}
DIV[name=3DPopupDialog] .hw_dialog_layout_top {
	DISPLAY: none
}
DIV[name=3DPopupDialog] .hw_dialog_layout_main {
	DISPLAY: none
}
DIV[name=3DPopupDialog] .hw_dialog_layout_bottom {
	DISPLAY: none
}
DIV[name=3DPopupDialog] .hw_dialog_layout_content {
	POSITION: static; PADDING-BOTTOM: 10px; PADDING-LEFT: 10px; WIDTH: =
auto; PADDING-RIGHT: 10px; BACKGROUND: none transparent scroll repeat 0% =
0%; HEIGHT: auto; PADDING-TOP: 10px
}
DIV[name=3DPopupDialog] .hw_dialog_layout_content A {
	COLOR: #00aeef; TEXT-DECORATION: underline
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/frameset/htmlres/buildframes.css?cachekeY=515488b2-en

HTML {
	BORDER-BOTTOM: 0px; BORDER-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; =
PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; HEIGHT: 100%; =
OVERFLOW: hidden; BORDER-TOP: 0px; BORDER-RIGHT: 0px; PADDING-TOP: 0px
}
BODY {
	BORDER-BOTTOM: 0px; BORDER-LEFT: 0px; PADDING-BOTTOM: 0px; MARGIN: 0px; =
PADDING-LEFT: 0px; WIDTH: 100%; PADDING-RIGHT: 0px; HEIGHT: 100%; =
OVERFLOW: hidden; BORDER-TOP: 0px; BORDER-RIGHT: 0px; PADDING-TOP: 0px
}
IFRAME {
	WIDTH: 100%; HEIGHT: 100%
}
#hiddenframeContainer {
	DISPLAY: none
}
#ecsframeContainer {
	DISPLAY: none
}
#userblockContainer {
=09
}
#treeviewContainer {
	POSITION: relative; FLOAT: left
}
#treeviewContainer DIV {
	POSITION: absolute; WIDTH: 18px; HEIGHT: 35px; TOP: 9px; CURSOR: =
pointer
}
.notreetoggle #treeviewContainer DIV {
	DISPLAY: none
}
.treeviewOn #treeviewContainer DIV {
	BACKGROUND-IMAGE: =
url(../../../uistyle/hwdefault/images/bg_treeview_collapse.png)
}
.treeviewOff #treeviewContainer DIV {
	BACKGROUND-IMAGE: =
url(../../../uistyle/hwdefault/images/bg_treeview_expand.png)
}
.treeviewOff #treeviewContainer {
	WIDTH: 0px
}
.treeviewOff #mainframeContainer {
	MARGIN-LEFT: 0px
}
.treeviewOff #headerContainer {
	MARGIN-LEFT: 0px
}
.treeviewOff #footerContainer {
	MARGIN-LEFT: 0px
}
.treeviewOff #breadcrumbingContainer {
	MARGIN-LEFT: 0px
}
.treeviewOn #treeviewContainer {
	WIDTH: 250px
}
.treeviewOn #menuContainer {
	MARGIN-LEFT: 265px
}
.treeviewOn #footerContainer {
	MARGIN-LEFT: 265px
}
.breadcrumbingOn #breadcrumbingContainer {
	BORDER-BOTTOM: #6592c9 1px solid; BACKGROUND-COLOR: #77a5cf; =
MARGIN-TOP: -3px; WIDTH: auto; DISPLAY: block; HEIGHT: auto
}
.breadcrumbingOff #breadcrumbingContainer {
	WIDTH: 0px; DISPLAY: none; HEIGHT: 0px
}
#menuContainer {
	MARGIN-LEFT: 15px; OVERFLOW: hidden
}
#menuContainer #hwiconbarContainerOpener {
	WIDTH: 1px; FLOAT: left
}
#menuContainer #opener {
	WIDTH: 1px; FLOAT: right
}
#menuContainer #mainFilter {
	FLOAT: right
}
.isViewMode .displayInEditMode {
	DISPLAY: none
}
.isEditMode .displayInViewMode {
	DISPLAY: none
}
#footerContainer {
	DISPLAY: none; HEIGHT: 0px
}
#mainframeContainer .frame {
	MARGIN: 0px
}
#mainframeHeader {
	OVERFLOW: hidden
}
#mainframeFooter {
	OVERFLOW: hidden
}
#headerContainer {
	OVERFLOW: hidden
}
#footerContainer {
	OVERFLOW: hidden
}
#mainframeHeaderLeft {
	FLOAT: left
}
#mainframeFooterLeft {
	FLOAT: left
}
#headerContainerLeft {
	FLOAT: left
}
#footerContainerLeft {
	FLOAT: left
}
#mainframeHeaderRight {
	FLOAT: right
}
#mainframeFooterRight {
	FLOAT: right
}
#headerContainerRight {
	FLOAT: right
}
#footerContainerRight {
	FLOAT: right
}
#mainframeHeaderTop {
	FLOAT: none; CLEAR: both
}
#mainframeHeaderBottom {
	FLOAT: none; CLEAR: both
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/css/com/hyperwave/framework/framework.css?cachekeY=515488b2-en

.hw_framework_outer_div {
	POSITION: absolute; FILTER: alpha(opacity=3D75); BACKGROUND-COLOR: =
white; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; LEFT: 0px; opacity: 0.75
}
.hw_framework_inner_div {
	POSITION: absolute; OVERFLOW: visible
}
.hw_framework_clicklayer {
	BACKGROUND-IMAGE: url(empty.gif); POSITION: absolute; WIDTH: 100%; =
HEIGHT: 100%; TOP: 0px; LEFT: 0px
}
.hw_framework_interfacelock {
	POSITION: absolute; WIDTH: 100%; HEIGHT: 100%; TOP: 0px; CURSOR: wait; =
LEFT: 0px
}
.disabled.hw_framework_interfacelock {
	FILTER: alpha(opacity=3D70); BACKGROUND: #fff; CURSOR: default; =
opacity: 0.7
}
.hw_framework_interfacelock DIV {
	BACKGROUND: url(../../../../images/bg_progress_large.png) no-repeat 50% =
49%; HEIGHT: 100%
}
.hw_framework_interfacelock DIV DIV {
	BACKGROUND-IMAGE: url(../../../../images/progress_large.gif)
}
.hw_framework_infoarea {
	POSITION: absolute; BOTTOM: 10px; RIGHT: 50px
}
.hw_framework_infoarea > DIV {
	FLOAT: right; CLEAR: both
}
.hw_framework_infoarea > DIV > DIV {
	LINE-HEIGHT: 70px; BACKGROUND: =
url(../../../../images/bg_progress_small.png) no-repeat 0px 0px; FLOAT: =
left; HEIGHT: 73px
}
.hw_framework_infoarea > DIV > DIV > DIV {
	LINE-HEIGHT: 70px; BACKGROUND: =
url(../../../../images/bg_progress_small.png) no-repeat 0px 0px; FLOAT: =
left; HEIGHT: 73px
}
.hw_framework_infoarea > DIV > DIV > DIV {
	POSITION: relative; PADDING-RIGHT: 27px; BACKGROUND-POSITION: 100% 0px; =
RIGHT: -27px
}
.hw_framework_infoarea > DIV > DIV > DIV > SPAN {
	PADDING-BOTTOM: 3px; PADDING-LEFT: 8px; PADDING-RIGHT: 35px; =
WHITE-SPACE: nowrap; BACKGROUND: =
url(../../../../images/icon_check_small.png) no-repeat 99% 0px; COLOR: =
#7f7f7f; FONT-SIZE: 13px; PADDING-TOP: 3px
}
.hw_framework_infoarea DIV[name=3Dblocking] SPAN {
	BACKGROUND-IMAGE: url(../../../../images/progress_small.gif)
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/css/displayareafooter.css?cachekeY=515488b2-en

.DisplayAreaFooter {
	TEXT-ALIGN: left; PADDING-BOTTOM: 2px; PADDING-LEFT: 0px; WIDTH: 100%; =
PADDING-RIGHT: 0px; FONT: 11.2px/15px "Lucida Grande", Tahoma, =
Helvetica, Arial, Verdana, sans-serif; WHITE-SPACE: nowrap; BACKGROUND: =
url(../images/bg_displayareafooter.gif) #c6d8f3 repeat-x 0px 0px; =
LETTER-SPACING: normal; COLOR: #001d4d; BORDER-TOP: #98b7e7 1px solid; =
WORD-SPACING: normal; PADDING-TOP: 6px
}
.DisplayAreaFooter SPAN {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 10px; PADDING-RIGHT: 10px; =
PADDING-TOP: 0px
}
.DisplayAreaFooter A {
	COLOR: #001d4d; TEXT-DECORATION: underline
}
.DisplayAreaFooter A:hover {
	COLOR: #f60; TEXT-DECORATION: underline
}
.Sequence {
	TEXT-ALIGN: right; PADDING-BOTTOM: 3px; PADDING-LEFT: 10px; =
PADDING-RIGHT: 10px; WHITE-SPACE: nowrap; COLOR: #000; FONT-WEIGHT: =
normal; PADDING-TOP: 3px
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: text/css;
	charset="iso-8859-1"
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/Documents/Users/hw_master.css

* {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; TEXT-DECORATION: none; PADDING-TOP: 0px
}
HTML {
	HEIGHT: 100%; OVERFLOW: auto
}
BODY {
	MARGIN: 0px; FONT: 13px/150% Helvetica, Arial, Verdana, sans-serif; =
BACKGROUND: #bed6ed; HEIGHT: 100%; COLOR: #001322; CURSOR: default
}
BODY.ekslisting {
	BACKGROUND-COLOR: transparent
}
BODY.eksdcpartialview {
	BACKGROUND-COLOR: transparent
}
BODY.eksopendocument {
	BACKGROUND-COLOR: transparent
}
BODY.errorpage {
	BACKGROUND-COLOR: transparent
}
BODY.eksmulticluster {
	BACKGROUND-COLOR: transparent
}
BODY.ekslisting FORM[name=3Dbodyform] {
	HEIGHT: 100%
}
BODY.eksdcpartialview DIV {
	PADDING-BOTTOM: 1em; PADDING-LEFT: 1em; PADDING-RIGHT: 1em; =
PADDING-TOP: 1em
}
BODY.eksdcpartialview H1 {
	PADDING-BOTTOM: 1em; PADDING-LEFT: 1em; PADDING-RIGHT: 1em; =
PADDING-TOP: 1em
}
A {
	COLOR: #0093d8
}
TABLE {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-COLLAPSE: =
collapse; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
TR {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-COLLAPSE: =
collapse; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
TD {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-COLLAPSE: =
collapse; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
IMG {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-COLLAPSE: =
collapse; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
INPUT[type=3D'text'] {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 2px; PADDING-LEFT: 2px; PADDING-RIGHT: 2px; FONT-FAMILY: =
Helvetica, Arial, Verdana, sans-serif; BACKGROUND: #fff; FONT-SIZE: =
13px; BORDER-TOP: #708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; =
PADDING-TOP: 2px
}
INPUT[type=3D'password'] {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 2px; PADDING-LEFT: 2px; PADDING-RIGHT: 2px; FONT-FAMILY: =
Helvetica, Arial, Verdana, sans-serif; BACKGROUND: #fff; FONT-SIZE: =
13px; BORDER-TOP: #708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; =
PADDING-TOP: 2px
}
INPUT[type=3D'file'] {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 2px; PADDING-LEFT: 2px; PADDING-RIGHT: 2px; FONT-FAMILY: =
Helvetica, Arial, Verdana, sans-serif; BACKGROUND: #fff; FONT-SIZE: =
13px; BORDER-TOP: #708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; =
PADDING-TOP: 2px
}
SELECT[multiple] {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 2px; PADDING-LEFT: 2px; PADDING-RIGHT: 2px; FONT-FAMILY: =
Helvetica, Arial, Verdana, sans-serif; BACKGROUND: #fff; FONT-SIZE: =
13px; BORDER-TOP: #708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; =
PADDING-TOP: 2px
}
TEXTAREA {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 2px; PADDING-LEFT: 2px; PADDING-RIGHT: 2px; FONT-FAMILY: =
Helvetica, Arial, Verdana, sans-serif; BACKGROUND: #fff; FONT-SIZE: =
13px; BORDER-TOP: #708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; =
PADDING-TOP: 2px
}
SELECT {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; =
PADDING-TOP: 0px
}
SELECT[multiple] OPTION {
	PADDING-BOTTOM: 3px; PADDING-LEFT: 3px; PADDING-RIGHT: 3px; =
PADDING-TOP: 3px
}
TEXTAREA {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; BORDER-TOP: =
#708bb3 1px solid; BORDER-RIGHT: #708bb3 1px solid; PADDING-TOP: 5px
}
#header {
	POSITION: relative; BACKGROUND: url(../images/bg_header.gif) #001322 =
repeat-x 0px 0px; COLOR: #fff
}
#header > DIV:first-child {
	MIN-HEIGHT: 34px
}
* + HTML #header {
	POSITION: static
}
#header A {
	COLOR: #fff; TEXT-DECORATION: none
}
#header H1 {
	POSITION: absolute; LINE-HEIGHT: 100px; WIDTH: 185px; BACKGROUND: =
url(../images/logo.png) no-repeat 0px -1px; HEIGHT: 25px; OVERFLOW: =
hidden; TOP: 4px; LEFT: 10px
}
#header .tools {
	POSITION: absolute; TOP: 0px; RIGHT: 7px
}
*:first-child + HTML #header .tools {
	RIGHT: 17px
}
#header .tools * {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
FLOAT: left
}
#header .username {
	MARGIN-TOP: 6px; MARGIN-RIGHT: 13px
}
#header .login.hw_button {
	MARGIN-TOP: 2px; MARGIN-RIGHT: 5px
}
#header .tools UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#header .tools UL LI {
	DISPLAY: inline
}
#header .tools UL LI {
	WIDTH: 24px; MARGIN-LEFT: 2px; OVERFLOW: hidden
}
#header .tools UL LI A {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 24px; PADDING-RIGHT: 0px; =
BACKGROUND: url(../images/icon_manage.png) no-repeat 0px 50%; =
PADDING-TOP: 5px
}
.isViewMode #header .tools UL LI.authoring A {
	BACKGROUND-IMAGE: url(../images/icon_edit_normal_g.png)
}
.isEditMode #header .tools UL LI.authoring A {
	BACKGROUND-IMAGE: url(../images/icon_edit_indent_g.png)
}
#header .tools UL LI.manage A {
	BACKGROUND-IMAGE: url(../images/icon_manage.png)
}
#header .tools UL LI.search A {
	BACKGROUND-IMAGE: url(../images/icon_search.png)
}
#search_container {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 18px; WIDTH: 214px; PADDING-RIGHT: =
22px; BACKGROUND: url(../images/bg_searchpopover.png) no-repeat 0px 0px; =
HEIGHT: 62px; PADDING-TOP: 30px
}
#search_container #searchstring {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: =
0px; LINE-HEIGHT: 20px; PADDING-LEFT: 22px; WIDTH: 195px; PADDING-RIGHT: =
0px; BACKGROUND: url(../images/bg_searchfield.png) no-repeat 0px 0px; =
HEIGHT: 21px; BORDER-TOP: medium none; BORDER-RIGHT: medium none; =
PADDING-TOP: 0px
}
#search_container .hw_button {
	DISPLAY: none
}
#search_container A {
	TEXT-ALIGN: right; DISPLAY: block; COLOR: #0072c6; FONT-SIZE: 11px; =
TEXT-DECORATION: underline; PADDING-TOP: 2px
}
#search_container A:hover {
	TEXT-ALIGN: right; DISPLAY: block; COLOR: #0072c6; FONT-SIZE: 11px; =
TEXT-DECORATION: underline; PADDING-TOP: 2px
}
#header .bookmarkbar {
	TEXT-ALIGN: center; PADDING-BOTTOM: 7px; LIST-STYLE-TYPE: none; =
PADDING-LEFT: 220px; PADDING-RIGHT: 220px; LIST-STYLE-IMAGE: none; =
PADDING-TOP: 7px
}
#header .bookmarkbar LI {
	DISPLAY: inline; WHITE-SPACE: nowrap
}
#header .bookmarkbar LI IMG {
	MARGIN-TOP: -3px; VERTICAL-ALIGN: middle; MARGIN-RIGHT: 3px
}
#header .bookmarkbar LI.separator {
	BACKGROUND: url(../images/vertical_separator.png) no-repeat 100% 50%
}
#header .bookmarkbar LI A {
	PADDING-BOTTOM: 10px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
PADDING-LEFT: 3px; OUTLINE-WIDTH: medium; PADDING-RIGHT: 7px; COLOR: =
#fff; PADDING-TOP: 10px
}
#header .bookmarkbar LI.myplaces {
	BACKGROUND: none transparent scroll repeat 0% 0%
}
#header .bookmarkbar LI.myplaces SPAN {
	PADDING-RIGHT: 14px; BACKGROUND: url(../images/context_arrow.png) =
no-repeat 100% 50%
}
#personalbookmarksmenu SPAN {
	PADDING-RIGHT: 14px; BACKGROUND: url(../images/arrow_expanded.png) =
no-repeat 100% -49px
}
#personalbookmarksmenu A {
	BACKGROUND: url(../images/vertical_separator2.png) no-repeat 0px 50%
}
#personalbookmarksmenu IMG {
	MARGIN-LEFT: 5px
}
.BookmarkAttrValueIndented {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 20px; PADDING-RIGHT: 5px; =
WHITE-SPACE: nowrap; PADDING-TOP: 0px
}
.BookmarkAttrValueIndented .hw_disabled {
	FILTER: alpha(opacity=3D50); opacity: 0.5
}
#MENU_CONTAINER_1 .hw_horizontal.hw_menu {
	PADDING-LEFT: 5px; PADDING-TOP: 5px
}
#MENU_CONTAINER_0 .hw_horizontal.hw_menu {
	MARGIN-LEFT: -10px; PADDING-TOP: 5px
}
.hw_menu {
	PADDING-BOTTOM: 0px; LIST-STYLE-TYPE: none; MARGIN: 0px; PADDING-LEFT: =
0px; PADDING-RIGHT: 0px; FLOAT: left; LIST-STYLE-IMAGE: none; =
PADDING-TOP: 0px
}
.hw_menu * {
	PADDING-BOTTOM: 0px; LIST-STYLE-TYPE: none; MARGIN: 0px; PADDING-LEFT: =
0px; PADDING-RIGHT: 0px; FLOAT: left; LIST-STYLE-IMAGE: none; =
PADDING-TOP: 0px
}
.hw_menu LI A {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
COLOR: #001322; TEXT-DECORATION: none
}
.hw_menu LI A SPAN {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 0px; PADDING-RIGHT: 8px; =
BACKGROUND-REPEAT: no-repeat; BACKGROUND-POSITION: 0px 2px; CURSOR: =
pointer; PADDING-TOP: 5px
}
.hw_menu LI.hw_disabled A SPAN {
	BACKGROUND-POSITION: 0px -48px; COLOR: #8195a5
}
.hw_menu LI.hw_disabled {
	CURSOR: default
}
.hw_menu LI.hw_disabled * {
	CURSOR: default
}
.hw_horizontal.hw_menu LI {
	MIN-HEIGHT: 29px; MARGIN-RIGHT: 5px
}
.hw_horizontal.hw_menu .hw_haschildren {
	MARGIN-RIGHT: 10px
}
.hw_horizontal.hw_menu .hw_haschildren A {
	PADDING-RIGHT: 7px; BACKGROUND: url(../images/arrow_expanded.png) =
no-repeat 100% 9px
}
.hw_horizontal.hw_menu .hw_separator {
	POSITION: relative; MARGIN: 0px 10px 0px 0px; BOTTOM: 0px; BACKGROUND: =
url(../images/vertical_separator.png) no-repeat 100% 50%
}
.hw_vertical.hw_menu {
	BORDER-BOTTOM: #94b9dc 1px solid; FILTER: =
progid:DXImageTransform.Microsoft.Shadow(color=3D#bed6ed,direction=3D120,=
 strength=3D3)\9; BORDER-LEFT: #94b9dc 1px solid; BACKGROUND: #fff; =
BORDER-TOP: #94b9dc 1px solid; BORDER-RIGHT: #94b9dc 1px solid; =
-moz-border-radius: 3px; -webkit-border-radius: 3px; border-radius: 3px; =
-moz-box-shadow: 0 1px 15px #407397; -webkit-box-shadow: 0 1px 15px =
#407397; box-shadow: 0 1px 15px #407397
}
.hw_vertical.hw_menu > LI:first-child {
	-moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; =
-webkit-border-top-left-radius: 3px; -webkit-border-top-right-radius: =
3px; border-top-left-radius: 3px; border-top-right-radius: 3px
}
.hw_vertical.hw_menu * {
	FLOAT: none
}
.hw_vertical.hw_menu LI {
	BACKGROUND: #fff
}
.hw_vertical.hw_menu LI.hw_disabled {
	BACKGROUND: #fff
}
.hw_vertical.hw_menu LI.hw_disabled:hover {
	BACKGROUND: #fff
}
.hw_vertical.hw_menu LI.hw_separator:hover {
	BACKGROUND: #fff
}
.hw_vertical.hw_menu LI SPAN {
	COLOR: #001322
}
.hw_vertical.hw_menu LI.hw_disabled SPAN {
	COLOR: #8195a5
}
.hw_vertical.hw_menu LI.hw_disabled:hover SPAN {
	COLOR: #8195a5
}
.hw_vertical.hw_menu LI.hw_separator {
	BORDER-BOTTOM: #bad7ed 1px solid; LINE-HEIGHT: 1px; HEIGHT: 1px
}
* + HTML .hw_vertical.hw_menu LI.hw_separator {
	HEIGHT: auto
}
.hw_vertical.hw_menu A {
	DISPLAY: block
}
.hw_vertical.hw_menu A SPAN {
	DISPLAY: block
}
.hw_vertical.hw_menu A {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 5px; PADDING-RIGHT: 25px; =
PADDING-TOP: 0px
}
.hw_vertical.hw_menu .hw_active {
	BACKGROUND-COLOR: #0979cd
}
.hw_vertical.hw_menu LI:hover {
	BACKGROUND-COLOR: #0979cd
}
.hw_vertical.hw_menu SPAN {
	PADDING-LEFT: 26px
}
.hw_vertical.hw_menu .hw_active SPAN {
	COLOR: #fff
}
.hw_vertical.hw_menu LI:hover SPAN {
	COLOR: #fff
}
.hw_vertical.hw_menu .hw_haschildren A {
	BACKGROUND: url(../images/arrow_collapsed.png) no-repeat 95% 8px
}
.hw_vertical.hw_menu .hw_haschildren.hw_active A {
	BACKGROUND-POSITION: 95% -42px
}
.hw_vertical.hw_menu .hw_haschildren:hover A {
	BACKGROUND-POSITION: 95% -42px
}
.hw_menu .hw_aaccessrights SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addbookmark SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addcontent SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addevent SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addhistoryentry SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addhyperlink SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addnote SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addtask SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addteam SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_addusers SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_archive SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_checked SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_checkin SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_checkout SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_checkprocessdefinition SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_clean SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_contact SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_copy SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_createagent SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_createshortcut SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_createtrack SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_delete SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_edit SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_filter SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_findexpert SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_help SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_hideheaderfooter SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_history SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_info SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_linkmap SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_listview SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_logout SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_maillink SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_managemembers SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_move SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_newdiscussiongroup SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_newfile SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_newcoll SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_newpost SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_notes SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_opendocuments SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_openmodeller SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_organizebookmarks SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_pause SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_play SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_preferences SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_reassign SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_refresh SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_replace SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_reply SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_save SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_search SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_send SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_similardocuments SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_share SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_sortorder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_showtoday SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_startcase SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_statistics SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_stop SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_subscribe SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_summary SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_threadview SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_versions SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_warning SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_accessrights SPAN {
	BACKGROUND-IMAGE: url(../images/tb_accessrights.png)
}
.hw_menu .hw_addbookmark SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addbookmark.png)
}
.hw_menu .hw_addcontent SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addcontent.png)
}
.hw_menu .hw_addevent SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addevent.png)
}
.hw_menu .hw_addhistoryentry SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addhistoryentry.png)
}
.hw_menu .hw_addhyperlink SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addhyperlink.png)
}
.hw_menu .hw_addnote SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addnote.png)
}
.hw_menu .hw_addtask SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addtask.png)
}
.hw_menu .hw_addtaskdefinition SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addtaskdefinition.png)
}
.hw_menu .hw_addteam SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addteam.png)
}
.hw_menu .hw_addusers SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addusers.png)
}
.hw_menu .hw_archive SPAN {
	BACKGROUND-IMAGE: url(../images/tb_archive.png)
}
.hw_menu .hw_checked SPAN {
	BACKGROUND-IMAGE: url(../images/tb_check.png)
}
.hw_menu .hw_checkin SPAN {
	BACKGROUND-IMAGE: url(../images/tb_checkin.png)
}
.hw_menu .hw_checkout SPAN {
	BACKGROUND-IMAGE: url(../images/tb_checkout.png)
}
.hw_menu .hw_checkprocessdefinition SPAN {
	BACKGROUND-IMAGE: url(../images/tb_checkprocessdefinition.png)
}
.hw_menu .hw_clean SPAN {
	BACKGROUND-IMAGE: url(../images/tb_clean.png)
}
.hw_menu .hw_contact SPAN {
	BACKGROUND-IMAGE: url(../images/tb_contact.png)
}
.hw_menu .hw_copy SPAN {
	BACKGROUND-IMAGE: url(../images/tb_copy.png)
}
.hw_menu .hw_createagent SPAN {
	BACKGROUND-IMAGE: url(../images/tb_agent.png)
}
.hw_menu .hw_createshortcut SPAN {
	BACKGROUND-IMAGE: url(../images/tb_createshortcut.png)
}
.hw_menu .hw_createtrack SPAN {
	BACKGROUND-IMAGE: url(../images/tb_createtrack.png)
}
.hw_menu .hw_delete SPAN {
	BACKGROUND-IMAGE: url(../images/tb_delete.png)
}
.hw_menu .hw_edit SPAN {
	BACKGROUND-IMAGE: url(../images/tb_edit.png)
}
.hw_menu .hw_filter SPAN {
	BACKGROUND-IMAGE: url(../images/tb_filter.png)
}
.hw_menu .hw_findexpert SPAN {
	BACKGROUND-IMAGE: url(../images/tb_expert.png)
}
.hw_menu .hw_help SPAN {
	BACKGROUND-IMAGE: url(../images/tb_help.png)
}
.hw_menu .hw_hideheaderfooter SPAN {
	BACKGROUND-IMAGE: url(../images/tb_hideheaderfooter.png)
}
.hw_menu .hw_history SPAN {
	BACKGROUND-IMAGE: url(../images/tb_history.png)
}
.hw_menu .hw_info SPAN {
	BACKGROUND-IMAGE: url(../images/tb_info.png)
}
.hw_menu .hw_linkmap SPAN {
	BACKGROUND-IMAGE: url(../images/tb_linkmap.png)
}
.hw_menu .hw_listview SPAN {
	BACKGROUND-IMAGE: url(../images/tb_listview.png)
}
.hw_menu .hw_logout SPAN {
	BACKGROUND-IMAGE: url(../images/tb_login.png)
}
.hw_menu .hw_maillink SPAN {
	BACKGROUND-IMAGE: url(../images/tb_maillink.png)
}
.hw_menu .hw_managemembers SPAN {
	BACKGROUND-IMAGE: url(../images/tb_managemembers.png)
}
.hw_menu .hw_move SPAN {
	BACKGROUND-IMAGE: url(../images/tb_move.png)
}
.hw_menu .hw_newdiscussiongroup SPAN {
	BACKGROUND-IMAGE: url(../images/tb_newdiscussiongroup.png)
}
.hw_menu .hw_newfile SPAN {
	BACKGROUND-IMAGE: url(../images/tb_newfile.png)
}
.hw_menu .hw_newcoll SPAN {
	BACKGROUND-IMAGE: url(../images/tb_newfolder.png)
}
.hw_menu .hw_newpost SPAN {
	BACKGROUND-IMAGE: url(../images/tb_newpost.png)
}
.hw_menu .hw_notes SPAN {
	BACKGROUND-IMAGE: url(../images/tb_notes.png)
}
.hw_menu .hw_opendocuments SPAN {
	BACKGROUND-IMAGE: url(../images/tb_opendocuments.png)
}
.hw_menu .hw_openmodeller SPAN {
	BACKGROUND-IMAGE: url(../images/tb_openmodeller.png)
}
.hw_menu .hw_organizebookmarks SPAN {
	BACKGROUND-IMAGE: url(../images/tb_organizebookmarks.png)
}
.hw_menu .hw_play SPAN {
	BACKGROUND-IMAGE: url(../images/tb_play.png)
}
.hw_menu .hw_pause SPAN {
	BACKGROUND-IMAGE: url(../images/tb_pause.png)
}
.hw_menu .hw_preferences SPAN {
	BACKGROUND-IMAGE: url(../images/tb_preferences.png)
}
.hw_menu .hw_reassign SPAN {
	BACKGROUND-IMAGE: url(../images/tb_reassign.png)
}
.hw_menu .hw_refresh SPAN {
	BACKGROUND-IMAGE: url(../images/tb_refresh.png)
}
.hw_menu .hw_replace SPAN {
	BACKGROUND-IMAGE: url(../images/tb_replace.png)
}
.hw_menu .hw_epostresponse SPAN {
	BACKGROUND-IMAGE: url(../images/tb_statistics.png)
}
.hw_menu .hw_reply SPAN {
	BACKGROUND-IMAGE: url(../images/tb_reply.png)
}
.hw_menu .hw_linkerica SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addhyperlink.png)
}
.hw_menu .hw_assignto SPAN {
	BACKGROUND-IMAGE: url(../images/tb_managemembers.png)
}
.hw_menu .hw_rejectpost SPAN {
	BACKGROUND-IMAGE: url(../images/tb_reassign.png)
}
.hw_menu .hw_filepost SPAN {
	BACKGROUND-IMAGE: url(../images/tb_archive.png)
}
.hw_menu .hw_phisicalcopy SPAN {
	BACKGROUND-IMAGE: url(../images/icon_note.png)
}
.hw_menu .hw_wbrestore SPAN {
	BACKGROUND-IMAGE: url(../images/tb_share.png)
}
.hw_menu .hw_checkedoutdocs SPAN {
	BACKGROUND-IMAGE: url(../images/tb_agent.png)
}
.hw_menu .hw_reqnewcollection SPAN {
	BACKGROUND-IMAGE: url(../images/tb_addcontent.png)
}
.hw_menu .hw_save SPAN {
	BACKGROUND-IMAGE: url(../images/tb_save.png)
}
.hw_menu .hw_search SPAN {
	BACKGROUND-IMAGE: url(../images/tb_search.png)
}
.hw_menu .hw_send SPAN {
	BACKGROUND-IMAGE: url(../images/tb_send.png)
}
.hw_menu .hw_share SPAN {
	BACKGROUND-IMAGE: url(../images/tb_share.png)
}
.hw_menu .hw_similardocuments SPAN {
	BACKGROUND-IMAGE: url(../images/tb_similardocuments.png)
}
.hw_menu .hw_showtoday SPAN {
	BACKGROUND-IMAGE: url(../images/tb_showtoday.png)
}
.hw_menu .hw_sortorder SPAN {
	BACKGROUND-IMAGE: url(../images/tb_sortorder.png)
}
.hw_menu .hw_startcase SPAN {
	BACKGROUND-IMAGE: url(../images/tb_startcase.png)
}
.hw_menu .hw_statistics SPAN {
	BACKGROUND-IMAGE: url(../images/tb_statistics.png)
}
.hw_menu .hw_stop SPAN {
	BACKGROUND-IMAGE: url(../images/tb_stop.png)
}
.hw_menu .hw_subscribe SPAN {
	BACKGROUND-IMAGE: url(../images/tb_subscribe.png)
}
.hw_menu .hw_summary SPAN {
	BACKGROUND-IMAGE: url(../images/tb_summary.png)
}
.hw_menu .hw_threadview SPAN {
	BACKGROUND-IMAGE: url(../images/tb_threadview.png)
}
.hw_menu .hw_versions SPAN {
	BACKGROUND-IMAGE: url(../images/tb_versions.png)
}
.hw_menu .hw_warning SPAN {
	BACKGROUND-IMAGE: url(../images/tb_warning.png)
}
.hw_horizontal.hw_menu .hw_info SPAN {
	TEXT-INDENT: 20px; WIDTH: 0px; OVERFLOW: hidden
}
.hw_horizontal.hw_menu .hw_share SPAN {
	TEXT-INDENT: 20px; WIDTH: 0px; OVERFLOW: hidden
}
BODY.isEditMode .hw_menu .hw_authoring SPAN {
	BACKGROUND-IMAGE: url(../images/tb_check.png)
}
.hw_button {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
CURSOR: pointer
}
.hw_button * {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
CURSOR: pointer
}
.hw_button {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; MARGIN: 0px 3px; =
OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
FONT-FAMILY: Helvetica, Arial, Verdana, sans-serif; BACKGROUND: none =
transparent scroll repeat 0% 0%; HEIGHT: 25px; FONT-SIZE: 13px; =
OVERFLOW: visible; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
.hw_button SPAN {
	BORDER-BOTTOM: medium none; TEXT-ALIGN: center; BORDER-LEFT: medium =
none; LINE-HEIGHT: 26px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; BACKGROUND: url(../images/hw_button_light.png) =
no-repeat 0px 0px; FLOAT: left; HEIGHT: 25px; COLOR: #001322; =
BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
.hw_button SPAN SPAN {
	POSITION: relative; PADDING-BOTTOM: 0px; PADDING-LEFT: 10px; =
PADDING-RIGHT: 15px; WHITE-SPACE: nowrap; BACKGROUND-POSITION: 100% 0px; =
TOP: 0px; RIGHT: -5px; PADDING-TOP: 0px
}
*:first-child + HTML .hw_button SPAN SPAN {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 15px; PADDING-RIGHT: 15px; =
PADDING-TOP: 0px
}
.hw_primary.hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.hw_primary.hw_button SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.buttons > .hw_button:first-child SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.buttons > .hw_button:first-child SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.has_submit_button.buttons > .hw_button:first-child SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_light.png); COLOR: #001322
}
.has_submit_button.buttons > .hw_button:first-child SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_light.png); COLOR: #001322
}
.has_submit_button.buttons > .hw_primary.hw_button:first-child SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.has_submit_button.buttons > .hw_primary.hw_button:first-child SPAN SPAN =
{
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.hw_primary.hw_button SPAN {
	COLOR: #fff
}
.hw_dark.hw_button SPAN {
	COLOR: #fff
}
.hw_dark.hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_dark.png); COLOR: #fff
}
.hw_dark.hw_button SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_dark.png); COLOR: #fff
}
.hw_button:hover SPAN {
	BACKGROUND-POSITION: 0px -50px
}
.hw_button:hover SPAN SPAN {
	BACKGROUND-POSITION: 100% -50px
}
.hw_button:active SPAN {
	BACKGROUND-POSITION: 0px -100px
}
.hw_button:active SPAN SPAN {
	BACKGROUND-POSITION: 100% -100px
}
.hw_button_date {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; WIDTH: 29px; =
BACKGROUND: url(../images/button_datechooser.png) no-repeat 0px 0px; =
HEIGHT: 21px; BORDER-TOP: medium none; CURSOR: pointer; BORDER-RIGHT: =
medium none
}
.hw_button_date SPAN {
	DISPLAY: none
}
.hw_button IMG {
	MARGIN-TOP: 4px; FLOAT: left
}
.hw_button LABEL {
	FLOAT: left
}
.hw_up.hw_button LABEL {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/arrow_up.png) no-repeat =
0px 5px
}
.hw_down.hw_button LABEL {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/arrow_down.png) no-repeat =
0px 5px
}
.hw_right.hw_button LABEL {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/arrow_right.png) =
no-repeat 0px 5px
}
#TreeLoading .TreeviewLoading {
	POSITION: absolute; LINE-HEIGHT: 200px; MARGIN-TOP: -30px; WIDTH: 40px; =
BACKGROUND: url(../images/progress_dark.gif) no-repeat 0px 0px; FLOAT: =
left; HEIGHT: 40px; MARGIN-LEFT: -15px; OVERFLOW: hidden; TOP: 50%; =
LEFT: 50%
}
BODY#treeview {
	MARGIN-TOP: 5px; HEIGHT: auto
}
#treeview UL {
	PADDING-BOTTOM: 0px; LIST-STYLE-TYPE: none; PADDING-LEFT: 0px; =
PADDING-RIGHT: 0px; LIST-STYLE-IMAGE: none; PADDING-TOP: 0px
}
#treeview UL LI {
	POSITION: relative
}
#treeview UL LI {
	LINE-HEIGHT: 26px; WHITE-SPACE: nowrap; HEIGHT: 26px; COLOR: #001322; =
CURSOR: pointer; TEXT-DECORATION: none
}
#treeview UL LI .label {
	LINE-HEIGHT: 26px; WHITE-SPACE: nowrap; HEIGHT: 26px; COLOR: #001322; =
CURSOR: pointer; TEXT-DECORATION: none
}
#treeview UL LI .label {
	DISPLAY: block
}
#treeview UL LI .label IMG {
	POSITION: absolute; MAX-WIDTH: 16px; MAX-HEIGHT: 16px; TOP: 3px
}
#treeview UL LI .label SPAN {
	FLOAT: left; MARGIN-LEFT: 40px
}
#treeview UL LI.root .label SPAN {
	MARGIN-LEFT: 30px
}
#treeview UL LI.root .toggle {
	DISPLAY: none
}
#treeview UL LI .toggle {
	POSITION: absolute; LINE-HEIGHT: 200px; WIDTH: 10px; HEIGHT: 10px; =
MARGIN-LEFT: 5px; OVERFLOW: hidden; TOP: 7px; CURSOR: pointer
}
#treeview UL LI.collapsed .toggle {
	BACKGROUND: url(../images/arrow_collapsed.png) no-repeat 0px 0px
}
#treeview UL LI.expanded .toggle {
	BACKGROUND: url(../images/arrow_expanded.png) no-repeat 0px 0px
}
#treeview UL LI.selected {
	BACKGROUND: url(../images/bg_treeview_selected.png) no-repeat 100% 0px
}
#treeview UL LI.selected * {
	COLOR: #fff
}
#treeview UL LI.selected.expanded .toggle {
	BACKGROUND-POSITION: 0px -50px
}
#treeview UL LI.selected.collapsed .toggle {
	BACKGROUND-POSITION: 0px -50px
}
#tabbar {
	PADDING-BOTTOM: 0px; LINE-HEIGHT: 38px; PADDING-LEFT: 14px; =
PADDING-RIGHT: 14px; BACKGROUND: #77a5cf; COLOR: #fff; OVERFLOW: hidden; =
BORDER-TOP: #89b0d9 1px solid; PADDING-TOP: 0px
}
#tabbar H1 {
	MIN-WIDTH: 208px; LINE-HEIGHT: 21px; MARGIN-TOP: 10px; FLOAT: left; =
MARGIN-LEFT: 8px; FONT-SIZE: 18px; FONT-WEIGHT: normal; MARGIN-RIGHT: =
30px
}
#tabbar H1 A {
	MARGIN-TOP: 11px; FLOAT: left; MARGIN-RIGHT: 3px
}
#tabbar .tabs {
	MIN-WIDTH: 50%; TEXT-ALIGN: center; PADDING-BOTTOM: 0px; =
LIST-STYLE-TYPE: none; MARGIN-TOP: 10px; PADDING-LEFT: 0px; =
PADDING-RIGHT: 0px; FLOAT: left; LIST-STYLE-IMAGE: none; PADDING-TOP: =
0px
}
#tabbar .tabs * {
	LINE-HEIGHT: 28px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; FLOAT: left; HEIGHT: 28px
}
#tabbar LI A {
	BACKGROUND-IMAGE: url(../images/bg_tab.png); BACKGROUND-REPEAT: =
no-repeat; BACKGROUND-POSITION: 0px -100px; COLOR: #fff; =
TEXT-DECORATION: none
}
#tabbar LI SPAN {
	BACKGROUND-IMAGE: url(../images/bg_tab.png); BACKGROUND-REPEAT: =
no-repeat; BACKGROUND-POSITION: 0px -100px; COLOR: #fff; =
TEXT-DECORATION: none
}
#tabbar LI A {
	PADDING-LEFT: 5px
}
#tabbar LI A SPAN {
	POSITION: relative; PADDING-RIGHT: 14px; BACKGROUND-POSITION: 100% =
-100px; RIGHT: -10px
}
#tabbar LI.selected A {
	BACKGROUND-POSITION: 0px 0px; COLOR: #001322
}
#tabbar LI.selected SPAN {
	BACKGROUND-POSITION: 0px 0px; COLOR: #001322
}
#tabbar LI.selected A:hover {
	BACKGROUND-POSITION: 0px 0px; COLOR: #001322
}
#tabbar LI.selected A:hover SPAN {
	BACKGROUND-POSITION: 0px 0px; COLOR: #001322
}
#tabbar LI.selected A SPAN {
	BACKGROUND-POSITION: 100% 0px
}
#tabbar LI.selected A:hover SPAN {
	BACKGROUND-POSITION: 100% 0px
}
#tabbar LI A:hover {
	BACKGROUND-POSITION: 0px -50px
}
#tabbar LI A:hover SPAN {
	BACKGROUND-POSITION: 100% -50px
}
#mainFilter {
	POSITION: relative; PADDING-BOTTOM: 5px; PADDING-LEFT: 24px; WIDTH: =
195px; PADDING-RIGHT: 0px; BACKGROUND: url(../images/bg_search.png) =
no-repeat 0px 0px; HEIGHT: 20px; TOP: 4px; MARGIN-RIGHT: 50px; =
PADDING-TOP: 5px
}
* + HTML #mainFilter {
	PADDING-BOTTOM: 4px; PADDING-LEFT: 24px; PADDING-RIGHT: 0px; =
MARGIN-RIGHT: 65px; PADDING-TOP: 4px
}
#mainFilter LABEL {
	DISPLAY: none
}
#mainFilter #mainFilterGoButton {
	DISPLAY: none
}
#mainFilter INPUT {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: =
0.2em; PADDING-LEFT: 0px; WIDTH: 192px; PADDING-RIGHT: 0px; FONT: =
12px/160% Arial, Helvetica, Verdana, sans-serif; BACKGROUND: none =
transparent scroll repeat 0% 0%; FLOAT: left; HEIGHT: 16px; BORDER-TOP: =
medium none; BORDER-RIGHT: medium none; PADDING-TOP: 0.2em
}
#mainFilter #mainFilterClearButton {
	POSITION: absolute; LINE-HEIGHT: 200px; WIDTH: 30px; BACKGROUND: =
url(../images/bg_search.png) no-repeat 100% 0px; HEIGHT: 26px; OVERFLOW: =
hidden; TOP: 0px; RIGHT: -30px
}
* + HTML #mainFilter #mainFilterClearButton {
	WIDTH: 45px; RIGHT: -45px
}
#mainframeHeader {
	BORDER-BOTTOM: #d0e5f1 1px solid; POSITION: relative; PADDING-BOTTOM: =
5px; MIN-HEIGHT: 24px; PADDING-LEFT: 20px; PADDING-RIGHT: 20px; =
OVERFLOW: hidden; PADDING-TOP: 10px
}
.hw_defaultdialog #mainframeHeader {
	POSITION: static
}
#mainframeHeader H2 {
	MARGIN-BOTTOM: 5px; FLOAT: left; COLOR: #6ea7d0; FONT-WEIGHT: normal
}
#mainframeHeader H2 A {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/info.png) no-repeat 0px =
2px; COLOR: #6ea7d0
}
#mainframeHeader .actions {
	MARGIN-TOP: -6px; FLOAT: right
}
#mainframeHeader .status {
	MARGIN-TOP: -6px; FLOAT: right
}
#mainframeHeader .actions {
	PADDING-LEFT: 10px; MARGIN-RIGHT: -12px
}
#mainframeHeader #mainframeHeaderRight {
	MARGIN: 0px; COLOR: #6ea7d0
}
#mainframeHeader #mainframeHeaderRight A {
	COLOR: #001322; MARGIN-LEFT: 5px; TEXT-DECORATION: underline
}
#mainframeHeader #mainframeHeaderRight A.notes {
	PADDING-BOTTOM: 0.1em; PADDING-LEFT: 20px; PADDING-RIGHT: 0px; =
BACKGROUND: url(../images/icon_note.png) no-repeat 0px 0px; PADDING-TOP: =
0.1em
}
#mainframeHeader #mainframeHeaderRight .hw_button {
	POSITION: relative; MARGIN-TOP: -6px; TOP: 2px
}
#mainframeHeader .hw_button SPAN {
	COLOR: #dbe8f3
}
#mainframeHeader .hw_primary.hw_button SPAN {
	COLOR: #fff
}
#mainframeHeader .tabs {
	POSITION: absolute; LIST-STYLE-TYPE: none; MARGIN-LEFT: -105px; TOP: =
4px; LIST-STYLE-IMAGE: none; LEFT: 50%
}
#mainframeHeader .tabs * {
	FLOAT: left; COLOR: #6ea7d0
}
* + HTML #mainframeHeader .tabs LI {
	BORDER-LEFT: #a9b8c1 1px solid
}
#mainframeHeader .tabs LI {
	BORDER-LEFT: #ccc 1px solid; MARGIN-RIGHT: -1px
}
#mainframeHeader .tabs LI:first-child {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-TOP: =
medium none; BORDER-RIGHT: medium none
}
#mainframeHeader .tabs A {
	PADDING-BOTTOM: 0px; LINE-HEIGHT: 25px; OUTLINE-STYLE: none; =
OUTLINE-COLOR: invert; PADDING-LEFT: 20px; OUTLINE-WIDTH: medium; =
PADDING-RIGHT: 20px; BACKGROUND: url(../images/hw_button_filter.png) =
no-repeat -10px 0px; HEIGHT: 25px; PADDING-TOP: 0px
}
#mainframeHeader .tabs LI:first-child A {
	BACKGROUND-POSITION: 0px 0px
}
#mainframeHeader .tabs .last A {
	BACKGROUND-POSITION: 100% 0px
}
#mainframeHeader .tabs .selected A {
	BACKGROUND-POSITION: -10px -50px
}
#mainframeHeader .tabs .selected A SPAN {
	COLOR: #fff
}
#mainframeHeader .tabs .selected:first-child A {
	BACKGROUND-POSITION: 0px -50px
}
#mainframeHeader .tabs .last.selected A {
	BACKGROUND-POSITION: 100% -50px
}
#mainframeHeader .tabs .hw_disabled A {
	CURSOR: default
}
#mainframeHeader .tabs .hw_disabled A SPAN {
	FILTER: alpha(opacity=3D50); opacity: 0.5
}
#mainframeHeader .tabs .first A SPAN {
	TEXT-INDENT: 2px; PADDING-LEFT: 12px; WIDTH: 1px; BACKGROUND: =
url(../images/icon_next.png) no-repeat 0px 7px; OVERFLOW: hidden
}
#mainframeHeader .tabs .previous A SPAN {
	TEXT-INDENT: 2px; PADDING-LEFT: 12px; WIDTH: 1px; BACKGROUND: =
url(../images/icon_next.png) no-repeat 0px 7px; OVERFLOW: hidden
}
#mainframeHeader .tabs .next A SPAN {
	TEXT-INDENT: 2px; PADDING-LEFT: 12px; WIDTH: 1px; BACKGROUND: =
url(../images/icon_next.png) no-repeat 0px 7px; OVERFLOW: hidden
}
#mainframeHeader .tabs .last A SPAN {
	TEXT-INDENT: 2px; PADDING-LEFT: 12px; WIDTH: 1px; BACKGROUND: =
url(../images/icon_next.png) no-repeat 0px 7px; OVERFLOW: hidden
}
#mainframeHeader .tabs .first A SPAN {
	BACKGROUND-IMAGE: url(../images/icon_first.png)
}
#mainframeHeader .tabs .previous A SPAN {
	BACKGROUND-IMAGE: url(../images/icon_previous.png)
}
#mainframeHeader .tabs .next A SPAN {
	BACKGROUND-IMAGE: url(../images/icon_next.png)
}
#mainframeHeader .tabs .last A SPAN {
	BACKGROUND-IMAGE: url(../images/icon_last.png)
}
#mainframeHeader SELECT {
	MARGIN-TOP: 4px
}
#mainframeHeader .sequence {
	POSITION: relative; MARGIN: auto auto 10px; WIDTH: 300px; OVERFLOW: =
auto
}
#mainframeHeader .sequence BUTTON {
	MARGIN-BOTTOM: 2px; MARGIN-LEFT: 40px
}
#mainframeHeader .sequence .sequencecount {
	POSITION: absolute; FLOAT: right; COLOR: #6ea7d0; TOP: 3px; LEFT: 222px
}
#mainframeHeader .sequence .tabs {
	POSITION: static; MARGIN-LEFT: 0px
}
#mainframeHeader .hw_clear {
	PADDING-LEFT: 14px; MARGIN-BOTTOM: -3px; BACKGROUND: =
url(../images/icon_clear.png) no-repeat 0px 0px; HEIGHT: 14px
}
#mainframeHeader .hw_clear SPAN {
	DISPLAY: none
}
#mainframeHeader .hw_disabled.hw_clear {
	BACKGROUND-POSITION: 100px 0px; CURSOR: default
}
#mainframeHeader #mainframeHeaderBottom {
	PADDING-BOTTOM: 2px; MARGIN: 0px -20px; PADDING-LEFT: 0px; =
PADDING-RIGHT: 0px; OVERFLOW: hidden; BORDER-TOP: #d0e5f1 1px solid; =
PADDING-TOP: 2px
}
#mainframeHeader #mainframeHeaderBottom .paging {
	MARGIN-TOP: 5px; FLOAT: left; MARGIN-LEFT: 20px
}
#mainframeHeader #mainframeHeaderBottom FORM {
	PADDING-RIGHT: 15px; FLOAT: right
}
#mainframeHeader #mainframeHeaderBottom FORM * {
	FLOAT: left
}
#mainframeHeader #mainframeHeaderBottom FORM * {
	FLOAT: left
}
#mainframeHeader #mainframeHeaderBottom FORM LABEL {
	MARGIN-TOP: 5px; PADDING-RIGHT: 5px; MARGIN-LEFT: 15px
}
#mainframeHeader #mainframeHeaderBottom FORM INPUT[type=3Dtext] {
	BORDER-BOTTOM-COLOR: #a9b4bb; MARGIN-TOP: 4px; BORDER-TOP-COLOR: =
#a9b4bb; BORDER-RIGHT-COLOR: #a9b4bb; BORDER-LEFT-COLOR: #a9b4bb; =
-moz-border-radius: 2px; -webkit-border-radius: 2px; border-radius: 2px
}
#mainframeHeader #mainframeHeaderBottom FORM SELECT {
	MARGIN-TOP: 5px
}
#mainframeHeader #mainframeHeaderBottom FORM .hw_button {
	MARGIN-TOP: 1px; MARGIN-LEFT: 10px
}
#listing .checkbox {
	DISPLAY: none
}
#listing {
	WIDTH: 100%; BORDER-COLLAPSE: collapse
}
#listing TD {
	TEXT-ALIGN: left; PADDING-BOTTOM: 0.3em; PADDING-LEFT: 0.5em; =
PADDING-RIGHT: 0.5em; WHITE-SPACE: nowrap; PADDING-TOP: 0.3em
}
#listing TH {
	TEXT-ALIGN: left; PADDING-BOTTOM: 0.3em; PADDING-LEFT: 0.5em; =
PADDING-RIGHT: 0.5em; WHITE-SPACE: nowrap; PADDING-TOP: 0.3em
}
#listing * {
	COLOR: #82888c
}
#listing TD A:hover {
	TEXT-DECORATION: underline
}
#listing .sortable {
	CURSOR: pointer
}
#listing .main * {
	COLOR: #001322
}
#listing .main {
	WIDTH: 100%; WHITE-SPACE: normal
}
#listing .main A {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
FLOAT: left; FONT-SIZE: 15px
}
#listing .main SPAN {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
FLOAT: left; FONT-SIZE: 15px
}
#listing .icon {
	PADDING-LEFT: 16px; PADDING-TOP: 0.15em
}
#listing .icon A {
	FLOAT: left
}
* + HTML #listing .icon A {
	FLOAT: none
}
#listing .center {
	TEXT-ALIGN: center
}
#listing .number {
	TEXT-ALIGN: right
}
#listing TR > TH:first-child {
	TEXT-ALIGN: right
}
#listing TD {
	PADDING-BOTTOM: 0.3em; BACKGROUND-COLOR: #fff; PADDING-LEFT: 0.5em; =
PADDING-RIGHT: 0.5em; VERTICAL-ALIGN: top; PADDING-TOP: 0.7em
}
#listing .selected TD {
	BACKGROUND: url(../images/bg_selected.gif) #0979cd repeat-x 0px 0px
}
#listing .selected.alternate TD {
	BACKGROUND: url(../images/bg_selected.gif) #0979cd repeat-x 0px 0px
}
#listing .selected * {
	COLOR: #fff
}
.hw_selection_enabled#listing .hw_selectable:hover > * {
	BACKGROUND-COLOR: #e1ecf8
}
.hw_selection_enabled#listingContentArea .hw_selectable:hover > * {
	BACKGROUND-COLOR: #e1ecf8
}
.hw_selection_enabled#listing .selected.hw_selectable:hover > * {
	BACKGROUND-COLOR: #0979cd
}
.hw_selection_enabled#listingContentArea .selected.hw_selectable:hover > =
* {
	BACKGROUND-COLOR: #0979cd
}
#listing .description {
	LINE-HEIGHT: 120%; MARGIN-TOP: -0.2em; DISPLAY: block; WHITE-SPACE: =
normal; COLOR: #82888c; CLEAR: both
}
#listing .selected .description {
	COLOR: #bfdef2
}
#listing .status {
	MARGIN-TOP: 2px; MARGIN-LEFT: 10px
}
#listing .status {
	LINE-HEIGHT: 17px; BACKGROUND: url(../images/status_badge.png) =
no-repeat 0px 0px; FLOAT: left; HEIGHT: 16px; COLOR: #fff
}
#listing .status SPAN {
	LINE-HEIGHT: 17px; BACKGROUND: url(../images/status_badge.png) =
no-repeat 0px 0px; FLOAT: left; HEIGHT: 16px; COLOR: #fff
}
* + HTML #listing .status {
	POSITION: relative
}
* + HTML #listing .status SPAN {
	POSITION: relative
}
#listing .status SPAN {
	POSITION: relative; PADDING-RIGHT: 7px; BACKGROUND-POSITION: 100% 0px; =
FONT-SIZE: 12px; RIGHT: -7px; font-transform: uppercase
}
* + HTML #listing .status {
	BACKGROUND: none transparent scroll repeat 0% 0%; COLOR: #f4a300; =
FONT-WEIGHT: bold
}
* + HTML #listing .status SPAN {
	BACKGROUND: none transparent scroll repeat 0% 0%; COLOR: #f4a300; =
FONT-WEIGHT: bold
}
* + HTML #listing .status SPAN {
	POSITION: static
}
#listing .selected .status {
	BACKGROUND-POSITION: 0px -50px
}
#listing .selected .status SPAN {
	BACKGROUND-POSITION: 100% -50px; COLOR: #007ccd
}
* + HTML #listing .selected .status SPAN {
	COLOR: #fff
}
.attention {
	MARGIN-TOP: 2px; MARGIN-BOTTOM: 2px; MARGIN-LEFT: 10px
}
.attention {
	LINE-HEIGHT: 17px; BACKGROUND: url(../images/attention_badge.png) =
no-repeat 0px 0px; HEIGHT: 16px; COLOR: #fff
}
.attention > SPAN {
	LINE-HEIGHT: 17px; BACKGROUND: url(../images/attention_badge.png) =
no-repeat 0px 0px; HEIGHT: 16px; COLOR: #fff
}
* + HTML .attention {
	POSITION: relative
}
* + HTML .attention > SPAN {
	POSITION: relative
}
.attention > SPAN {
	POSITION: relative; PADDING-RIGHT: 7px; BACKGROUND-POSITION: 100% 0px; =
FONT-SIZE: 12px; RIGHT: -7px; PADDING-TOP: 1px; font-transform: =
uppercase
}
* + HTML .attention {
	BACKGROUND: none transparent scroll repeat 0% 0%; COLOR: #f4a300; =
FONT-WEIGHT: bold
}
* + HTML .attention > SPAN {
	BACKGROUND: none transparent scroll repeat 0% 0%; COLOR: #f4a300; =
FONT-WEIGHT: bold
}
* + HTML #header .attention > SPAN > SPAN > A {
	BACKGROUND: none transparent scroll repeat 0% 0%; COLOR: #f4a300; =
FONT-WEIGHT: bold
}
* + HTML .attention > SPAN {
	POSITION: static
}
.empty#listing {
	HEIGHT: 90%
}
.empty#listing TD {
	HEIGHT: 100%
}
.empty#listing TD {
	TEXT-ALIGN: center; FONT-SIZE: 20px
}
.empty#listing TD SPAN {
	DISPLAY: block; BACKGROUND: url(../images/emptyfolder.png) no-repeat =
50% 0px; COLOR: #bed6ed; PADDING-TOP: 140px
}
.members.empty#listing TD {
	PADDING-TOP: 80px
}
.members.empty#listing TD SPAN {
	BACKGROUND-IMAGE: url(../images/emptyusers.png)
}
#listing .alternate TD {
	BACKGROUND-COLOR: #f1f7fb
}
#listing .hw_status_locked {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
#mainframeHeader .hw_status_locked {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
#listing .hw_status_shared {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
#mainframeHeader .hw_status_shared {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
#listing .hw_status_reminder {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
#mainframeHeader .hw_status_reminder {
	PADDING-BOTTOM: 2px; PADDING-LEFT: 20px; DISPLAY: inline; BACKGROUND: =
url(../images/status_locked.png) no-repeat 0px 0px; FLOAT: none; =
MARGIN-LEFT: 5px
}
* + HTML #listing .hw_status_locked {
	WIDTH: 16px; DISPLAY: block
}
* + HTML #mainframeHeader .hw_status_locked {
	WIDTH: 16px; DISPLAY: block
}
* + HTML #listing .hw_status_shared {
	WIDTH: 16px; DISPLAY: block
}
* + HTML #mainframeHeader .hw_status_shared {
	WIDTH: 16px; DISPLAY: block
}
* + HTML #listing .hw_status_reminder {
	WIDTH: 16px; DISPLAY: block
}
* + HTML #mainframeHeader .hw_status_reminder {
	WIDTH: 16px; DISPLAY: block
}
#listing .hw_status_shared {
	BACKGROUND-IMAGE: url(../images/status_shared.png); CURSOR: default
}
#mainframeHeader .hw_status_shared {
	BACKGROUND-IMAGE: url(../images/status_shared.png); CURSOR: default
}
#listing .hw_status_reminder {
	BACKGROUND-IMAGE: url(../images/status_reminder.png); CURSOR: default
}
#mainframeHeader .hw_status_reminder {
	BACKGROUND-IMAGE: url(../images/status_reminder.png); CURSOR: default
}
#listing .hw_status_shared SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#mainframeHeader .hw_status_shared SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#listing .hw_status_locked SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#mainframeHeader .hw_status_locked SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#listing .hw_status_reminder SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#mainframeHeader .hw_status_reminder SPAN {
	PADDING-BOTTOM: 2px; TEXT-INDENT: 5px; WIDTH: 1px; FLOAT: left; =
OVERFLOW: hidden
}
#listing .agentitem A {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/status_agent.png) =
no-repeat 0px 3px
}
.ekslisting .dropbox {
	POSITION: absolute; TEXT-ALIGN: center; LINE-HEIGHT: 135%; MARGIN-TOP: =
-140px; WIDTH: 300px; BACKGROUND: url(../images/emptydropbox.png) =
no-repeat 50% 0px; COLOR: #bed6ed; MARGIN-LEFT: -150px; TOP: 50%; =
PADDING-TOP: 140px; LEFT: 50%
}
.ekslisting .dropbox H1 {
	MARGIN-BOTTOM: 5px; FONT-SIZE: 20px; FONT-WEIGHT: normal
}
.eksopendocument #openmessageinfo {
	BORDER-BOTTOM: #b4d1e6 2px solid; POSITION: absolute; MIN-WIDTH: 300px; =
BORDER-LEFT: #b4d1e6 2px solid; PADDING-BOTTOM: 30px; MARGIN-TOP: =
-120px; PADDING-LEFT: 90px; PADDING-RIGHT: 30px; BACKGROUND: =
url(../images/icon_info_large.png) no-repeat 34px 22px; MARGIN-LEFT: =
-220px; BORDER-TOP: #b4d1e6 2px solid; TOP: 50%; BORDER-RIGHT: #b4d1e6 =
2px solid; PADDING-TOP: 30px; LEFT: 50%; -moz-border-radius: 5px; =
-webkit-border-radius: 5px; border-radius: 5px
}
.eksopendocument #openmessageinfo H1 {
	LINE-HEIGHT: 110%; MARGIN-BOTTOM: 0.3em; FONT-SIZE: 27px; FONT-WEIGHT: =
normal
}
.eksopendocument #openmessageinfo P {
	LINE-HEIGHT: 120%; MARGIN-TOP: -0.3em; MARGIN-BOTTOM: 0.3em; COLOR: =
#82888c
}
.eksopendocument #openmessageinfo DL {
	MARGIN-BOTTOM: 1em; OVERFLOW: hidden
}
.eksopendocument #openmessageinfo DT {
	PADDING-RIGHT: 3px; FLOAT: left; FONT-WEIGHT: bold
}
.eksopendocument #openmessageinfo DD {
	COLOR: #82888c
}
.eksopendocument #openmessageinfo DD A {
	COLOR: #82888c
}
.eksopendocument #openmessageinfo DD A:hover {
	TEXT-DECORATION: underline
}
.eksopendocument #openmessage {
	POSITION: absolute; TEXT-ALIGN: center; MARGIN-TOP: -10px; WIDTH: =
400px; FONT: 14px Arial, Helvetica, sans-serif; COLOR: #737a80; =
MARGIN-LEFT: -200px; TOP: 45%; LEFT: 50%
}
.eksopendocument #openmessage H1 {
	COLOR: #82888c; FONT-SIZE: 27px; FONT-WEIGHT: normal
}
BODY.errorpage {
	PADDING-BOTTOM: 50px; PADDING-LEFT: 50px; PADDING-RIGHT: 50px; =
PADDING-TOP: 50px
}
.errorpage {
	HEIGHT: auto
}
.errorpage #errormessageinfo {
	BORDER-BOTTOM: #b4d1e6 2px solid; MIN-WIDTH: 300px; BORDER-LEFT: =
#b4d1e6 2px solid; PADDING-BOTTOM: 30px; PADDING-LEFT: 90px; =
PADDING-RIGHT: 30px; BACKGROUND: url(../images/icon_warning.png) =
no-repeat 34px 22px; BORDER-TOP: #b4d1e6 2px solid; BORDER-RIGHT: =
#b4d1e6 2px solid; PADDING-TOP: 30px; -moz-border-radius: 5px; =
-webkit-border-radius: 5px; border-radius: 5px
}
.errorpage #errormessageinfo .hw_button {
	MARGIN: 10px
}
.errorpage #errormessageinfo H1 {
	LINE-HEIGHT: 110%; MARGIN-BOTTOM: 0.3em; FONT-SIZE: 27px; FONT-WEIGHT: =
normal
}
.errorpage #errormessageinfo P {
	LINE-HEIGHT: 120%; MARGIN-TOP: -0.3em; MARGIN-BOTTOM: 0.3em; COLOR: =
#82888c
}
.errorpage #errormessageinfo UL {
	MARGIN-TOP: 10px; PADDING-LEFT: 15px; MARGIN-BOTTOM: 15px
}
.errorpage #FullErrorMessage {
	BORDER-BOTTOM: #7f9db9 1px solid; BORDER-LEFT: #7f9db9 1px solid; =
PADDING-BOTTOM: 0.5em; PADDING-LEFT: 1em; PADDING-RIGHT: 1em; DISPLAY: =
none; WHITE-SPACE: pre-line; BORDER-TOP: #7f9db9 1px solid; CURSOR: =
text; BORDER-RIGHT: #7f9db9 1px solid; PADDING-TOP: 0.5em
}
.errorpage #errormessagefooter {
	POSITION: fixed; BACKGROUND-COLOR: #ffffff; BOTTOM: 0px; HEIGHT: 40px; =
RIGHT: 0px
}
.errorpage #errormessagefooter .hw_button {
	POSITION: absolute; BOTTOM: 8px; RIGHT: 10px
}
.errorpage #errormessagefooter .hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #ffffff
}
.errorpage #errormessagefooter .hw_button SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #ffffff
}
#listing .button A {
	WHITE-SPACE: nowrap; MARGIN-RIGHT: 10px
}
#listing .button A:hover {
	TEXT-DECORATION: none
}
#listing .button A {
	MIN-WIDTH: 50px; LINE-HEIGHT: 18px; OUTLINE-STYLE: none; OUTLINE-COLOR: =
invert; OUTLINE-WIDTH: medium; DISPLAY: block; BACKGROUND: =
url(../images/button_action.png) no-repeat 0px 0px; HEIGHT: 17px; CLEAR: =
none; FONT-SIZE: 11px; CURSOR: pointer; FONT-WEIGHT: bold
}
#listing .button A SPAN {
	MIN-WIDTH: 50px; LINE-HEIGHT: 18px; OUTLINE-STYLE: none; OUTLINE-COLOR: =
invert; OUTLINE-WIDTH: medium; DISPLAY: block; BACKGROUND: =
url(../images/button_action.png) no-repeat 0px 0px; HEIGHT: 17px; CLEAR: =
none; FONT-SIZE: 11px; CURSOR: pointer; FONT-WEIGHT: bold
}
#listing .button A SPAN {
	POSITION: relative; TEXT-ALIGN: center; PADDING-RIGHT: 10px; =
BACKGROUND-POSITION: 100% 0px; RIGHT: -10px
}
* + HTML #listing .button A {
	BORDER-BOTTOM: #82888c 1px solid; BORDER-LEFT: #82888c 1px solid; =
BACKGROUND: #fff; BORDER-TOP: #82888c 1px solid; BORDER-RIGHT: #82888c =
1px solid
}
* + HTML #listing .button A SPAN {
	POSITION: static; PADDING-BOTTOM: 0px; PADDING-LEFT: 5px; =
PADDING-RIGHT: 5px; BACKGROUND: none transparent scroll repeat 0% 0%; =
PADDING-TOP: 0px
}
#listing .button A:active {
	BACKGROUND-POSITION: 0px -50px
}
#listing .button A:active SPAN {
	BACKGROUND-POSITION: 100% -50px
}
#listing .selected .button A SPAN {
	COLOR: #82888c
}
#listing .selected .button A SPAN * {
	COLOR: #82888c
}
#revertform #listing TD:first-child {
	TEXT-ALIGN: right
}
#VersionsDialog #listing TD.main {
	MIN-WIDTH: 200px
}
* + HTML #VersionsDialog #listing TD {
	WHITE-SPACE: nowrap
}
#VersionsDialog #listing TD.checkbox {
	DISPLAY: table-cell
}
* + HTML #VersionsDialog #listing TD.checkbox {
	DISPLAY: block
}
* + HTML #VersionsDialog #listing TD.main A {
	FLOAT: none
}
#VersionsDialog #listing TD.checkbox INPUT {
	MARGIN-TOP: 2px
}
#VersionsDialog #listing TD.version {
	TEXT-ALIGN: right
}
#VersionsDialog #listing .lastcommitted TD.version SPAN.indicator {
	WIDTH: 16px; DISPLAY: block; BACKGROUND: =
url(../images/icon_currentversion.png) no-repeat 0px 0px; HEIGHT: 16px
}
#VersionsDialog #listing TD.version {
	PADDING-LEFT: 1px; PADDING-RIGHT: 1px
}
#VersionsDialog #listing TD.version INPUT {
	MARGIN-TOP: 3px
}
* + HTML #VersionsDialog #listing TD.version INPUT {
	MARGIN-TOP: 0px
}
#VersionsDialog #listing .main A {
	FONT-SIZE: 13px
}
#VersionsDialog #listing .main SPAN {
	FONT-SIZE: 13px
}
#VersionsDialog #listing .icon {
	PADDING-LEFT: 0px
}
#breadcrumbingContainer {
	PADDING-LEFT: 7px
}
#breadcrumbing {
	MIN-HEIGHT: 22px; OVERFLOW: auto
}
#breadcrumbing * {
	LINE-HEIGHT: 22px
}
#breadcrumbing > DIV {
	WIDTH: 100%
}
#breadcrumbing UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#breadcrumbing UL * {
	DISPLAY: inline; COLOR: #000
}
#header #breadcrumbing UL * {
	COLOR: #fff
}
#breadcrumbing UL LI {
	MARGIN: 0px 2px
}
#breadcrumbing UL LI A {
	PADDING-LEFT: 13px; BACKGROUND: url(../images/arrow_collapsed.png) =
no-repeat 0px 3px
}
#header #breadcrumbing UL LI A {
	BACKGROUND: url(../images/arrow_collapsed.png) no-repeat 0px -48px
}
#breadcrumbing UL LI A:hover {
	TEXT-DECORATION: underline
}
#breadcrumbing UL LI:first-child A {
	PADDING-LEFT: 0px; BACKGROUND: none transparent scroll repeat 0% 0%
}
#header #breadcrumbing UL LI:first-child A {
	PADDING-LEFT: 0px; BACKGROUND: none transparent scroll repeat 0% 0%
}
#breadcrumbing UL LI .selected {
	CURSOR: default; FONT-WEIGHT: bold; TEXT-DECORATION: none
}
#breadcrumbing UL LI .selected:hover {
	CURSOR: default; FONT-WEIGHT: bold; TEXT-DECORATION: none
}
#breadcrumbing #CSBreadCrumbingXInstance_0_next A {
	LINE-HEIGHT: 100px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; WIDTH: 17px; BACKGROUND: =
url(../images/button_scrollleft.png) no-repeat 0px 50%; FLOAT: left; =
HEIGHT: 22px; OVERFLOW: hidden
}
#breadcrumbing #CSBreadCrumbingXInstance_0_previous A {
	LINE-HEIGHT: 100px; OUTLINE-STYLE: none; OUTLINE-COLOR: invert; =
OUTLINE-WIDTH: medium; WIDTH: 17px; BACKGROUND: =
url(../images/button_scrollleft.png) no-repeat 0px 50%; FLOAT: left; =
HEIGHT: 22px; OVERFLOW: hidden
}
#breadcrumbing #CSBreadCrumbingXInstance_0_next A {
	BACKGROUND-IMAGE: url(../images/button_scrollright.png); FLOAT: right
}
#breadcrumbing #CSBreadCrumbingXInstance_0_next {
	FLOAT: right; MARGIN-RIGHT: 5px
}
#breadcrumbing #CSBreadCrumbingXInstance_0_previous {
	MARGIN-LEFT: 5px
}
#breadcrumbing .disabled {
	DISPLAY: none
}
.frame {
	MARGIN: 0px 5px; BACKGROUND: url(../images/bg_frame.gif) no-repeat 0px =
0px; OVERFLOW: hidden
}
.frame .frame {
	MARGIN: 0px; WIDTH: auto; BACKGROUND-POSITION: 100% 0px
}
.frame .frame .frame {
	BACKGROUND-POSITION: 0px 100%
}
.frame .frame .frame .frame {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 10px; PADDING-RIGHT: 10px; =
BACKGROUND-POSITION: 100% 100%; PADDING-TOP: 10px
}
.noframe .frame {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; BACKGROUND: none transparent scroll repeat 0% 0%; PADDING-TOP: 0px
}
.noframe .frame .frame {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; BACKGROUND: none transparent scroll repeat 0% 0%; PADDING-TOP: 0px
}
.noframe .frame .frame .frame {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; BACKGROUND: none transparent scroll repeat 0% 0%; PADDING-TOP: 0px
}
.noframe .frame .frame .frame .frame {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; BACKGROUND: none transparent scroll repeat 0% 0%; PADDING-TOP: 0px
}
#dialogheader {
	PADDING-BOTTOM: 5px; MIN-HEIGHT: 28px; PADDING-LEFT: 15px; =
PADDING-RIGHT: 15px; PADDING-TOP: 10px
}
#dialogheader H1 {
	LINE-HEIGHT: 18px; MARGIN: 5px; FONT-SIZE: 18px; FONT-WEIGHT: normal
}
#dialogfooter .help.hw_button {
	POSITION: absolute; MIN-WIDTH: 0px; WIDTH: 24px; BACKGROUND: =
url(../images/tb_help.png) no-repeat 0px 0px; HEIGHT: 24px; TOP: 10px; =
RIGHT: 10px
}
#dialogfooter .help.hw_button SPAN {
	DISPLAY: none
}
.defaultstyle#dialogbody {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 15px; PADDING-RIGHT: 15px; =
PADDING-TOP: 10px
}
#dialogbody H2 {
	MARGIN: 5px; FONT-SIZE: 14px; FONT-WEIGHT: normal
}
#dialogbody H3 {
	MARGIN: 5px; FONT-SIZE: 12px; FONT-WEIGHT: normal
}
#dialogbody .tabs {
	PADDING-BOTTOM: 0px; LIST-STYLE-TYPE: none; PADDING-LEFT: 0px; =
PADDING-RIGHT: 0px; FLOAT: left; LIST-STYLE-IMAGE: none; PADDING-TOP: =
0px
}
#dialogbody .tabs * {
	OUTLINE-STYLE: none; OUTLINE-COLOR: invert; OUTLINE-WIDTH: medium; =
FLOAT: left; COLOR: #001322; TEXT-DECORATION: none
}
#dialogbody .tabs LI {
	MARGIN-RIGHT: 5px
}
#dialogbody .tabs LI {
	LINE-HEIGHT: 28px; BACKGROUND-REPEAT: no-repeat; BACKGROUND-POSITION: =
0px 0px; HEIGHT: 28px
}
#dialogbody .tabs LI SPAN {
	LINE-HEIGHT: 28px; BACKGROUND-REPEAT: no-repeat; BACKGROUND-POSITION: =
0px 0px; HEIGHT: 28px
}
#dialogbody .tabs LI SPAN {
	POSITION: relative; PADDING-LEFT: 8px; PADDING-RIGHT: 18px; =
BACKGROUND-POSITION: 100% 0px; CURSOR: pointer; RIGHT: -10px
}
#dialogbody .tabs .selected {
	BACKGROUND-IMAGE: url(../images/bg_tab2.png)
}
#dialogbody .tabs .selected SPAN {
	BACKGROUND-IMAGE: url(../images/bg_tab2.png)
}
#dialogbody .section {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
MARGIN-BOTTOM: 10px; BACKGROUND: #fff; CLEAR: both; PADDING-TOP: 5px; =
-moz-border-radius: 5px; -webkit-border-radius: 5px; border-radius: 5px; =
-moz-box-shadow: 0 1px 5px #6da6cf; -webkit-box-shadow: 0 1px 5px =
#6da6cf; box-shadow: 0 1px 5px #6da6cf
}
.hw_defaultdialogtable {
	MARGIN: auto
}
#dialogbody .hw_defaultdialogtable TR.hw_disabled {
	FILTER: alpha(opacity=3D50); opacity: 0.5
}
#dialogbody .infomessage {
	TEXT-ALIGN: center; PADDING-BOTTOM: 0px; MARGIN: 10px; MIN-HEIGHT: =
35px; PADDING-LEFT: 20px; PADDING-RIGHT: 20px; BACKGROUND: =
url(../images/emptyfolder.png) no-repeat 50% 2px; COLOR: #77a5cf; =
FONT-SIZE: 16px; PADDING-TOP: 140px
}
#dialogbody .emptymessage {
	TEXT-ALIGN: center; PADDING-BOTTOM: 0px; MARGIN: 10px; MIN-HEIGHT: =
35px; PADDING-LEFT: 20px; PADDING-RIGHT: 20px; BACKGROUND: =
url(../images/emptyfolder.png) no-repeat 50% 2px; COLOR: #77a5cf; =
FONT-SIZE: 16px; PADDING-TOP: 140px
}
#dialogbody .infomessage {
	BACKGROUND-IMAGE: url(../images/infomessage.png)
}
* + HTML #dialogbody .hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_light.gif)
}
* + HTML #dialogbody .hw_button SPAN SPAN {
	POSITION: static
}
#dialogbody {
	OVERFLOW-Y: auto
}
#dialogfooter {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 15px; PADDING-RIGHT: 15px; =
OVERFLOW: hidden; PADDING-TOP: 10px
}
#dialogfooter .buttons {
	FLOAT: right
}
#dialogfooter #workingIndicatorContainer {
	FLOAT: left; VISIBILITY: hidden
}
.floating.controlgroup {
	FLOAT: left
}
.controlgroup INPUT {
	FLOAT: left
}
.controlgroup SELECT {
	FLOAT: left
}
.controlgroup BUTTON {
	FLOAT: left
}
.controlgroup TEXTAREA {
	FLOAT: left
}
.controlgroup TEXTAREA {
	MARGIN-RIGHT: 4px
}
.controlgroup INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 3px; MARGIN-RIGHT: 4px
}
.controlgroup BUTTON {
	MARGIN-TOP: -2px; MARGIN-RIGHT: 9px
}
BODY.hw_defaultdialog SELECT {
	MIN-WIDTH: 5em
}
BODY.hw_defaultdialog #dialogbody {
	MIN-HEIGHT: 80px
}
BODY.tabbed.hw_defaultdialog #dialogbody {
	MIN-HEIGHT: 160px
}
.hw_asterisk {
	WHITE-SPACE: nowrap
}
.hw_asterisk SPAN {
	MARGIN-LEFT: 5px; VERTICAL-ALIGN: top
}
.ProgressBar {
	BACKGROUND-COLOR: #b9cbdd
}
#workingIndicatorContainer .workingIndicator {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; DISPLAY: block; =
FLOAT: left; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
#workingIndicatorContainer .indicator {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; DISPLAY: block; =
FLOAT: left; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
#workingIndicatorContainer .description {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; DISPLAY: block; =
FLOAT: left; BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
#workingIndicatorContainer .workingIndicator {
	BORDER-BOTTOM: #90b1e4 1px solid; BORDER-LEFT: #90b1e4 1px solid; =
PADDING-BOTTOM: 1px; PADDING-LEFT: 1px; WIDTH: 50px; PADDING-RIGHT: 1px; =
BACKGROUND: url(../dialogimg/bg_workingIndicator.gif) #fff repeat-x 0px =
0px; BORDER-TOP: #90b1e4 1px solid; BORDER-RIGHT: #90b1e4 1px solid; =
PADDING-TOP: 1px
}
#workingIndicatorContainer .workingIndicator .indicator {
	WIDTH: 100%; BACKGROUND: url(../dialogimg/workingIndicator.gif) #90b1e4 =
repeat-x 0px 0px; HEIGHT: 10px; FONT-SIZE: 0px
}
#workingIndicatorContainer .description {
	MARGIN-TOP: -0.1em; COLOR: #666666
}
#SearchResults .hw_menu {
	MARGIN: 0px 0px 5px 10px
}
#SearchResults .section .listingcontainer {
	OVERFLOW: auto
}
#SearchResults #listing .description * {
	COLOR: #82888c
}
#SearchResults #listing .description A {
	FLOAT: none; TEXT-DECORATION: underline
}
#SearchResults #mainframeHeader {
	MIN-HEIGHT: 50px
}
#SearchResults .empty#mainframeHeader {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; BORDER-TOP: =
medium none; BORDER-RIGHT: medium none
}
#SearchResults #mainframeHeader .hw_button {
	FLOAT: right
}
#SearchResults #mainframeHeader .descriptioncontrol {
	CLEAR: both
}
#SearchResults #mainframeFooter {
	MIN-HEIGHT: 30px; PADDING-LEFT: 20px; OVERFLOW: hidden; BORDER-TOP: =
#d0e5f1 1px solid; PADDING-TOP: 10px
}
#SearchResults #listing .sendmail SPAN {
	WIDTH: 16px; BACKGROUND: url(../images/icon_sendmail.png) no-repeat 0px =
0px; FLOAT: left; HEIGHT: 16px
}
#SearchResults #listing .score {
	TEXT-ALIGN: right
}
#SearchResults #listing .main {
	MIN-WIDTH: 200px
}
#CreateAgent .typeoption {
	VERTICAL-ALIGN: top
}
#EditAgent .typeoption {
	VERTICAL-ALIGN: top
}
#CreateAgent .typeoption INPUT {
	MARGIN: 9px 2px 9px 9px; FLOAT: right
}
#EditAgent .typeoption INPUT {
	MARGIN: 9px 2px 9px 9px; FLOAT: right
}
#CreateAgent .typedescription {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
PADDING-TOP: 5px
}
#EditAgent .typedescription {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
PADDING-TOP: 5px
}
#CreateAgent .typedescription LABEL {
	FONT-WEIGHT: bold
}
#EditAgent .typedescription LABEL {
	FONT-WEIGHT: bold
}
#dialogMySubscriptions #mainframeHeader H2 {
	FONT-SIZE: 20px
}
#SortOrder .section .sortlist {
	WIDTH: 100%
}
#SortOrder #mainframeHeader {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 8px; PADDING-RIGHT: 8px; =
PADDING-TOP: 10px
}
#SortOrder #mainframeHeaderRight {
	FLOAT: right
}
#SortOrder #mainframeHeaderLeft {
	FLOAT: left
}
#SortOrder .description {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; COLOR: =
#82888c; PADDING-TOP: 8px
}
#Summary #mainframeHeader {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; =
PADDING-TOP: 0px
}
#Summary .summarytext {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
PADDING-TOP: 5px
}
#dialogChooseTarget .hw_defaultdialogtable {
	WIDTH: 100%
}
#dialogChooseTarget #listingContentArea {
	WIDTH: 100%
}
#dialogChooseTarget #listing .icon {
	PADDING-TOP: 0.7em
}
BODY.linkmap {
	MIN-WIDTH: 650px
}
BODY.linkmap .columns {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; OVERFLOW: =
hidden; PADDING-TOP: 0px
}
BODY.linkmap .columns > DIV {
	WIDTH: 45%; FLOAT: left; MARGIN-LEFT: 5%
}
BODY.linkmap .columns DIV:first-child {
	MARGIN-LEFT: 0px
}
BODY.linkmap .columns .section {
	WIDTH: 100%
}
BODY.linkmap .columns UL {
	LIST-STYLE-TYPE: none; CLEAR: both; LIST-STYLE-IMAGE: none
}
BODY.linkmap .columns UL LI {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 15px; PADDING-RIGHT: 15px; =
PADDING-TOP: 0px
}
BODY.linkmap .columns UL LI IMG {
	PADDING-RIGHT: 5px
}
BODY.linkmap .columns UL LI A {
	DISPLAY: block; WHITE-SPACE: nowrap; COLOR: #001322
}
BODY.linkmap .columns UL LI A:hover SPAN {
	TEXT-DECORATION: underline
}
BODY.linkmap H3 {
	FONT-STYLE: italic
}
BODY.linkmap #dialogbody .section {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; PADDING-TOP: 0px
}
.hw_defaultdialog .writerow TD {
	PADDING-TOP: 0px
}
.hw_defaultdialog .readrow TD {
	PADDING-TOP: 0px
}
.hw_defaultdialog .disabled.writerow TD {
	FILTER: alpha(opacity=3D30); opacity: 0.3
}
.hw_defaultdialog .disabled.readrow TD {
	FILTER: alpha(opacity=3D30); opacity: 0.3
}
.hw_defaultdialog .writerow LABEL {
	PADDING-LEFT: 5px
}
.hw_defaultdialog .readrow LABEL {
	PADDING-LEFT: 5px
}
.columns {
	PADDING-BOTTOM: 10px; PADDING-LEFT: 10px; PADDING-RIGHT: 10px; =
OVERFLOW: hidden; PADDING-TOP: 10px
}
.columns DIV {
	FLOAT: left
}
.columns .span10 {
	WIDTH: 10%
}
.columns .span20 {
	WIDTH: 20%
}
.columns .span30 {
	WIDTH: 30%
}
.columns .span40 {
	WIDTH: 40%
}
.columns .span45 {
	WIDTH: 45%
}
.columns .span50 {
	WIDTH: 50%
}
.columns .span60 {
	WIDTH: 60%
}
.columns .span70 {
	WIDTH: 70%
}
.columns .span80 {
	WIDTH: 80%
}
.columns .span90 {
	WIDTH: 90%
}
.columns .span100 {
	WIDTH: 100%
}
#rights {
	MIN-WIDTH: 600px
}
#userchooser {
	MIN-WIDTH: 600px
}
#editusersgroups {
	MIN-WIDTH: 600px
}
#editgroupmembers {
	MIN-WIDTH: 600px
}
#assignusersgroups {
	MIN-WIDTH: 600px
}
#rights .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#userchooser .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#editusersgroups .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#editgroupmembers .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#assignusersgroups .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#assignusersgroups .columns DIV SELECT {
	HEIGHT: 150px
}
#rights .columns DIV SELECT {
	WIDTH: 100%; HEIGHT: 200px
}
#rights .columns DIV:first-child SELECT {
	WIDTH: 100%; HEIGHT: 250px
}
#rights INPUT[type=3Dcheckbox] {
	MARGIN-RIGHT: 3px
}
#userchooser INPUT[type=3Dcheckbox] {
	MARGIN-RIGHT: 3px
}
#editusersgroups INPUT[type=3Dcheckbox] {
	MARGIN-RIGHT: 3px
}
#editgroupmembers INPUT[type=3Dcheckbox] {
	MARGIN-RIGHT: 3px
}
#assignusersgroups INPUT[type=3Dcheckbox] {
	MARGIN-RIGHT: 3px
}
#rights .assignbuttons {
	PADDING-TOP: 110px
}
#userchooser .assignbuttons {
	PADDING-TOP: 110px
}
#editusersgroups .assignbuttons {
	PADDING-TOP: 110px
}
#editgroupmembers .assignbuttons {
	PADDING-TOP: 110px
}
#assignusersgroups .assignbuttons {
	PADDING-TOP: 85px
}
#rights .assignbuttons .hw_button {
	DISPLAY: block; MARGIN-BOTTOM: 5px
}
#userchooser .assignbuttons .hw_button {
	DISPLAY: block; MARGIN-BOTTOM: 5px
}
#editusersgroups .assignbuttons .hw_button {
	DISPLAY: block; MARGIN-BOTTOM: 5px
}
#editgroupmembers .assignbuttons .hw_button {
	DISPLAY: block; MARGIN-BOTTOM: 5px
}
#assignusersgroups .assignbuttons .hw_button {
	DISPLAY: block; MARGIN-BOTTOM: 5px
}
#assignusersgroups .hw_right.hw_button SPAN SPAN {
	PADDING-RIGHT: 3px
}
#editusersgroups .editbutton {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; =
PADDING-TOP: 5px
}
#editusersgroups .deletebutton {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; =
PADDING-TOP: 5px
}
#editusersgroups .editbutton .hw_button {
	MARGIN: 0px
}
#editusersgroups .deletebutton .hw_button {
	MARGIN: 0px
}
#rights .filter {
	BORDER-BOTTOM: #bbd7ee 1px solid; PADDING-BOTTOM: 5px; PADDING-LEFT: =
10px; PADDING-RIGHT: 10px; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: =
5px
}
#userchooser .filter {
	BORDER-BOTTOM: #bbd7ee 1px solid; PADDING-BOTTOM: 5px; PADDING-LEFT: =
10px; PADDING-RIGHT: 10px; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: =
5px
}
#editusersgroups .filter {
	BORDER-BOTTOM: #bbd7ee 1px solid; PADDING-BOTTOM: 5px; PADDING-LEFT: =
10px; PADDING-RIGHT: 10px; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: =
5px
}
#editgroupmembers .filter {
	BORDER-BOTTOM: #bbd7ee 1px solid; PADDING-BOTTOM: 5px; PADDING-LEFT: =
10px; PADDING-RIGHT: 10px; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: =
5px
}
#assignusersgroups .filter {
	BORDER-BOTTOM: #bbd7ee 1px solid; PADDING-BOTTOM: 5px; PADDING-LEFT: =
10px; PADDING-RIGHT: 10px; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: =
5px
}
#assignusersgroups .filter {
	PADDING-BOTTOM: 15px; WIDTH: 100%; MARGIN-BOTTOM: 10px
}
#assignusersgroups .filter .hw_button {
	MARGIN: 0px; HEIGHT: 15px; FONT-SIZE: 10px
}
#assignusersgroups .filter .hw_button {
	MARGIN: 0px; FLOAT: left; HEIGHT: 15px; FONT-SIZE: 10px
}
* + HTML #assignusersgroups .filter .hw_button {
	MARGIN-RIGHT: 4px
}
#assignusersgroups .filter .hw_button {
	MARGIN-RIGHT: 10px
}
#assignusersgroups .filter .hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_short_light.gif); =
LINE-HEIGHT: 18px
}
* + HTML #assignusersgroups .filter .hw_button SPAN {
	LINE-HEIGHT: 14px
}
#assignusersgroups .filter .hw_button SPAN SPAN {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 3px; PADDING-RIGHT: 7px; =
PADDING-TOP: 0px
}
#assignusersgroups .controlgroup {
	WIDTH: 100%; PADDING-TOP: 10px
}
#assignusersgroups .controlgroup .hw_button {
	MARGIN-BOTTOM: 10px; FLOAT: right
}
#assignusersgroups .controlgroup H2 {
	MARGIN-TOP: 13px; MARGIN-BOTTOM: 0px; FLOAT: left
}
#rights .searchfield {
	MIN-WIDTH: 240px
}
#userchooser .searchfield {
	MIN-WIDTH: 240px
}
#editusersgroups .searchfield {
	MIN-WIDTH: 240px
}
#editgroupmembers .searchfield {
	MIN-WIDTH: 240px
}
#assignusersgroups .searchfield {
	MIN-WIDTH: 240px
}
#rights .search {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 17px; PADDING-RIGHT: 17px; OVERFLOW: =
hidden; PADDING-TOP: 15px
}
#userchooser .search {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 17px; PADDING-RIGHT: 17px; OVERFLOW: =
hidden; PADDING-TOP: 15px
}
#editusersgroups .search {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 17px; PADDING-RIGHT: 17px; OVERFLOW: =
hidden; PADDING-TOP: 15px
}
#editgroupmembers .search {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 17px; PADDING-RIGHT: 17px; OVERFLOW: =
hidden; PADDING-TOP: 15px
}
#assignusersgroups .search {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 17px; PADDING-RIGHT: 17px; OVERFLOW: =
hidden; PADDING-TOP: 15px
}
#rights .search * {
	FLOAT: left
}
#userchooser .search * {
	FLOAT: left
}
#editusersgroups .search * {
	FLOAT: left
}
#editgroupmembers .search * {
	FLOAT: left
}
#assignusersgroups .search * {
	FLOAT: left
}
#rights .search INPUT[type=3Dtext] {
	WIDTH: 200px; HEIGHT: 18px
}
#userchooser .search INPUT[type=3Dtext] {
	WIDTH: 200px; HEIGHT: 18px
}
#editusersgroups .search INPUT[type=3Dtext] {
	WIDTH: 200px; HEIGHT: 18px
}
#editgroupmembers .search INPUT[type=3Dtext] {
	WIDTH: 200px; HEIGHT: 18px
}
#assignusersgroups .search INPUT[type=3Dtext] {
	WIDTH: 200px; HEIGHT: 18px
}
#assignusersgroups .search INPUT[type=3Dtext] {
	WIDTH: 150px
}
#rights .search .hw_button {
	MARGIN-TOP: -1px; MARGIN-RIGHT: 5px
}
#userchooser .search .hw_button {
	MARGIN-TOP: -1px; MARGIN-RIGHT: 5px
}
#editusersgroups .search .hw_button {
	MARGIN-TOP: -1px; MARGIN-RIGHT: 5px
}
#editgroupmembers .search .hw_button {
	MARGIN-TOP: -1px; MARGIN-RIGHT: 5px
}
#assignusersgroups .search .hw_button {
	MARGIN-TOP: -1px; MARGIN-RIGHT: 5px
}
#rights .search INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 5px; MARGIN-LEFT: 10px
}
#userchooser .search INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 5px; MARGIN-LEFT: 10px
}
#editusersgroups .search INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 5px; MARGIN-LEFT: 10px
}
#editgroupmembers .search INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 5px; MARGIN-LEFT: 10px
}
#assignusersgroups .search INPUT[type=3Dcheckbox] {
	MARGIN-TOP: 5px; MARGIN-LEFT: 10px
}
#rights .search LABEL {
	MARGIN-TOP: 2px
}
#userchooser .search LABEL {
	MARGIN-TOP: 2px
}
#editusersgroups .search LABEL {
	MARGIN-TOP: 2px
}
#editgroupmembers .search LABEL {
	MARGIN-TOP: 2px
}
#assignusersgroups .search LABEL {
	MARGIN-TOP: 2px
}
#rights .section > TABLE {
	WIDTH: 100%
}
#userchooser .section > TABLE {
	WIDTH: 100%
}
#editusersgroups .section > TABLE {
	WIDTH: 100%
}
#editgroupmembers .section > TABLE {
	WIDTH: 100%
}
#assignusersgroups .section > TABLE {
	WIDTH: 100%
}
#rights UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#userchooser UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#editusersgroups UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#editgroupmembers UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#assignusersgroups UL {
	LIST-STYLE-TYPE: none; LIST-STYLE-IMAGE: none
}
#rights UL LI {
	FLOAT: left; MARGIN-RIGHT: 10px
}
#userchooser UL LI {
	FLOAT: left; MARGIN-RIGHT: 10px
}
#editusersgroups UL LI {
	FLOAT: left; MARGIN-RIGHT: 10px
}
#editgroupmembers UL LI {
	FLOAT: left; MARGIN-RIGHT: 10px
}
#assignusersgroups UL LI {
	FLOAT: left; MARGIN-RIGHT: 10px
}
#miniebccontainer {
	MIN-HEIGHT: 55px
}
#miniebc {
	POSITION: relative; MIN-WIDTH: 200px; PADDING-BOTTOM: 10px; =
LINE-HEIGHT: 140%; MARGIN: 0px 10px 10px; MIN-HEIGHT: 30px; =
PADDING-LEFT: 50px; PADDING-RIGHT: 12px; BACKGROUND: #d4e4f7 0px 0px; =
COLOR: #00204d; CLEAR: both; OVERFLOW: hidden; PADDING-TOP: 12px; =
-moz-border-radius: 3px 3px 3px 3px
}
#miniebccontainer .image {
	BORDER-BOTTOM: #b6c8df 1px solid; POSITION: absolute; BORDER-LEFT: =
#b6c8df 1px solid; LINE-HEIGHT: 0px; BACKGROUND: =
url(../images/bg_userimage.png) #ffffff no-repeat 0px 0px; BORDER-TOP: =
#b6c8df 1px solid; TOP: 8px; BORDER-RIGHT: #b6c8df 1px solid; LEFT: 10px
}
.group#miniebccontainer .image {
	BACKGROUND-IMAGE: url(../images/bg_userimage.png)
}
#miniebccontainer .image IMG {
	BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; HEIGHT: 32px; =
BORDER-TOP: medium none; BORDER-RIGHT: medium none
}
#miniebccontainer H3 {
	LINE-HEIGHT: 100%; MARGIN: 0px; FONT-WEIGHT: bold
}
#miniebccontainer H3 A {
	FONT-WEIGHT: normal
}
#miniebccontainer UL {
	LIST-STYLE: none none outside; PADDING-BOTTOM: 0px; PADDING-LEFT: 0px; =
PADDING-RIGHT: 0px; PADDING-TOP: 0px
}
#miniebccontainer UL * {
	COLOR: #53719a
}
#miniebccontainer UL LI {
	DISPLAY: inline
}
#miniebccontainer UL LI STRONG {
	FONT-WEIGHT: normal
}
#miniebccontainer UL A {
	COLOR: #329ae5
}
#miniebccontainer H3 A {
	COLOR: #329ae5
}
#miniebccontainer UL A:hover {
	TEXT-DECORATION: underline
}
#PackagesDialogBody .hw_defaultdialogtable {
	WIDTH: 100%
}
#PackagesDialogBody #dialogbody {
	MIN-WIDTH: 700px
}
#PackagesDialogBody #listing TD {
	VERTICAL-ALIGN: top
}
#PackagesDialogBody #listing .warning {
	COLOR: #cc3300
}
#PackagesDialogBody #listing .warning A {
	COLOR: #cc3300; TEXT-DECORATION: underline
}
#SearchResults .SearchNavContainer {
	MARGIN-TOP: 5px; FLOAT: right
}
#mainframeHeaderBottom .SearchNav {
	COLOR: #001322
}
#SearchResults .SearchNav {
	COLOR: #001322
}
#dialogChooseTarget .SearchNav {
	COLOR: #001322
}
#mainframeHeaderBottom .SearchNavCurrent {
	COLOR: #cc3300; FONT-WEIGHT: bold
}
#SearchResults .SearchNavCurrent {
	COLOR: #cc3300; FONT-WEIGHT: bold
}
#dialogChooseTarget .SearchNavCurrent {
	COLOR: #cc3300; FONT-WEIGHT: bold
}
#mainframeHeaderBottom .SearchNavWidgets {
	FONT-FAMILY: "Andale Mono", "ms sans serif"; COLOR: #001322
}
#SearchResults .SearchNavWidgets {
	FONT-FAMILY: "Andale Mono", "ms sans serif"; COLOR: #001322
}
#dialogChooseTarget .SearchNavWidgets {
	FONT-FAMILY: "Andale Mono", "ms sans serif"; COLOR: #001322
}
#definitionBrowserDialog .hw_defaultdialogtable {
	WIDTH: 100%
}
#definitionBrowserDialog .TreeviewItemDefault A {
	COLOR: #001322
}
#definitionBrowserDialog .TreeviewItemSelected A {
	COLOR: #001322
}
#FormBrowserDialog .hw_defaultdialogtable {
	WIDTH: 100%
}
#FormBrowserDialog .TreeviewItemDefault {
	PADDING-LEFT: 1em
}
#FormBrowserDialog .hw_defaultdialogtable TD.empty {
	PADDING-LEFT: 1em
}
#FormBrowserDialog .TreeviewItemDefault A {
	COLOR: #001322
}
#FormBrowserDialog .TreeviewItemSelected A {
	COLOR: #001322
}
#FormBrowserDialog .hw_defaultdialogtable .description {
	LINE-HEIGHT: 120%; MARGIN-TOP: -0.2em; PADDING-LEFT: 20px; DISPLAY: =
block; WHITE-SPACE: normal; COLOR: #82888c; CLEAR: both
}
#managePDVersions #listing .version {
	TEXT-ALIGN: right
}
#managePDVersions #listing .lastcommitted .version A {
	PADDING-LEFT: 20px; BACKGROUND: url(../images/icon_currentversion.png) =
no-repeat 0px -1px
}
#managePDVersions #mainframeFooter {
	MIN-HEIGHT: 30px; PADDING-LEFT: 20px; OVERFLOW: hidden; BORDER-TOP: =
#d0e5f1 1px solid; PADDING-TOP: 10px
}
#CheckedOutDocuments #mainframeFooter {
	MIN-HEIGHT: 30px; PADDING-LEFT: 20px; OVERFLOW: hidden; BORDER-TOP: =
#d0e5f1 1px solid; PADDING-TOP: 10px
}
#EditLocally .hw_defaultdialogtable {
	WIDTH: 100%
}
#EditLocally #listing TR > TH:first-child {
	TEXT-ALIGN: left
}
#EditLocally #listing .button A {
	FLOAT: right
}
BODY.choosetarget .TreeviewItemDefault > A {
	WHITE-SPACE: nowrap
}
BODY.choosetarget .TreeviewItemDefault > B {
	WHITE-SPACE: nowrap
}
BODY.choosetarget .TreeviewItemDefault DIV {
	WHITE-SPACE: nowrap
}
BODY.choosetarget .TreeviewItemDefault DIV * {
	WHITE-SPACE: nowrap
}
BODY.choosetarget .TreeviewItemDefault A {
	COLOR: #001322
}
BODY.choosetarget .TreeviewItemDefault INPUT {
	MARGIN-TOP: 2px
}
BODY.choosetarget .TreeviewItemDefault IMG {
	PADDING-BOTTOM: 0px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
MARGIN-BOTTOM: -4px; PADDING-TOP: 0px
}
BODY.choosetarget #previewdiv {
	DISPLAY: none
}
.SearchDescription {
	COLOR: #001d4d
}
.SearchDescriptionWarning {
	MARGIN-TOP: 10px; COLOR: #cc3300
}
.SearchDescriptionError {
	PADDING-BOTTOM: 1em; PADDING-LEFT: 3em; PADDING-RIGHT: 3em; COLOR: =
#cc3300; FONT-WEIGHT: bold; PADDING-TOP: 1em
}
#AdvancedSearchDialog TABLE TABLE .AttrName {
	WIDTH: 12em
}
#AdvancedSearchDialog TABLE TABLE TABLE .AttrName {
	WIDTH: auto
}
#AdvancedSearchDialog TABLE TABLE {
	MARGIN-BOTTOM: 1em
}
#AdvancedSearchDialog TABLE TABLE TABLE {
	MARGIN-BOTTOM: 0px
}
#dialogChooseTarget .bold {
	BACKGROUND-IMAGE: none
}
#dialogChooseTarget .DocumentPreviewImage {
	PADDING-BOTTOM: 25px; PADDING-LEFT: 25px; PADDING-RIGHT: 25px; =
PADDING-TOP: 25px
}
#dialogChooseTarget .DocumentPreviewDocTitle {
	PADDING-BOTTOM: 25px; PADDING-LEFT: 0px; PADDING-RIGHT: 25px; =
FONT-SIZE: 160%; FONT-WEIGHT: bold; PADDING-TOP: 25px
}
#dialogChooseTarget .DocumentPreviewDocTitle {
	TEXT-ALIGN: left; FONT-SIZE: 160%; FONT-WEIGHT: bold
}
#dialogChooseTarget .DocumentPreview .DocumentPreviewInformation =
.attrName {
	TEXT-ALIGN: left; COLOR: #b1b1b1; FONT-WEIGHT: bold
}
#dialogChooseTarget .DocumentPreview .DocumentPreviewInformation =
.attrName {
	PADDING-TOP: 0px
}
#dialogChooseTarget .DocumentPreview .DocumentPreviewInformation =
.attrValue {
	PADDING-TOP: 0px
}
#dialogChooseTarget .ListingTitle {
	WIDTH: 100%
}
#dialogChooseTarget .ListingCollectionIsEmpty {
	DISPLAY: block
}
#dialogChooseTarget .TooManyItemsWarning .ListingCollectionIsEmpty {
	MARGIN-TOP: 0.5em; PADDING-LEFT: 35px; BACKGROUND: =
url(../images/info_large.gif) no-repeat -5px 13px; MARGIN-LEFT: 2em
}
#dialogChooseTarget .TooManyItemsTitle {
	FONT-WEIGHT: bold
}
#dialogChooseTarget #listingPagingTop {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 25px; PADDING-RIGHT: 25px; =
PADDING-TOP: 5px
}
#dialogChooseTarget #listingPagingTop {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 25px; PADDING-RIGHT: 25px; =
PADDING-TOP: 5px
}
.DatechooserHeader {
	BORDER-BOTTOM: #9dbfeb 1px solid; TEXT-ALIGN: center; WIDTH: 5em; =
BACKGROUND: url(../images/bg_listingheader.gif) #bdd3ec repeat-x 0px =
0px; BORDER-TOP: #dce7f8 1px solid
}
.DatechooserHeaderDay {
	PADDING-BOTTOM: 3px; DISPLAY: block; COLOR: #001d4d; FONT-WEIGHT: =
normal; TEXT-DECORATION: none; PADDING-TOP: 2px
}
.DatechooserBody {
	BORDER-BOTTOM: #9dbfeb 1px solid; BORDER-LEFT: #9dbfeb 1px solid; =
WIDTH: 35em; BORDER-TOP: #9dbfeb 1px solid; BORDER-RIGHT: #9dbfeb 1px =
solid
}
.NoDatechooserItem {
	BORDER-BOTTOM: #ffffff 1px solid; TEXT-ALIGN: right; BORDER-LEFT: =
#ffffff 1px solid; LINE-HEIGHT: 2.1em; WIDTH: 5em; HEIGHT: 2em; =
BORDER-TOP: #ffffff 1px solid; BORDER-RIGHT: #ffffff 1px solid
}
.DatechooserItemDisabled {
	BORDER-BOTTOM: #ffffff 1px solid; TEXT-ALIGN: right; BORDER-LEFT: =
#ffffff 1px solid; LINE-HEIGHT: 2.1em; WIDTH: 5em; HEIGHT: 2em; =
BORDER-TOP: #ffffff 1px solid; BORDER-RIGHT: #ffffff 1px solid
}
.DatechooserItemToday {
	BORDER-BOTTOM: #ffffff 1px solid; TEXT-ALIGN: right; BORDER-LEFT: =
#ffffff 1px solid; LINE-HEIGHT: 2.1em; WIDTH: 5em; HEIGHT: 2em; =
BORDER-TOP: #ffffff 1px solid; BORDER-RIGHT: #ffffff 1px solid
}
.NoDatechooserItem {
	BACKGROUND: #ffffff 0px 0px
}
.DatechooserItemToday {
	BORDER-BOTTOM: #f18e00 1px solid; BORDER-LEFT: #f18e00 1px solid; =
BACKGROUND-COLOR: #fae7a6; BORDER-TOP: #f18e00 1px solid; BORDER-RIGHT: =
#f18e00 1px solid
}
.DatechooserItemDisabled {
	BORDER-BOTTOM: #e8effa 1px solid; BORDER-LEFT: #e8effa 1px solid; =
BACKGROUND-COLOR: #e8effa; BORDER-TOP: #e8effa 1px solid; BORDER-RIGHT: =
#e8effa 1px solid
}
A.DatechooserItem {
	PADDING-RIGHT: 0.3em; DISPLAY: block; COLOR: #000000; TEXT-DECORATION: =
none
}
A.DatechooserSelected {
	PADDING-RIGHT: 0.3em; DISPLAY: block; COLOR: #000000; TEXT-DECORATION: =
none
}
A.DatechooserSelected {
	BACKGROUND: #f6d04e 0px 0px
}
A.DatechooserItem:hover {
	BACKGROUND: #fae7a6 0px 0px; TEXT-DECORATION: none
}
A.DatechooserSelected:hover {
	BACKGROUND: #fae7a6 0px 0px; TEXT-DECORATION: none
}
.HWBrowseIframe {
	BACKGROUND-COLOR: #ffffff; WIDTH: 100%; VERTICAL-ALIGN: top
}
.HWBrowseIframeContent {
	PADDING-BOTTOM: 0px; BACKGROUND-COLOR: #ffffff; PADDING-LEFT: 20px; =
PADDING-RIGHT: 20px; HEIGHT: 100%; PADDING-TOP: 0px
}
* HTML .HWBrowseIframeContent {
	BORDER-BOTTOM: #7f9db9 1px solid; BORDER-LEFT: #7f9db9 1px solid; =
BORDER-TOP: #7f9db9 1px solid; BORDER-RIGHT: #7f9db9 1px solid
}
.HWBrowseButtonContainer {
	POSITION: absolute; MARGIN-TOP: -50px; MARGIN-LEFT: -13px; TOP: 50%; =
LEFT: 50%
}
.CommandLink {
	MARGIN: 1px 10px 2px 0px; WHITE-SPACE: nowrap
}
.CommandLink IMG {
	MARGIN-RIGHT: 3px
}
.CommandLink A {
	TEXT-DECORATION: underline
}
.CommandLink A:active {
	COLOR: #ff6600
}
.ControlDisabled {
	BACKGROUND-COLOR: #cddae7
}
.SpacerLeft {
	MARGIN-LEFT: 10px
}
.AccessKey {
	TEXT-DECORATION: underline
}
.AttrName {
	TEXT-ALIGN: right; PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; =
PADDING-RIGHT: 5px; WHITE-SPACE: nowrap; VERTICAL-ALIGN: top; =
PADDING-TOP: 5px
}
.AttrValue {
	TEXT-ALIGN: left; PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; =
PADDING-RIGHT: 5px; VERTICAL-ALIGN: top; PADDING-TOP: 5px
}
#ColorTable LI {
	FLOAT: left; CLEAR: both
}
#ColorTable LI LI {
	BORDER-BOTTOM: #000000 1px solid; WIDTH: 22px; HEIGHT: 22px; CLEAR: =
none; CURSOR: pointer; BORDER-RIGHT: #000000 1px solid
}
#ColorTable .ClearColor {
	BACKGROUND: url(../images/icon_transparent.gif) #ffffff no-repeat 0px =
0px
}
#ColorTable {
	LIST-STYLE: none none outside; PADDING-BOTTOM: 0px; BACKGROUND-COLOR: =
#000000; MARGIN: 0px; PADDING-LEFT: 0px; WIDTH: 368px; PADDING-RIGHT: =
0px; FLOAT: left; CLEAR: both; PADDING-TOP: 0px
}
#ColorTable UL {
	LIST-STYLE: none none outside; PADDING-BOTTOM: 0px; BACKGROUND-COLOR: =
#000000; MARGIN: 0px; PADDING-LEFT: 0px; WIDTH: 368px; PADDING-RIGHT: =
0px; FLOAT: left; CLEAR: both; PADDING-TOP: 0px
}
#ColorTable {
	PADDING-LEFT: 1px; PADDING-TOP: 1px
}
#ColorTableColor {
	MARGIN-TOP: 1.5em; FLOAT: left; CLEAR: both
}
#SelectedColor {
	BORDER-BOTTOM: #708bb3 1px solid; BORDER-LEFT: #708bb3 1px solid; =
WIDTH: 16px; FLOAT: left; HEIGHT: 16px; MARGIN-LEFT: 0.2em; BORDER-TOP: =
#708bb3 1px solid; MARGIN-RIGHT: 0.3em; BORDER-RIGHT: #708bb3 1px solid
}
.ColorChooser {
	BACKGROUND-IMAGE: url(../images/icon_colorchooser.gif); WIDTH: 20px; =
BACKGROUND-REPEAT: no-repeat; BACKGROUND-POSITION: 0px 0px; HEIGHT: =
20px; CURSOR: pointer
}
.SortOrderListing SELECT {
	MARGIN: 1em 0px; WIDTH: 440px
}
.SortOrderListing SELECT OPTION {
	PADDING-BOTTOM: 0.2em; PADDING-LEFT: 0.4em; PADDING-RIGHT: 0.4em; =
PADDING-TOP: 0.2em
}
.AttachmentListing {
	LIST-STYLE: none none outside; PADDING-BOTTOM: 0px; MARGIN: 0px; =
PADDING-LEFT: 0px; PADDING-RIGHT: 0px; PADDING-TOP: 0px
}
.horizontal.AttachmentListing {
	FLOAT: left
}
.horizontal.AttachmentListing LI {
	PADDING-RIGHT: 1em; WHITE-SPACE: nowrap; FLOAT: left
}
.UserWizardRow {
	TEXT-ALIGN: left; PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; =
PADDING-RIGHT: 5px; WHITE-SPACE: nowrap; VERTICAL-ALIGN: top; =
FONT-WEIGHT: bold; PADDING-TOP: 5px
}
.Warning {
	COLOR: #cc3300
}
.AttrValue BUTTON {
	FONT-SIZE: 100%
}
.Normal {
	FONT-WEIGHT: normal
}
.Bold {
	FONT-WEIGHT: bold
}
.EbcAttrName {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
WHITE-SPACE: nowrap; VERTICAL-ALIGN: top; PADDING-TOP: 5px
}
.EbcAttrValue {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 5px; PADDING-RIGHT: 5px; =
WHITE-SPACE: nowrap; PADDING-TOP: 5px
}
.EbcAttrValueIndented {
	PADDING-BOTTOM: 5px; PADDING-LEFT: 20px; PADDING-RIGHT: 5px; =
WHITE-SPACE: nowrap; PADDING-TOP: 0px
}
.EbcWarning {
	PADDING-LEFT: 20px; COLOR: gray
}
.imagecontainer {
	MAX-WIDTH: 86px; MAX-HEIGHT: 110px
}
.imagecontainer IMG {
	MAX-WIDTH: 86px; MAX-HEIGHT: 110px
}
.imagecontainer {
	PADDING-BOTTOM: 12px; PADDING-LEFT: 12px; WIDTH: 98px; PADDING-RIGHT: =
12px; BACKGROUND: url(../images/bg_userimage.png) no-repeat 0px 0px; =
HEIGHT: 122px; PADDING-TOP: 12px
}
* HTML .imagecontainer {
	WIDTH: 110px; HEIGHT: 134px
}
#upbutton {
	POSITION: relative; MARGIN-TOP: 3px; WIDTH: 16px; BACKGROUND: =
url(../images/icon_up.png) no-repeat 0px 0px; FLOAT: left; HEIGHT: 16px; =
CURSOR: pointer
}
.newsticker {
	TEXT-ALIGN: center; WIDTH: 100%; MARGIN-BOTTOM: 2px; HEIGHT: 19px; =
OVERFLOW: hidden; BORDER-TOP: #aaaaaa 1px solid
}
.newsdate {
	MARGIN-LEFT: 20px
}
.newsdescription {
	MARGIN-LEFT: 20px
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/css/master.css?cachekeY=515488b2-en

@import url( hw_master.css );
* + HTML #listing .description {
	MIN-WIDTH: 95%
}
.hw_button SPAN {
	BACKGROUND: url(../images/hw_button_primary.png) no-repeat 0px 0px; =
COLOR: #fff
}
.has_submit_button.buttons > .hw_button:first-child SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
.has_submit_button.buttons > .hw_button:first-child SPAN SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.png); COLOR: #fff
}
* + HTML #dialogbody .hw_button SPAN {
	BACKGROUND-IMAGE: url(../images/hw_button_primary.gif); =
background-width: 90%
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/portal/ui/portal.css?cachekeY=515488b2-en

#tabbar LI.role_tab A {
	BACKGROUND-IMAGE: =
url(../../../uistyle/hwdefault/portal/bg_tab_role.png); WHITE-SPACE: =
nowrap
}
#tabbar LI.role_tab SPAN {
	BACKGROUND-IMAGE: =
url(../../../uistyle/hwdefault/portal/bg_tab_role.png); WHITE-SPACE: =
nowrap
}
#tabbar LI.role_tab A {
	PADDING-LEFT: 23px
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/css/erms_menu.css?cachekeY=515488b2-en

.hw_menu .hw_erms_record_unfreeze SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_record_freeze SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_declassification_review SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_declare_record SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_undeclare_record SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_reopen_closed_part SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_close_part SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_set_event_date SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_review SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_upgrade_content SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_upgrade_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_unlock_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_lock_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_activate_class SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_close_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_folder_freeze SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_folder_unfreeze SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_record_freeze_reason SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_reopen_closed_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_deactivate_class SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_new_class SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_new_part SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_record SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_new_folder SPAN {
	PADDING-LEFT: 26px
}
.hw_menu .hw_erms_new_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_addfolder=
.png)
}
.hw_menu .hw_erms_record SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_addrecord=
.png)
}
.hw_menu .hw_erms_new_part SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_addpart.p=
ng)
}
.hw_menu .hw_erms_new_class SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_addclass.=
png)
}
.hw_menu .hw_erms_new_review SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_review.pn=
g)
}
.hw_menu .hw_erms_deactivate_class SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_deactivat=
e.png)
}
.hw_menu .hw_erms_folder_freeze SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_freezefol=
der.png)
}
.hw_menu .hw_erms_folder_unfreeze SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_unfreezef=
older.png)
}
.hw_menu .hw_erms_record_freeze_reason SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_freezerec=
ord.png)
}
.hw_menu .hw_erms_close_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_closefold=
er.png)
}
.hw_menu .hw_erms_reopen_closed_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_openfolde=
r.png)
}
.hw_menu .hw_erms_activate_class SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_activate.=
png)
}
.hw_menu .hw_erms_lock_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_lock.png)=

}
.hw_menu .hw_erms_unlock_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_unlock.pn=
g)
}
.hw_menu .hw_erms_upgrade_folder SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_upgrade.p=
ng)
}
.hw_menu .hw_erms_upgrade_content SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_upgrade.p=
ng)
}
.hw_menu .hw_erms_review SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_review.pn=
g)
}
.hw_menu .hw_erms_close_part SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_closepart=
.png)
}
.hw_menu .hw_erms_reopen_closed_part SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_openpart.=
png)
}
.hw_menu .hw_erms_undeclare_record SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_undeclare=
record.png)
}
.hw_menu .hw_erms_declare_record SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_declarere=
cord.png)
}
.hw_menu .hw_erms_set_event_date SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_setevenda=
te.png)
}
.hw_menu .hw_erms_declassification_review SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_review.pn=
g)
}
.hw_menu .hw_erms_record_freeze SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_freezerec=
ord.png)
}
.hw_menu .hw_erms_record_unfreeze SPAN {
	BACKGROUND-IMAGE: =
url(/wavemaster.internal/webapp/components/erms/images/icons/tb_unfreezer=
ecord.png)
}

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: multipart/alternative;
	boundary="----=_NextPart_001_0017_01CE307B.33382030"







------=_NextPart_001_0017_01CE307B.33382030
mime-version: 1.0
content-type: text/html;
	charset="utf-8"
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/Documents/Users/JamesHyde;
	internal&Parameter=1364985030155&action=buildframes.action

=EF=BB=BF<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "h=
ttp://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML xmlns:mso=3D"urn:schemas-microsoft-com:office:office" xmlns:msdt=3D"=
uuid:C2F41010-65B3-11d1-A29F-00AA00C14882"><HEAD><META content=3D"IE=3D8.0=
000" http-equiv=3D"X-UA-Compatible">
<TITLE></TITLE>
<META content=3D"text/html; charset=3Dutf-8" http-equiv=3DContent-Type>
<SCRIPT>HW_Staticframe =3D frames.HW_Staticframe =3D window;</SCRIPT>
<LINK rel=3D"SHORTCUT ICON"=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/icons/favicon=
.ico?cachekeY=3D515488b2-en">
<META content=3D0 http-equiv=3Dexpires><LINK rel=3Dstylesheet type=3Dtext/=
css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/css/com/hyperwave/dialogs/dialog.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
prototype/prototype.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
ojs/Object.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/hw.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/util/IncludeManager.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript>hw.util.IncludeManager.static_.getInstance(=
).setUnique("515488b2-en").setPrefix("/wavemaster.internal/").setPlacehold=
er("vd", "webapp").setPlaceholder("sp", "/wavemaster.internal/webapp/uisty=
le/hwdefault");</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/csl=
ib.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3Dlib%2Fc=
lientlib%2Fcom%2Fhyperwave%2Fframework%2Fhtmlres%2FFramework.xml&amp;cache=
keY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3Dlib%2Fc=
lientlib%2Fcom%2Fhyperwave%2Fframework%2Flangres%2FFramework.%25lang%25.xm=
l&amp;cachekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/framework/Framework.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.framework_6_1221"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/framework/DisplayManager.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.framework_6_1221"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/framework/BaseMediator.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.framework_6_1221"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/util/Clipboard.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.clipboard_1_141"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/BaseDialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/Dialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/IframeDialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/IframePopupDialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/Prompt.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/Message.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/Confirm.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/UserChooserDialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/PopupDialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/Button.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/dialogs/CloseButton.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.dialogs_11_1605"></SCRIPT>

<SCRIPT>
var fw =3D hw.framework.Framework.static_.setAsRoot();
</SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/frameset/htmlres/buildframes.css?cachekeY=3D515488b2-en"><LINK=20
rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/css/com/hyperwave/framework/framework.css?cachekeY=3D515488b2-=
en"><LINK=20
rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/css/displayareafooter.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/util/KeyValueMap.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/util/Object.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/ui/SelectionModel.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/util/Url.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/frameset/code/FrameSetMediator.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/standardpage/code/csframesetscripts.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSB=
readCrumbing.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSS=
croller.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSB=
readCrumbingX.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSO=
bjectCache.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSL=
angresServer.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/frameset/code/SearchElement.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/frameset/code/MainFilterElement.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/frameset/code/setDateCookie.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/dyn=
amic_reloading.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Fcomponents%2Fframeset%2Fhtmlres%2Fcsbuildframes.xml&amp;cachekeY=3D515=
488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Fcomponents%2Fstandardpage%2Flangres%2Fmodifyalertmsgs.%25lang%25.xml&a=
mp;cachekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Fcomponents%2Fframeset%2Flangres%2Fbuildframes.%25lang%25.lrc&amp;cache=
keY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
ojs/Event.js?cachekeY=3D515488b2-en"=20
concatid=3D"ojs_3_378"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
ojs/EventSource.js?cachekeY=3D515488b2-en"=20
concatid=3D"ojs_3_378"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
ojs/Exception.js?cachekeY=3D515488b2-en"=20
concatid=3D"ojs_3_378"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
lang/Exception.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/AbstractCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/AbstractResource.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/AbstractResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/CSResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/DebugCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ForCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/IfCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/IterateCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/PlaceCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/WithCmd.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/MapStack.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ResourceException.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/Resource.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ResourceManagerIFC.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ResourceManager.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ScopedMap.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/ServerResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/SkinXMLResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/Template.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/XMLResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
com/hyperwave/res/XMLServerResourceReader.js?cachekeY=3D515488b2-en"=20
concatid=3D"hw.res_23_3318"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
com/hyperwave/util/WebParameters.js?cachekeY=3D515488b2-en"=20
concatid=3D"buildframes.html_23_21_7271"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {
(function (theUserId, theUserDescr, theUserOutOfOffice) {
    var fw =3D com.hyperwave.framework.Framework.static_.getInstance();
    fw.setApplicationProperty("eks", "userid", theUserId);
    fw.setApplicationProperty("eks", "userdescr", theUserDescr);
    fw.setApplicationProperty("eks", "useroutofoffice", theUserOutOfOffice=
);
}).apply(this, ["JamesHy", "James Hyde", false]);
(function () {
    name =3D "HW_Mainwindow";
}).call(this);
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/dat=
efunctions.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.datefunctions_1_123"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {
(function (theDateFormatName) {
    HW_UI_UseLocalDate =3D true;
    HW_UI_ConvertGMTLocalGMT =3D true;
    HW_UI_Date =3D g_dates.getFormat(theDateFormatName);
}).apply(this, ["HWDate"]);
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/csv=
iew_lib.js?cachekeY=3D515488b2-en"=20
concatid=3D"sslisting.js_135_4_808"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSC=
ollectionListing.js?cachekeY=3D515488b2-en"=20
concatid=3D"sslisting.js_135_4_808"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Flib%2Fhtmlres%2Flisting.%25style%25.xml&amp;cachekeY=3D515488b2-en"></=
SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Flib%2Flangres%2Flisting_text.%25lang%25.xml&amp;cachekeY=3D515488b2-en=
"></SCRIPT>

<SCRIPT type=3Dtext/javascript>
  // get the collection listing texts from server
  var cslisting_reader =3D hw.util.IncludeManager.static_.getResource("%vd=
%/lib/htmlres/listing.%style%.xml");
  var cslisting_texts =3D hw.util.IncludeManager.static_.getResource("%vd%=
/lib/langres/listing_text.%lang%.xml");

  // create resource for collection listing (CS)
  var cslisting_res =3D new com.hyperwave.res.Resource({templateKey_: "mai=
n"});
  cslisting_res.makeRoot();

  // assign all templates from server (text and HTML)
  cslisting_res.readAll( cslisting_reader );
  cslisting_res.readAll( cslisting_texts );
</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CST=
reeview.js?cachekeY=3D515488b2-en"=20
concatid=3D"ssnavigation.js_26_2_398"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Flib%2Fhtmlres%2Ftreeview.%25style%25.xml&amp;cachekeY=3D515488b2-en"><=
/SCRIPT>

<SCRIPT type=3Dtext/javascript>
  var cstreeview_reader =3D hw.util.IncludeManager.static_.getResource("%v=
d%/lib/htmlres/treeview.%style%.xml");
  var cstreeview_res =3D new com.hyperwave.res.Resource( {templateKey_:"ma=
in"} );
  cstreeview_res.makeRoot();
  cstreeview_res.readAll( cstreeview_reader );
</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/standardpage/code/CSFooter.js?cachekeY=3D515488b2-en"=20
concatid=3D"footer.js_183_3_744"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Fcomponents%2Fstandardpage%2Fhtmlres%2Fcsfooter.%25style%25.xml&amp;cac=
hekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/hw_temporary_objects;internal&amp;=
action=3Djs.execute.action&amp;Parameter=3D%23%28UIClass%3Acom.hyperwave.u=
til.IncludeManager%29%28Method%3Astatic_.getResource%29&amp;file=3D%25vd%2=
5%2Fcomponents%2Fstandardpage%2Flangres%2Ffooter_txt.%25lang%25.xml&amp;ca=
chekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript>
  // create resource for collection footer (CS)
  var csfooter_res =3D new com.hyperwave.res.Resource( {templateKey_:"main=
"} );
  csfooter_res.makeRoot();
  // assign all templates from server (text and HTML)
  csfooter_res.readAll(hw.util.IncludeManager.static_.getResource("%vd%/co=
mponents/standardpage/htmlres/csfooter.%style%.xml"));
  csfooter_res.readAll(hw.util.IncludeManager.static_.getResource("%vd%/co=
mponents/standardpage/langres/footer_txt.%lang%.xml"));
</SCRIPT>

<SCRIPT type=3Dtext/javascript>
  top.request_objectpath =3D '/Documents/Users/JamesHyde';

  reloadRef=3D"top.HW_Mainframe.";
  var gToff=3Dnew Date().getTimezoneOffset()/60;
  if (gToff>12) gToff=3DgToff-24;
  setCookie('HW_GMTOff',gToff)
  setDateCookie();

  function BCSelectFunc (breadCrumbingLine, aPosition, aGOid)
  {
    var path =3D top.gBreadCrumb.getPath();
    var new_path =3D [];
    for (var path_count=3D0; path_count<aPosition; path_count++) {
      new_path[new_path.length] =3D top.gObjectCache.getObject(path[path_c=
ount].G || path[path_count].goid);
    }

    top.cs_lib_ld(aGOid, new_path);
    return false;
  }

  top.gObjectCache =3D new CSObjectCache();
  var params =3D {};
  params.server_function_name =3D "navigateTreeview";
  params.frame_reload_function =3D "top.reload_navigation()";
  params.navigation_id =3D ("" || "/");
  params.indent =3D 20;
  params.variable_name =3D 'top.gTreeview';
  params.output_frame =3D 'top.frames.HW_Subframe.frames.HW_Navigationfram=
e';
  params.onclick =3D 'top.cs_lib_ld';
  params.multiple_open =3D true;
  params.show_system_objects =3D false;
  top.gTreeview =3D new CSTreeview(top.gObjectCache, params);
  top.cslisting_config =3D {friendlyname:true,show_system_objects:false};
  top.gListing       =3D new CSCollectionListing(top.gObjectCache, 'HW_Mai=
nframe',top.cslisting_config);
  top.gBreadCrumb    =3D new CSBreadCrumbingX();
  top.gLangresServer =3D new CSLangresServer();
  top.gPostFixForServer =3D "80010cb580";
  top.gUIStylePath=3D"/wavemaster.internal/webapp/uistyle/hwdefault";
  top.gFileExtensionExclusionList =3D ({pdf:true, html:true, htm:true});
  top.gRemoteDocumentsInNewWindow =3D false;
  // FR9.2 treeview presentation attriute
  top.tv_hw_ui =3D false;
  top.HW_treeview_unique=3D{};
var url_base=3D"/";
  top.gLangresServer.registerReader("stdp",
    hw.util.IncludeManager.static_.getResource("%vd%/components/standardpa=
ge/langres/modifyalertmsgs.%lang%.xml"));
  top.editmode =3D true;

  function updateUpButtonState() {
    if (top.search_up_in_progress) {
      top.setTimeout("top.updateUpButtonState()", 250);
    }
    else {
      var aTmpPath =3D top.gTreeview.getCurrentPath();
      if (aTmpPath.length > 1) {
        $(fw.static_.UPBUTTON).show();
 =20
        var obj =3D aTmpPath[aTmpPath.length - 2];
        var res =3D hw.util.IncludeManager.static_.getResource("%vd%/compo=
nents/frameset/langres/buildframes.%lang%.lrc");
        $(fw.static_.UPBUTTON).title =3D res.getRes("butLbl2") + ' "' + ob=
j.T  + '"';
        $(fw.static_.UPBUTTON).href =3D obj.U;
      }
      else {
        $(fw.static_.UPBUTTON).hide();
      }
    }
  }

  function getGoUpUrl(new_obj) {
    var new_loc =3D new_obj.U;
    var separator =3D ";internal&";
    if (new_obj.U.search(/;internal&/i) !=3D -1 || new_obj.U.search(/\?/i)=
 !=3D -1) {
      separator =3D "&";
    }
    if (new_obj.CTX) {
      new_loc +=3D separator + "ctx=3D" + new_obj.CTX;
    }
    return new_loc;
  }

  function goUp()
  {
    if (top.search_up_in_progress)
    {
      top.go_up_timeout =3D top.setTimeout("top.goUp()", 250);
      top.onUnload =3D "if (top.go_up_timeout) top.clearTimeout(top.go_up_=
timeout);";
      return;
    }
    else if (top.go_up_timeout)
    {
      top.clearTimeout(top.go_up_timeout);
    }

    // check whether currently displayed page overrides the standard goUp-=
function
    var use_default_go_up =3D true;
    try {
      if (typeof HW_Mainframe.goUp =3D=3D "function")
      {
        use_default_go_up =3D false
        HW_Mainframe.goUp();
      }
    } catch (e) {
      // use standard goUp
    }

    if (use_default_go_up) {
      var aTmpPath =3D top.gTreeview.getCurrentPath();
      if (aTmpPath.length > 1)
      {
        aTmpPath.length --;
        HW_Mainframe.location =3D getGoUpUrl(aTmpPath[aTmpPath.length - 1]=
);
        top.gTreeview.setNextPath(aTmpPath, true);
      }
    }
  }

  var debug =3D false;
  function debugWindow(aString) {

    if (!debug)
      return;
    aString +=3D "";
    if (typeof top.debug_window_document=3D=3D"undefined") {

      var debug_window =3D window.open("","debugWindow","menubar=3Dno, too=
lbar=3Dno, screenX=3D0, width=3D400, height=3D800, scrollbars=3Dyes");
      top.debug_window_document =3D debug_window.document;
    }
    top.debug_window_document.writeln("<nobr><font size=3D\"-3\">"+aString=
.replace(/</g,'&lt;').replace(/>/g,'&gt;')+"</font></nobr><br>");
    if (top.debug_window_document.body)
      top.debug_window_document.body.scrollTop =3D 1000000;
  }

  function restore_frameset () {

    to_do_frames_arr =3D [top.frames];
    while (to_do_frames_arr.length>0) {

      var cur_frames_arr =3D to_do_frames_arr.pop();
      for (var cnt=3D0; cnt<cur_frames_arr.length; cnt++) {

        if (cur_frames_arr[cnt].name)
          cur_frames_arr[cur_frames_arr[cnt].name] =3D cur_frames_arr[cnt];
        to_do_frames_arr.push(cur_frames_arr[cnt].frames);
      }
    }
  }

</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/csd=
ialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"dialogscripts.js_238_1_118"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {
(function (theWindowNamePostfixForServer) {
    top.gPostFixForServer =3D theWindowNamePostfixForServer;
}).apply(this, ["80010cb580"]);
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/config/=
dmc.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/menu_dc/code/menucommon.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/menu_dc/code/menu.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle=
/hwdefault/mstyle.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/menu_dc/code/openclosemenudom.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/menu_dc/code/menudom.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/menu_dc/code/keyfunctions.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT>
var hwfs =3D "init";
var mstyle =3D "" || "hwblue";
var nsbform =3D false;

var mbarst =3D typeof mbstyle !=3D "undefined" ? mbstyle : DMC;
var mitemst =3D typeof mitstyle !=3D "undefined" ? mitstyle : DMC;

var object_tags =3D [];
addToOnload(function () {
  // in msie menus are hidden behind oject tags
  if (navigator.appVersion.indexOf("MSIE") !=3D -1)
  {
    object_tags =3D $$("object");
    if (object_tags.length)
    {
      hw.getFramework().getDisplayManager().addHideLayer($(document.body));
    }
  }
});
addToOnunload(function () {
  // in msie menus are hidden behind oject tags
  if (navigator.appVersion.indexOf("MSIE") !=3D -1)
  {
    if (object_tags.length)
    {
      hw.getFramework().getDisplayManager().remHideLayer($(document.body));
    }
  }
});

</SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/css/master.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/hw_=
swapimages.js?cachekeY=3D515488b2-en"=20
concatid=3D"userblock.html_4_1_123"></SCRIPT>

<SCRIPT>
top.lastcollection =3D "0x80010cb5_0x000008d1";
top.editmode =3D true;
var user_id =3D "JamesHy";

// makes Function available to other frames
top.opDlg =3D opDlg;
if (top.HW_Navigationframe)=20
{=20
  top.HW_Navigationframe.opDlg =3D opDlg;=20
}

function openpreferences() {
  opDlg('/;internal&action=3Ddialog.preferences.action','dialogs');
}
function openebc(event) {
  var event=3DEvent.extend(event);
  if (event.shiftKey)
  {
    hwidentify();
  }
  else
  {
    opDlg('/;internal&action=3Ddialog.ebc.action&Parameter=3Duid=3D' + enc=
odeURIComponent(user_id),'dialogs');
  }
}

// The following methods control the behaviour of the help button=20
// (context sensitive help)
HelpButtonMediator =3D function () {
  this.url_ =3D null;
}

HelpButtonMediator.setUrl =3D function (aUrl) {
  this.url_ =3D aUrl;
}
 =20
HelpButtonMediator.openHelp =3D function () {
  if (this.url_)=20
    opDlg(this.url_,'HelpWindow');
  else
    opDlg('/;internal&action=3Ddialog.mainhelp.hw_bhelp','HelpWindow');
  return false;
}
var fw =3D hw.getFramework();
fw.registerUIElement(fw.static_.HELPBUTTON, HelpButtonMediator);
 =20
function hwidentify(e) {
  if (e && e.shiftKey) {
    e.cancelBubble=3Dtrue;
  }
  var href =3D "/;internal&action=3Ddialog.login.action&Parameter=3D136499=
7290623";
  opDlg(href,'identify',{height: 300, width: 600});
}

function logout (e) {

  // --> eCS 1.5
  top.rebuildeCSMenu =3D false;   // dont rebuild eCS-Menu in Coll-Listing
 =20
  if (top.wndAVCtrl !=3D null) {
     top.wndACVCtrl.close();
     top.wndACVCtrl =3D null;
  }
 =20
  if (top.wndeCSHlp !=3D null) {
      top.wndeCSHlp.close();
      top.wndeCSHlp =3D null;
  }
 =20
  if (top.wndeCSMain !=3D null) {
     top.wndeCSMain.eCSCloseClient();
     top.wndeCSMain =3D null;
  }
  // <-- eCS

  // if ssl client certificate identification is active
  // prevent automatic login via ssl client certificate again
  if (getCookie("hw_sslclientcertificate") =3D=3D "true")
  {
    setCookie("HW_AuthentificationControl","no-sslclientcertificate",null);
    setCookie("hw_sslclientcertificate","",null);
  }

  if (e && e.shiftKey) {
    e.cancelBubble=3Dtrue;
    hwidentify();
    return false;
  }

  var negative_date =3D new Date(0);
  setCookie("sk", "", negative_date);
setCookie("HW_POOL_SELECTOR", "", negative_date);
setCookie("NTLM", "false", null);
  var href =3D "/;internal&action=3Dlogout.action&Parameter=3D136499729062=
3";
  if (top.frames.HW_DataRequestFrame)
    top.frames.HW_DataRequestFrame.location.replace(href);
  else
    location.replace(href);
  return false;
}

var search_alert1 =3D 'Please enter a search term and click \'Search\' aga=
in or\nclick Advanced Search for more detailed search options.';
var search_alert5 =3D 'Search string must be at least three characters lon=
g';
function onLoadLogin() {
}
</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSF=
ormData.js?cachekeY=3D515488b2-en"=20
concatid=3D"userblock.html_172_3_385"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/Par=
ameterHandler.js?cachekeY=3D515488b2-en"=20
concatid=3D"userblock.html_172_3_385"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/search/code/CSSearch.js?cachekeY=3D515488b2-en"=20
concatid=3D"userblock.html_172_3_385"></SCRIPT>

<SCRIPT>
m1=3Dnew Menu("UserblockMenu",({close:true, showdisabledicons:true}));
m1.add("Preferences...",({exec:"openpreferences()", cssclass:"hw_preferenc=
es", selectionminimum:-1, selectionmaximum:1000000}));
m1.addSep();
m1.add("Authoring",({exec:"FrameSetMediator.static_.getInstance().switchEd=
itMode()", cssclass:"hw_authoring", selectionminimum:-1, selectionmaximum:=
1000000}));
m1.add("My&nbsp;Workspaces",({url:"/Documents/Users/JamesHyde;internal&act=
ion=3Djs.execute.action&Parameter=3D%23%28UIClass%3AHW_TeamWorkspaceUI%29%=
28Method%3AshowMyWorkspaces%29&ctx=3DGOid_0x80010cb5_0x000005b0", targetmu=
lt:"dialogs", target:"dialogs", selectionminimum:-1, selectionmaximum:1000=
000}));
m1.add("My&nbsp;Subscriptions",({targetmult:"dialogs", target:"dialogs", a=
ct:"dialog.showsubscriptions", selectionminimum:-1, selectionmaximum:10000=
00}));
m1.addSep();
m1.add("Help",({exec:"HelpButtonMediator.openHelp()", cssclass:"hw_help", =
selectionminimum:-1, selectionmaximum:1000000}));
m1.addSep();
m1.add("Logout",({exec:"logout()", shiftexec:"hwidentify()", cssclass:"hw_=
logout", selectionminimum:-1, selectionmaximum:1000000}));

top.userblock_menuname =3D "m1";
addToOnunload(function () { m1.destructor(); });
function openUserblockMenu () {
  openMenu(-1,-1,{mname: top.userblock_menuname, oname:'userblockmenu', yp=
:'b', xp:'l', ma:'l', h:false, event: self.event||arguments[0], element: t=
his});
}
</SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/portal/ui/portal.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/bookmarks/code/csjs/BookmarksMediator.js?cachekeY=3D515488b2-en"></SCR=
IPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/editlocally/code/csjs/EditLocallyDialogController.js?cachekeY=3D515488=
b2-en"></SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/newsticker/css/rssticker.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/newsticker/code/csjs/NewsTickerMediator.js?cachekeY=3D515488b2-en"></S=
CRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/newsticker/code/csjs/rssticker.js?cachekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/workflow/code/csjs/WorkflowMediator.js?cachekeY=3D515488b2-en"></SCRIP=
T>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
prototype/excanvas/excanvas.js?cachekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/=
prototype/ProtoChart/ProtoChart.js?cachekeY=3D515488b2-en"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/=
lang/datejs/date.js?cachekeY=3D515488b2-en"></SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/css/erms_menu.css?cachekeY=3D515488b2-en">
<SCRIPT type=3Dtext/javascript>(function () {

  bm_m2=3Dnew Menu("HWbookmarksMenubookmarks",({close:true, showdisabledic=
ons:true}));
bm_m2.add("Add&nbsp;Bookmark",({exec:(function anonymous() {(function () {=
BookmarksMediator.static_.getInstance().addBookmark();}.call(this));}), cs=
sclass:"hw_addbookmark", selectionminimum:-1, selectionmaximum:1000000}));
bm_m2.add("Organize&nbsp;Bookmarks",({url:"/;internal&action=3Djs.execute.=
action&Parameter=3D%23%28UIClass%3AHW_Bookmarks%29%28Method%3Astatic_.orga=
nizeBookmarks%29&ctx=3DGOid_0x80010cb5_0x000005b0", targetmult:"HW_Mainfra=
me", target:"HW_Mainframe", cssclass:"hw_organizebookmarks", selectionmini=
mum:-1, selectionmaximum:1000000}));
bm_m2.addSep();

  BookmarksMediator.static_.getInstance().setPersonalMenu( bm_m2 );

}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {
NewsTickerMediator.static_.getInstance().setConfiguration(({active:true, o=
bject:"NewTicker", cache:"private", cachetime:7200, target:"HW_Mainframe",=
 delay:10, display:"date+description", action:"/Documents/TIckerBin/NewTic=
ker;internal&action=3Djs.execute.action&Parameter=3D%23%28UIClass%3AHW_Mis=
cUI%29%28Method%3Astatic_.getCollectionRSS%29&ctx=3DGOid_0x80010cb5_0x0000=
05b0?cachetime=3D7200&cache=3Dprivate"}));
NewsTickerMediator.static_.getInstance().setId('ohf2k56bu_elqkbznzyrw_1')
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {
Framework.static_.getInstance().setApplicationProperty(
  'eks.workflow', 'WorkflowMediator', WorkflowMediator.static_.getInstance=
());
}).call(this);</SCRIPT>

<META name=3DGENERATOR content=3D"MSHTML 8.00.7601.18094">
<!--[if gte mso 9]><xml>
<mso:CustomDocumentProperties>
<mso:display_urn_x003a_schemas-microsoft-com_x003a_office_x003a_office_x00=
23_Editor msdt:dt=3D"string">SVC_Sharepoint</mso:display_urn_x003a_schemas=
-microsoft-com_x003a_office_x003a_office_x0023_Editor>
<mso:CategoryDescription msdt:dt=3D"string"></mso:CategoryDescription>
<mso:FileType1 msdt:dt=3D"string">Amended Documentation</mso:FileType1>
<mso:display_urn_x003a_schemas-microsoft-com_x003a_office_x003a_office_x00=
23_Author msdt:dt=3D"string">SVC_Sharepoint</mso:display_urn_x003a_schemas=
-microsoft-com_x003a_office_x003a_office_x0023_Author>
<mso:Public msdt:dt=3D"string">1</mso:Public>
</mso:CustomDocumentProperties>
</xml><![endif]-->
</HEAD>
<BODY>
<DIV id=3DhiddenframeContainer><IFRAME id=3Dhiddenframe=20
onload=3DFrameSetMediator.static_.getInstance().frameOnload(this);=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/emp=
ty.html"=20
frameBorder=3D0 name=3DHW_DataRequestFrame>
    </IFRAME></DIV>
<DIV id=3Dheader>
<DIV>
<SCRIPT>

function prepareMenu()
{
  onLoadLogin();
  if (typeof hw_menuContainer =3D=3D "undefined")
  {
    var str =3D "";
    // create container for menu
    hw_menuContainer=3DWriteToPage(str,window);
    // create container for iconbar
    hw_iconbarContainer=3DWriteToPage(str,window);
  }
}

addToOnload(prepareMenu);
</SCRIPT>
<A href=3D"http://hyperwave.barnsley.gov.uk/" target=3DHW_Mainframe>
<H1>Hyperwave</H1></A>
<UL class=3Dbookmarkbar>
  <LI class=3Dseparator><A title=3D"My Home"=20
  href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/JamesHyde"=20
  target=3DHW_Mainframe><IMG=20
  src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uisty=
le/hwdefault/ubimg/bookmark_home.png">My=20
  Home</A></LI>
  <LI><A title=3DDashboard=20
  href=3D"http://hyperwave.barnsley.gov.uk/workflow/dashboard"=20
  target=3DHW_Mainframe><IMG=20
  src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compo=
nents/workflow/images/dashboard.png?r=3D7.0.1">Dashboard</A></LI>
  <LI id=3Dpersonalbookmarksmenu class=3Dmanage title=3DBookmarks><A=20
  onclick=3D"BookmarksMediator.static_.getInstance().openPersonalBookmarks=
Menu(this); return false"=20
  href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%2=
0amended%20plan.mht#"><IMG=20
  src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/icons/bookma=
rks_16.png"><SPAN>Bookmarks</SPAN></A></LI></UL>
<DIV class=3Dtools>
<DIV class=3Dusername><A onclick=3D"openebc( $(event)); return false;"=20
href=3D"http://hyperwave.barnsley.gov.uk/">James&nbsp;Hyde </A></DIV>
<UL>
  <LI class=3Dauthoring title=3DAuthoring><A=20
  onclick=3D"FrameSetMediator.static_.getInstance().switchEditMode(); retu=
rn false;"=20
  href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%2=
0amended%20plan.mht#"><SPAN>Authoring</SPAN>=20
  </A></LI>
  <LI id=3Duserblockmenu class=3Dmanage title=3DManage><A=20
  onclick=3D"openUserblockMenu(); return false;"=20
  href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%2=
0amended%20plan.mht#"><SPAN>Manage</SPAN>=20
  </A></LI>
  <LI id=3Dsearchbutton class=3Dsearch title=3DSearch><!--//bmbc mod repla=
ce commented line below with advanced search one to make it a default to a=
dvanced search on clicking magnifying glass
          <a href=3D"#" onclick=3D"return SearchElement.static_.getInstanc=
e().searchButtonOnClick(event); return false;">--><A=20
  class=3DAdvancedSearch=20
  onclick=3D"return SearchElement.static_.getInstance().performAdvancedSea=
rch( $('UB_SearchForm').searchstring.value );"=20
  href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%2=
0amended%20plan.mht#"><!--// bmbc end mod--><SPAN>Search</SPAN>=20
  </A></LI><!--// ERS - add print button --></UL></DIV>
<DIV style=3D"Z-INDEX: 1; POSITION: absolute; DISPLAY: none" id=3Dsearch_c=
ontainer>
<FORM id=3DUB_SearchForm=20
onsubmit=3D"return SearchButtonMediator.performSimpleSearch(this)" method=
=3Dpost=20
name=3DUB_SearchForm=20
action=3Dhttp://hyperwave.barnsley.gov.uk/;internal%26action=3Dexecute.sea=
rch.action%26Parameter=3D(Caller:UserBlock)(DummyScope:yes%2529=20
target=3Dsearch80010cb580><INPUT id=3Dsearchstring class=3DInputElementEna=
bled=20
maxLength=3D256 size=3D20 type=3Dtext name=3Dsearchstring><A class=3Dhw_bu=
tton=20
onclick=3D"$('UB_SearchForm').submit(); return false;"=20
href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%20a=
mended%20plan.mht#">Go</A>=20
<A class=3DAdvancedSearch=20
onclick=3D"return SearchElement.static_.getInstance().performAdvancedSearc=
h( $('UB_SearchForm').searchstring.value );"=20
href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%20a=
mended%20plan.mht#">Advanced=20
Search...</A> <INPUT value=3Dselect_created_modified type=3Dhidden=20
name=3Ddd_group_dates_> <INPUT value=3Ddefault_scope type=3Dhidden=20
name=3Ddd_group_scopes_> <INPUT value=3Dselect_created_modified type=3Dhid=
den=20
name=3Ddd_groupfields_dates_> <INPUT value=3Dcustom_date_after type=3Dhidd=
en=20
name=3Ddd_groupfields_dates_> <INPUT value=3Dcustom_date_before type=3Dhid=
den=20
name=3Ddd_groupfields_dates_> <INPUT value=3Ddefault_scope type=3Dhidden=20
name=3Ddd_groupfields_scopes_> <INPUT value=3Dcustom_scope type=3Dhidden=20
name=3Ddd_groupfields_scopes_> <INPUT value=3Dwholeserver type=3Dhidden=20
name=3Ddefault_scope> <INPUT value=3Dcollections:?scope=3D%2F type=3Dhidde=
n=20
name=3Dentire_server_scope> <INPUT value=3D100 type=3Dhidden name=3Ddocs_p=
er_page>=20
<INPUT value=3Dall type=3Dhidden name=3Dlanguages> <INPUT value=3Dall type=
=3Dhidden=20
name=3Dmimetype> <INPUT value=3Dnone type=3Dhidden name=3Dsearch_descripti=
on> <INPUT=20
value=3Dall type=3Dhidden name=3Dselect_created_modified> <INPUT=20
value=3D(dd_group_dates_:select_created_modified)(dd_group_scopes_:default=
_scope)(dd_groupfields_dates_:select_created_modified,custom_date_after,cu=
stom_date_before)(dd_groupfields_scopes_:default_scope,custom_scope)(defau=
lt_scope:wholeserver)(entire_server_scope:collections%3A%3Fscope%3D%252F)(=
docs_per_page:100)(languages:all)(mimetype:all)(search_description:none)(s=
elect_created_modified:all)(searchstring:)=20
type=3Dhidden name=3DHW_HiddenFormData> </FORM></DIV>
<SCRIPT>
	      var SearchButtonMediator =3D SearchElement.static_.getInstance();
	      var fw =3D hw.getFramework();
	      fw.registerUIElement(fw.static_.SEARCHBUTTON, SearchButtonMediator);
	      fw.registerUIElement(fw.static_.SEARCHFORM, {searchForm: $("UB_Sear=
chForm")});
	    </SCRIPT>
</DIV>
<DIV id=3Dnewsticker class=3Dnewsticker></DIV>
<SCRIPT type=3Dtext/javascript>$("newsticker").update("\x3cspan>\x3cspan i=
d=3D\"ohf2k56bu_elqkbznzyrw_1\">\x3c/span>\x3c/span>");</SCRIPT>

<DIV id=3DbreadcrumbingContainer><A id=3Dupbutton onclick=3D"goUp(); retur=
n false;"=20
href=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/2013.0165%20-%20a=
mended%20plan.mht#"=20
target=3DHW_Mainframe></A>
<DIV id=3Dbreadcrumbing></DIV>
<SCRIPT>
        var param =3D {window: window,
                     stepSize: 1,
                     maxEntryLength: 30,
                     containerId: "breadcrumbing",
                     onSelectFunction: "top.BCSelectFunc"};
        param.entryResource =3D '<li><a class=3D"breadcrumbing" title=3D"$=
{entry}" href=3D"${url}" ${onclick}><span>${entryAbbr}</span></a></li>';
        param.lastEntryResource =3D '<li><a class=3D"breadcrumbing selecte=
d" title=3D"${entry}" href=3D"${url}" ${onclick}><span>${entryAbbr}</span>=
</a></li>';

        top.gBreadCrumb.initialize(param);
      </SCRIPT>
</DIV></DIV>
<DIV id=3DheaderContainer>
<DIV id=3DheaderContainerTop></DIV>
<DIV id=3DheaderContainerLeft></DIV>
<DIV id=3DheaderContainerCenter></DIV>
<DIV id=3DheaderContainerRight></DIV></DIV>
<DIV id=3DtreeviewContainer><IFRAME id=3Dtreeview=20
onload=3DFrameSetMediator.static_.getInstance().frameOnload(this);=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compone=
nts/frameset/ui/naviframe_static.html?cachekeY=3D515488b2-en"=20
frameBorder=3D0 name=3DHW_Navigationframe>
    </IFRAME>
<DIV=20
onclick=3DFrameSetMediator.static_.getInstance().toggleTreeviewState();></=
DIV></DIV>
<DIV id=3DmenuContainer>
<DIV id=3DhwiconbarContainerOpener></DIV>
<DIV id=3Dopener></DIV>
<DIV style=3D"DISPLAY: none" id=3DmainFilter>
<FORM id=3DmainFilterForm><LABEL id=3DmainFilterCaption=20
for=3DmainFilterInput>Filter:</LABEL> <INPUT id=3DmainFilterInput type=3Dt=
ext=20
autocomplete=3D"off"> <A id=3DmainFilterGoButton>Apply Filter</A> <A=20
id=3DmainFilterClearButton>Clear Filter</A> </FORM></DIV>
<SCRIPT>
      var filter_mediator =3D new MainFilterElement();
      var fw =3D hw.getFramework();
      fw.registerUIElement(fw.static_.MAINFILTER, filter_mediator);
      addToOnunload(function () { filter_mediator.destructor(); });
    </SCRIPT>
</DIV>
<DIV id=3DmainframeContainer>
<DIV class=3Dframe>
<DIV class=3Dframe>
<DIV class=3Dframe>
<DIV class=3Dframe>
<DIV id=3DmainframeHeader>
<DIV id=3DmainframeHeaderTop></DIV>
<DIV id=3DmainframeHeaderLeft></DIV>
<DIV id=3DmainframeHeaderCenter></DIV>
<DIV id=3DmainframeHeaderRight></DIV>
<DIV id=3DmainframeHeaderBottom></DIV></DIV>
<DIV id=3DinnerMainframeContainer><IFRAME id=3Dmainframe=20
onload=3DFrameSetMediator.static_.getInstance().frameOnload(this);=20
src=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/JamesHyde/_id36bc0=
51548b00cda_/615654_KfxPDF00001.pdf;internal&amp;Parameter=3D1364985039541=
e&amp;ctx=3DeKS&amp;action=3Dforcetemplates.action&amp;ctx=3DeKS"=20
frameBorder=3D0 name=3DHW_Mainframe>
              </IFRAME></DIV>
<DIV id=3DmainframeFooter>
<DIV id=3DmainframeFooterLeft></DIV>
<DIV id=3DmainframeFooterCenter></DIV>
<DIV id=3DmainframeFooterRight></DIV></DIV></DIV></DIV></DIV></DIV></DIV>
<DIV id=3DfooterContainer>
<DIV id=3DfooterContainerLeft></DIV>
<DIV id=3DfooterContainerCenter></DIV>
<DIV id=3DfooterContainerRight></DIV></DIV>
<SCRIPT type=3Dtext/javascript>(function () {
(function (theMainframeUrl, theTreeviewState, theBreadcrumbingState) {
    HW_Subframe =3D frames.HW_Subframe =3D {'frames': {'HW_Mainframe': HW_=
Mainframe, 'HW_Navigationframe': HW_Navigationframe}, 'HW_Mainframe': HW_M=
ainframe, 'HW_Navigationframe': HW_Navigationframe};
    var fsm =3D FrameSetMediator.static_.getInstance();
    hw.getFramework().setFrameSetMediator(fsm);
    fsm.setTreeviewState(FrameSetMediator.static_[theTreeviewState]);
    fsm.setBreadcrumbingState(FrameSetMediator.static_[theBreadcrumbingSta=
te]);
    fsm.setMainframeUrl(theMainframeUrl);
}).apply(this, ["/Documents/Users/JamesHyde;internal&ctx=3DGOid_0x80010cb5=
_0x000005b0", "ON", "ON"]);
}).call(this);</SCRIPT>
</BODY></HTML>

------=_NextPart_001_0017_01CE307B.33382030
mime-version: 1.0
content-type: text/html;
	charset="utf-8"
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/empty.html

=EF=BB=BF<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "h=
ttp://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML><HEAD><TITLE>empty.html</TITLE>
<META content=3D"text/html; charset=3Dutf-8" http-equiv=3DContent-Type>
<META name=3DGENERATOR content=3D"MSHTML 8.00.7601.18094"></HEAD>
<BODY></BODY></HTML>

------=_NextPart_001_0017_01CE307B.33382030--
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/prototype/prototype.js?cachekeY=515488b2-en

/*  Prototype JavaScript framework, version 1.6.1=0A=
 *  (c) 2005-2009 Sam Stephenson=0A=
 *=0A=
 *  Prototype is freely distributable under the terms of an MIT-style =
license.=0A=
 *  For details, see the Prototype web site: http://www.prototypejs.org/=0A=
 *=0A=
 =
*------------------------------------------------------------------------=
--*/=0A=
=0A=
var Prototype =3D {=0A=
  Version: '1.6.1',=0A=
=0A=
  Browser: (function(){=0A=
    var ua =3D navigator.userAgent;=0A=
    var isOpera =3D Object.prototype.toString.call(window.opera) =3D=3D =
'[object Opera]';=0A=
    return {=0A=
      IE:             !!window.attachEvent && !isOpera,=0A=
      Opera:          isOpera,=0A=
      WebKit:         ua.indexOf('AppleWebKit/') > -1,=0A=
      Gecko:          ua.indexOf('Gecko') > -1 && ua.indexOf('KHTML') =
=3D=3D=3D -1,=0A=
      MobileSafari:   /Apple.*Mobile.*Safari/.test(ua)=0A=
    }=0A=
  })(),=0A=
=0A=
  BrowserFeatures: {=0A=
    XPath: !!document.evaluate,=0A=
    SelectorsAPI: !!document.querySelector,=0A=
    ElementExtensions: (function() {=0A=
      var constructor =3D window.Element || window.HTMLElement;=0A=
      return !!(constructor && constructor.prototype);=0A=
    })(),=0A=
    SpecificElementExtensions: (function() {=0A=
      if (typeof window.HTMLDivElement !=3D=3D 'undefined')=0A=
        return true;=0A=
=0A=
      var div =3D document.createElement('div');=0A=
      var form =3D document.createElement('form');=0A=
      var isSupported =3D false;=0A=
=0A=
      if (div['__proto__'] && (div['__proto__'] !=3D=3D =
form['__proto__'])) {=0A=
        isSupported =3D true;=0A=
      }=0A=
=0A=
      div =3D form =3D null;=0A=
=0A=
      return isSupported;=0A=
    })()=0A=
  },=0A=
=0A=
  ScriptFragment: '<script[^>]*>([\\S\\s]*?)<\/script>',=0A=
  JSONFilter: /^\/\*-secure-([\s\S]*)\*\/\s*$/,=0A=
=0A=
  emptyFunction: function() { },=0A=
  K: function(x) { return x }=0A=
};=0A=
=0A=
if (Prototype.Browser.MobileSafari)=0A=
  Prototype.BrowserFeatures.SpecificElementExtensions =3D false;=0A=
=0A=
=0A=
var Abstract =3D { };=0A=
=0A=
=0A=
var Try =3D {=0A=
  these: function() {=0A=
    var returnValue;=0A=
=0A=
    for (var i =3D 0, length =3D arguments.length; i < length; i++) {=0A=
      var lambda =3D arguments[i];=0A=
      try {=0A=
        returnValue =3D lambda();=0A=
        break;=0A=
      } catch (e) { }=0A=
    }=0A=
=0A=
    return returnValue;=0A=
  }=0A=
};=0A=
=0A=
/* Based on Alex Arnell's inheritance implementation. */=0A=
=0A=
var Class =3D (function() {=0A=
  function subclass() {};=0A=
  function create() {=0A=
    var parent =3D null, properties =3D $A(arguments);=0A=
    if (Object.isFunction(properties[0]))=0A=
      parent =3D properties.shift();=0A=
=0A=
    function klass() {=0A=
      this.initialize.apply(this, arguments);=0A=
    }=0A=
=0A=
    Object.extend(klass, Class.Methods);=0A=
    klass.superclass =3D parent;=0A=
    klass.subclasses =3D [];=0A=
=0A=
    if (parent) {=0A=
      subclass.prototype =3D parent.prototype;=0A=
      klass.prototype =3D new subclass;=0A=
      parent.subclasses.push(klass);=0A=
    }=0A=
=0A=
    for (var i =3D 0; i < properties.length; i++)=0A=
      klass.addMethods(properties[i]);=0A=
=0A=
    if (!klass.prototype.initialize)=0A=
      klass.prototype.initialize =3D Prototype.emptyFunction;=0A=
=0A=
    klass.prototype.constructor =3D klass;=0A=
    return klass;=0A=
  }=0A=
=0A=
  function addMethods(source) {=0A=
    var ancestor   =3D this.superclass && this.superclass.prototype;=0A=
    var properties =3D Object.keys(source);=0A=
=0A=
    if (!Object.keys({ toString: true }).length) {=0A=
      if (source.toString !=3D Object.prototype.toString)=0A=
        properties.push("toString");=0A=
      if (source.valueOf !=3D Object.prototype.valueOf)=0A=
        properties.push("valueOf");=0A=
    }=0A=
=0A=
    for (var i =3D 0, length =3D properties.length; i < length; i++) {=0A=
      var property =3D properties[i], value =3D source[property];=0A=
      if (ancestor && Object.isFunction(value) &&=0A=
          value.argumentNames().first() =3D=3D "$super") {=0A=
        var method =3D value;=0A=
        value =3D (function(m) {=0A=
          return function() { return ancestor[m].apply(this, arguments); =
};=0A=
        })(property).wrap(method);=0A=
=0A=
        value.valueOf =3D method.valueOf.bind(method);=0A=
        value.toString =3D method.toString.bind(method);=0A=
      }=0A=
      this.prototype[property] =3D value;=0A=
    }=0A=
=0A=
    return this;=0A=
  }=0A=
=0A=
  return {=0A=
    create: create,=0A=
    Methods: {=0A=
      addMethods: addMethods=0A=
    }=0A=
  };=0A=
})();=0A=
(function() {=0A=
=0A=
  var _toString =3D Object.prototype.toString;=0A=
=0A=
  function extend(destination, source) {=0A=
    for (var property in source)=0A=
      destination[property] =3D source[property];=0A=
    return destination;=0A=
  }=0A=
=0A=
  function inspect(object) {=0A=
    try {=0A=
      if (isUndefined(object)) return 'undefined';=0A=
      if (object =3D=3D=3D null) return 'null';=0A=
      return object.inspect ? object.inspect() : String(object);=0A=
    } catch (e) {=0A=
      if (e instanceof RangeError) return '...';=0A=
      throw e;=0A=
    }=0A=
  }=0A=
=0A=
  function toJSON(object) {=0A=
    var type =3D typeof object;=0A=
    switch (type) {=0A=
      case 'undefined':=0A=
      case 'function':=0A=
      case 'unknown': return;=0A=
      case 'boolean': return object.toString();=0A=
    }=0A=
=0A=
    if (object =3D=3D=3D null) return 'null';=0A=
    if (object.toJSON) return object.toJSON();=0A=
    if (isElement(object)) return;=0A=
=0A=
    var results =3D [];=0A=
    for (var property in object) {=0A=
      var value =3D toJSON(object[property]);=0A=
      if (!isUndefined(value))=0A=
        results.push(property.toJSON() + ': ' + value);=0A=
    }=0A=
=0A=
    return '{' + results.join(', ') + '}';=0A=
  }=0A=
=0A=
  function toQueryString(object) {=0A=
    return $H(object).toQueryString();=0A=
  }=0A=
=0A=
  function toHTML(object) {=0A=
    return object && object.toHTML ? object.toHTML() : =
String.interpret(object);=0A=
  }=0A=
=0A=
  function keys(object) {=0A=
    var results =3D [];=0A=
    for (var property in object)=0A=
      results.push(property);=0A=
    return results;=0A=
  }=0A=
=0A=
  function values(object) {=0A=
    var results =3D [];=0A=
    for (var property in object)=0A=
      results.push(object[property]);=0A=
    return results;=0A=
  }=0A=
=0A=
  function clone(object) {=0A=
    return extend({ }, object);=0A=
  }=0A=
=0A=
  function isElement(object) {=0A=
    return !!(object && object.nodeType =3D=3D 1);=0A=
  }=0A=
=0A=
  function isArray(object) {=0A=
    return _toString.call(object) =3D=3D "[object Array]";=0A=
  }=0A=
=0A=
=0A=
  function isHash(object) {=0A=
    return object instanceof Hash;=0A=
  }=0A=
=0A=
  function isFunction(object) {=0A=
    return typeof object =3D=3D=3D "function";=0A=
  }=0A=
=0A=
  function isString(object) {=0A=
    return _toString.call(object) =3D=3D "[object String]";=0A=
  }=0A=
=0A=
  function isNumber(object) {=0A=
    return _toString.call(object) =3D=3D "[object Number]";=0A=
  }=0A=
=0A=
  function isUndefined(object) {=0A=
    return typeof object =3D=3D=3D "undefined";=0A=
  }=0A=
=0A=
  extend(Object, {=0A=
    extend:        extend,=0A=
    inspect:       inspect,=0A=
    toJSON:        toJSON,=0A=
    toQueryString: toQueryString,=0A=
    toHTML:        toHTML,=0A=
    keys:          keys,=0A=
    values:        values,=0A=
    clone:         clone,=0A=
    isElement:     isElement,=0A=
    isArray:       isArray,=0A=
    isHash:        isHash,=0A=
    isFunction:    isFunction,=0A=
    isString:      isString,=0A=
    isNumber:      isNumber,=0A=
    isUndefined:   isUndefined=0A=
  });=0A=
})();=0A=
Object.extend(Function.prototype, (function() {=0A=
  var slice =3D Array.prototype.slice;=0A=
=0A=
  function update(array, args) {=0A=
    var arrayLength =3D array.length, length =3D args.length;=0A=
    while (length--) array[arrayLength + length] =3D args[length];=0A=
    return array;=0A=
  }=0A=
=0A=
  function merge(array, args) {=0A=
    array =3D slice.call(array, 0);=0A=
    return update(array, args);=0A=
  }=0A=
=0A=
  function argumentNames() {=0A=
    var names =3D =
this.toString().match(/^[\s\(]*function[^(]*\(([^)]*)\)/)[1]=0A=
      .replace(/\/\/.*?[\r\n]|\/\*(?:.|[\r\n])*?\*\//g, '')=0A=
      .replace(/\s+/g, '').split(',');=0A=
    return names.length =3D=3D 1 && !names[0] ? [] : names;=0A=
  }=0A=
=0A=
  function bind(context) {=0A=
    if (arguments.length < 2 && Object.isUndefined(arguments[0])) return =
this;=0A=
    var __method =3D this, args =3D slice.call(arguments, 1);=0A=
    return function() {=0A=
      var a =3D merge(args, arguments);=0A=
      return __method.apply(context, a);=0A=
    }=0A=
  }=0A=
=0A=
  function bindAsEventListener(context) {=0A=
    var __method =3D this, args =3D slice.call(arguments, 1);=0A=
    return function(event) {=0A=
      var a =3D update([event || window.event], args);=0A=
      return __method.apply(context, a);=0A=
    }=0A=
  }=0A=
=0A=
  function curry() {=0A=
    if (!arguments.length) return this;=0A=
    var __method =3D this, args =3D slice.call(arguments, 0);=0A=
    return function() {=0A=
      var a =3D merge(args, arguments);=0A=
      return __method.apply(this, a);=0A=
    }=0A=
  }=0A=
=0A=
  function delay(timeout) {=0A=
    var __method =3D this, args =3D slice.call(arguments, 1);=0A=
    timeout =3D timeout * 1000=0A=
    return window.setTimeout(function() {=0A=
      return __method.apply(__method, args);=0A=
    }, timeout);=0A=
  }=0A=
=0A=
  function defer() {=0A=
    var args =3D update([0.01], arguments);=0A=
    return this.delay.apply(this, args);=0A=
  }=0A=
=0A=
  function wrap(wrapper) {=0A=
    var __method =3D this;=0A=
    return function() {=0A=
      var a =3D update([__method.bind(this)], arguments);=0A=
      return wrapper.apply(this, a);=0A=
    }=0A=
  }=0A=
=0A=
  function methodize() {=0A=
    if (this._methodized) return this._methodized;=0A=
    var __method =3D this;=0A=
    return this._methodized =3D function() {=0A=
      var a =3D update([this], arguments);=0A=
      return __method.apply(null, a);=0A=
    };=0A=
  }=0A=
=0A=
  return {=0A=
    argumentNames:       argumentNames,=0A=
    bind:                bind,=0A=
    bindAsEventListener: bindAsEventListener,=0A=
    curry:               curry,=0A=
    delay:               delay,=0A=
    defer:               defer,=0A=
    wrap:                wrap,=0A=
    methodize:           methodize=0A=
  }=0A=
})());=0A=
=0A=
=0A=
Date.prototype.toJSON =3D function() {=0A=
  return '"' + this.getUTCFullYear() + '-' +=0A=
    (this.getUTCMonth() + 1).toPaddedString(2) + '-' +=0A=
    this.getUTCDate().toPaddedString(2) + 'T' +=0A=
    this.getUTCHours().toPaddedString(2) + ':' +=0A=
    this.getUTCMinutes().toPaddedString(2) + ':' +=0A=
    this.getUTCSeconds().toPaddedString(2) + 'Z"';=0A=
};=0A=
=0A=
=0A=
RegExp.prototype.match =3D RegExp.prototype.test;=0A=
=0A=
RegExp.escape =3D function(str) {=0A=
  return String(str).replace(/([.*+?^=3D!:${}()|[\]\/\\])/g, '\\$1');=0A=
};=0A=
var PeriodicalExecuter =3D Class.create({=0A=
  initialize: function(callback, frequency) {=0A=
    this.callback =3D callback;=0A=
    this.frequency =3D frequency;=0A=
    this.currentlyExecuting =3D false;=0A=
=0A=
    this.registerCallback();=0A=
  },=0A=
=0A=
  registerCallback: function() {=0A=
    this.timer =3D setInterval(this.onTimerEvent.bind(this), =
this.frequency * 1000);=0A=
  },=0A=
=0A=
  execute: function() {=0A=
    this.callback(this);=0A=
  },=0A=
=0A=
  stop: function() {=0A=
    if (!this.timer) return;=0A=
    clearInterval(this.timer);=0A=
    this.timer =3D null;=0A=
  },=0A=
=0A=
  onTimerEvent: function() {=0A=
    if (!this.currentlyExecuting) {=0A=
      try {=0A=
        this.currentlyExecuting =3D true;=0A=
        this.execute();=0A=
        this.currentlyExecuting =3D false;=0A=
      } catch(e) {=0A=
        this.currentlyExecuting =3D false;=0A=
        throw e;=0A=
      }=0A=
    }=0A=
  }=0A=
});=0A=
Object.extend(String, {=0A=
  interpret: function(value) {=0A=
    return value =3D=3D null ? '' : String(value);=0A=
  },=0A=
  specialChar: {=0A=
    '\b': '\\b',=0A=
    '\t': '\\t',=0A=
    '\n': '\\n',=0A=
    '\f': '\\f',=0A=
    '\r': '\\r',=0A=
    '\\': '\\\\'=0A=
  }=0A=
});=0A=
=0A=
Object.extend(String.prototype, (function() {=0A=
=0A=
  function prepareReplacement(replacement) {=0A=
    if (Object.isFunction(replacement)) return replacement;=0A=
    var template =3D new Template(replacement);=0A=
    return function(match) { return template.evaluate(match) };=0A=
  }=0A=
=0A=
  function gsub(pattern, replacement) {=0A=
    var result =3D '', source =3D this, match;=0A=
    replacement =3D prepareReplacement(replacement);=0A=
=0A=
    if (Object.isString(pattern))=0A=
      pattern =3D RegExp.escape(pattern);=0A=
=0A=
    if (!(pattern.length || pattern.source)) {=0A=
      replacement =3D replacement('');=0A=
      return replacement + source.split('').join(replacement) + =
replacement;=0A=
    }=0A=
=0A=
    while (source.length > 0) {=0A=
      if (match =3D source.match(pattern)) {=0A=
        result +=3D source.slice(0, match.index);=0A=
        result +=3D String.interpret(replacement(match));=0A=
        source  =3D source.slice(match.index + match[0].length);=0A=
      } else {=0A=
        result +=3D source, source =3D '';=0A=
      }=0A=
    }=0A=
    return result;=0A=
  }=0A=
=0A=
  function sub(pattern, replacement, count) {=0A=
    replacement =3D prepareReplacement(replacement);=0A=
    count =3D Object.isUndefined(count) ? 1 : count;=0A=
=0A=
    return this.gsub(pattern, function(match) {=0A=
      if (--count < 0) return match[0];=0A=
      return replacement(match);=0A=
    });=0A=
  }=0A=
=0A=
  function scan(pattern, iterator) {=0A=
    this.gsub(pattern, iterator);=0A=
    return String(this);=0A=
  }=0A=
=0A=
  function truncate(length, truncation) {=0A=
    length =3D length || 30;=0A=
    truncation =3D Object.isUndefined(truncation) ? '...' : truncation;=0A=
    return this.length > length ?=0A=
      this.slice(0, length - truncation.length) + truncation : =
String(this);=0A=
  }=0A=
=0A=
  function strip() {=0A=
    return this.replace(/^\s+/, '').replace(/\s+$/, '');=0A=
  }=0A=
=0A=
  function stripTags() {=0A=
    return this.replace(/<\w+(\s+("[^"]*"|'[^']*'|[^>])+)?>|<\/\w+>/gi, =
'');=0A=
  }=0A=
=0A=
  function stripScripts() {=0A=
    return this.replace(new RegExp(Prototype.ScriptFragment, 'img'), '');=0A=
  }=0A=
=0A=
  function extractScripts() {=0A=
    var matchAll =3D new RegExp(Prototype.ScriptFragment, 'img');=0A=
    var matchOne =3D new RegExp(Prototype.ScriptFragment, 'im');=0A=
    return (this.match(matchAll) || []).map(function(scriptTag) {=0A=
      return (scriptTag.match(matchOne) || ['', ''])[1];=0A=
    });=0A=
  }=0A=
=0A=
  function evalScripts() {=0A=
    return this.extractScripts().map(function(script) { return =
eval(script) });=0A=
  }=0A=
=0A=
  function escapeHTML() {=0A=
    return =
this.replace(/&/g,'&amp;').replace(/</g,'&lt;').replace(/>/g,'&gt;');=0A=
  }=0A=
=0A=
  function unescapeHTML() {=0A=
    return =
this.stripTags().replace(/&lt;/g,'<').replace(/&gt;/g,'>').replace(/&amp;=
/g,'&');=0A=
  }=0A=
=0A=
=0A=
  function toQueryParams(separator) {=0A=
    var match =3D this.strip().match(/([^?#]*)(#.*)?$/);=0A=
    if (!match) return { };=0A=
=0A=
    return match[1].split(separator || '&').inject({ }, function(hash, =
pair) {=0A=
      if ((pair =3D pair.split('=3D'))[0]) {=0A=
        var key =3D decodeURIComponent(pair.shift());=0A=
        var value =3D pair.length > 1 ? pair.join('=3D') : pair[0];=0A=
        if (value !=3D undefined) value =3D decodeURIComponent(value);=0A=
=0A=
        if (key in hash) {=0A=
          if (!Object.isArray(hash[key])) hash[key] =3D [hash[key]];=0A=
          hash[key].push(value);=0A=
        }=0A=
        else hash[key] =3D value;=0A=
      }=0A=
      return hash;=0A=
    });=0A=
  }=0A=
=0A=
  function toArray() {=0A=
    return this.split('');=0A=
  }=0A=
=0A=
  function succ() {=0A=
    return this.slice(0, this.length - 1) +=0A=
      String.fromCharCode(this.charCodeAt(this.length - 1) + 1);=0A=
  }=0A=
=0A=
  function times(count) {=0A=
    return count < 1 ? '' : new Array(count + 1).join(this);=0A=
  }=0A=
=0A=
  function camelize() {=0A=
    var parts =3D this.split('-'), len =3D parts.length;=0A=
    if (len =3D=3D 1) return parts[0];=0A=
=0A=
    var camelized =3D this.charAt(0) =3D=3D '-'=0A=
      ? parts[0].charAt(0).toUpperCase() + parts[0].substring(1)=0A=
      : parts[0];=0A=
=0A=
    for (var i =3D 1; i < len; i++)=0A=
      camelized +=3D parts[i].charAt(0).toUpperCase() + =
parts[i].substring(1);=0A=
=0A=
    return camelized;=0A=
  }=0A=
=0A=
  function capitalize() {=0A=
    return this.charAt(0).toUpperCase() + =
this.substring(1).toLowerCase();=0A=
  }=0A=
=0A=
  function underscore() {=0A=
    return this.replace(/::/g, '/')=0A=
               .replace(/([A-Z]+)([A-Z][a-z])/g, '$1_$2')=0A=
               .replace(/([a-z\d])([A-Z])/g, '$1_$2')=0A=
               .replace(/-/g, '_')=0A=
               .toLowerCase();=0A=
  }=0A=
=0A=
  function dasherize() {=0A=
    return this.replace(/_/g, '-');=0A=
  }=0A=
=0A=
  function inspect(useDoubleQuotes) {=0A=
    var escapedString =3D this.replace(/[\x00-\x1f\\]/g, =
function(character) {=0A=
      if (character in String.specialChar) {=0A=
        return String.specialChar[character];=0A=
      }=0A=
      return '\\u00' + character.charCodeAt().toPaddedString(2, 16);=0A=
    });=0A=
    if (useDoubleQuotes) return '"' + escapedString.replace(/"/g, '\\"') =
+ '"';=0A=
    return "'" + escapedString.replace(/'/g, '\\\'') + "'";=0A=
  }=0A=
=0A=
  function toJSON() {=0A=
    return this.inspect(true);=0A=
  }=0A=
=0A=
  function unfilterJSON(filter) {=0A=
    return this.replace(filter || Prototype.JSONFilter, '$1');=0A=
  }=0A=
=0A=
  function isJSON() {=0A=
    var str =3D this;=0A=
    if (str.blank()) return false;=0A=
    str =3D this.replace(/\\./g, '@').replace(/"[^"\\\n\r]*"/g, '');=0A=
    return (/^[,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]*$/).test(str);=0A=
  }=0A=
=0A=
  function evalJSON(sanitize) {=0A=
    var json =3D this.unfilterJSON();=0A=
    try {=0A=
      if (!sanitize || json.isJSON()) return eval('(' + json + ')');=0A=
    } catch (e) { }=0A=
    throw new SyntaxError('Badly formed JSON string: ' + this.inspect());=0A=
  }=0A=
=0A=
  function include(pattern) {=0A=
    return this.indexOf(pattern) > -1;=0A=
  }=0A=
=0A=
  function startsWith(pattern) {=0A=
    return this.indexOf(pattern) =3D=3D=3D 0;=0A=
  }=0A=
=0A=
  function endsWith(pattern) {=0A=
    var d =3D this.length - pattern.length;=0A=
    return d >=3D 0 && this.lastIndexOf(pattern) =3D=3D=3D d;=0A=
  }=0A=
=0A=
  function empty() {=0A=
    return this =3D=3D '';=0A=
  }=0A=
=0A=
  function blank() {=0A=
    return /^\s*$/.test(this);=0A=
  }=0A=
=0A=
  function interpolate(object, pattern) {=0A=
    return new Template(this, pattern).evaluate(object);=0A=
  }=0A=
=0A=
  return {=0A=
    gsub:           gsub,=0A=
    sub:            sub,=0A=
    scan:           scan,=0A=
    truncate:       truncate,=0A=
    strip:          String.prototype.trim ? String.prototype.trim : =
strip,=0A=
    stripTags:      stripTags,=0A=
    stripScripts:   stripScripts,=0A=
    extractScripts: extractScripts,=0A=
    evalScripts:    evalScripts,=0A=
    escapeHTML:     escapeHTML,=0A=
    unescapeHTML:   unescapeHTML,=0A=
    toQueryParams:  toQueryParams,=0A=
    parseQuery:     toQueryParams,=0A=
    toArray:        toArray,=0A=
    succ:           succ,=0A=
    times:          times,=0A=
    camelize:       camelize,=0A=
    capitalize:     capitalize,=0A=
    underscore:     underscore,=0A=
    dasherize:      dasherize,=0A=
    inspect:        inspect,=0A=
    toJSON:         toJSON,=0A=
    unfilterJSON:   unfilterJSON,=0A=
    isJSON:         isJSON,=0A=
    evalJSON:       evalJSON,=0A=
    include:        include,=0A=
    startsWith:     startsWith,=0A=
    endsWith:       endsWith,=0A=
    empty:          empty,=0A=
    blank:          blank,=0A=
    interpolate:    interpolate=0A=
  };=0A=
})());=0A=
=0A=
var Template =3D Class.create({=0A=
  initialize: function(template, pattern) {=0A=
    this.template =3D template.toString();=0A=
    this.pattern =3D pattern || Template.Pattern;=0A=
  },=0A=
=0A=
  evaluate: function(object) {=0A=
    if (object && Object.isFunction(object.toTemplateReplacements))=0A=
      object =3D object.toTemplateReplacements();=0A=
=0A=
    return this.template.gsub(this.pattern, function(match) {=0A=
      if (object =3D=3D null) return (match[1] + '');=0A=
=0A=
      var before =3D match[1] || '';=0A=
      if (before =3D=3D '\\') return match[2];=0A=
=0A=
      var ctx =3D object, expr =3D match[3];=0A=
      var pattern =3D /^([^.[]+|\[((?:.*?[^\\])?)\])(\.|\[|$)/;=0A=
      match =3D pattern.exec(expr);=0A=
      if (match =3D=3D null) return before;=0A=
=0A=
      while (match !=3D null) {=0A=
        var comp =3D match[1].startsWith('[') ? =
match[2].replace(/\\\\]/g, ']') : match[1];=0A=
        ctx =3D ctx[comp];=0A=
        if (null =3D=3D ctx || '' =3D=3D match[3]) break;=0A=
        expr =3D expr.substring('[' =3D=3D match[3] ? match[1].length : =
match[0].length);=0A=
        match =3D pattern.exec(expr);=0A=
      }=0A=
=0A=
      return before + String.interpret(ctx);=0A=
    });=0A=
  }=0A=
});=0A=
Template.Pattern =3D /(^|.|\r|\n)(#\{(.*?)\})/;=0A=
=0A=
var $break =3D { };=0A=
=0A=
var Enumerable =3D (function() {=0A=
  function each(iterator, context) {=0A=
    var index =3D 0;=0A=
    try {=0A=
      this._each(function(value) {=0A=
        iterator.call(context, value, index++);=0A=
      });=0A=
    } catch (e) {=0A=
      if (e !=3D $break) throw e;=0A=
    }=0A=
    return this;=0A=
  }=0A=
=0A=
  function eachSlice(number, iterator, context) {=0A=
    var index =3D -number, slices =3D [], array =3D this.toArray();=0A=
    if (number < 1) return array;=0A=
    while ((index +=3D number) < array.length)=0A=
      slices.push(array.slice(index, index+number));=0A=
    return slices.collect(iterator, context);=0A=
  }=0A=
=0A=
  function all(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var result =3D true;=0A=
    this.each(function(value, index) {=0A=
      result =3D result && !!iterator.call(context, value, index);=0A=
      if (!result) throw $break;=0A=
    });=0A=
    return result;=0A=
  }=0A=
=0A=
  function any(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var result =3D false;=0A=
    this.each(function(value, index) {=0A=
      if (result =3D !!iterator.call(context, value, index))=0A=
        throw $break;=0A=
    });=0A=
    return result;=0A=
  }=0A=
=0A=
  function collect(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var results =3D [];=0A=
    this.each(function(value, index) {=0A=
      results.push(iterator.call(context, value, index));=0A=
    });=0A=
    return results;=0A=
  }=0A=
=0A=
  function detect(iterator, context) {=0A=
    var result;=0A=
    this.each(function(value, index) {=0A=
      if (iterator.call(context, value, index)) {=0A=
        result =3D value;=0A=
        throw $break;=0A=
      }=0A=
    });=0A=
    return result;=0A=
  }=0A=
=0A=
  function findAll(iterator, context) {=0A=
    var results =3D [];=0A=
    this.each(function(value, index) {=0A=
      if (iterator.call(context, value, index))=0A=
        results.push(value);=0A=
    });=0A=
    return results;=0A=
  }=0A=
=0A=
  function grep(filter, iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var results =3D [];=0A=
=0A=
    if (Object.isString(filter))=0A=
      filter =3D new RegExp(RegExp.escape(filter));=0A=
=0A=
    this.each(function(value, index) {=0A=
      if (filter.match(value))=0A=
        results.push(iterator.call(context, value, index));=0A=
    });=0A=
    return results;=0A=
  }=0A=
=0A=
  function include(object) {=0A=
    if (Object.isFunction(this.indexOf))=0A=
      if (this.indexOf(object) !=3D -1) return true;=0A=
=0A=
    var found =3D false;=0A=
    this.each(function(value) {=0A=
      if (value =3D=3D object) {=0A=
        found =3D true;=0A=
        throw $break;=0A=
      }=0A=
    });=0A=
    return found;=0A=
  }=0A=
=0A=
  function inGroupsOf(number, fillWith) {=0A=
    fillWith =3D Object.isUndefined(fillWith) ? null : fillWith;=0A=
    return this.eachSlice(number, function(slice) {=0A=
      while(slice.length < number) slice.push(fillWith);=0A=
      return slice;=0A=
    });=0A=
  }=0A=
=0A=
  function inject(memo, iterator, context) {=0A=
    this.each(function(value, index) {=0A=
      memo =3D iterator.call(context, memo, value, index);=0A=
    });=0A=
    return memo;=0A=
  }=0A=
=0A=
  function invoke(method) {=0A=
    var args =3D $A(arguments).slice(1);=0A=
    return this.map(function(value) {=0A=
      return value[method].apply(value, args);=0A=
    });=0A=
  }=0A=
=0A=
  function max(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var result;=0A=
    this.each(function(value, index) {=0A=
      value =3D iterator.call(context, value, index);=0A=
      if (result =3D=3D null || value >=3D result)=0A=
        result =3D value;=0A=
    });=0A=
    return result;=0A=
  }=0A=
=0A=
  function min(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var result;=0A=
    this.each(function(value, index) {=0A=
      value =3D iterator.call(context, value, index);=0A=
      if (result =3D=3D null || value < result)=0A=
        result =3D value;=0A=
    });=0A=
    return result;=0A=
  }=0A=
=0A=
  function partition(iterator, context) {=0A=
    iterator =3D iterator || Prototype.K;=0A=
    var trues =3D [], falses =3D [];=0A=
    this.each(function(value, index) {=0A=
      (iterator.call(context, value, index) ?=0A=
        trues : falses).push(value);=0A=
    });=0A=
    return [trues, falses];=0A=
  }=0A=
=0A=
  function pluck(property) {=0A=
    var results =3D [];=0A=
    this.each(function(value) {=0A=
      results.push(value[property]);=0A=
    });=0A=
    return results;=0A=
  }=0A=
=0A=
  function reject(iterator, context) {=0A=
    var results =3D [];=0A=
    this.each(function(value, index) {=0A=
      if (!iterator.call(context, value, index))=0A=
        results.push(value);=0A=
    });=0A=
    return results;=0A=
  }=0A=
=0A=
  function sortBy(iterator, context) {=0A=
    return this.map(function(value, index) {=0A=
      return {=0A=
        value: value,=0A=
        criteria: iterator.call(context, value, index)=0A=
      };=0A=
    }).sort(function(left, right) {=0A=
      var a =3D left.criteria, b =3D right.criteria;=0A=
      return a < b ? -1 : a > b ? 1 : 0;=0A=
    }).pluck('value');=0A=
  }=0A=
=0A=
  function toArray() {=0A=
    return this.map();=0A=
  }=0A=
=0A=
  function zip() {=0A=
    var iterator =3D Prototype.K, args =3D $A(arguments);=0A=
    if (Object.isFunction(args.last()))=0A=
      iterator =3D args.pop();=0A=
=0A=
    var collections =3D [this].concat(args).map($A);=0A=
    return this.map(function(value, index) {=0A=
      return iterator(collections.pluck(index));=0A=
    });=0A=
  }=0A=
=0A=
  function size() {=0A=
    return this.toArray().length;=0A=
  }=0A=
=0A=
  function inspect() {=0A=
    return '#<Enumerable:' + this.toArray().inspect() + '>';=0A=
  }=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
  return {=0A=
    each:       each,=0A=
    eachSlice:  eachSlice,=0A=
    all:        all,=0A=
    every:      all,=0A=
    any:        any,=0A=
    some:       any,=0A=
    collect:    collect,=0A=
    map:        collect,=0A=
    detect:     detect,=0A=
    findAll:    findAll,=0A=
    select:     findAll,=0A=
    filter:     findAll,=0A=
    grep:       grep,=0A=
    include:    include,=0A=
    member:     include,=0A=
    inGroupsOf: inGroupsOf,=0A=
    inject:     inject,=0A=
    invoke:     invoke,=0A=
    max:        max,=0A=
    min:        min,=0A=
    partition:  partition,=0A=
    pluck:      pluck,=0A=
    reject:     reject,=0A=
    sortBy:     sortBy,=0A=
    toArray:    toArray,=0A=
    entries:    toArray,=0A=
    zip:        zip,=0A=
    size:       size,=0A=
    inspect:    inspect,=0A=
    find:       detect=0A=
  };=0A=
})();=0A=
function $A(iterable) {=0A=
  if (!iterable) return [];=0A=
  if ('toArray' in Object(iterable)) return iterable.toArray();=0A=
  var length =3D iterable.length || 0, results =3D new Array(length);=0A=
  while (length--) results[length] =3D iterable[length];=0A=
  return results;=0A=
}=0A=
=0A=
function $w(string) {=0A=
  if (!Object.isString(string)) return [];=0A=
  string =3D string.strip();=0A=
  return string ? string.split(/\s+/) : [];=0A=
}=0A=
=0A=
Array.from =3D $A;=0A=
=0A=
=0A=
(function() {=0A=
  var arrayProto =3D Array.prototype,=0A=
      slice =3D arrayProto.slice,=0A=
      _each =3D arrayProto.forEach; // use native browser JS 1.6 =
implementation if available=0A=
=0A=
  function each(iterator) {=0A=
    for (var i =3D 0, length =3D this.length; i < length; i++)=0A=
      iterator(this[i]);=0A=
  }=0A=
  if (!_each) _each =3D each;=0A=
=0A=
  function clear() {=0A=
    this.length =3D 0;=0A=
    return this;=0A=
  }=0A=
=0A=
  function first() {=0A=
    return this[0];=0A=
  }=0A=
=0A=
  function last() {=0A=
    return this[this.length - 1];=0A=
  }=0A=
=0A=
  function compact() {=0A=
    return this.select(function(value) {=0A=
      return value !=3D null;=0A=
    });=0A=
  }=0A=
=0A=
  function flatten() {=0A=
    return this.inject([], function(array, value) {=0A=
      if (Object.isArray(value))=0A=
        return array.concat(value.flatten());=0A=
      array.push(value);=0A=
      return array;=0A=
    });=0A=
  }=0A=
=0A=
  function without() {=0A=
    var values =3D slice.call(arguments, 0);=0A=
    return this.select(function(value) {=0A=
      return !values.include(value);=0A=
    });=0A=
  }=0A=
=0A=
  function reverse(inline) {=0A=
    return (inline !=3D=3D false ? this : this.toArray())._reverse();=0A=
  }=0A=
=0A=
  function uniq(sorted) {=0A=
    return this.inject([], function(array, value, index) {=0A=
      if (0 =3D=3D index || (sorted ? array.last() !=3D value : =
!array.include(value)))=0A=
        array.push(value);=0A=
      return array;=0A=
    });=0A=
  }=0A=
=0A=
  function intersect(array) {=0A=
    return this.uniq().findAll(function(item) {=0A=
      return array.detect(function(value) { return item =3D=3D=3D value =
});=0A=
    });=0A=
  }=0A=
=0A=
=0A=
  function clone() {=0A=
    return slice.call(this, 0);=0A=
  }=0A=
=0A=
  function size() {=0A=
    return this.length;=0A=
  }=0A=
=0A=
  function inspect() {=0A=
    return '[' + this.map(Object.inspect).join(', ') + ']';=0A=
  }=0A=
=0A=
  function toJSON() {=0A=
    var results =3D [];=0A=
    this.each(function(object) {=0A=
      var value =3D Object.toJSON(object);=0A=
      if (!Object.isUndefined(value)) results.push(value);=0A=
    });=0A=
    return '[' + results.join(', ') + ']';=0A=
  }=0A=
=0A=
  function indexOf(item, i) {=0A=
    i || (i =3D 0);=0A=
    var length =3D this.length;=0A=
    if (i < 0) i =3D length + i;=0A=
    for (; i < length; i++)=0A=
      if (this[i] =3D=3D=3D item) return i;=0A=
    return -1;=0A=
  }=0A=
=0A=
  function lastIndexOf(item, i) {=0A=
    i =3D isNaN(i) ? this.length : (i < 0 ? this.length + i : i) + 1;=0A=
    var n =3D this.slice(0, i).reverse().indexOf(item);=0A=
    return (n < 0) ? n : i - n - 1;=0A=
  }=0A=
=0A=
  function concat() {=0A=
    var array =3D slice.call(this, 0), item;=0A=
    for (var i =3D 0, length =3D arguments.length; i < length; i++) {=0A=
      item =3D arguments[i];=0A=
      if (Object.isArray(item) && !('callee' in item)) {=0A=
        for (var j =3D 0, arrayLength =3D item.length; j < arrayLength; =
j++)=0A=
          array.push(item[j]);=0A=
      } else {=0A=
        array.push(item);=0A=
      }=0A=
    }=0A=
    return array;=0A=
  }=0A=
=0A=
  Object.extend(arrayProto, Enumerable);=0A=
=0A=
  if (!arrayProto._reverse)=0A=
    arrayProto._reverse =3D arrayProto.reverse;=0A=
=0A=
  Object.extend(arrayProto, {=0A=
    _each:     _each,=0A=
    clear:     clear,=0A=
    first:     first,=0A=
    last:      last,=0A=
    compact:   compact,=0A=
    flatten:   flatten,=0A=
    without:   without,=0A=
    reverse:   reverse,=0A=
    uniq:      uniq,=0A=
    intersect: intersect,=0A=
    clone:     clone,=0A=
    toArray:   clone,=0A=
    size:      size,=0A=
    inspect:   inspect,=0A=
    toJSON:    toJSON=0A=
  });=0A=
=0A=
  var CONCAT_ARGUMENTS_BUGGY =3D (function() {=0A=
    return [].concat(arguments)[0][0] !=3D=3D 1;=0A=
  })(1,2)=0A=
=0A=
  if (CONCAT_ARGUMENTS_BUGGY) arrayProto.concat =3D concat;=0A=
=0A=
  if (!arrayProto.indexOf) arrayProto.indexOf =3D indexOf;=0A=
  if (!arrayProto.lastIndexOf) arrayProto.lastIndexOf =3D lastIndexOf;=0A=
})();=0A=
function $H(object) {=0A=
  return new Hash(object);=0A=
};=0A=
=0A=
var Hash =3D Class.create(Enumerable, (function() {=0A=
  function initialize(object) {=0A=
    this._object =3D Object.isHash(object) ? object.toObject() : =
Object.clone(object);=0A=
  }=0A=
=0A=
  function _each(iterator) {=0A=
    for (var key in this._object) {=0A=
      var value =3D this._object[key], pair =3D [key, value];=0A=
      pair.key =3D key;=0A=
      pair.value =3D value;=0A=
      iterator(pair);=0A=
    }=0A=
  }=0A=
=0A=
  function set(key, value) {=0A=
    return this._object[key] =3D value;=0A=
  }=0A=
=0A=
  function get(key) {=0A=
    if (this._object[key] !=3D=3D Object.prototype[key])=0A=
      return this._object[key];=0A=
  }=0A=
=0A=
  function unset(key) {=0A=
    var value =3D this._object[key];=0A=
    delete this._object[key];=0A=
    return value;=0A=
  }=0A=
=0A=
  function toObject() {=0A=
    return Object.clone(this._object);=0A=
  }=0A=
=0A=
  function keys() {=0A=
    return this.pluck('key');=0A=
  }=0A=
=0A=
  function values() {=0A=
    return this.pluck('value');=0A=
  }=0A=
=0A=
  function index(value) {=0A=
    var match =3D this.detect(function(pair) {=0A=
      return pair.value =3D=3D=3D value;=0A=
    });=0A=
    return match && match.key;=0A=
  }=0A=
=0A=
  function merge(object) {=0A=
    return this.clone().update(object);=0A=
  }=0A=
=0A=
  function update(object) {=0A=
    return new Hash(object).inject(this, function(result, pair) {=0A=
      result.set(pair.key, pair.value);=0A=
      return result;=0A=
    });=0A=
  }=0A=
=0A=
  function toQueryPair(key, value) {=0A=
    if (Object.isUndefined(value)) return key;=0A=
    return key + '=3D' + encodeURIComponent(String.interpret(value));=0A=
  }=0A=
=0A=
  function toQueryString() {=0A=
    return this.inject([], function(results, pair) {=0A=
      var key =3D encodeURIComponent(pair.key), values =3D pair.value;=0A=
=0A=
      if (values && typeof values =3D=3D 'object') {=0A=
        if (Object.isArray(values))=0A=
          return results.concat(values.map(toQueryPair.curry(key)));=0A=
      } else results.push(toQueryPair(key, values));=0A=
      return results;=0A=
    }).join('&');=0A=
  }=0A=
=0A=
  function inspect() {=0A=
    return '#<Hash:{' + this.map(function(pair) {=0A=
      return pair.map(Object.inspect).join(': ');=0A=
    }).join(', ') + '}>';=0A=
  }=0A=
=0A=
  function toJSON() {=0A=
    return Object.toJSON(this.toObject());=0A=
  }=0A=
=0A=
  function clone() {=0A=
    return new Hash(this);=0A=
  }=0A=
=0A=
  return {=0A=
    initialize:             initialize,=0A=
    _each:                  _each,=0A=
    set:                    set,=0A=
    get:                    get,=0A=
    unset:                  unset,=0A=
    toObject:               toObject,=0A=
    toTemplateReplacements: toObject,=0A=
    keys:                   keys,=0A=
    values:                 values,=0A=
    index:                  index,=0A=
    merge:                  merge,=0A=
    update:                 update,=0A=
    toQueryString:          toQueryString,=0A=
    inspect:                inspect,=0A=
    toJSON:                 toJSON,=0A=
    clone:                  clone=0A=
  };=0A=
})());=0A=
=0A=
Hash.from =3D $H;=0A=
Object.extend(Number.prototype, (function() {=0A=
  function toColorPart() {=0A=
    return this.toPaddedString(2, 16);=0A=
  }=0A=
=0A=
  function succ() {=0A=
    return this + 1;=0A=
  }=0A=
=0A=
  function times(iterator, context) {=0A=
    $R(0, this, true).each(iterator, context);=0A=
    return this;=0A=
  }=0A=
=0A=
  function toPaddedString(length, radix) {=0A=
    var string =3D this.toString(radix || 10);=0A=
    return '0'.times(length - string.length) + string;=0A=
  }=0A=
=0A=
  function toJSON() {=0A=
    return isFinite(this) ? this.toString() : 'null';=0A=
  }=0A=
=0A=
  function abs() {=0A=
    return Math.abs(this);=0A=
  }=0A=
=0A=
  function round() {=0A=
    return Math.round(this);=0A=
  }=0A=
=0A=
  function ceil() {=0A=
    return Math.ceil(this);=0A=
  }=0A=
=0A=
  function floor() {=0A=
    return Math.floor(this);=0A=
  }=0A=
=0A=
  return {=0A=
    toColorPart:    toColorPart,=0A=
    succ:           succ,=0A=
    times:          times,=0A=
    toPaddedString: toPaddedString,=0A=
    toJSON:         toJSON,=0A=
    abs:            abs,=0A=
    round:          round,=0A=
    ceil:           ceil,=0A=
    floor:          floor=0A=
  };=0A=
})());=0A=
=0A=
function $R(start, end, exclusive) {=0A=
  return new ObjectRange(start, end, exclusive);=0A=
}=0A=
=0A=
var ObjectRange =3D Class.create(Enumerable, (function() {=0A=
  function initialize(start, end, exclusive) {=0A=
    this.start =3D start;=0A=
    this.end =3D end;=0A=
    this.exclusive =3D exclusive;=0A=
  }=0A=
=0A=
  function _each(iterator) {=0A=
    var value =3D this.start;=0A=
    while (this.include(value)) {=0A=
      iterator(value);=0A=
      value =3D value.succ();=0A=
    }=0A=
  }=0A=
=0A=
  function include(value) {=0A=
    if (value < this.start)=0A=
      return false;=0A=
    if (this.exclusive)=0A=
      return value < this.end;=0A=
    return value <=3D this.end;=0A=
  }=0A=
=0A=
  return {=0A=
    initialize: initialize,=0A=
    _each:      _each,=0A=
    include:    include=0A=
  };=0A=
})());=0A=
=0A=
=0A=
=0A=
var Ajax =3D {=0A=
  getTransport: function() {=0A=
    return Try.these(=0A=
      function() {return new XMLHttpRequest()},=0A=
      function() {return new ActiveXObject('Msxml2.XMLHTTP')},=0A=
      function() {return new ActiveXObject('Microsoft.XMLHTTP')}=0A=
    ) || false;=0A=
  },=0A=
=0A=
  activeRequestCount: 0=0A=
};=0A=
=0A=
Ajax.Responders =3D {=0A=
  responders: [],=0A=
=0A=
  _each: function(iterator) {=0A=
    this.responders._each(iterator);=0A=
  },=0A=
=0A=
  register: function(responder) {=0A=
    if (!this.include(responder))=0A=
      this.responders.push(responder);=0A=
  },=0A=
=0A=
  unregister: function(responder) {=0A=
    this.responders =3D this.responders.without(responder);=0A=
  },=0A=
=0A=
  dispatch: function(callback, request, transport, json) {=0A=
    this.each(function(responder) {=0A=
      if (Object.isFunction(responder[callback])) {=0A=
        try {=0A=
          responder[callback].apply(responder, [request, transport, =
json]);=0A=
        } catch (e) { }=0A=
      }=0A=
    });=0A=
  }=0A=
};=0A=
=0A=
Object.extend(Ajax.Responders, Enumerable);=0A=
=0A=
Ajax.Responders.register({=0A=
  onCreate:   function() { Ajax.activeRequestCount++ },=0A=
  onComplete: function() { Ajax.activeRequestCount-- }=0A=
});=0A=
Ajax.Base =3D Class.create({=0A=
  initialize: function(options) {=0A=
    this.options =3D {=0A=
      method:       'post',=0A=
      asynchronous: true,=0A=
      contentType:  'application/x-www-form-urlencoded',=0A=
      encoding:     'UTF-8',=0A=
      parameters:   '',=0A=
      evalJSON:     true,=0A=
      evalJS:       true=0A=
    };=0A=
    Object.extend(this.options, options || { });=0A=
=0A=
    this.options.method =3D this.options.method.toLowerCase();=0A=
=0A=
    if (Object.isString(this.options.parameters))=0A=
      this.options.parameters =3D =
this.options.parameters.toQueryParams();=0A=
    else if (Object.isHash(this.options.parameters))=0A=
      this.options.parameters =3D this.options.parameters.toObject();=0A=
  }=0A=
});=0A=
Ajax.Request =3D Class.create(Ajax.Base, {=0A=
  _complete: false,=0A=
=0A=
  initialize: function($super, url, options) {=0A=
    $super(options);=0A=
    this.transport =3D Ajax.getTransport();=0A=
    this.request(url);=0A=
  },=0A=
=0A=
  request: function(url) {=0A=
    this.url =3D url;=0A=
    this.method =3D this.options.method;=0A=
    var params =3D Object.clone(this.options.parameters);=0A=
=0A=
    if (!['get', 'post'].include(this.method)) {=0A=
      params['_method'] =3D this.method;=0A=
      this.method =3D 'post';=0A=
    }=0A=
=0A=
    this.parameters =3D params;=0A=
=0A=
    if (params =3D Object.toQueryString(params)) {=0A=
      if (this.method =3D=3D 'get')=0A=
        this.url +=3D (this.url.include('?') ? '&' : '?') + params;=0A=
      else if (/Konqueror|Safari|KHTML/.test(navigator.userAgent))=0A=
        params +=3D '&_=3D';=0A=
    }=0A=
=0A=
    try {=0A=
      var response =3D new Ajax.Response(this);=0A=
      if (this.options.onCreate) this.options.onCreate(response);=0A=
      Ajax.Responders.dispatch('onCreate', this, response);=0A=
=0A=
      this.transport.open(this.method.toUpperCase(), this.url,=0A=
        this.options.asynchronous);=0A=
=0A=
      if (this.options.asynchronous) =
this.respondToReadyState.bind(this).defer(1);=0A=
=0A=
      this.transport.onreadystatechange =3D =
this.onStateChange.bind(this);=0A=
      this.setRequestHeaders();=0A=
=0A=
      this.body =3D this.method =3D=3D 'post' ? (this.options.postBody =
|| params) : null;=0A=
      this.transport.send(this.body);=0A=
=0A=
      /* Force Firefox to handle ready state 4 for synchronous requests =
*/=0A=
      if (!this.options.asynchronous && this.transport.overrideMimeType)=0A=
        this.onStateChange();=0A=
=0A=
    }=0A=
    catch (e) {=0A=
      this.dispatchException(e);=0A=
    }=0A=
  },=0A=
=0A=
  onStateChange: function() {=0A=
    var readyState =3D this.transport.readyState;=0A=
    if (readyState > 1 && !((readyState =3D=3D 4) && this._complete))=0A=
      this.respondToReadyState(this.transport.readyState);=0A=
  },=0A=
=0A=
  setRequestHeaders: function() {=0A=
    var headers =3D {=0A=
      'X-Requested-With': 'XMLHttpRequest',=0A=
      'X-Prototype-Version': Prototype.Version,=0A=
      'Accept': 'text/javascript, text/html, application/xml, text/xml, =
*/*'=0A=
    };=0A=
=0A=
    if (this.method =3D=3D 'post') {=0A=
      headers['Content-type'] =3D this.options.contentType +=0A=
        (this.options.encoding ? '; charset=3D' + this.options.encoding =
: '');=0A=
=0A=
      /* Force "Connection: close" for older Mozilla browsers to work=0A=
       * around a bug where XMLHttpRequest sends an incorrect=0A=
       * Content-length header. See Mozilla Bugzilla #246651.=0A=
       */=0A=
      if (this.transport.overrideMimeType &&=0A=
          (navigator.userAgent.match(/Gecko\/(\d{4})/) || [0,2005])[1] < =
2005)=0A=
            headers['Connection'] =3D 'close';=0A=
    }=0A=
=0A=
    if (typeof this.options.requestHeaders =3D=3D 'object') {=0A=
      var extras =3D this.options.requestHeaders;=0A=
=0A=
      if (Object.isFunction(extras.push))=0A=
        for (var i =3D 0, length =3D extras.length; i < length; i +=3D 2)=0A=
          headers[extras[i]] =3D extras[i+1];=0A=
      else=0A=
        $H(extras).each(function(pair) { headers[pair.key] =3D =
pair.value });=0A=
    }=0A=
=0A=
    for (var name in headers)=0A=
      this.transport.setRequestHeader(name, headers[name]);=0A=
  },=0A=
=0A=
  success: function() {=0A=
    var status =3D this.getStatus();=0A=
    return !status || (status >=3D 200 && status < 300);=0A=
  },=0A=
=0A=
  getStatus: function() {=0A=
    try {=0A=
      return this.transport.status || 0;=0A=
    } catch (e) { return 0 }=0A=
  },=0A=
=0A=
  respondToReadyState: function(readyState) {=0A=
    var state =3D Ajax.Request.Events[readyState], response =3D new =
Ajax.Response(this);=0A=
=0A=
    if (state =3D=3D 'Complete') {=0A=
      try {=0A=
        this._complete =3D true;=0A=
        (this.options['on' + response.status]=0A=
         || this.options['on' + (this.success() ? 'Success' : 'Failure')]=0A=
         || Prototype.emptyFunction)(response, response.headerJSON);=0A=
      } catch (e) {=0A=
        this.dispatchException(e);=0A=
      }=0A=
=0A=
      var contentType =3D response.getHeader('Content-type');=0A=
      if (this.options.evalJS =3D=3D 'force'=0A=
          || (this.options.evalJS && this.isSameOrigin() && contentType=0A=
          && =
contentType.match(/^\s*(text|application)\/(x-)?(java|ecma)script(;.*)?\s=
*$/i)))=0A=
        this.evalResponse();=0A=
    }=0A=
=0A=
    try {=0A=
      (this.options['on' + state] || Prototype.emptyFunction)(response, =
response.headerJSON);=0A=
      Ajax.Responders.dispatch('on' + state, this, response, =
response.headerJSON);=0A=
    } catch (e) {=0A=
      this.dispatchException(e);=0A=
    }=0A=
=0A=
    if (state =3D=3D 'Complete') {=0A=
      this.transport.onreadystatechange =3D Prototype.emptyFunction;=0A=
    }=0A=
  },=0A=
=0A=
  isSameOrigin: function() {=0A=
    var m =3D this.url.match(/^\s*https?:\/\/[^\/]*/);=0A=
    return !m || (m[0] =3D=3D =
'#{protocol}//#{domain}#{port}'.interpolate({=0A=
      protocol: location.protocol,=0A=
      domain: document.domain,=0A=
      port: location.port ? ':' + location.port : ''=0A=
    }));=0A=
  },=0A=
=0A=
  getHeader: function(name) {=0A=
    try {=0A=
      return this.transport.getResponseHeader(name) || null;=0A=
    } catch (e) { return null; }=0A=
  },=0A=
=0A=
  evalResponse: function() {=0A=
    try {=0A=
      return eval((this.transport.responseText || '').unfilterJSON());=0A=
    } catch (e) {=0A=
      this.dispatchException(e);=0A=
    }=0A=
  },=0A=
=0A=
  dispatchException: function(exception) {=0A=
    (this.options.onException || Prototype.emptyFunction)(this, =
exception);=0A=
    Ajax.Responders.dispatch('onException', this, exception);=0A=
  }=0A=
});=0A=
=0A=
Ajax.Request.Events =3D=0A=
  ['Uninitialized', 'Loading', 'Loaded', 'Interactive', 'Complete'];=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
=0A=
Ajax.Response =3D Class.create({=0A=
  initialize: function(request){=0A=
    this.request =3D request;=0A=
    var transport  =3D this.transport  =3D request.transport,=0A=
        readyState =3D this.readyState =3D transport.readyState;=0A=
=0A=
    if((readyState > 2 && !Prototype.Browser.IE) || readyState =3D=3D 4) =
{=0A=
      this.status       =3D this.getStatus();=0A=
      this.statusText   =3D this.getStatusText();=0A=
      this.responseText =3D String.interpret(transport.responseText);=0A=
      this.headerJSON   =3D this._getHeaderJSON();=0A=
    }=0A=
=0A=
    if(readyState =3D=3D 4) {=0A=
      var xml =3D transport.responseXML;=0A=
      this.responseXML  =3D Object.isUndefined(xml) ? null : xml;=0A=
      this.responseJSON =3D this._getResponseJSON();=0A=
    }=0A=
  },=0A=
=0A=
  status:      0,=0A=
=0A=
  statusText: '',=0A=
=0A=
  getStatus: Ajax.Request.prototype.getStatus,=0A=
=0A=
  getStatusText: function() {=0A=
    try {=0A=
      return this.transport.statusText || '';=0A=
    } catch (e) { return '' }=0A=
  },=0A=
=0A=
  getHeader: Ajax.Request.prototype.getHeader,=0A=
=0A=
  getAllHeaders: function() {=0A=
    try {=0A=
      return this.getAllResponseHeaders();=0A=
    } catch (e) { return null }=0A=
  },=0A=
=0A=
  getResponseHeader: function(name) {=0A=
    return this.transport.getResponseHeader(name);=0A=
  },=0A=
=0A=
  getAllResponseHeaders: function() {=0A=
    return this.transport.getAllResponseHeaders();=0A=
  },=0A=
=0A=
  _getHeaderJSON: function() {=0A=
    var json =3D this.getHeader('X-JSON');=0A=
    if (!json) return null;=0A=
    json =3D decodeURIComponent(escape(json));=0A=
    try {=0A=
      return json.evalJSON(this.request.options.sanitizeJSON ||=0A=
        !this.request.isSameOrigin());=0A=
    } catch (e) {=0A=
      this.request.dispatchException(e);=0A=
    }=0A=
  },=0A=
=0A=
  _getResponseJSON: function() {=0A=
    var options =3D this.request.options;=0A=
    if (!options.evalJSON || (options.evalJSON !=3D 'force' &&=0A=
      !(this.getHeader('Content-type') || =
'').include('application/json')) ||=0A=
        this.responseText.blank())=0A=
          return null;=0A=
    try {=0A=
      return this.responseText.evalJSON(options.sanitizeJSON ||=0A=
        !this.request.isSameOrigin());=0A=
    } catch (e) {=0A=
      this.request.dispatchException(e);=0A=
    }=0A=
  }=0A=
});=0A=
=0A=
Ajax.Updater =3D Class.create(Ajax.Request, {=0A=
  initialize: function($super, container, url, options) {=0A=
    this.container =3D {=0A=
      success: (container.success || container),=0A=
      failure: (container.failure || (container.success ? null : =
container))=0A=
    };=0A=
=0A=
    options =3D Object.clone(options);=0A=
    var onComplete =3D options.onComplete;=0A=
    options.onComplete =3D (function(response, json) {=0A=
      this.updateContent(response.responseText);=0A=
      if (Object.isFunction(onComplete)) onComplete(response, json);=0A=
    }).bind(this);=0A=
=0A=
    $super(url, options);=0A=
  },=0A=
=0A=
  updateContent: function(responseText) {=0A=
    var receiver =3D this.container[this.success() ? 'success' : =
'failure'],=0A=
        options =3D this.options;=0A=
=0A=
    if (!options.evalScripts) responseText =3D =
responseText.stripScripts();=0A=
=0A=
    if (receiver =3D $(receiver)) {=0A=
      if (options.insertion) {=0A=
        if (Object.isString(options.insertion)) {=0A=
          var insertion =3D { }; insertion[options.insertion] =3D =
responseText;=0A=
          receiver.insert(insertion);=0A=
        }=0A=
        else options.insertion(receiver, responseText);=0A=
      }=0A=
      else receiver.update(responseText);=0A=
    }=0A=
  }=0A=
});=0A=
=0A=
Ajax.PeriodicalUpdater =3D Class.create(Ajax.Base, {=0A=
  initialize: function($super, container, url, options) {=0A=
    $super(options);=0A=
    this.onComplete =3D this.options.onComplete;=0A=
=0A=
    this.frequency =3D (this.options.frequency || 2);=0A=
    this.decay =3D (this.options.decay || 1);=0A=
=0A=
    this.updater =3D { };=0A=
    this.container =3D container;=0A=
    this.url =3D url;=0A=
=0A=
    this.start();=0A=
  },=0A=
=0A=
  start: function() {=0A=
    this.options.onComplete =3D this.updateComplete.bind(this);=0A=
    this.onTimerEvent();=0A=
  },=0A=
=0A=
  stop: function() {=0A=
    this.updater.options.onComplete =3D undefined;=0A=
    clearTimeout(this.timer);=0A=
    (this.onComplete || Prototype.emptyFunction).apply(this, arguments);=0A=
  },=0A=
=0A=
  updateComplete: function(response) {=0A=
    if (this.options.decay) {=0A=
      this.decay =3D (response.responseText =3D=3D this.lastText ?=0A=
        this.decay * this.options.decay : 1);=0A=
=0A=
      this.lastText =3D response.responseText;=0A=
    }=0A=
    this.timer =3D this.onTimerEvent.bind(this).delay(this.decay * =
this.frequency);=0A=
  },=0A=
=0A=
  onTimerEvent: function() {=0A=
    this.updater =3D new Ajax.Updater(this.container, this.url, =
this.options);=0A=
  }=0A=
});=0A=
=0A=
=0A=
=0A=
function $(element) {=0A=
  if (arguments.length > 1) {=0A=
    for (var i =3D 0, elements =3D [], length =3D arguments.length; i < =
length; i++)=0A=
      elements.push($(arguments[i]));=0A=
    return elements;=0A=
  }=0A=
  if (Object.isString(element))=0A=
    element =3D document.getElementById(element);=0A=
  return Element.extend(element);=0A=
}=0A=
=0A=
if (Prototype.BrowserFeatures.XPath) {=0A=
  document._getElementsByXPath =3D function(expression, parentElement) {=0A=
    var results =3D [];=0A=
    var query =3D document.evaluate(expression, $(parentElement) || =
document,=0A=
      null, XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);=0A=
    for (var i =3D 0, length =3D query.snapshotLength; i < length; i++)=0A=
      results.push(Element.extend(query.snapshotItem(i)));=0A=
    return results;=0A=
  };=0A=
}=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
if (!window.Node) var Node =3D { };=0A=
=0A=
if (!Node.ELEMENT_NODE) {=0A=
  Object.extend(Node, {=0A=
    ELEMENT_NODE: 1,=0A=
    ATTRIBUTE_NODE: 2,=0A=
    TEXT_NODE: 3,=0A=
    CDATA_SECTION_NODE: 4,=0A=
    ENTITY_REFERENCE_NODE: 5,=0A=
    ENTITY_NODE: 6,=0A=
    PROCESSING_INSTRUCTION_NODE: 7,=0A=
    COMMENT_NODE: 8,=0A=
    DOCUMENT_NODE: 9,=0A=
    DOCUMENT_TYPE_NODE: 10,=0A=
    DOCUMENT_FRAGMENT_NODE: 11,=0A=
    NOTATION_NODE: 12=0A=
  });=0A=
}=0A=
=0A=
=0A=
(function(global) {=0A=
=0A=
  var SETATTRIBUTE_IGNORES_NAME =3D (function(){=0A=
    var elForm =3D document.createElement("form");=0A=
    var elInput =3D document.createElement("input");=0A=
    var root =3D document.documentElement;=0A=
    elInput.setAttribute("name", "test");=0A=
    elForm.appendChild(elInput);=0A=
    root.appendChild(elForm);=0A=
    var isBuggy =3D elForm.elements=0A=
      ? (typeof elForm.elements.test =3D=3D "undefined")=0A=
      : null;=0A=
    root.removeChild(elForm);=0A=
    elForm =3D elInput =3D null;=0A=
    return isBuggy;=0A=
  })();=0A=
=0A=
  var element =3D global.Element;=0A=
  global.Element =3D function(tagName, attributes) {=0A=
    attributes =3D attributes || { };=0A=
    tagName =3D tagName.toLowerCase();=0A=
    var cache =3D Element.cache;=0A=
    if (SETATTRIBUTE_IGNORES_NAME && attributes.name) {=0A=
      tagName =3D '<' + tagName + ' name=3D"' + attributes.name + '">';=0A=
      delete attributes.name;=0A=
      return Element.writeAttribute(document.createElement(tagName), =
attributes);=0A=
    }=0A=
    if (!cache[tagName]) cache[tagName] =3D =
Element.extend(document.createElement(tagName));=0A=
    return Element.writeAttribute(cache[tagName].cloneNode(false), =
attributes);=0A=
  };=0A=
  Object.extend(global.Element, element || { });=0A=
  if (element) global.Element.prototype =3D element.prototype;=0A=
})(this);=0A=
=0A=
Element.cache =3D { };=0A=
Element.idCounter =3D 1;=0A=
=0A=
Element.Methods =3D {=0A=
  visible: function(element) {=0A=
    return $(element).style.display !=3D 'none';=0A=
  },=0A=
=0A=
  toggle: function(element) {=0A=
    element =3D $(element);=0A=
    Element[Element.visible(element) ? 'hide' : 'show'](element);=0A=
    return element;=0A=
  },=0A=
=0A=
=0A=
  hide: function(element) {=0A=
    element =3D $(element);=0A=
    element.style.display =3D 'none';=0A=
    return element;=0A=
  },=0A=
=0A=
  show: function(element) {=0A=
    element =3D $(element);=0A=
    element.style.display =3D '';=0A=
    return element;=0A=
  },=0A=
=0A=
  remove: function(element) {=0A=
    element =3D $(element);=0A=
    element.parentNode.removeChild(element);=0A=
    return element;=0A=
  },=0A=
=0A=
  update: (function(){=0A=
=0A=
    var SELECT_ELEMENT_INNERHTML_BUGGY =3D (function(){=0A=
      var el =3D document.createElement("select"),=0A=
          isBuggy =3D true;=0A=
      el.innerHTML =3D "<option value=3D\"test\">test</option>";=0A=
      if (el.options && el.options[0]) {=0A=
        isBuggy =3D el.options[0].nodeName.toUpperCase() !=3D=3D =
"OPTION";=0A=
      }=0A=
      el =3D null;=0A=
      return isBuggy;=0A=
    })();=0A=
=0A=
    var TABLE_ELEMENT_INNERHTML_BUGGY =3D (function(){=0A=
      try {=0A=
        var el =3D document.createElement("table");=0A=
        if (el && el.tBodies) {=0A=
          el.innerHTML =3D "<tbody><tr><td>test</td></tr></tbody>";=0A=
          var isBuggy =3D typeof el.tBodies[0] =3D=3D "undefined";=0A=
          el =3D null;=0A=
          return isBuggy;=0A=
        }=0A=
      } catch (e) {=0A=
        return true;=0A=
      }=0A=
    })();=0A=
=0A=
    var SCRIPT_ELEMENT_REJECTS_TEXTNODE_APPENDING =3D (function () {=0A=
      var s =3D document.createElement("script"),=0A=
          isBuggy =3D false;=0A=
      try {=0A=
        s.appendChild(document.createTextNode(""));=0A=
        isBuggy =3D !s.firstChild ||=0A=
          s.firstChild && s.firstChild.nodeType !=3D=3D 3;=0A=
      } catch (e) {=0A=
        isBuggy =3D true;=0A=
      }=0A=
      s =3D null;=0A=
      return isBuggy;=0A=
    })();=0A=
=0A=
    function update(element, content) {=0A=
      element =3D $(element);=0A=
=0A=
      if (content && content.toElement)=0A=
        content =3D content.toElement();=0A=
=0A=
      if (Object.isElement(content))=0A=
        return element.update().insert(content);=0A=
=0A=
      content =3D Object.toHTML(content);=0A=
=0A=
      var tagName =3D element.tagName.toUpperCase();=0A=
=0A=
      if (tagName =3D=3D=3D 'SCRIPT' && =
SCRIPT_ELEMENT_REJECTS_TEXTNODE_APPENDING) {=0A=
        element.text =3D content;=0A=
        return element;=0A=
      }=0A=
=0A=
      if (SELECT_ELEMENT_INNERHTML_BUGGY || =
TABLE_ELEMENT_INNERHTML_BUGGY) {=0A=
        if (tagName in Element._insertionTranslations.tags) {=0A=
          while (element.firstChild) {=0A=
            element.removeChild(element.firstChild);=0A=
          }=0A=
          Element._getContentFromAnonymousElement(tagName, =
content.stripScripts())=0A=
            .each(function(node) {=0A=
              element.appendChild(node)=0A=
            });=0A=
        }=0A=
        else {=0A=
          element.innerHTML =3D content.stripScripts();=0A=
        }=0A=
      }=0A=
      else {=0A=
        element.innerHTML =3D content.stripScripts();=0A=
      }=0A=
=0A=
      content.evalScripts.bind(content).defer();=0A=
      return element;=0A=
    }=0A=
=0A=
    return update;=0A=
  })(),=0A=
=0A=
  replace: function(element, content) {=0A=
    element =3D $(element);=0A=
    if (content && content.toElement) content =3D content.toElement();=0A=
    else if (!Object.isElement(content)) {=0A=
      content =3D Object.toHTML(content);=0A=
      var range =3D element.ownerDocument.createRange();=0A=
      range.selectNode(element);=0A=
      content.evalScripts.bind(content).defer();=0A=
      content =3D range.createContextualFragment(content.stripScripts());=0A=
    }=0A=
    element.parentNode.replaceChild(content, element);=0A=
    return element;=0A=
  },=0A=
=0A=
  insert: function(element, insertions) {=0A=
    element =3D $(element);=0A=
=0A=
    if (Object.isString(insertions) || Object.isNumber(insertions) ||=0A=
        Object.isElement(insertions) || (insertions && =
(insertions.toElement || insertions.toHTML)))=0A=
          insertions =3D {bottom:insertions};=0A=
=0A=
    var content, insert, tagName, childNodes;=0A=
=0A=
    for (var position in insertions) {=0A=
      content  =3D insertions[position];=0A=
      position =3D position.toLowerCase();=0A=
      insert =3D Element._insertionTranslations[position];=0A=
=0A=
      if (content && content.toElement) content =3D content.toElement();=0A=
      if (Object.isElement(content)) {=0A=
        insert(element, content);=0A=
        continue;=0A=
      }=0A=
=0A=
      content =3D Object.toHTML(content);=0A=
=0A=
      tagName =3D ((position =3D=3D 'before' || position =3D=3D 'after')=0A=
        ? element.parentNode : element).tagName.toUpperCase();=0A=
=0A=
      childNodes =3D Element._getContentFromAnonymousElement(tagName, =
content.stripScripts());=0A=
=0A=
      if (position =3D=3D 'top' || position =3D=3D 'after') =
childNodes.reverse();=0A=
      childNodes.each(insert.curry(element));=0A=
=0A=
      content.evalScripts.bind(content).defer();=0A=
    }=0A=
=0A=
    return element;=0A=
  },=0A=
=0A=
  wrap: function(element, wrapper, attributes) {=0A=
    element =3D $(element);=0A=
    if (Object.isElement(wrapper))=0A=
      $(wrapper).writeAttribute(attributes || { });=0A=
    else if (Object.isString(wrapper)) wrapper =3D new Element(wrapper, =
attributes);=0A=
    else wrapper =3D new Element('div', wrapper);=0A=
    if (element.parentNode)=0A=
      element.parentNode.replaceChild(wrapper, element);=0A=
    wrapper.appendChild(element);=0A=
    return wrapper;=0A=
  },=0A=
=0A=
  inspect: function(element) {=0A=
    element =3D $(element);=0A=
    var result =3D '<' + element.tagName.toLowerCase();=0A=
    $H({'id': 'id', 'className': 'class'}).each(function(pair) {=0A=
      var property =3D pair.first(), attribute =3D pair.last();=0A=
      var value =3D (element[property] || '').toString();=0A=
      if (value) result +=3D ' ' + attribute + '=3D' + =
value.inspect(true);=0A=
    });=0A=
    return result + '>';=0A=
  },=0A=
=0A=
  recursivelyCollect: function(element, property) {=0A=
    element =3D $(element);=0A=
    var elements =3D [];=0A=
    while (element =3D element[property])=0A=
      if (element.nodeType =3D=3D 1)=0A=
        elements.push(Element.extend(element));=0A=
    return elements;=0A=
  },=0A=
=0A=
  ancestors: function(element) {=0A=
    return Element.recursivelyCollect(element, 'parentNode');=0A=
  },=0A=
=0A=
  descendants: function(element) {=0A=
    return Element.select(element, "*");=0A=
  },=0A=
=0A=
  firstDescendant: function(element) {=0A=
    element =3D $(element).firstChild;=0A=
    while (element && element.nodeType !=3D 1) element =3D =
element.nextSibling;=0A=
    return $(element);=0A=
  },=0A=
=0A=
  immediateDescendants: function(element) {=0A=
    if (!(element =3D $(element).firstChild)) return [];=0A=
    while (element && element.nodeType !=3D 1) element =3D =
element.nextSibling;=0A=
    if (element) return [element].concat($(element).nextSiblings());=0A=
    return [];=0A=
  },=0A=
=0A=
  previousSiblings: function(element) {=0A=
    return Element.recursivelyCollect(element, 'previousSibling');=0A=
  },=0A=
=0A=
  nextSiblings: function(element) {=0A=
    return Element.recursivelyCollect(element, 'nextSibling');=0A=
  },=0A=
=0A=
  siblings: function(element) {=0A=
    element =3D $(element);=0A=
    return Element.previousSiblings(element).reverse()=0A=
      .concat(Element.nextSiblings(element));=0A=
  },=0A=
=0A=
  match: function(element, selector) {=0A=
    if (Object.isString(selector))=0A=
      selector =3D new Selector(selector);=0A=
    return selector.match($(element));=0A=
  },=0A=
=0A=
  up: function(element, expression, index) {=0A=
    element =3D $(element);=0A=
    if (arguments.length =3D=3D 1) return $(element.parentNode);=0A=
    var ancestors =3D Element.ancestors(element);=0A=
    return Object.isNumber(expression) ? ancestors[expression] :=0A=
      Selector.findElement(ancestors, expression, index);=0A=
  },=0A=
=0A=
  down: function(element, expression, index) {=0A=
    element =3D $(element);=0A=
    if (arguments.length =3D=3D 1) return =
Element.firstDescendant(element);=0A=
    return Object.isNumber(expression) ? =
Element.descendants(element)[expression] :=0A=
      Element.select(element, expression)[index || 0];=0A=
  },=0A=
=0A=
  previous: function(element, expression, index) {=0A=
    element =3D $(element);=0A=
    if (arguments.length =3D=3D 1) return =
$(Selector.handlers.previousElementSibling(element));=0A=
    var previousSiblings =3D Element.previousSiblings(element);=0A=
    return Object.isNumber(expression) ? previousSiblings[expression] :=0A=
      Selector.findElement(previousSiblings, expression, index);=0A=
  },=0A=
=0A=
  next: function(element, expression, index) {=0A=
    element =3D $(element);=0A=
    if (arguments.length =3D=3D 1) return =
$(Selector.handlers.nextElementSibling(element));=0A=
    var nextSiblings =3D Element.nextSiblings(element);=0A=
    return Object.isNumber(expression) ? nextSiblings[expression] :=0A=
      Selector.findElement(nextSiblings, expression, index);=0A=
  },=0A=
=0A=
=0A=
  select: function(element) {=0A=
    var args =3D Array.prototype.slice.call(arguments, 1);=0A=
    return Selector.findChildElements(element, args);=0A=
  },=0A=
=0A=
  adjacent: function(element) {=0A=
    var args =3D Array.prototype.slice.call(arguments, 1);=0A=
    return Selector.findChildElements(element.parentNode, =
args).without(element);=0A=
  },=0A=
=0A=
  identify: function(element) {=0A=
    element =3D $(element);=0A=
    var id =3D Element.readAttribute(element, 'id');=0A=
    if (id) return id;=0A=
    do { id =3D 'anonymous_element_' + Element.idCounter++ } while =
($(id));=0A=
    Element.writeAttribute(element, 'id', id);=0A=
    return id;=0A=
  },=0A=
=0A=
  readAttribute: function(element, name) {=0A=
    element =3D $(element);=0A=
    if (Prototype.Browser.IE) {=0A=
      var t =3D Element._attributeTranslations.read;=0A=
      if (t.values[name]) return t.values[name](element, name);=0A=
      if (t.names[name]) name =3D t.names[name];=0A=
      if (name.include(':')) {=0A=
        return (!element.attributes || !element.attributes[name]) ? null =
:=0A=
         element.attributes[name].value;=0A=
      }=0A=
    }=0A=
    return element.getAttribute(name);=0A=
  },=0A=
=0A=
  writeAttribute: function(element, name, value) {=0A=
    element =3D $(element);=0A=
    var attributes =3D { }, t =3D Element._attributeTranslations.write;=0A=
=0A=
    if (typeof name =3D=3D 'object') attributes =3D name;=0A=
    else attributes[name] =3D Object.isUndefined(value) ? true : value;=0A=
=0A=
    for (var attr in attributes) {=0A=
      name =3D t.names[attr] || attr;=0A=
      value =3D attributes[attr];=0A=
      if (t.values[attr]) name =3D t.values[attr](element, value);=0A=
      if (value =3D=3D=3D false || value =3D=3D=3D null)=0A=
        element.removeAttribute(name);=0A=
      else if (value =3D=3D=3D true)=0A=
        element.setAttribute(name, name);=0A=
      else element.setAttribute(name, value);=0A=
    }=0A=
    return element;=0A=
  },=0A=
=0A=
  getHeight: function(element) {=0A=
    return Element.getDimensions(element).height;=0A=
  },=0A=
=0A=
  getWidth: function(element) {=0A=
    return Element.getDimensions(element).width;=0A=
  },=0A=
=0A=
  classNames: function(element) {=0A=
    return new Element.ClassNames(element);=0A=
  },=0A=
=0A=
  hasClassName: function(element, className) {=0A=
    if (!(element =3D $(element))) return;=0A=
    var elementClassName =3D element.className;=0A=
    return (elementClassName.length > 0 && (elementClassName =3D=3D =
className ||=0A=
      new RegExp("(^|\\s)" + className + =
"(\\s|$)").test(elementClassName)));=0A=
  },=0A=
=0A=
  addClassName: function(element, className) {=0A=
    if (!(element =3D $(element))) return;=0A=
    if (!Element.hasClassName(element, className))=0A=
      element.className +=3D (element.className ? ' ' : '') + className;=0A=
    return element;=0A=
  },=0A=
=0A=
  removeClassName: function(element, className) {=0A=
    if (!(element =3D $(element))) return;=0A=
    element.className =3D element.className.replace(=0A=
      new RegExp("(^|\\s+)" + className + "(\\s+|$)"), ' ').strip();=0A=
    return element;=0A=
  },=0A=
=0A=
  toggleClassName: function(element, className) {=0A=
    if (!(element =3D $(element))) return;=0A=
    return Element[Element.hasClassName(element, className) ?=0A=
      'removeClassName' : 'addClassName'](element, className);=0A=
  },=0A=
=0A=
  cleanWhitespace: function(element) {=0A=
    element =3D $(element);=0A=
    var node =3D element.firstChild;=0A=
    while (node) {=0A=
      var nextNode =3D node.nextSibling;=0A=
      if (node.nodeType =3D=3D 3 && !/\S/.test(node.nodeValue))=0A=
        element.removeChild(node);=0A=
      node =3D nextNode;=0A=
    }=0A=
    return element;=0A=
  },=0A=
=0A=
  empty: function(element) {=0A=
    return $(element).innerHTML.blank();=0A=
  },=0A=
=0A=
  descendantOf: function(element, ancestor) {=0A=
    element =3D $(element), ancestor =3D $(ancestor);=0A=
=0A=
    if (element.compareDocumentPosition)=0A=
      return (element.compareDocumentPosition(ancestor) & 8) =3D=3D=3D 8;=0A=
=0A=
    if (ancestor.contains)=0A=
      return ancestor.contains(element) && ancestor !=3D=3D element;=0A=
=0A=
    while (element =3D element.parentNode)=0A=
      if (element =3D=3D ancestor) return true;=0A=
=0A=
    return false;=0A=
  },=0A=
=0A=
  scrollTo: function(element) {=0A=
    element =3D $(element);=0A=
    var pos =3D Element.cumulativeOffset(element);=0A=
    window.scrollTo(pos[0], pos[1]);=0A=
    return element;=0A=
  },=0A=
=0A=
  getStyle: function(element, style) {=0A=
    element =3D $(element);=0A=
    style =3D style =3D=3D 'float' ? 'cssFloat' : style.camelize();=0A=
    var value =3D element.style[style];=0A=
    if (!value || value =3D=3D 'auto') {=0A=
      var css =3D document.defaultView.getComputedStyle(element, null);=0A=
      value =3D css ? css[style] : null;=0A=
    }=0A=
    if (style =3D=3D 'opacity') return value ? parseFloat(value) : 1.0;=0A=
    return value =3D=3D 'auto' ? null : value;=0A=
  },=0A=
=0A=
  getOpacity: function(element) {=0A=
    return $(element).getStyle('opacity');=0A=
  },=0A=
=0A=
  setStyle: function(element, styles) {=0A=
    element =3D $(element);=0A=
    var elementStyle =3D element.style, match;=0A=
    if (Object.isString(styles)) {=0A=
      element.style.cssText +=3D ';' + styles;=0A=
      return styles.include('opacity') ?=0A=
        element.setOpacity(styles.match(/opacity:\s*(\d?\.?\d*)/)[1]) : =
element;=0A=
    }=0A=
    for (var property in styles)=0A=
      if (property =3D=3D 'opacity') =
element.setOpacity(styles[property]);=0A=
      else=0A=
        elementStyle[(property =3D=3D 'float' || property =3D=3D =
'cssFloat') ?=0A=
          (Object.isUndefined(elementStyle.styleFloat) ? 'cssFloat' : =
'styleFloat') :=0A=
            property] =3D styles[property];=0A=
=0A=
    return element;=0A=
  },=0A=
=0A=
  setOpacity: function(element, value) {=0A=
    element =3D $(element);=0A=
    element.style.opacity =3D (value =3D=3D 1 || value =3D=3D=3D '') ? =
'' :=0A=
      (value < 0.00001) ? 0 : value;=0A=
    return element;=0A=
  },=0A=
=0A=
  getDimensions: function(element) {=0A=
    element =3D $(element);=0A=
    var display =3D Element.getStyle(element, 'display');=0A=
    if (display !=3D 'none' && display !=3D null) // Safari bug=0A=
      return {width: element.offsetWidth, height: element.offsetHeight};=0A=
=0A=
    var els =3D element.style;=0A=
    var originalVisibility =3D els.visibility;=0A=
    var originalPosition =3D els.position;=0A=
    var originalDisplay =3D els.display;=0A=
    els.visibility =3D 'hidden';=0A=
    if (originalPosition !=3D 'fixed') // Switching fixed to absolute =
causes issues in Safari=0A=
      els.position =3D 'absolute';=0A=
    els.display =3D 'block';=0A=
    var originalWidth =3D element.clientWidth;=0A=
    var originalHeight =3D element.clientHeight;=0A=
    els.display =3D originalDisplay;=0A=
    els.position =3D originalPosition;=0A=
    els.visibility =3D originalVisibility;=0A=
    return {width: originalWidth, height: originalHeight};=0A=
  },=0A=
=0A=
  makePositioned: function(element) {=0A=
    element =3D $(element);=0A=
    var pos =3D Element.getStyle(element, 'position');=0A=
    if (pos =3D=3D 'static' || !pos) {=0A=
      element._madePositioned =3D true;=0A=
      element.style.position =3D 'relative';=0A=
      if (Prototype.Browser.Opera) {=0A=
        element.style.top =3D 0;=0A=
        element.style.left =3D 0;=0A=
      }=0A=
    }=0A=
    return element;=0A=
  },=0A=
=0A=
  undoPositioned: function(element) {=0A=
    element =3D $(element);=0A=
    if (element._madePositioned) {=0A=
      element._madePositioned =3D undefined;=0A=
      element.style.position =3D=0A=
        element.style.top =3D=0A=
        element.style.left =3D=0A=
        element.style.bottom =3D=0A=
        element.style.right =3D '';=0A=
    }=0A=
    return element;=0A=
  },=0A=
=0A=
  makeClipping: function(element) {=0A=
    element =3D $(element);=0A=
    if (element._overflow) return element;=0A=
    element._overflow =3D Element.getStyle(element, 'overflow') || =
'auto';=0A=
    if (element._overflow !=3D=3D 'hidden')=0A=
      element.style.overflow =3D 'hidden';=0A=
    return element;=0A=
  },=0A=
=0A=
  undoClipping: function(element) {=0A=
    element =3D $(element);=0A=
    if (!element._overflow) return element;=0A=
    element.style.overflow =3D element._overflow =3D=3D 'auto' ? '' : =
element._overflow;=0A=
    element._overflow =3D null;=0A=
    return element;=0A=
  },=0A=
=0A=
  cumulativeOffset: function(element) {=0A=
    var valueT =3D 0, valueL =3D 0;=0A=
    do {=0A=
      valueT +=3D element.offsetTop  || 0;=0A=
      valueL +=3D element.offsetLeft || 0;=0A=
      element =3D element.offsetParent;=0A=
    } while (element);=0A=
    return Element._returnOffset(valueL, valueT);=0A=
  },=0A=
=0A=
  positionedOffset: function(element) {=0A=
    var valueT =3D 0, valueL =3D 0;=0A=
    do {=0A=
      valueT +=3D element.offsetTop  || 0;=0A=
      valueL +=3D element.offsetLeft || 0;=0A=
      element =3D element.offsetParent;=0A=
      if (element) {=0A=
        if (element.tagName.toUpperCase() =3D=3D 'BODY') break;=0A=
        var p =3D Element.getStyle(element, 'position');=0A=
        if (p !=3D=3D 'static') break;=0A=
      }=0A=
    } while (element);=0A=
    return Element._returnOffset(valueL, valueT);=0A=
  },=0A=
=0A=
  absolutize: function(element) {=0A=
    element =3D $(element);=0A=
    if (Element.getStyle(element, 'position') =3D=3D 'absolute') return =
element;=0A=
=0A=
    var offsets =3D Element.positionedOffset(element);=0A=
    var top     =3D offsets[1];=0A=
    var left    =3D offsets[0];=0A=
    var width   =3D element.clientWidth;=0A=
    var height  =3D element.clientHeight;=0A=
=0A=
    element._originalLeft   =3D left - parseFloat(element.style.left  || =
0);=0A=
    element._originalTop    =3D top  - parseFloat(element.style.top || =
0);=0A=
    element._originalWidth  =3D element.style.width;=0A=
    element._originalHeight =3D element.style.height;=0A=
=0A=
    element.style.position =3D 'absolute';=0A=
    element.style.top    =3D top + 'px';=0A=
    element.style.left   =3D left + 'px';=0A=
    element.style.width  =3D width + 'px';=0A=
    element.style.height =3D height + 'px';=0A=
    return element;=0A=
  },=0A=
=0A=
  relativize: function(element) {=0A=
    element =3D $(element);=0A=
    if (Element.getStyle(element, 'position') =3D=3D 'relative') return =
element;=0A=
=0A=
    element.style.position =3D 'relative';=0A=
    var top  =3D parseFloat(element.style.top  || 0) - =
(element._originalTop || 0);=0A=
    var left =3D parseFloat(element.style.left || 0) - =
(element._originalLeft || 0);=0A=
=0A=
    element.style.top    =3D top + 'px';=0A=
    element.style.left   =3D left + 'px';=0A=
    element.style.height =3D element._originalHeight;=0A=
    element.style.width  =3D element._originalWidth;=0A=
    return element;=0A=
  },=0A=
=0A=
  cumulativeScrollOffset: function(element) {=0A=
    var valueT =3D 0, valueL =3D 0;=0A=
    do {=0A=
      valueT +=3D element.scrollTop  || 0;=0A=
      valueL +=3D element.scrollLeft || 0;=0A=
      element =3D element.parentNode;=0A=
    } while (element);=0A=
    return Element._returnOffset(valueL, valueT);=0A=
  },=0A=
=0A=
  getOffsetParent: function(element) {=0A=
    if (element.offsetParent) return $(element.offsetParent);=0A=
    if (element =3D=3D document.body) return $(element);=0A=
=0A=
    while ((element =3D element.parentNode) && element !=3D =
document.body)=0A=
      if (Element.getStyle(element, 'position') !=3D 'static')=0A=
        return $(element);=0A=
=0A=
    return $(document.body);=0A=
  },=0A=
=0A=
  viewportOffset: function(forElement) {=0A=
    var valueT =3D 0, valueL =3D 0;=0A=
=0A=
    var element =3D forElement;=0A=
    do {=0A=
      valueT +=3D element.offsetTop  || 0;=0A=
      valueL +=3D element.offsetLeft || 0;=0A=
=0A=
      if (element.offsetParent =3D=3D document.body &&=0A=
        Element.getStyle(element, 'position') =3D=3D 'absolute') break;=0A=
=0A=
    } while (element =3D element.offsetParent);=0A=
=0A=
    element =3D forElement;=0A=
    do {=0A=
      if (!Prototype.Browser.Opera || (element.tagName && =
(element.tagName.toUpperCase() =3D=3D 'BODY'))) {=0A=
        valueT -=3D element.scrollTop  || 0;=0A=
        valueL -=3D element.scrollLeft || 0;=0A=
      }=0A=
    } while (element =3D element.parentNode);=0A=
=0A=
    return Element._returnOffset(valueL, valueT);=0A=
  },=0A=
=0A=
  clonePosition: function(element, source) {=0A=
    var options =3D Object.extend({=0A=
      setLeft:    true,=0A=
      setTop:     true,=0A=
      setWidth:   true,=0A=
      setHeight:  true,=0A=
      offsetTop:  0,=0A=
      offsetLeft: 0=0A=
    }, arguments[2] || { });=0A=
=0A=
    source =3D $(source);=0A=
    var p =3D Element.viewportOffset(source);=0A=
=0A=
    element =3D $(element);=0A=
    var delta =3D [0, 0];=0A=
    var parent =3D null;=0A=
    if (Element.getStyle(element, 'position') =3D=3D 'absolute') {=0A=
      parent =3D Element.getOffsetParent(element);=0A=
      delta =3D Element.viewportOffset(parent);=0A=
    }=0A=
=0A=
    if (parent =3D=3D document.body) {=0A=
      delta[0] -=3D document.body.offsetLeft;=0A=
      delta[1] -=3D document.body.offsetTop;=0A=
    }=0A=
=0A=
    if (options.setLeft)   element.style.left  =3D (p[0] - delta[0] + =
options.offsetLeft) + 'px';=0A=
    if (options.setTop)    element.style.top   =3D (p[1] - delta[1] + =
options.offsetTop) + 'px';=0A=
    if (options.setWidth)  element.style.width =3D source.offsetWidth + =
'px';=0A=
    if (options.setHeight) element.style.height =3D source.offsetHeight =
+ 'px';=0A=
    return element;=0A=
  }=0A=
};=0A=
=0A=
Object.extend(Element.Methods, {=0A=
  getElementsBySelector: Element.Methods.select,=0A=
=0A=
  childElements: Element.Methods.immediateDescendants=0A=
});=0A=
=0A=
Element._attributeTranslations =3D {=0A=
  write: {=0A=
    names: {=0A=
      className: 'class',=0A=
      htmlFor:   'for'=0A=
    },=0A=
    values: { }=0A=
  }=0A=
};=0A=
=0A=
if (Prototype.Browser.Opera) {=0A=
  Element.Methods.getStyle =3D Element.Methods.getStyle.wrap(=0A=
    function(proceed, element, style) {=0A=
      switch (style) {=0A=
        case 'left': case 'top': case 'right': case 'bottom':=0A=
          if (proceed(element, 'position') =3D=3D=3D 'static') return =
null;=0A=
        case 'height': case 'width':=0A=
          if (!Element.visible(element)) return null;=0A=
=0A=
          var dim =3D parseInt(proceed(element, style), 10);=0A=
=0A=
          if (dim !=3D=3D element['offset' + style.capitalize()])=0A=
            return dim + 'px';=0A=
=0A=
          var properties;=0A=
          if (style =3D=3D=3D 'height') {=0A=
            properties =3D ['border-top-width', 'padding-top',=0A=
             'padding-bottom', 'border-bottom-width'];=0A=
          }=0A=
          else {=0A=
            properties =3D ['border-left-width', 'padding-left',=0A=
             'padding-right', 'border-right-width'];=0A=
          }=0A=
          return properties.inject(dim, function(memo, property) {=0A=
            var val =3D proceed(element, property);=0A=
            return val =3D=3D=3D null ? memo : memo - parseInt(val, 10);=0A=
          }) + 'px';=0A=
        default: return proceed(element, style);=0A=
      }=0A=
    }=0A=
  );=0A=
=0A=
  Element.Methods.readAttribute =3D Element.Methods.readAttribute.wrap(=0A=
    function(proceed, element, attribute) {=0A=
      if (attribute =3D=3D=3D 'title') return element.title;=0A=
      return proceed(element, attribute);=0A=
    }=0A=
  );=0A=
}=0A=
=0A=
else if (Prototype.Browser.IE) {=0A=
  Element.Methods.getOffsetParent =3D =
Element.Methods.getOffsetParent.wrap(=0A=
    function(proceed, element) {=0A=
      element =3D $(element);=0A=
      try { element.offsetParent }=0A=
      catch(e) { return $(document.body) }=0A=
      var position =3D element.getStyle('position');=0A=
      if (position !=3D=3D 'static') return proceed(element);=0A=
      element.setStyle({ position: 'relative' });=0A=
      var value =3D proceed(element);=0A=
      element.setStyle({ position: position });=0A=
      return value;=0A=
    }=0A=
  );=0A=
=0A=
  $w('positionedOffset viewportOffset').each(function(method) {=0A=
    Element.Methods[method] =3D Element.Methods[method].wrap(=0A=
      function(proceed, element) {=0A=
        element =3D $(element);=0A=
        try { element.offsetParent }=0A=
        catch(e) { return Element._returnOffset(0,0) }=0A=
        var position =3D element.getStyle('position');=0A=
        if (position !=3D=3D 'static') return proceed(element);=0A=
        var offsetParent =3D element.getOffsetParent();=0A=
        if (offsetParent && offsetParent.getStyle('position') =3D=3D=3D =
'fixed')=0A=
          offsetParent.setStyle({ zoom: 1 });=0A=
        element.setStyle({ position: 'relative' });=0A=
        var value =3D proceed(element);=0A=
        element.setStyle({ position: position });=0A=
        return value;=0A=
      }=0A=
    );=0A=
  });=0A=
=0A=
  Element.Methods.cumulativeOffset =3D =
Element.Methods.cumulativeOffset.wrap(=0A=
    function(proceed, element) {=0A=
      try { element.offsetParent }=0A=
      catch(e) { return Element._returnOffset(0,0) }=0A=
      return proceed(element);=0A=
    }=0A=
  );=0A=
=0A=
  Element.Methods.getStyle =3D function(element, style) {=0A=
    element =3D $(element);=0A=
    style =3D (style =3D=3D 'float' || style =3D=3D 'cssFloat') ? =
'styleFloat' : style.camelize();=0A=
    var value =3D element.style[style];=0A=
    if (!value && element.currentStyle) value =3D =
element.currentStyle[style];=0A=
=0A=
    if (style =3D=3D 'opacity') {=0A=
      if (value =3D (element.getStyle('filter') || =
'').match(/alpha\(opacity=3D(.*)\)/))=0A=
        if (value[1]) return parseFloat(value[1]) / 100;=0A=
      return 1.0;=0A=
    }=0A=
=0A=
    if (value =3D=3D 'auto') {=0A=
      if ((style =3D=3D 'width' || style =3D=3D 'height') && =
(element.getStyle('display') !=3D 'none'))=0A=
        return element['offset' + style.capitalize()] + 'px';=0A=
      return null;=0A=
    }=0A=
    return value;=0A=
  };=0A=
=0A=
  Element.Methods.setOpacity =3D function(element, value) {=0A=
    function stripAlpha(filter){=0A=
      return filter.replace(/alpha\([^\)]*\)/gi,'');=0A=
    }=0A=
    element =3D $(element);=0A=
    var currentStyle =3D element.currentStyle;=0A=
    if ((currentStyle && !currentStyle.hasLayout) ||=0A=
      (!currentStyle && element.style.zoom =3D=3D 'normal'))=0A=
        element.style.zoom =3D 1;=0A=
=0A=
    var filter =3D element.getStyle('filter'), style =3D element.style;=0A=
    if (value =3D=3D 1 || value =3D=3D=3D '') {=0A=
      (filter =3D stripAlpha(filter)) ?=0A=
        style.filter =3D filter : style.removeAttribute('filter');=0A=
      return element;=0A=
    } else if (value < 0.00001) value =3D 0;=0A=
    style.filter =3D stripAlpha(filter) +=0A=
      'alpha(opacity=3D' + (value * 100) + ')';=0A=
    return element;=0A=
  };=0A=
=0A=
  Element._attributeTranslations =3D (function(){=0A=
=0A=
    var classProp =3D 'className';=0A=
    var forProp =3D 'for';=0A=
=0A=
    var el =3D document.createElement('div');=0A=
=0A=
    el.setAttribute(classProp, 'x');=0A=
=0A=
    if (el.className !=3D=3D 'x') {=0A=
      el.setAttribute('class', 'x');=0A=
      if (el.className =3D=3D=3D 'x') {=0A=
        classProp =3D 'class';=0A=
      }=0A=
    }=0A=
    el =3D null;=0A=
=0A=
    el =3D document.createElement('label');=0A=
    el.setAttribute(forProp, 'x');=0A=
    if (el.htmlFor !=3D=3D 'x') {=0A=
      el.setAttribute('htmlFor', 'x');=0A=
      if (el.htmlFor =3D=3D=3D 'x') {=0A=
        forProp =3D 'htmlFor';=0A=
      }=0A=
    }=0A=
    el =3D null;=0A=
=0A=
    return {=0A=
      read: {=0A=
        names: {=0A=
          'class':      classProp,=0A=
          'className':  classProp,=0A=
          'for':        forProp,=0A=
          'htmlFor':    forProp=0A=
        },=0A=
        values: {=0A=
          _getAttr: function(element, attribute) {=0A=
            return element.getAttribute(attribute);=0A=
          },=0A=
          _getAttr2: function(element, attribute) {=0A=
            return element.getAttribute(attribute, 2);=0A=
          },=0A=
          _getAttrNode: function(element, attribute) {=0A=
            var node =3D element.getAttributeNode(attribute);=0A=
            return node ? node.value : "";=0A=
          },=0A=
          _getEv: (function(){=0A=
=0A=
            var el =3D document.createElement('div');=0A=
            el.onclick =3D Prototype.emptyFunction;=0A=
            var value =3D el.getAttribute('onclick');=0A=
            var f;=0A=
=0A=
            if (String(value).indexOf('{') > -1) {=0A=
              f =3D function(element, attribute) {=0A=
                attribute =3D element.getAttribute(attribute);=0A=
                if (!attribute) return null;=0A=
                attribute =3D attribute.toString();=0A=
                attribute =3D attribute.split('{')[1];=0A=
                attribute =3D attribute.split('}')[0];=0A=
                return attribute.strip();=0A=
              };=0A=
            }=0A=
            else if (value =3D=3D=3D '') {=0A=
              f =3D function(element, attribute) {=0A=
                attribute =3D element.getAttribute(attribute);=0A=
                if (!attribute) return null;=0A=
                return attribute.strip();=0A=
              };=0A=
            }=0A=
            el =3D null;=0A=
            return f;=0A=
          })(),=0A=
          _flag: function(element, attribute) {=0A=
            return $(element).hasAttribute(attribute) ? attribute : null;=0A=
          },=0A=
          style: function(element) {=0A=
            return element.style.cssText.toLowerCase();=0A=
          },=0A=
          title: function(element) {=0A=
            return element.title;=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
  })();=0A=
=0A=
  Element._attributeTranslations.write =3D {=0A=
    names: Object.extend({=0A=
      cellpadding: 'cellPadding',=0A=
      cellspacing: 'cellSpacing'=0A=
    }, Element._attributeTranslations.read.names),=0A=
    values: {=0A=
      checked: function(element, value) {=0A=
        element.checked =3D !!value;=0A=
      },=0A=
=0A=
      style: function(element, value) {=0A=
        element.style.cssText =3D value ? value : '';=0A=
      }=0A=
    }=0A=
  };=0A=
=0A=
  Element._attributeTranslations.has =3D {};=0A=
=0A=
  $w('colSpan rowSpan vAlign dateTime accessKey tabIndex ' +=0A=
      'encType maxLength readOnly longDesc =
frameBorder').each(function(attr) {=0A=
    Element._attributeTranslations.write.names[attr.toLowerCase()] =3D =
attr;=0A=
    Element._attributeTranslations.has[attr.toLowerCase()] =3D attr;=0A=
  });=0A=
=0A=
  (function(v) {=0A=
    Object.extend(v, {=0A=
      href:        v._getAttr2,=0A=
      src:         v._getAttr2,=0A=
      type:        v._getAttr,=0A=
      action:      v._getAttrNode,=0A=
      disabled:    v._flag,=0A=
      checked:     v._flag,=0A=
      readonly:    v._flag,=0A=
      multiple:    v._flag,=0A=
      onload:      v._getEv,=0A=
      onunload:    v._getEv,=0A=
      onclick:     v._getEv,=0A=
      ondblclick:  v._getEv,=0A=
      onmousedown: v._getEv,=0A=
      onmouseup:   v._getEv,=0A=
      onmouseover: v._getEv,=0A=
      onmousemove: v._getEv,=0A=
      onmouseout:  v._getEv,=0A=
      onfocus:     v._getEv,=0A=
      onblur:      v._getEv,=0A=
      onkeypress:  v._getEv,=0A=
      onkeydown:   v._getEv,=0A=
      onkeyup:     v._getEv,=0A=
      onsubmit:    v._getEv,=0A=
      onreset:     v._getEv,=0A=
      onselect:    v._getEv,=0A=
      onchange:    v._getEv=0A=
    });=0A=
  })(Element._attributeTranslations.read.values);=0A=
=0A=
  if (Prototype.BrowserFeatures.ElementExtensions) {=0A=
    (function() {=0A=
      function _descendants(element) {=0A=
        var nodes =3D element.getElementsByTagName('*'), results =3D [];=0A=
        for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
          if (node.tagName !=3D=3D "!") // Filter out comment nodes.=0A=
            results.push(node);=0A=
        return results;=0A=
      }=0A=
=0A=
      Element.Methods.down =3D function(element, expression, index) {=0A=
        element =3D $(element);=0A=
        if (arguments.length =3D=3D 1) return element.firstDescendant();=0A=
        return Object.isNumber(expression) ? =
_descendants(element)[expression] :=0A=
          Element.select(element, expression)[index || 0];=0A=
      }=0A=
    })();=0A=
  }=0A=
=0A=
}=0A=
=0A=
else if (Prototype.Browser.Gecko && =
/rv:1\.8\.0/.test(navigator.userAgent)) {=0A=
  Element.Methods.setOpacity =3D function(element, value) {=0A=
    element =3D $(element);=0A=
    element.style.opacity =3D (value =3D=3D 1) ? 0.999999 :=0A=
      (value =3D=3D=3D '') ? '' : (value < 0.00001) ? 0 : value;=0A=
    return element;=0A=
  };=0A=
}=0A=
=0A=
else if (Prototype.Browser.WebKit) {=0A=
  Element.Methods.setOpacity =3D function(element, value) {=0A=
    element =3D $(element);=0A=
    element.style.opacity =3D (value =3D=3D 1 || value =3D=3D=3D '') ? =
'' :=0A=
      (value < 0.00001) ? 0 : value;=0A=
=0A=
    if (value =3D=3D 1)=0A=
      if(element.tagName.toUpperCase() =3D=3D 'IMG' && element.width) {=0A=
        element.width++; element.width--;=0A=
      } else try {=0A=
        var n =3D document.createTextNode(' ');=0A=
        element.appendChild(n);=0A=
        element.removeChild(n);=0A=
      } catch (e) { }=0A=
=0A=
    return element;=0A=
  };=0A=
=0A=
  Element.Methods.cumulativeOffset =3D function(element) {=0A=
    var valueT =3D 0, valueL =3D 0;=0A=
    do {=0A=
      valueT +=3D element.offsetTop  || 0;=0A=
      valueL +=3D element.offsetLeft || 0;=0A=
      if (element.offsetParent =3D=3D document.body)=0A=
        if (Element.getStyle(element, 'position') =3D=3D 'absolute') =
break;=0A=
=0A=
      element =3D element.offsetParent;=0A=
    } while (element);=0A=
=0A=
    return Element._returnOffset(valueL, valueT);=0A=
  };=0A=
}=0A=
=0A=
if ('outerHTML' in document.documentElement) {=0A=
  Element.Methods.replace =3D function(element, content) {=0A=
    element =3D $(element);=0A=
=0A=
    if (content && content.toElement) content =3D content.toElement();=0A=
    if (Object.isElement(content)) {=0A=
      element.parentNode.replaceChild(content, element);=0A=
      return element;=0A=
    }=0A=
=0A=
    content =3D Object.toHTML(content);=0A=
    var parent =3D element.parentNode, tagName =3D =
parent.tagName.toUpperCase();=0A=
=0A=
    if (Element._insertionTranslations.tags[tagName]) {=0A=
      var nextSibling =3D element.next();=0A=
      var fragments =3D Element._getContentFromAnonymousElement(tagName, =
content.stripScripts());=0A=
      parent.removeChild(element);=0A=
      if (nextSibling)=0A=
        fragments.each(function(node) { parent.insertBefore(node, =
nextSibling) });=0A=
      else=0A=
        fragments.each(function(node) { parent.appendChild(node) });=0A=
    }=0A=
    else element.outerHTML =3D content.stripScripts();=0A=
=0A=
    content.evalScripts.bind(content).defer();=0A=
    return element;=0A=
  };=0A=
}=0A=
=0A=
Element._returnOffset =3D function(l, t) {=0A=
  var result =3D [l, t];=0A=
  result.left =3D l;=0A=
  result.top =3D t;=0A=
  return result;=0A=
};=0A=
=0A=
Element._getContentFromAnonymousElement =3D function(tagName, html) {=0A=
  var div =3D new Element('div'), t =3D =
Element._insertionTranslations.tags[tagName];=0A=
  if (t) {=0A=
    div.innerHTML =3D t[0] + html + t[1];=0A=
    t[2].times(function() { div =3D div.firstChild });=0A=
  } else div.innerHTML =3D html;=0A=
  return $A(div.childNodes);=0A=
};=0A=
=0A=
Element._insertionTranslations =3D {=0A=
  before: function(element, node) {=0A=
    element.parentNode.insertBefore(node, element);=0A=
  },=0A=
  top: function(element, node) {=0A=
    element.insertBefore(node, element.firstChild);=0A=
  },=0A=
  bottom: function(element, node) {=0A=
    element.appendChild(node);=0A=
  },=0A=
  after: function(element, node) {=0A=
    element.parentNode.insertBefore(node, element.nextSibling);=0A=
  },=0A=
  tags: {=0A=
    TABLE:  ['<table>',                '</table>',                   1],=0A=
    TBODY:  ['<table><tbody>',         '</tbody></table>',           2],=0A=
    TR:     ['<table><tbody><tr>',     '</tr></tbody></table>',      3],=0A=
    TD:     ['<table><tbody><tr><td>', '</td></tr></tbody></table>', 4],=0A=
    SELECT: ['<select>',               '</select>',                  1]=0A=
  }=0A=
};=0A=
=0A=
(function() {=0A=
  var tags =3D Element._insertionTranslations.tags;=0A=
  Object.extend(tags, {=0A=
    THEAD: tags.TBODY,=0A=
    TFOOT: tags.TBODY,=0A=
    TH:    tags.TD=0A=
  });=0A=
})();=0A=
=0A=
Element.Methods.Simulated =3D {=0A=
  hasAttribute: function(element, attribute) {=0A=
    attribute =3D Element._attributeTranslations.has[attribute] || =
attribute;=0A=
    var node =3D $(element).getAttributeNode(attribute);=0A=
    return !!(node && node.specified);=0A=
  }=0A=
};=0A=
=0A=
Element.Methods.ByTag =3D { };=0A=
=0A=
Object.extend(Element, Element.Methods);=0A=
=0A=
(function(div) {=0A=
=0A=
  if (!Prototype.BrowserFeatures.ElementExtensions && div['__proto__']) {=0A=
    window.HTMLElement =3D { };=0A=
    window.HTMLElement.prototype =3D div['__proto__'];=0A=
    Prototype.BrowserFeatures.ElementExtensions =3D true;=0A=
  }=0A=
=0A=
  div =3D null;=0A=
=0A=
})(document.createElement('div'))=0A=
=0A=
Element.extend =3D (function() {=0A=
=0A=
  function checkDeficiency(tagName) {=0A=
    if (typeof window.Element !=3D 'undefined') {=0A=
      var proto =3D window.Element.prototype;=0A=
      if (proto) {=0A=
        var id =3D '_' + (Math.random()+'').slice(2);=0A=
        var el =3D document.createElement(tagName);=0A=
        proto[id] =3D 'x';=0A=
        var isBuggy =3D (el[id] !=3D=3D 'x');=0A=
        delete proto[id];=0A=
        el =3D null;=0A=
        return isBuggy;=0A=
      }=0A=
    }=0A=
    return false;=0A=
  }=0A=
=0A=
  function extendElementWith(element, methods) {=0A=
    for (var property in methods) {=0A=
      var value =3D methods[property];=0A=
      if (Object.isFunction(value) && !(property in element))=0A=
        element[property] =3D value.methodize();=0A=
    }=0A=
  }=0A=
=0A=
  var HTMLOBJECTELEMENT_PROTOTYPE_BUGGY =3D checkDeficiency('object');=0A=
=0A=
  if (Prototype.BrowserFeatures.SpecificElementExtensions) {=0A=
    if (HTMLOBJECTELEMENT_PROTOTYPE_BUGGY) {=0A=
      return function(element) {=0A=
        if (element && typeof element._extendedByPrototype =3D=3D =
'undefined') {=0A=
          var t =3D element.tagName;=0A=
          if (t && (/^(?:object|applet|embed)$/i.test(t))) {=0A=
            extendElementWith(element, Element.Methods);=0A=
            extendElementWith(element, Element.Methods.Simulated);=0A=
            extendElementWith(element, =
Element.Methods.ByTag[t.toUpperCase()]);=0A=
          }=0A=
        }=0A=
        return element;=0A=
      }=0A=
    }=0A=
    return Prototype.K;=0A=
  }=0A=
=0A=
  var Methods =3D { }, ByTag =3D Element.Methods.ByTag;=0A=
=0A=
  var extend =3D Object.extend(function(element) {=0A=
    if (!element || typeof element._extendedByPrototype !=3D 'undefined' =
||=0A=
        element.nodeType !=3D 1 || element =3D=3D window) return element;=0A=
=0A=
    var methods =3D Object.clone(Methods),=0A=
        tagName =3D element.tagName.toUpperCase();=0A=
=0A=
    if (ByTag[tagName]) Object.extend(methods, ByTag[tagName]);=0A=
=0A=
    extendElementWith(element, methods);=0A=
=0A=
    element._extendedByPrototype =3D Prototype.emptyFunction;=0A=
    return element;=0A=
=0A=
  }, {=0A=
    refresh: function() {=0A=
      if (!Prototype.BrowserFeatures.ElementExtensions) {=0A=
        Object.extend(Methods, Element.Methods);=0A=
        Object.extend(Methods, Element.Methods.Simulated);=0A=
      }=0A=
    }=0A=
  });=0A=
=0A=
  extend.refresh();=0A=
  return extend;=0A=
})();=0A=
=0A=
Element.hasAttribute =3D function(element, attribute) {=0A=
  if (element.hasAttribute) return element.hasAttribute(attribute);=0A=
  return Element.Methods.Simulated.hasAttribute(element, attribute);=0A=
};=0A=
=0A=
Element.addMethods =3D function(methods) {=0A=
  var F =3D Prototype.BrowserFeatures, T =3D Element.Methods.ByTag;=0A=
=0A=
  if (!methods) {=0A=
    Object.extend(Form, Form.Methods);=0A=
    Object.extend(Form.Element, Form.Element.Methods);=0A=
    Object.extend(Element.Methods.ByTag, {=0A=
      "FORM":     Object.clone(Form.Methods),=0A=
      "INPUT":    Object.clone(Form.Element.Methods),=0A=
      "SELECT":   Object.clone(Form.Element.Methods),=0A=
      "TEXTAREA": Object.clone(Form.Element.Methods)=0A=
    });=0A=
  }=0A=
=0A=
  if (arguments.length =3D=3D 2) {=0A=
    var tagName =3D methods;=0A=
    methods =3D arguments[1];=0A=
  }=0A=
=0A=
  if (!tagName) Object.extend(Element.Methods, methods || { });=0A=
  else {=0A=
    if (Object.isArray(tagName)) tagName.each(extend);=0A=
    else extend(tagName);=0A=
  }=0A=
=0A=
  function extend(tagName) {=0A=
    tagName =3D tagName.toUpperCase();=0A=
    if (!Element.Methods.ByTag[tagName])=0A=
      Element.Methods.ByTag[tagName] =3D { };=0A=
    Object.extend(Element.Methods.ByTag[tagName], methods);=0A=
  }=0A=
=0A=
  function copy(methods, destination, onlyIfAbsent) {=0A=
    onlyIfAbsent =3D onlyIfAbsent || false;=0A=
    for (var property in methods) {=0A=
      var value =3D methods[property];=0A=
      if (!Object.isFunction(value)) continue;=0A=
      if (!onlyIfAbsent || !(property in destination))=0A=
        destination[property] =3D value.methodize();=0A=
    }=0A=
  }=0A=
=0A=
  function findDOMClass(tagName) {=0A=
    var klass;=0A=
    var trans =3D {=0A=
      "OPTGROUP": "OptGroup", "TEXTAREA": "TextArea", "P": "Paragraph",=0A=
      "FIELDSET": "FieldSet", "UL": "UList", "OL": "OList", "DL": =
"DList",=0A=
      "DIR": "Directory", "H1": "Heading", "H2": "Heading", "H3": =
"Heading",=0A=
      "H4": "Heading", "H5": "Heading", "H6": "Heading", "Q": "Quote",=0A=
      "INS": "Mod", "DEL": "Mod", "A": "Anchor", "IMG": "Image", =
"CAPTION":=0A=
      "TableCaption", "COL": "TableCol", "COLGROUP": "TableCol", "THEAD":=0A=
      "TableSection", "TFOOT": "TableSection", "TBODY": "TableSection", =
"TR":=0A=
      "TableRow", "TH": "TableCell", "TD": "TableCell", "FRAMESET":=0A=
      "FrameSet", "IFRAME": "IFrame"=0A=
    };=0A=
    if (trans[tagName]) klass =3D 'HTML' + trans[tagName] + 'Element';=0A=
    if (window[klass]) return window[klass];=0A=
    klass =3D 'HTML' + tagName + 'Element';=0A=
    if (window[klass]) return window[klass];=0A=
    klass =3D 'HTML' + tagName.capitalize() + 'Element';=0A=
    if (window[klass]) return window[klass];=0A=
=0A=
    var element =3D document.createElement(tagName);=0A=
    var proto =3D element['__proto__'] || element.constructor.prototype;=0A=
    element =3D null;=0A=
    return proto;=0A=
  }=0A=
=0A=
  var elementPrototype =3D window.HTMLElement ? HTMLElement.prototype :=0A=
   Element.prototype;=0A=
=0A=
  if (F.ElementExtensions) {=0A=
    copy(Element.Methods, elementPrototype);=0A=
    copy(Element.Methods.Simulated, elementPrototype, true);=0A=
  }=0A=
=0A=
  if (F.SpecificElementExtensions) {=0A=
    for (var tag in Element.Methods.ByTag) {=0A=
      var klass =3D findDOMClass(tag);=0A=
      if (Object.isUndefined(klass)) continue;=0A=
      copy(T[tag], klass.prototype);=0A=
    }=0A=
  }=0A=
=0A=
  Object.extend(Element, Element.Methods);=0A=
  delete Element.ByTag;=0A=
=0A=
  if (Element.extend.refresh) Element.extend.refresh();=0A=
  Element.cache =3D { };=0A=
};=0A=
=0A=
=0A=
document.viewport =3D {=0A=
=0A=
  getDimensions: function() {=0A=
    return { width: this.getWidth(), height: this.getHeight() };=0A=
  },=0A=
=0A=
  getScrollOffsets: function() {=0A=
    return Element._returnOffset(=0A=
      window.pageXOffset || document.documentElement.scrollLeft || =
document.body.scrollLeft,=0A=
      window.pageYOffset || document.documentElement.scrollTop  || =
document.body.scrollTop);=0A=
  }=0A=
};=0A=
=0A=
(function(viewport) {=0A=
  var B =3D Prototype.Browser, doc =3D document, element, property =3D =
{};=0A=
=0A=
  function getRootElement() {=0A=
    if (B.WebKit && !doc.evaluate)=0A=
      return document;=0A=
=0A=
    if (B.Opera && window.parseFloat(window.opera.version()) < 9.5)=0A=
      return document.body;=0A=
=0A=
    return document.documentElement;=0A=
  }=0A=
=0A=
  function define(D) {=0A=
    if (!element) element =3D getRootElement();=0A=
=0A=
    property[D] =3D 'client' + D;=0A=
=0A=
    viewport['get' + D] =3D function() { return element[property[D]] };=0A=
    return viewport['get' + D]();=0A=
  }=0A=
=0A=
  viewport.getWidth  =3D define.curry('Width');=0A=
=0A=
  viewport.getHeight =3D define.curry('Height');=0A=
})(document.viewport);=0A=
=0A=
=0A=
Element.Storage =3D {=0A=
  UID: 1=0A=
};=0A=
=0A=
Element.addMethods({=0A=
  getStorage: function(element) {=0A=
    if (!(element =3D $(element))) return;=0A=
=0A=
    var uid;=0A=
    if (element =3D=3D=3D window) {=0A=
      uid =3D 0;=0A=
    } else {=0A=
      if (typeof element._prototypeUID =3D=3D=3D "undefined")=0A=
        element._prototypeUID =3D [Element.Storage.UID++];=0A=
      uid =3D element._prototypeUID[0];=0A=
    }=0A=
=0A=
    if (!Element.Storage[uid])=0A=
      Element.Storage[uid] =3D $H();=0A=
=0A=
    return Element.Storage[uid];=0A=
  },=0A=
=0A=
  store: function(element, key, value) {=0A=
    if (!(element =3D $(element))) return;=0A=
=0A=
    if (arguments.length =3D=3D=3D 2) {=0A=
      Element.getStorage(element).update(key);=0A=
    } else {=0A=
      Element.getStorage(element).set(key, value);=0A=
    }=0A=
=0A=
    return element;=0A=
  },=0A=
=0A=
  retrieve: function(element, key, defaultValue) {=0A=
    if (!(element =3D $(element))) return;=0A=
    var hash =3D Element.getStorage(element), value =3D hash.get(key);=0A=
=0A=
    if (Object.isUndefined(value)) {=0A=
      hash.set(key, defaultValue);=0A=
      value =3D defaultValue;=0A=
    }=0A=
=0A=
    return value;=0A=
  },=0A=
=0A=
  clone: function(element, deep) {=0A=
    if (!(element =3D $(element))) return;=0A=
    var clone =3D element.cloneNode(deep);=0A=
    clone._prototypeUID =3D void 0;=0A=
    if (deep) {=0A=
      var descendants =3D Element.select(clone, '*'),=0A=
          i =3D descendants.length;=0A=
      while (i--) {=0A=
        descendants[i]._prototypeUID =3D void 0;=0A=
      }=0A=
    }=0A=
    return Element.extend(clone);=0A=
  }=0A=
});=0A=
/* Portions of the Selector class are derived from Jack Slocum's =
DomQuery,=0A=
 * part of YUI-Ext version 0.40, distributed under the terms of an =
MIT-style=0A=
 * license.  Please see http://www.yui-ext.com/ for more information. */=0A=
=0A=
var Selector =3D Class.create({=0A=
  initialize: function(expression) {=0A=
    this.expression =3D expression.strip();=0A=
=0A=
    if (this.shouldUseSelectorsAPI()) {=0A=
      this.mode =3D 'selectorsAPI';=0A=
    } else if (this.shouldUseXPath()) {=0A=
      this.mode =3D 'xpath';=0A=
      this.compileXPathMatcher();=0A=
    } else {=0A=
      this.mode =3D "normal";=0A=
      this.compileMatcher();=0A=
    }=0A=
=0A=
  },=0A=
=0A=
  shouldUseXPath: (function() {=0A=
=0A=
    var IS_DESCENDANT_SELECTOR_BUGGY =3D (function(){=0A=
      var isBuggy =3D false;=0A=
      if (document.evaluate && window.XPathResult) {=0A=
        var el =3D document.createElement('div');=0A=
        el.innerHTML =3D =
'<ul><li></li></ul><div><ul><li></li></ul></div>';=0A=
=0A=
        var xpath =3D ".//*[local-name()=3D'ul' or local-name()=3D'UL']" =
+=0A=
          "//*[local-name()=3D'li' or local-name()=3D'LI']";=0A=
=0A=
        var result =3D document.evaluate(xpath, el, null,=0A=
          XPathResult.ORDERED_NODE_SNAPSHOT_TYPE, null);=0A=
=0A=
        isBuggy =3D (result.snapshotLength !=3D=3D 2);=0A=
        el =3D null;=0A=
      }=0A=
      return isBuggy;=0A=
    })();=0A=
=0A=
    return function() {=0A=
      if (!Prototype.BrowserFeatures.XPath) return false;=0A=
=0A=
      var e =3D this.expression;=0A=
=0A=
      if (Prototype.Browser.WebKit &&=0A=
       (e.include("-of-type") || e.include(":empty")))=0A=
        return false;=0A=
=0A=
      if ((/(\[[\w-]*?:|:checked)/).test(e))=0A=
        return false;=0A=
=0A=
      if (IS_DESCENDANT_SELECTOR_BUGGY) return false;=0A=
=0A=
      return true;=0A=
    }=0A=
=0A=
  })(),=0A=
=0A=
  shouldUseSelectorsAPI: function() {=0A=
    if (!Prototype.BrowserFeatures.SelectorsAPI) return false;=0A=
=0A=
    if (Selector.CASE_INSENSITIVE_CLASS_NAMES) return false;=0A=
=0A=
    if (!Selector._div) Selector._div =3D new Element('div');=0A=
=0A=
    try {=0A=
      Selector._div.querySelector(this.expression);=0A=
    } catch(e) {=0A=
      return false;=0A=
    }=0A=
=0A=
    return true;=0A=
  },=0A=
=0A=
  compileMatcher: function() {=0A=
    var e =3D this.expression, ps =3D Selector.patterns, h =3D =
Selector.handlers,=0A=
        c =3D Selector.criteria, le, p, m, len =3D ps.length, name;=0A=
=0A=
    if (Selector._cache[e]) {=0A=
      this.matcher =3D Selector._cache[e];=0A=
      return;=0A=
    }=0A=
=0A=
    this.matcher =3D ["this.matcher =3D function(root) {",=0A=
                    "var r =3D root, h =3D Selector.handlers, c =3D =
false, n;"];=0A=
=0A=
    while (e && le !=3D e && (/\S/).test(e)) {=0A=
      le =3D e;=0A=
      for (var i =3D 0; i<len; i++) {=0A=
        p =3D ps[i].re;=0A=
        name =3D ps[i].name;=0A=
        if (m =3D e.match(p)) {=0A=
          this.matcher.push(Object.isFunction(c[name]) ? c[name](m) :=0A=
            new Template(c[name]).evaluate(m));=0A=
          e =3D e.replace(m[0], '');=0A=
          break;=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
    this.matcher.push("return h.unique(n);\n}");=0A=
    eval(this.matcher.join('\n'));=0A=
    Selector._cache[this.expression] =3D this.matcher;=0A=
  },=0A=
=0A=
  compileXPathMatcher: function() {=0A=
    var e =3D this.expression, ps =3D Selector.patterns,=0A=
        x =3D Selector.xpath, le, m, len =3D ps.length, name;=0A=
=0A=
    if (Selector._cache[e]) {=0A=
      this.xpath =3D Selector._cache[e]; return;=0A=
    }=0A=
=0A=
    this.matcher =3D ['.//*'];=0A=
    while (e && le !=3D e && (/\S/).test(e)) {=0A=
      le =3D e;=0A=
      for (var i =3D 0; i<len; i++) {=0A=
        name =3D ps[i].name;=0A=
        if (m =3D e.match(ps[i].re)) {=0A=
          this.matcher.push(Object.isFunction(x[name]) ? x[name](m) :=0A=
            new Template(x[name]).evaluate(m));=0A=
          e =3D e.replace(m[0], '');=0A=
          break;=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
    this.xpath =3D this.matcher.join('');=0A=
    Selector._cache[this.expression] =3D this.xpath;=0A=
  },=0A=
=0A=
  findElements: function(root) {=0A=
    root =3D root || document;=0A=
=0A=
    var e =3D this.expression, results;=0A=
=0A=
    switch (this.mode) {=0A=
      case 'selectorsAPI':=0A=
        if (root !=3D=3D document) {=0A=
          var oldId =3D root.id, id =3D $(root).identify();=0A=
=0A=
          // Hyperwave change =0A=
          // to support "/", "[" and "]" in id attributes=0A=
=0A=
          //id =3D id.replace(/([\.:])/g, "\\$1");=0A=
          id =3D id.replace(/([\.:\/\[\]\%])/g, "\\$1");=0A=
=0A=
          // Hyperwave change end=0A=
=0A=
          e =3D "#" + id + " " + e;=0A=
        }=0A=
=0A=
        results =3D $A(root.querySelectorAll(e)).map(Element.extend);=0A=
        root.id =3D oldId;=0A=
=0A=
        return results;=0A=
      case 'xpath':=0A=
        return document._getElementsByXPath(this.xpath, root);=0A=
      default:=0A=
       return this.matcher(root);=0A=
    }=0A=
  },=0A=
=0A=
  match: function(element) {=0A=
    this.tokens =3D [];=0A=
=0A=
    var e =3D this.expression, ps =3D Selector.patterns, as =3D =
Selector.assertions;=0A=
    var le, p, m, len =3D ps.length, name;=0A=
=0A=
    while (e && le !=3D=3D e && (/\S/).test(e)) {=0A=
      le =3D e;=0A=
      for (var i =3D 0; i<len; i++) {=0A=
        p =3D ps[i].re;=0A=
        name =3D ps[i].name;=0A=
        if (m =3D e.match(p)) {=0A=
          if (as[name]) {=0A=
            this.tokens.push([name, Object.clone(m)]);=0A=
            e =3D e.replace(m[0], '');=0A=
          } else {=0A=
            return this.findElements(document).include(element);=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
    var match =3D true, name, matches;=0A=
    for (var i =3D 0, token; token =3D this.tokens[i]; i++) {=0A=
      name =3D token[0], matches =3D token[1];=0A=
      if (!Selector.assertions[name](element, matches)) {=0A=
        match =3D false; break;=0A=
      }=0A=
    }=0A=
=0A=
    return match;=0A=
  },=0A=
=0A=
  toString: function() {=0A=
    return this.expression;=0A=
  },=0A=
=0A=
  inspect: function() {=0A=
    return "#<Selector:" + this.expression.inspect() + ">";=0A=
  }=0A=
});=0A=
=0A=
if (Prototype.BrowserFeatures.SelectorsAPI &&=0A=
 document.compatMode =3D=3D=3D 'BackCompat') {=0A=
  Selector.CASE_INSENSITIVE_CLASS_NAMES =3D (function(){=0A=
    var div =3D document.createElement('div'),=0A=
     span =3D document.createElement('span');=0A=
=0A=
    div.id =3D "prototype_test_id";=0A=
    span.className =3D 'Test';=0A=
    div.appendChild(span);=0A=
    var isIgnored =3D (div.querySelector('#prototype_test_id .test') =
!=3D=3D null);=0A=
    div =3D span =3D null;=0A=
    return isIgnored;=0A=
  })();=0A=
}=0A=
=0A=
Object.extend(Selector, {=0A=
  _cache: { },=0A=
=0A=
  xpath: {=0A=
    descendant:   "//*",=0A=
    child:        "/*",=0A=
    adjacent:     "/following-sibling::*[1]",=0A=
    laterSibling: '/following-sibling::*',=0A=
    tagName:      function(m) {=0A=
      if (m[1] =3D=3D '*') return '';=0A=
      return "[local-name()=3D'" + m[1].toLowerCase() +=0A=
             "' or local-name()=3D'" + m[1].toUpperCase() + "']";=0A=
    },=0A=
    className:    "[contains(concat(' ', @class, ' '), ' #{1} ')]",=0A=
    id:           "[@id=3D'#{1}']",=0A=
    attrPresence: function(m) {=0A=
      m[1] =3D m[1].toLowerCase();=0A=
      return new Template("[@#{1}]").evaluate(m);=0A=
    },=0A=
    attr: function(m) {=0A=
      m[1] =3D m[1].toLowerCase();=0A=
      m[3] =3D m[5] || m[6];=0A=
      return new Template(Selector.xpath.operators[m[2]]).evaluate(m);=0A=
    },=0A=
    pseudo: function(m) {=0A=
      var h =3D Selector.xpath.pseudos[m[1]];=0A=
      if (!h) return '';=0A=
      if (Object.isFunction(h)) return h(m);=0A=
      return new Template(Selector.xpath.pseudos[m[1]]).evaluate(m);=0A=
    },=0A=
    operators: {=0A=
      '=3D':  "[@#{1}=3D'#{3}']",=0A=
      '!=3D': "[@#{1}!=3D'#{3}']",=0A=
      '^=3D': "[starts-with(@#{1}, '#{3}')]",=0A=
      '$=3D': "[substring(@#{1}, (string-length(@#{1}) - =
string-length('#{3}') + 1))=3D'#{3}']",=0A=
      '*=3D': "[contains(@#{1}, '#{3}')]",=0A=
      '~=3D': "[contains(concat(' ', @#{1}, ' '), ' #{3} ')]",=0A=
      '|=3D': "[contains(concat('-', @#{1}, '-'), '-#{3}-')]"=0A=
    },=0A=
    pseudos: {=0A=
      'first-child': '[not(preceding-sibling::*)]',=0A=
      'last-child':  '[not(following-sibling::*)]',=0A=
      'only-child':  '[not(preceding-sibling::* or =
following-sibling::*)]',=0A=
      'empty':       "[count(*) =3D 0 and (count(text()) =3D 0)]",=0A=
      'checked':     "[@checked]",=0A=
      'disabled':    "[(@disabled) and (@type!=3D'hidden')]",=0A=
      'enabled':     "[not(@disabled) and (@type!=3D'hidden')]",=0A=
      'not': function(m) {=0A=
        var e =3D m[6], p =3D Selector.patterns,=0A=
            x =3D Selector.xpath, le, v, len =3D p.length, name;=0A=
=0A=
        var exclusion =3D [];=0A=
        while (e && le !=3D e && (/\S/).test(e)) {=0A=
          le =3D e;=0A=
          for (var i =3D 0; i<len; i++) {=0A=
            name =3D p[i].name=0A=
            if (m =3D e.match(p[i].re)) {=0A=
              v =3D Object.isFunction(x[name]) ? x[name](m) : new =
Template(x[name]).evaluate(m);=0A=
              exclusion.push("(" + v.substring(1, v.length - 1) + ")");=0A=
              e =3D e.replace(m[0], '');=0A=
              break;=0A=
            }=0A=
          }=0A=
        }=0A=
        return "[not(" + exclusion.join(" and ") + ")]";=0A=
      },=0A=
      'nth-child':      function(m) {=0A=
        return =
Selector.xpath.pseudos.nth("(count(./preceding-sibling::*) + 1) ", m);=0A=
      },=0A=
      'nth-last-child': function(m) {=0A=
        return =
Selector.xpath.pseudos.nth("(count(./following-sibling::*) + 1) ", m);=0A=
      },=0A=
      'nth-of-type':    function(m) {=0A=
        return Selector.xpath.pseudos.nth("position() ", m);=0A=
      },=0A=
      'nth-last-of-type': function(m) {=0A=
        return Selector.xpath.pseudos.nth("(last() + 1 - position()) ", =
m);=0A=
      },=0A=
      'first-of-type':  function(m) {=0A=
        m[6] =3D "1"; return Selector.xpath.pseudos['nth-of-type'](m);=0A=
      },=0A=
      'last-of-type':   function(m) {=0A=
        m[6] =3D "1"; return =
Selector.xpath.pseudos['nth-last-of-type'](m);=0A=
      },=0A=
      'only-of-type':   function(m) {=0A=
        var p =3D Selector.xpath.pseudos; return p['first-of-type'](m) + =
p['last-of-type'](m);=0A=
      },=0A=
      nth: function(fragment, m) {=0A=
        var mm, formula =3D m[6], predicate;=0A=
        if (formula =3D=3D 'even') formula =3D '2n+0';=0A=
        if (formula =3D=3D 'odd')  formula =3D '2n+1';=0A=
        if (mm =3D formula.match(/^(\d+)$/)) // digit only=0A=
          return '[' + fragment + "=3D " + mm[1] + ']';=0A=
        if (mm =3D formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // an+b=0A=
          if (mm[1] =3D=3D "-") mm[1] =3D -1;=0A=
          var a =3D mm[1] ? Number(mm[1]) : 1;=0A=
          var b =3D mm[2] ? Number(mm[2]) : 0;=0A=
          predicate =3D "[((#{fragment} - #{b}) mod #{a} =3D 0) and " +=0A=
          "((#{fragment} - #{b}) div #{a} >=3D 0)]";=0A=
          return new Template(predicate).evaluate({=0A=
            fragment: fragment, a: a, b: b });=0A=
        }=0A=
      }=0A=
    }=0A=
  },=0A=
=0A=
  criteria: {=0A=
    tagName:      'n =3D h.tagName(n, r, "#{1}", c);      c =3D false;',=0A=
    className:    'n =3D h.className(n, r, "#{1}", c);    c =3D false;',=0A=
    id:           'n =3D h.id(n, r, "#{1}", c);           c =3D false;',=0A=
    attrPresence: 'n =3D h.attrPresence(n, r, "#{1}", c); c =3D false;',=0A=
    attr: function(m) {=0A=
      m[3] =3D (m[5] || m[6]);=0A=
      return new Template('n =3D h.attr(n, r, "#{1}", "#{3}", "#{2}", =
c); c =3D false;').evaluate(m);=0A=
    },=0A=
    pseudo: function(m) {=0A=
      if (m[6]) m[6] =3D m[6].replace(/"/g, '\\"');=0A=
      return new Template('n =3D h.pseudo(n, "#{1}", "#{6}", r, c); c =
=3D false;').evaluate(m);=0A=
    },=0A=
    descendant:   'c =3D "descendant";',=0A=
    child:        'c =3D "child";',=0A=
    adjacent:     'c =3D "adjacent";',=0A=
    laterSibling: 'c =3D "laterSibling";'=0A=
  },=0A=
=0A=
  patterns: [=0A=
    { name: 'laterSibling', re: /^\s*~\s*/ },=0A=
    { name: 'child',        re: /^\s*>\s*/ },=0A=
    { name: 'adjacent',     re: /^\s*\+\s*/ },=0A=
    { name: 'descendant',   re: /^\s/ },=0A=
=0A=
    { name: 'tagName',      re: /^\s*(\*|[\w\-]+)(\b|$)?/ },=0A=
    { name: 'id',           re: /^#([\w\-\*]+)(\b|$)/ },=0A=
    { name: 'className',    re: /^\.([\w\-\*]+)(\b|$)/ },=0A=
    { name: 'pseudo',       re: =
/^:((first|last|nth|nth-last|only)(-child|-of-type)|empty|checked|(en|dis=
)abled|not)(\((.*?)\))?(\b|$|(?=3D\s|[:+~>]))/ },=0A=
    { name: 'attrPresence', re: /^\[((?:[\w-]+:)?[\w-]+)\]/ },=0A=
    { name: 'attr',         re: =
/\[((?:[\w-]*:)?[\w-]+)\s*(?:([!^$*~|]?=3D)\s*((['"])([^\4]*?)\4|([^'"][^=
\]]*?)))?\]/ }=0A=
  ],=0A=
=0A=
  assertions: {=0A=
    tagName: function(element, matches) {=0A=
      return matches[1].toUpperCase() =3D=3D =
element.tagName.toUpperCase();=0A=
    },=0A=
=0A=
    className: function(element, matches) {=0A=
      return Element.hasClassName(element, matches[1]);=0A=
    },=0A=
=0A=
    id: function(element, matches) {=0A=
      return element.id =3D=3D=3D matches[1];=0A=
    },=0A=
=0A=
    attrPresence: function(element, matches) {=0A=
      return Element.hasAttribute(element, matches[1]);=0A=
    },=0A=
=0A=
    attr: function(element, matches) {=0A=
      var nodeValue =3D Element.readAttribute(element, matches[1]);=0A=
      return nodeValue && Selector.operators[matches[2]](nodeValue, =
matches[5] || matches[6]);=0A=
    }=0A=
  },=0A=
=0A=
  handlers: {=0A=
    concat: function(a, b) {=0A=
      for (var i =3D 0, node; node =3D b[i]; i++)=0A=
        a.push(node);=0A=
      return a;=0A=
    },=0A=
=0A=
    mark: function(nodes) {=0A=
      var _true =3D Prototype.emptyFunction;=0A=
      for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
        node._countedByPrototype =3D _true;=0A=
      return nodes;=0A=
    },=0A=
=0A=
    unmark: (function(){=0A=
=0A=
      var PROPERTIES_ATTRIBUTES_MAP =3D (function(){=0A=
        var el =3D document.createElement('div'),=0A=
            isBuggy =3D false,=0A=
            propName =3D '_countedByPrototype',=0A=
            value =3D 'x'=0A=
        el[propName] =3D value;=0A=
        isBuggy =3D (el.getAttribute(propName) =3D=3D=3D value);=0A=
        el =3D null;=0A=
        return isBuggy;=0A=
      })();=0A=
=0A=
      return PROPERTIES_ATTRIBUTES_MAP ?=0A=
        function(nodes) {=0A=
          for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
            node.removeAttribute('_countedByPrototype');=0A=
          return nodes;=0A=
        } :=0A=
        function(nodes) {=0A=
          for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
            node._countedByPrototype =3D void 0;=0A=
          return nodes;=0A=
        }=0A=
    })(),=0A=
=0A=
    index: function(parentNode, reverse, ofType) {=0A=
      parentNode._countedByPrototype =3D Prototype.emptyFunction;=0A=
      if (reverse) {=0A=
        for (var nodes =3D parentNode.childNodes, i =3D nodes.length - =
1, j =3D 1; i >=3D 0; i--) {=0A=
          var node =3D nodes[i];=0A=
          if (node.nodeType =3D=3D 1 && (!ofType || =
node._countedByPrototype)) node.nodeIndex =3D j++;=0A=
        }=0A=
      } else {=0A=
        for (var i =3D 0, j =3D 1, nodes =3D parentNode.childNodes; node =
=3D nodes[i]; i++)=0A=
          if (node.nodeType =3D=3D 1 && (!ofType || =
node._countedByPrototype)) node.nodeIndex =3D j++;=0A=
      }=0A=
    },=0A=
=0A=
    unique: function(nodes) {=0A=
      if (nodes.length =3D=3D 0) return nodes;=0A=
      var results =3D [], n;=0A=
      for (var i =3D 0, l =3D nodes.length; i < l; i++)=0A=
        if (typeof (n =3D nodes[i])._countedByPrototype =3D=3D =
'undefined') {=0A=
          n._countedByPrototype =3D Prototype.emptyFunction;=0A=
          results.push(Element.extend(n));=0A=
        }=0A=
      return Selector.handlers.unmark(results);=0A=
    },=0A=
=0A=
    descendant: function(nodes) {=0A=
      var h =3D Selector.handlers;=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        h.concat(results, node.getElementsByTagName('*'));=0A=
      return results;=0A=
    },=0A=
=0A=
    child: function(nodes) {=0A=
      var h =3D Selector.handlers;=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++) {=0A=
        for (var j =3D 0, child; child =3D node.childNodes[j]; j++)=0A=
          if (child.nodeType =3D=3D 1 && child.tagName !=3D '!') =
results.push(child);=0A=
      }=0A=
      return results;=0A=
    },=0A=
=0A=
    adjacent: function(nodes) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++) {=0A=
        var next =3D this.nextElementSibling(node);=0A=
        if (next) results.push(next);=0A=
      }=0A=
      return results;=0A=
    },=0A=
=0A=
    laterSibling: function(nodes) {=0A=
      var h =3D Selector.handlers;=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        h.concat(results, Element.nextSiblings(node));=0A=
      return results;=0A=
    },=0A=
=0A=
    nextElementSibling: function(node) {=0A=
      while (node =3D node.nextSibling)=0A=
        if (node.nodeType =3D=3D 1) return node;=0A=
      return null;=0A=
    },=0A=
=0A=
    previousElementSibling: function(node) {=0A=
      while (node =3D node.previousSibling)=0A=
        if (node.nodeType =3D=3D 1) return node;=0A=
      return null;=0A=
    },=0A=
=0A=
    tagName: function(nodes, root, tagName, combinator) {=0A=
      var uTagName =3D tagName.toUpperCase();=0A=
      var results =3D [], h =3D Selector.handlers;=0A=
      if (nodes) {=0A=
        if (combinator) {=0A=
          if (combinator =3D=3D "descendant") {=0A=
            for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
              h.concat(results, node.getElementsByTagName(tagName));=0A=
            return results;=0A=
          } else nodes =3D this[combinator](nodes);=0A=
          if (tagName =3D=3D "*") return nodes;=0A=
        }=0A=
        for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
          if (node.tagName.toUpperCase() =3D=3D=3D uTagName) =
results.push(node);=0A=
        return results;=0A=
      } else return root.getElementsByTagName(tagName);=0A=
    },=0A=
=0A=
    id: function(nodes, root, id, combinator) {=0A=
      var targetNode =3D $(id), h =3D Selector.handlers;=0A=
=0A=
      if (root =3D=3D document) {=0A=
        if (!targetNode) return [];=0A=
        if (!nodes) return [targetNode];=0A=
      } else {=0A=
        if (!root.sourceIndex || root.sourceIndex < 1) {=0A=
          var nodes =3D root.getElementsByTagName('*');=0A=
          for (var j =3D 0, node; node =3D nodes[j]; j++) {=0A=
            if (node.id =3D=3D=3D id) return [node];=0A=
          }=0A=
        }=0A=
      }=0A=
=0A=
      if (nodes) {=0A=
        if (combinator) {=0A=
          if (combinator =3D=3D 'child') {=0A=
            for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
              if (targetNode.parentNode =3D=3D node) return [targetNode];=0A=
          } else if (combinator =3D=3D 'descendant') {=0A=
            for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
              if (Element.descendantOf(targetNode, node)) return =
[targetNode];=0A=
          } else if (combinator =3D=3D 'adjacent') {=0A=
            for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
              if (Selector.handlers.previousElementSibling(targetNode) =
=3D=3D node)=0A=
                return [targetNode];=0A=
          } else nodes =3D h[combinator](nodes);=0A=
        }=0A=
        for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
          if (node =3D=3D targetNode) return [targetNode];=0A=
        return [];=0A=
      }=0A=
      return (targetNode && Element.descendantOf(targetNode, root)) ? =
[targetNode] : [];=0A=
    },=0A=
=0A=
    className: function(nodes, root, className, combinator) {=0A=
      if (nodes && combinator) nodes =3D this[combinator](nodes);=0A=
      return Selector.handlers.byClassName(nodes, root, className);=0A=
    },=0A=
=0A=
    byClassName: function(nodes, root, className) {=0A=
      if (!nodes) nodes =3D Selector.handlers.descendant([root]);=0A=
      var needle =3D ' ' + className + ' ';=0A=
      for (var i =3D 0, results =3D [], node, nodeClassName; node =3D =
nodes[i]; i++) {=0A=
        nodeClassName =3D node.className;=0A=
        if (nodeClassName.length =3D=3D 0) continue;=0A=
        if (nodeClassName =3D=3D className || (' ' + nodeClassName + ' =
').include(needle))=0A=
          results.push(node);=0A=
      }=0A=
      return results;=0A=
    },=0A=
=0A=
    attrPresence: function(nodes, root, attr, combinator) {=0A=
      if (!nodes) nodes =3D root.getElementsByTagName("*");=0A=
      if (nodes && combinator) nodes =3D this[combinator](nodes);=0A=
      var results =3D [];=0A=
      for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
        if (Element.hasAttribute(node, attr)) results.push(node);=0A=
      return results;=0A=
    },=0A=
=0A=
    attr: function(nodes, root, attr, value, operator, combinator) {=0A=
      if (!nodes) nodes =3D root.getElementsByTagName("*");=0A=
      if (nodes && combinator) nodes =3D this[combinator](nodes);=0A=
      var handler =3D Selector.operators[operator], results =3D [];=0A=
      for (var i =3D 0, node; node =3D nodes[i]; i++) {=0A=
        var nodeValue =3D Element.readAttribute(node, attr);=0A=
        if (nodeValue =3D=3D=3D null) continue;=0A=
        if (handler(nodeValue, value)) results.push(node);=0A=
      }=0A=
      return results;=0A=
    },=0A=
=0A=
    pseudo: function(nodes, name, value, root, combinator) {=0A=
      if (nodes && combinator) nodes =3D this[combinator](nodes);=0A=
      if (!nodes) nodes =3D root.getElementsByTagName("*");=0A=
      return Selector.pseudos[name](nodes, value, root);=0A=
    }=0A=
  },=0A=
=0A=
  pseudos: {=0A=
    'first-child': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++) {=0A=
        if (Selector.handlers.previousElementSibling(node)) continue;=0A=
          results.push(node);=0A=
      }=0A=
      return results;=0A=
    },=0A=
    'last-child': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++) {=0A=
        if (Selector.handlers.nextElementSibling(node)) continue;=0A=
          results.push(node);=0A=
      }=0A=
      return results;=0A=
    },=0A=
    'only-child': function(nodes, value, root) {=0A=
      var h =3D Selector.handlers;=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        if (!h.previousElementSibling(node) && =
!h.nextElementSibling(node))=0A=
          results.push(node);=0A=
      return results;=0A=
    },=0A=
    'nth-child':        function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, formula, root);=0A=
    },=0A=
    'nth-last-child':   function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, formula, root, true);=0A=
    },=0A=
    'nth-of-type':      function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, formula, root, false, true);=0A=
    },=0A=
    'nth-last-of-type': function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, formula, root, true, true);=0A=
    },=0A=
    'first-of-type':    function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, "1", root, false, true);=0A=
    },=0A=
    'last-of-type':     function(nodes, formula, root) {=0A=
      return Selector.pseudos.nth(nodes, "1", root, true, true);=0A=
    },=0A=
    'only-of-type':     function(nodes, formula, root) {=0A=
      var p =3D Selector.pseudos;=0A=
      return p['last-of-type'](p['first-of-type'](nodes, formula, root), =
formula, root);=0A=
    },=0A=
=0A=
    getIndices: function(a, b, total) {=0A=
      if (a =3D=3D 0) return b > 0 ? [b] : [];=0A=
      return $R(1, total).inject([], function(memo, i) {=0A=
        if (0 =3D=3D (i - b) % a && (i - b) / a >=3D 0) memo.push(i);=0A=
        return memo;=0A=
      });=0A=
    },=0A=
=0A=
    nth: function(nodes, formula, root, reverse, ofType) {=0A=
      if (nodes.length =3D=3D 0) return [];=0A=
      if (formula =3D=3D 'even') formula =3D '2n+0';=0A=
      if (formula =3D=3D 'odd')  formula =3D '2n+1';=0A=
      var h =3D Selector.handlers, results =3D [], indexed =3D [], m;=0A=
      h.mark(nodes);=0A=
      for (var i =3D 0, node; node =3D nodes[i]; i++) {=0A=
        if (!node.parentNode._countedByPrototype) {=0A=
          h.index(node.parentNode, reverse, ofType);=0A=
          indexed.push(node.parentNode);=0A=
        }=0A=
      }=0A=
      if (formula.match(/^\d+$/)) { // just a number=0A=
        formula =3D Number(formula);=0A=
        for (var i =3D 0, node; node =3D nodes[i]; i++)=0A=
          if (node.nodeIndex =3D=3D formula) results.push(node);=0A=
      } else if (m =3D formula.match(/^(-?\d*)?n(([+-])(\d+))?/)) { // =
an+b=0A=
        if (m[1] =3D=3D "-") m[1] =3D -1;=0A=
        var a =3D m[1] ? Number(m[1]) : 1;=0A=
        var b =3D m[2] ? Number(m[2]) : 0;=0A=
        var indices =3D Selector.pseudos.getIndices(a, b, nodes.length);=0A=
        for (var i =3D 0, node, l =3D indices.length; node =3D nodes[i]; =
i++) {=0A=
          for (var j =3D 0; j < l; j++)=0A=
            if (node.nodeIndex =3D=3D indices[j]) results.push(node);=0A=
        }=0A=
      }=0A=
      h.unmark(nodes);=0A=
      h.unmark(indexed);=0A=
      return results;=0A=
    },=0A=
=0A=
    'empty': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++) {=0A=
        if (node.tagName =3D=3D '!' || node.firstChild) continue;=0A=
        results.push(node);=0A=
      }=0A=
      return results;=0A=
    },=0A=
=0A=
    'not': function(nodes, selector, root) {=0A=
      var h =3D Selector.handlers, selectorType, m;=0A=
      var exclusions =3D new Selector(selector).findElements(root);=0A=
      h.mark(exclusions);=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        if (!node._countedByPrototype) results.push(node);=0A=
      h.unmark(exclusions);=0A=
      return results;=0A=
    },=0A=
=0A=
    'enabled': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        if (!node.disabled && (!node.type || node.type !=3D=3D 'hidden'))=0A=
          results.push(node);=0A=
      return results;=0A=
    },=0A=
=0A=
    'disabled': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        if (node.disabled) results.push(node);=0A=
      return results;=0A=
    },=0A=
=0A=
    'checked': function(nodes, value, root) {=0A=
      for (var i =3D 0, results =3D [], node; node =3D nodes[i]; i++)=0A=
        if (node.checked) results.push(node);=0A=
      return results;=0A=
    }=0A=
  },=0A=
=0A=
  operators: {=0A=
    '=3D':  function(nv, v) { return nv =3D=3D v; },=0A=
    '!=3D': function(nv, v) { return nv !=3D v; },=0A=
    '^=3D': function(nv, v) { return nv =3D=3D v || nv && =
nv.startsWith(v); },=0A=
    '$=3D': function(nv, v) { return nv =3D=3D v || nv && =
nv.endsWith(v); },=0A=
    '*=3D': function(nv, v) { return nv =3D=3D v || nv && nv.include(v); =
},=0A=
    '~=3D': function(nv, v) { return (' ' + nv + ' ').include(' ' + v + =
' '); },=0A=
    '|=3D': function(nv, v) { return ('-' + (nv || "").toUpperCase() +=0A=
     '-').include('-' + (v || "").toUpperCase() + '-'); }=0A=
  },=0A=
=0A=
  split: function(expression) {=0A=
    var expressions =3D [];=0A=
    expression.scan(/(([\w#:.~>+()\s-]+|\*|\[.*?\])+)\s*(,|$)/, =
function(m) {=0A=
      expressions.push(m[1].strip());=0A=
    });=0A=
    return expressions;=0A=
  },=0A=
=0A=
  matchElements: function(elements, expression) {=0A=
    var matches =3D $$(expression), h =3D Selector.handlers;=0A=
    h.mark(matches);=0A=
    for (var i =3D 0, results =3D [], element; element =3D elements[i]; =
i++)=0A=
      if (element._countedByPrototype) results.push(element);=0A=
    h.unmark(matches);=0A=
    return results;=0A=
  },=0A=
=0A=
  findElement: function(elements, expression, index) {=0A=
    if (Object.isNumber(expression)) {=0A=
      index =3D expression; expression =3D false;=0A=
    }=0A=
    return Selector.matchElements(elements, expression || '*')[index || =
0];=0A=
  },=0A=
=0A=
  findChildElements: function(element, expressions) {=0A=
    expressions =3D Selector.split(expressions.join(','));=0A=
    var results =3D [], h =3D Selector.handlers;=0A=
    for (var i =3D 0, l =3D expressions.length, selector; i < l; i++) {=0A=
      selector =3D new Selector(expressions[i].strip());=0A=
      h.concat(results, selector.findElements(element));=0A=
    }=0A=
    return (l > 1) ? h.unique(results) : results;=0A=
  }=0A=
});=0A=
=0A=
if (Prototype.Browser.IE) {=0A=
  Object.extend(Selector.handlers, {=0A=
    concat: function(a, b) {=0A=
      for (var i =3D 0, node; node =3D b[i]; i++)=0A=
        if (node.tagName !=3D=3D "!") a.push(node);=0A=
      return a;=0A=
    }=0A=
  });=0A=
}=0A=
=0A=
function $$() {=0A=
  return Selector.findChildElements(document, $A(arguments));=0A=
}=0A=
=0A=
var Form =3D {=0A=
  reset: function(form) {=0A=
    form =3D $(form);=0A=
    form.reset();=0A=
    return form;=0A=
  },=0A=
=0A=
  serializeElements: function(elements, options) {=0A=
    if (typeof options !=3D 'object') options =3D { hash: !!options };=0A=
    else if (Object.isUndefined(options.hash)) options.hash =3D true;=0A=
    var key, value, submitted =3D false, submit =3D options.submit;=0A=
=0A=
    var data =3D elements.inject({ }, function(result, element) {=0A=
      if (!element.disabled && element.name) {=0A=
        key =3D element.name; value =3D $(element).getValue();=0A=
        if (value !=3D null && element.type !=3D 'file' && (element.type =
!=3D 'submit' || (!submitted &&=0A=
            submit !=3D=3D false && (!submit || key =3D=3D submit) && =
(submitted =3D true)))) {=0A=
          if (key in result) {=0A=
            if (!Object.isArray(result[key])) result[key] =3D =
[result[key]];=0A=
            result[key].push(value);=0A=
          }=0A=
          else result[key] =3D value;=0A=
        }=0A=
      }=0A=
      return result;=0A=
    });=0A=
=0A=
    return options.hash ? data : Object.toQueryString(data);=0A=
  }=0A=
};=0A=
=0A=
Form.Methods =3D {=0A=
  serialize: function(form, options) {=0A=
    return Form.serializeElements(Form.getElements(form), options);=0A=
  },=0A=
=0A=
  getElements: function(form) {=0A=
    var elements =3D $(form).getElementsByTagName('*'),=0A=
        element,=0A=
        arr =3D [ ],=0A=
        serializers =3D Form.Element.Serializers;=0A=
    for (var i =3D 0; element =3D elements[i]; i++) {=0A=
      arr.push(element);=0A=
    }=0A=
    return arr.inject([], function(elements, child) {=0A=
      if (serializers[child.tagName.toLowerCase()])=0A=
        elements.push(Element.extend(child));=0A=
      return elements;=0A=
    })=0A=
  },=0A=
=0A=
  getInputs: function(form, typeName, name) {=0A=
    form =3D $(form);=0A=
    var inputs =3D form.getElementsByTagName('input');=0A=
=0A=
    if (!typeName && !name) return $A(inputs).map(Element.extend);=0A=
=0A=
    for (var i =3D 0, matchingInputs =3D [], length =3D inputs.length; i =
< length; i++) {=0A=
      var input =3D inputs[i];=0A=
      if ((typeName && input.type !=3D typeName) || (name && input.name =
!=3D name))=0A=
        continue;=0A=
      matchingInputs.push(Element.extend(input));=0A=
    }=0A=
=0A=
    return matchingInputs;=0A=
  },=0A=
=0A=
  disable: function(form) {=0A=
    form =3D $(form);=0A=
    Form.getElements(form).invoke('disable');=0A=
    return form;=0A=
  },=0A=
=0A=
  enable: function(form) {=0A=
    form =3D $(form);=0A=
    Form.getElements(form).invoke('enable');=0A=
    return form;=0A=
  },=0A=
=0A=
  findFirstElement: function(form) {=0A=
    var elements =3D $(form).getElements().findAll(function(element) {=0A=
      return 'hidden' !=3D element.type && !element.disabled;=0A=
    });=0A=
    var firstByIndex =3D elements.findAll(function(element) {=0A=
      return element.hasAttribute('tabIndex') && element.tabIndex >=3D 0;=0A=
    }).sortBy(function(element) { return element.tabIndex }).first();=0A=
=0A=
    return firstByIndex ? firstByIndex : elements.find(function(element) =
{=0A=
      return /^(?:input|select|textarea)$/i.test(element.tagName);=0A=
    });=0A=
  },=0A=
=0A=
  focusFirstElement: function(form) {=0A=
    form =3D $(form);=0A=
    form.findFirstElement().activate();=0A=
    return form;=0A=
  },=0A=
=0A=
  request: function(form, options) {=0A=
    form =3D $(form), options =3D Object.clone(options || { });=0A=
=0A=
    var params =3D options.parameters, action =3D =
form.readAttribute('action') || '';=0A=
    if (action.blank()) action =3D window.location.href;=0A=
    options.parameters =3D form.serialize(true);=0A=
=0A=
    if (params) {=0A=
      if (Object.isString(params)) params =3D params.toQueryParams();=0A=
      Object.extend(options.parameters, params);=0A=
    }=0A=
=0A=
    if (form.hasAttribute('method') && !options.method)=0A=
      options.method =3D form.method;=0A=
=0A=
    return new Ajax.Request(action, options);=0A=
  }=0A=
};=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
=0A=
Form.Element =3D {=0A=
  focus: function(element) {=0A=
    $(element).focus();=0A=
    return element;=0A=
  },=0A=
=0A=
  select: function(element) {=0A=
    $(element).select();=0A=
    return element;=0A=
  }=0A=
};=0A=
=0A=
Form.Element.Methods =3D {=0A=
=0A=
  serialize: function(element) {=0A=
    element =3D $(element);=0A=
    if (!element.disabled && element.name) {=0A=
      var value =3D element.getValue();=0A=
      if (value !=3D undefined) {=0A=
        var pair =3D { };=0A=
        pair[element.name] =3D value;=0A=
        return Object.toQueryString(pair);=0A=
      }=0A=
    }=0A=
    return '';=0A=
  },=0A=
=0A=
  getValue: function(element) {=0A=
    element =3D $(element);=0A=
    var method =3D element.tagName.toLowerCase();=0A=
    return Form.Element.Serializers[method](element);=0A=
  },=0A=
=0A=
  setValue: function(element, value) {=0A=
    element =3D $(element);=0A=
    var method =3D element.tagName.toLowerCase();=0A=
    Form.Element.Serializers[method](element, value);=0A=
    return element;=0A=
  },=0A=
=0A=
  clear: function(element) {=0A=
    $(element).value =3D '';=0A=
    return element;=0A=
  },=0A=
=0A=
  present: function(element) {=0A=
    return $(element).value !=3D '';=0A=
  },=0A=
=0A=
  activate: function(element) {=0A=
    element =3D $(element);=0A=
    try {=0A=
      element.focus();=0A=
      if (element.select && (element.tagName.toLowerCase() !=3D 'input' =
||=0A=
          !(/^(?:button|reset|submit)$/i.test(element.type))))=0A=
        element.select();=0A=
    } catch (e) { }=0A=
    return element;=0A=
  },=0A=
=0A=
  disable: function(element) {=0A=
    element =3D $(element);=0A=
    element.disabled =3D true;=0A=
    return element;=0A=
  },=0A=
=0A=
  enable: function(element) {=0A=
    element =3D $(element);=0A=
    element.disabled =3D false;=0A=
    return element;=0A=
  }=0A=
};=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
var Field =3D Form.Element;=0A=
=0A=
var $F =3D Form.Element.Methods.getValue;=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
Form.Element.Serializers =3D {=0A=
  input: function(element, value) {=0A=
    switch (element.type.toLowerCase()) {=0A=
      case 'checkbox':=0A=
      case 'radio':=0A=
        return Form.Element.Serializers.inputSelector(element, value);=0A=
      default:=0A=
        return Form.Element.Serializers.textarea(element, value);=0A=
    }=0A=
  },=0A=
=0A=
  inputSelector: function(element, value) {=0A=
    if (Object.isUndefined(value)) return element.checked ? =
element.value : null;=0A=
    else element.checked =3D !!value;=0A=
  },=0A=
=0A=
  textarea: function(element, value) {=0A=
    if (Object.isUndefined(value)) return element.value;=0A=
    else element.value =3D value;=0A=
  },=0A=
=0A=
  select: function(element, value) {=0A=
    if (Object.isUndefined(value))=0A=
      return this[element.type =3D=3D 'select-one' ?=0A=
        'selectOne' : 'selectMany'](element);=0A=
    else {=0A=
      var opt, currentValue, single =3D !Object.isArray(value);=0A=
      for (var i =3D 0, length =3D element.length; i < length; i++) {=0A=
        opt =3D element.options[i];=0A=
        currentValue =3D this.optionValue(opt);=0A=
        if (single) {=0A=
          if (currentValue =3D=3D value) {=0A=
            opt.selected =3D true;=0A=
            return;=0A=
          }=0A=
        }=0A=
        else opt.selected =3D value.include(currentValue);=0A=
      }=0A=
    }=0A=
  },=0A=
=0A=
  selectOne: function(element) {=0A=
    var index =3D element.selectedIndex;=0A=
    return index >=3D 0 ? this.optionValue(element.options[index]) : =
null;=0A=
  },=0A=
=0A=
  selectMany: function(element) {=0A=
    var values, length =3D element.length;=0A=
    if (!length) return null;=0A=
=0A=
    for (var i =3D 0, values =3D []; i < length; i++) {=0A=
      var opt =3D element.options[i];=0A=
      if (opt.selected) values.push(this.optionValue(opt));=0A=
    }=0A=
    return values;=0A=
  },=0A=
=0A=
  optionValue: function(opt) {=0A=
    return Element.extend(opt).hasAttribute('value') ? opt.value : =
opt.text;=0A=
  }=0A=
};=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
=0A=
Abstract.TimedObserver =3D Class.create(PeriodicalExecuter, {=0A=
  initialize: function($super, element, frequency, callback) {=0A=
    $super(callback, frequency);=0A=
    this.element   =3D $(element);=0A=
    this.lastValue =3D this.getValue();=0A=
  },=0A=
=0A=
  execute: function() {=0A=
    var value =3D this.getValue();=0A=
    if (Object.isString(this.lastValue) && Object.isString(value) ?=0A=
        this.lastValue !=3D value : String(this.lastValue) !=3D =
String(value)) {=0A=
      this.callback(this.element, value);=0A=
      this.lastValue =3D value;=0A=
    }=0A=
  }=0A=
});=0A=
=0A=
Form.Element.Observer =3D Class.create(Abstract.TimedObserver, {=0A=
  getValue: function() {=0A=
    return Form.Element.getValue(this.element);=0A=
  }=0A=
});=0A=
=0A=
Form.Observer =3D Class.create(Abstract.TimedObserver, {=0A=
  getValue: function() {=0A=
    return Form.serialize(this.element);=0A=
  }=0A=
});=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
Abstract.EventObserver =3D Class.create({=0A=
  initialize: function(element, callback) {=0A=
    this.element  =3D $(element);=0A=
    this.callback =3D callback;=0A=
=0A=
    this.lastValue =3D this.getValue();=0A=
    if (this.element.tagName.toLowerCase() =3D=3D 'form')=0A=
      this.registerFormCallbacks();=0A=
    else=0A=
      this.registerCallback(this.element);=0A=
  },=0A=
=0A=
  onElementEvent: function() {=0A=
    var value =3D this.getValue();=0A=
    if (this.lastValue !=3D value) {=0A=
      this.callback(this.element, value);=0A=
      this.lastValue =3D value;=0A=
    }=0A=
  },=0A=
=0A=
  registerFormCallbacks: function() {=0A=
    Form.getElements(this.element).each(this.registerCallback, this);=0A=
  },=0A=
=0A=
  registerCallback: function(element) {=0A=
    if (element.type) {=0A=
      switch (element.type.toLowerCase()) {=0A=
        case 'checkbox':=0A=
        case 'radio':=0A=
          Event.observe(element, 'click', =
this.onElementEvent.bind(this));=0A=
          break;=0A=
        default:=0A=
          Event.observe(element, 'change', =
this.onElementEvent.bind(this));=0A=
          break;=0A=
      }=0A=
    }=0A=
  }=0A=
});=0A=
=0A=
Form.Element.EventObserver =3D Class.create(Abstract.EventObserver, {=0A=
  getValue: function() {=0A=
    return Form.Element.getValue(this.element);=0A=
  }=0A=
});=0A=
=0A=
Form.EventObserver =3D Class.create(Abstract.EventObserver, {=0A=
  getValue: function() {=0A=
    return Form.serialize(this.element);=0A=
  }=0A=
});=0A=
(function() {=0A=
=0A=
  var Event =3D {=0A=
    KEY_BACKSPACE: 8,=0A=
    KEY_TAB:       9,=0A=
    KEY_RETURN:   13,=0A=
    KEY_ESC:      27,=0A=
    KEY_LEFT:     37,=0A=
    KEY_UP:       38,=0A=
    KEY_RIGHT:    39,=0A=
    KEY_DOWN:     40,=0A=
    KEY_DELETE:   46,=0A=
    KEY_HOME:     36,=0A=
    KEY_END:      35,=0A=
    KEY_PAGEUP:   33,=0A=
    KEY_PAGEDOWN: 34,=0A=
    KEY_INSERT:   45,=0A=
=0A=
    cache: {}=0A=
  };=0A=
=0A=
  var docEl =3D document.documentElement;=0A=
  var MOUSEENTER_MOUSELEAVE_EVENTS_SUPPORTED =3D 'onmouseenter' in docEl=0A=
    && 'onmouseleave' in docEl;=0A=
=0A=
  var _isButton;=0A=
  if (Prototype.Browser.IE) {=0A=
    var buttonMap =3D { 0: 1, 1: 4, 2: 2 };=0A=
    _isButton =3D function(event, code) {=0A=
      return event.button =3D=3D=3D buttonMap[code];=0A=
    };=0A=
  } else if (Prototype.Browser.WebKit) {=0A=
    _isButton =3D function(event, code) {=0A=
      switch (code) {=0A=
        case 0: return event.which =3D=3D 1 && !event.metaKey;=0A=
        case 1: return event.which =3D=3D 1 && event.metaKey;=0A=
        default: return false;=0A=
      }=0A=
    };=0A=
  } else {=0A=
    _isButton =3D function(event, code) {=0A=
      return event.which ? (event.which =3D=3D=3D code + 1) : =
(event.button =3D=3D=3D code);=0A=
    };=0A=
  }=0A=
=0A=
  function isLeftClick(event)   { return _isButton(event, 0) }=0A=
=0A=
  function isMiddleClick(event) { return _isButton(event, 1) }=0A=
=0A=
  function isRightClick(event)  { return _isButton(event, 2) }=0A=
=0A=
  function element(event) {=0A=
    event =3D Event.extend(event);=0A=
=0A=
    var node =3D event.target, type =3D event.type,=0A=
     currentTarget =3D event.currentTarget;=0A=
=0A=
    if (currentTarget && currentTarget.tagName) {=0A=
      if (type =3D=3D=3D 'load' || type =3D=3D=3D 'error' ||=0A=
        (type =3D=3D=3D 'click' && currentTarget.tagName.toLowerCase() =
=3D=3D=3D 'input'=0A=
          && currentTarget.type =3D=3D=3D 'radio'))=0A=
            node =3D currentTarget;=0A=
    }=0A=
=0A=
    if (node.nodeType =3D=3D Node.TEXT_NODE)=0A=
      node =3D node.parentNode;=0A=
=0A=
    return Element.extend(node);=0A=
  }=0A=
=0A=
  function findElement(event, expression) {=0A=
    var element =3D Event.element(event);=0A=
    if (!expression) return element;=0A=
    var elements =3D [element].concat(element.ancestors());=0A=
    return Selector.findElement(elements, expression, 0);=0A=
  }=0A=
=0A=
  function pointer(event) {=0A=
    return { x: pointerX(event), y: pointerY(event) };=0A=
  }=0A=
=0A=
  function pointerX(event) {=0A=
    var docElement =3D document.documentElement,=0A=
     body =3D document.body || { scrollLeft: 0 };=0A=
=0A=
    return event.pageX || (event.clientX +=0A=
      (docElement.scrollLeft || body.scrollLeft) -=0A=
      (docElement.clientLeft || 0));=0A=
  }=0A=
=0A=
  function pointerY(event) {=0A=
    var docElement =3D document.documentElement,=0A=
     body =3D document.body || { scrollTop: 0 };=0A=
=0A=
    return  event.pageY || (event.clientY +=0A=
       (docElement.scrollTop || body.scrollTop) -=0A=
       (docElement.clientTop || 0));=0A=
  }=0A=
=0A=
=0A=
  function stop(event) {=0A=
    Event.extend(event);=0A=
    event.preventDefault();=0A=
    event.stopPropagation();=0A=
=0A=
    event.stopped =3D true;=0A=
  }=0A=
=0A=
  Event.Methods =3D {=0A=
    isLeftClick: isLeftClick,=0A=
    isMiddleClick: isMiddleClick,=0A=
    isRightClick: isRightClick,=0A=
=0A=
    element: element,=0A=
    findElement: findElement,=0A=
=0A=
    pointer: pointer,=0A=
    pointerX: pointerX,=0A=
    pointerY: pointerY,=0A=
=0A=
    stop: stop=0A=
  };=0A=
=0A=
=0A=
  var methods =3D Object.keys(Event.Methods).inject({ }, function(m, =
name) {=0A=
    m[name] =3D Event.Methods[name].methodize();=0A=
    return m;=0A=
  });=0A=
=0A=
  if (Prototype.Browser.IE) {=0A=
    function _relatedTarget(event) {=0A=
      var element;=0A=
      switch (event.type) {=0A=
        case 'mouseover': element =3D event.fromElement; break;=0A=
        case 'mouseout':  element =3D event.toElement;   break;=0A=
        default: return null;=0A=
      }=0A=
      return Element.extend(element);=0A=
    }=0A=
=0A=
    Object.extend(methods, {=0A=
      stopPropagation: function() { this.cancelBubble =3D true },=0A=
      preventDefault:  function() { this.returnValue =3D false },=0A=
      inspect: function() { return '[object Event]' }=0A=
    });=0A=
=0A=
    Event.extend =3D function(event, element) {=0A=
      if (!event) return false;=0A=
      if (event._extendedByPrototype) return event;=0A=
=0A=
      event._extendedByPrototype =3D Prototype.emptyFunction;=0A=
      var pointer =3D Event.pointer(event);=0A=
=0A=
      Object.extend(event, {=0A=
        target: event.srcElement || element,=0A=
        relatedTarget: _relatedTarget(event),=0A=
        pageX:  pointer.x,=0A=
        pageY:  pointer.y=0A=
      });=0A=
=0A=
      return Object.extend(event, methods);=0A=
    };=0A=
  } else {=0A=
    Event.prototype =3D window.Event.prototype || =
document.createEvent('HTMLEvents').__proto__;=0A=
    Object.extend(Event.prototype, methods);=0A=
    Event.extend =3D Prototype.K;=0A=
  }=0A=
=0A=
  function _createResponder(element, eventName, handler) {=0A=
    var registry =3D Element.retrieve(element, =
'prototype_event_registry');=0A=
=0A=
    if (Object.isUndefined(registry)) {=0A=
      CACHE.push(element);=0A=
      registry =3D Element.retrieve(element, 'prototype_event_registry', =
$H());=0A=
    }=0A=
=0A=
    var respondersForEvent =3D registry.get(eventName);=0A=
    if (Object.isUndefined(respondersForEvent)) {=0A=
      respondersForEvent =3D [];=0A=
      registry.set(eventName, respondersForEvent);=0A=
    }=0A=
=0A=
    if (respondersForEvent.pluck('handler').include(handler)) return =
false;=0A=
=0A=
    var responder;=0A=
    if (eventName.include(":")) {=0A=
      responder =3D function(event) {=0A=
        if (Object.isUndefined(event.eventName))=0A=
          return false;=0A=
=0A=
        if (event.eventName !=3D=3D eventName)=0A=
          return false;=0A=
=0A=
        Event.extend(event, element);=0A=
        handler.call(element, event);=0A=
      };=0A=
    } else {=0A=
      if (!MOUSEENTER_MOUSELEAVE_EVENTS_SUPPORTED &&=0A=
       (eventName =3D=3D=3D "mouseenter" || eventName =3D=3D=3D =
"mouseleave")) {=0A=
        if (eventName =3D=3D=3D "mouseenter" || eventName =3D=3D=3D =
"mouseleave") {=0A=
          responder =3D function(event) {=0A=
            Event.extend(event, element);=0A=
=0A=
            var parent =3D event.relatedTarget;=0A=
            while (parent && parent !=3D=3D element) {=0A=
              try { parent =3D parent.parentNode; }=0A=
              catch(e) { parent =3D element; }=0A=
            }=0A=
=0A=
            if (parent =3D=3D=3D element) return;=0A=
=0A=
            handler.call(element, event);=0A=
          };=0A=
        }=0A=
      } else {=0A=
        responder =3D function(event) {=0A=
          Event.extend(event, element);=0A=
          handler.call(element, event);=0A=
        };=0A=
      }=0A=
    }=0A=
=0A=
    responder.handler =3D handler;=0A=
    respondersForEvent.push(responder);=0A=
    return responder;=0A=
  }=0A=
=0A=
  function _destroyCache() {=0A=
    for (var i =3D 0, length =3D CACHE.length; i < length; i++) {=0A=
      Event.stopObserving(CACHE[i]);=0A=
      CACHE[i] =3D null;=0A=
    }=0A=
  }=0A=
=0A=
  var CACHE =3D [];=0A=
=0A=
  if (Prototype.Browser.IE)=0A=
    window.attachEvent('onunload', _destroyCache);=0A=
=0A=
  if (Prototype.Browser.WebKit)=0A=
    window.addEventListener('unload', Prototype.emptyFunction, false);=0A=
=0A=
=0A=
  var _getDOMEventName =3D Prototype.K;=0A=
=0A=
  if (!MOUSEENTER_MOUSELEAVE_EVENTS_SUPPORTED) {=0A=
    _getDOMEventName =3D function(eventName) {=0A=
      var translations =3D { mouseenter: "mouseover", mouseleave: =
"mouseout" };=0A=
      return eventName in translations ? translations[eventName] : =
eventName;=0A=
    };=0A=
  }=0A=
=0A=
  function observe(element, eventName, handler) {=0A=
    element =3D $(element);=0A=
=0A=
    var responder =3D _createResponder(element, eventName, handler);=0A=
=0A=
    if (!responder) return element;=0A=
=0A=
    if (eventName.include(':')) {=0A=
      if (element.addEventListener)=0A=
        element.addEventListener("dataavailable", responder, false);=0A=
      else {=0A=
        element.attachEvent("ondataavailable", responder);=0A=
        element.attachEvent("onfilterchange", responder);=0A=
      }=0A=
    } else {=0A=
      var actualEventName =3D _getDOMEventName(eventName);=0A=
=0A=
      if (element.addEventListener)=0A=
        element.addEventListener(actualEventName, responder, false);=0A=
      else=0A=
        element.attachEvent("on" + actualEventName, responder);=0A=
    }=0A=
=0A=
    return element;=0A=
  }=0A=
=0A=
  function stopObserving(element, eventName, handler) {=0A=
    element =3D $(element);=0A=
=0A=
    var registry =3D Element.retrieve(element, =
'prototype_event_registry');=0A=
=0A=
    if (Object.isUndefined(registry)) return element;=0A=
=0A=
    if (eventName && !handler) {=0A=
      var responders =3D registry.get(eventName);=0A=
=0A=
      if (Object.isUndefined(responders)) return element;=0A=
=0A=
      responders.each( function(r) {=0A=
        Element.stopObserving(element, eventName, r.handler);=0A=
      });=0A=
      return element;=0A=
    } else if (!eventName) {=0A=
      registry.each( function(pair) {=0A=
        var eventName =3D pair.key, responders =3D pair.value;=0A=
=0A=
        responders.each( function(r) {=0A=
          Element.stopObserving(element, eventName, r.handler);=0A=
        });=0A=
      });=0A=
      return element;=0A=
    }=0A=
=0A=
    var responders =3D registry.get(eventName);=0A=
=0A=
    if (!responders) return;=0A=
=0A=
    var responder =3D responders.find( function(r) { return r.handler =
=3D=3D=3D handler; });=0A=
    if (!responder) return element;=0A=
=0A=
    var actualEventName =3D _getDOMEventName(eventName);=0A=
=0A=
    if (eventName.include(':')) {=0A=
      if (element.removeEventListener)=0A=
        element.removeEventListener("dataavailable", responder, false);=0A=
      else {=0A=
        element.detachEvent("ondataavailable", responder);=0A=
        element.detachEvent("onfilterchange",  responder);=0A=
      }=0A=
    } else {=0A=
      if (element.removeEventListener)=0A=
        element.removeEventListener(actualEventName, responder, false);=0A=
      else=0A=
        element.detachEvent('on' + actualEventName, responder);=0A=
    }=0A=
=0A=
    registry.set(eventName, responders.without(responder));=0A=
=0A=
    return element;=0A=
  }=0A=
=0A=
  function fire(element, eventName, memo, bubble) {=0A=
    element =3D $(element);=0A=
=0A=
    if (Object.isUndefined(bubble))=0A=
      bubble =3D true;=0A=
=0A=
    if (element =3D=3D document && document.createEvent && =
!element.dispatchEvent)=0A=
      element =3D document.documentElement;=0A=
=0A=
    var event;=0A=
    if (document.createEvent) {=0A=
      event =3D document.createEvent('HTMLEvents');=0A=
      event.initEvent('dataavailable', true, true);=0A=
    } else {=0A=
      event =3D document.createEventObject();=0A=
      event.eventType =3D bubble ? 'ondataavailable' : 'onfilterchange';=0A=
    }=0A=
=0A=
    event.eventName =3D eventName;=0A=
    event.memo =3D memo || { };=0A=
=0A=
    if (document.createEvent)=0A=
      element.dispatchEvent(event);=0A=
    else=0A=
      element.fireEvent(event.eventType, event);=0A=
=0A=
    return Event.extend(event);=0A=
  }=0A=
=0A=
=0A=
  Object.extend(Event, Event.Methods);=0A=
=0A=
  Object.extend(Event, {=0A=
    fire:          fire,=0A=
    observe:       observe,=0A=
    stopObserving: stopObserving=0A=
  });=0A=
=0A=
  Element.addMethods({=0A=
    fire:          fire,=0A=
=0A=
    observe:       observe,=0A=
=0A=
    stopObserving: stopObserving=0A=
  });=0A=
=0A=
  Object.extend(document, {=0A=
    fire:          fire.methodize(),=0A=
=0A=
    observe:       observe.methodize(),=0A=
=0A=
    stopObserving: stopObserving.methodize(),=0A=
=0A=
    loaded:        false=0A=
  });=0A=
=0A=
  if (window.Event) Object.extend(window.Event, Event);=0A=
  else window.Event =3D Event;=0A=
})();=0A=
=0A=
(function() {=0A=
  /* Support for the DOMContentLoaded event is based on work by Dan Webb,=0A=
     Matthias Miller, Dean Edwards, John Resig, and Diego Perini. */=0A=
=0A=
  var timer;=0A=
=0A=
  function fireContentLoadedEvent() {=0A=
    if (document.loaded) return;=0A=
    if (timer) window.clearTimeout(timer);=0A=
    document.loaded =3D true;=0A=
    document.fire('dom:loaded');=0A=
  }=0A=
=0A=
  function checkReadyState() {=0A=
    if (document.readyState =3D=3D=3D 'complete') {=0A=
      document.stopObserving('readystatechange', checkReadyState);=0A=
      fireContentLoadedEvent();=0A=
    }=0A=
  }=0A=
=0A=
  function pollDoScroll() {=0A=
    try { document.documentElement.doScroll('left'); }=0A=
    catch(e) {=0A=
      timer =3D pollDoScroll.defer();=0A=
      return;=0A=
    }=0A=
    fireContentLoadedEvent();=0A=
  }=0A=
=0A=
  if (document.addEventListener) {=0A=
    document.addEventListener('DOMContentLoaded', =
fireContentLoadedEvent, false);=0A=
  } else {=0A=
    document.observe('readystatechange', checkReadyState);=0A=
    if (window =3D=3D top)=0A=
      timer =3D pollDoScroll.defer();=0A=
  }=0A=
=0A=
  Event.observe(window, 'load', fireContentLoadedEvent);=0A=
})();=0A=
=0A=
Element.addMethods();=0A=
=0A=
/*------------------------------- DEPRECATED =
-------------------------------*/=0A=
=0A=
Hash.toQueryString =3D Object.toQueryString;=0A=
=0A=
var Toggle =3D { display: Element.toggle };=0A=
=0A=
Element.Methods.childOf =3D Element.Methods.descendantOf;=0A=
=0A=
var Insertion =3D {=0A=
  Before: function(element, content) {=0A=
    return Element.insert(element, {before:content});=0A=
  },=0A=
=0A=
  Top: function(element, content) {=0A=
    return Element.insert(element, {top:content});=0A=
  },=0A=
=0A=
  Bottom: function(element, content) {=0A=
    return Element.insert(element, {bottom:content});=0A=
  },=0A=
=0A=
  After: function(element, content) {=0A=
    return Element.insert(element, {after:content});=0A=
  }=0A=
};=0A=
=0A=
var $continue =3D new Error('"throw $continue" is deprecated, use =
"return" instead');=0A=
=0A=
var Position =3D {=0A=
  includeScrollOffsets: false,=0A=
=0A=
  prepare: function() {=0A=
    this.deltaX =3D  window.pageXOffset=0A=
                || document.documentElement.scrollLeft=0A=
                || document.body.scrollLeft=0A=
                || 0;=0A=
    this.deltaY =3D  window.pageYOffset=0A=
                || document.documentElement.scrollTop=0A=
                || document.body.scrollTop=0A=
                || 0;=0A=
  },=0A=
=0A=
  within: function(element, x, y) {=0A=
    if (this.includeScrollOffsets)=0A=
      return this.withinIncludingScrolloffsets(element, x, y);=0A=
    this.xcomp =3D x;=0A=
    this.ycomp =3D y;=0A=
    this.offset =3D Element.cumulativeOffset(element);=0A=
=0A=
    return (y >=3D this.offset[1] &&=0A=
            y <  this.offset[1] + element.offsetHeight &&=0A=
            x >=3D this.offset[0] &&=0A=
            x <  this.offset[0] + element.offsetWidth);=0A=
  },=0A=
=0A=
  withinIncludingScrolloffsets: function(element, x, y) {=0A=
    var offsetcache =3D Element.cumulativeScrollOffset(element);=0A=
=0A=
    this.xcomp =3D x + offsetcache[0] - this.deltaX;=0A=
    this.ycomp =3D y + offsetcache[1] - this.deltaY;=0A=
    this.offset =3D Element.cumulativeOffset(element);=0A=
=0A=
    return (this.ycomp >=3D this.offset[1] &&=0A=
            this.ycomp <  this.offset[1] + element.offsetHeight &&=0A=
            this.xcomp >=3D this.offset[0] &&=0A=
            this.xcomp <  this.offset[0] + element.offsetWidth);=0A=
  },=0A=
=0A=
  overlap: function(mode, element) {=0A=
    if (!mode) return 0;=0A=
    if (mode =3D=3D 'vertical')=0A=
      return ((this.offset[1] + element.offsetHeight) - this.ycomp) /=0A=
        element.offsetHeight;=0A=
    if (mode =3D=3D 'horizontal')=0A=
      return ((this.offset[0] + element.offsetWidth) - this.xcomp) /=0A=
        element.offsetWidth;=0A=
  },=0A=
=0A=
=0A=
  cumulativeOffset: Element.Methods.cumulativeOffset,=0A=
=0A=
  positionedOffset: Element.Methods.positionedOffset,=0A=
=0A=
  absolutize: function(element) {=0A=
    Position.prepare();=0A=
    return Element.absolutize(element);=0A=
  },=0A=
=0A=
  relativize: function(element) {=0A=
    Position.prepare();=0A=
    return Element.relativize(element);=0A=
  },=0A=
=0A=
  realOffset: Element.Methods.cumulativeScrollOffset,=0A=
=0A=
  offsetParent: Element.Methods.getOffsetParent,=0A=
=0A=
  page: Element.Methods.viewportOffset,=0A=
=0A=
  clone: function(source, target, options) {=0A=
    options =3D options || { };=0A=
    return Element.clonePosition(target, source, options);=0A=
  }=0A=
};=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
if (!document.getElementsByClassName) document.getElementsByClassName =
=3D function(instanceMethods){=0A=
  function iter(name) {=0A=
    return name.blank() ? null : "[contains(concat(' ', @class, ' '), ' =
" + name + " ')]";=0A=
  }=0A=
=0A=
  instanceMethods.getElementsByClassName =3D =
Prototype.BrowserFeatures.XPath ?=0A=
  function(element, className) {=0A=
    className =3D className.toString().strip();=0A=
    var cond =3D /\s/.test(className) ? $w(className).map(iter).join('') =
: iter(className);=0A=
    return cond ? document._getElementsByXPath('.//*' + cond, element) : =
[];=0A=
  } : function(element, className) {=0A=
    className =3D className.toString().strip();=0A=
    var elements =3D [], classNames =3D (/\s/.test(className) ? =
$w(className) : null);=0A=
    if (!classNames && !className) return elements;=0A=
=0A=
    var nodes =3D $(element).getElementsByTagName('*');=0A=
    className =3D ' ' + className + ' ';=0A=
=0A=
    for (var i =3D 0, child, cn; child =3D nodes[i]; i++) {=0A=
      if (child.className && (cn =3D ' ' + child.className + ' ') && =
(cn.include(className) ||=0A=
          (classNames && classNames.all(function(name) {=0A=
            return !name.toString().blank() && cn.include(' ' + name + ' =
');=0A=
          }))))=0A=
        elements.push(Element.extend(child));=0A=
    }=0A=
    return elements;=0A=
  };=0A=
=0A=
  return function(className, parentElement) {=0A=
    return $(parentElement || =
document.body).getElementsByClassName(className);=0A=
  };=0A=
}(Element.Methods);=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=
=0A=
Element.ClassNames =3D Class.create();=0A=
Element.ClassNames.prototype =3D {=0A=
  initialize: function(element) {=0A=
    this.element =3D $(element);=0A=
  },=0A=
=0A=
  _each: function(iterator) {=0A=
    this.element.className.split(/\s+/).select(function(name) {=0A=
      return name.length > 0;=0A=
    })._each(iterator);=0A=
  },=0A=
=0A=
  set: function(className) {=0A=
    this.element.className =3D className;=0A=
  },=0A=
=0A=
  add: function(classNameToAdd) {=0A=
    if (this.include(classNameToAdd)) return;=0A=
    this.set($A(this).concat(classNameToAdd).join(' '));=0A=
  },=0A=
=0A=
  remove: function(classNameToRemove) {=0A=
    if (!this.include(classNameToRemove)) return;=0A=
    this.set($A(this).without(classNameToRemove).join(' '));=0A=
  },=0A=
=0A=
  toString: function() {=0A=
    return $A(this).join(' ');=0A=
  }=0A=
};=0A=
=0A=
Object.extend(Element.ClassNames.prototype, Enumerable);=0A=
=0A=
/*-----------------------------------------------------------------------=
---*/=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/ojs/Object.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * Object.js,v 1.10 2003/04/23 09:29:14 szwoelf Exp=0A=
 *=0A=
 * The following functions form the Object JavaScript 1.2 environment.=0A=
 *=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: Object.js 157941 2010-08-20 09:50:09Z cgoess $=0A=
 */=0A=
=0A=
if ( typeof ojs !=3D "undefined" )=0A=
{=0A=
  var text =3D "Illegal State: double include of Object.js";=0A=
  alert(text);=0A=
  throw text;=0A=
}=0A=
=0A=
var ua$ =3D navigator.userAgent.toLowerCase();=0A=
var ua_isSafari$ =3D (ua$.indexOf("safari") >=3D 0);=0A=
var ua_isKonqueror$ =3D (ua$.indexOf("konqueror") >=3D 0);=0A=
var ua_isFireFox$ =3D (ua$.indexOf("firefox") >=3D 0);=0A=
var ua_isMicrosofInternetExplorer$ =3D (ua$.indexOf("msie") >=3D 0);=0A=
=0A=
LANG_OBJECTJS_REGEXP_WHITESPACESLINESTART =3D new RegExp("^ *", "g");=0A=
LANG_OBJECTJS_REGEXP_WHITESPACESLINEEND   =3D new RegExp(" *$", "g");=0A=
=0A=
/*=0A=
 * "zoom factor" - uncomment these lines when measuring memory leaks:=0A=
 *=0A=
var s =3D "1234567890";=0A=
var zoom =3D [];=0A=
for ( var i =3D 0; i < 18; ++i )=0A=
{=0A=
  zoom[zoom.length] =3D s =3D s + s;=0A=
}=0A=
//zoom =3D null;=0A=
*/=0A=
=0A=
/**=0A=
 * This function can be used to create instances of classes which are=0A=
 * not native in JavaScript (unlike Function, Object, Array,...).=0A=
 * It can be used instead of the JavaScript <code>new</code> operator.=0A=
 * =0A=
 * @param aClass: Function: the constructor function of the class to=0A=
 *   instantiate.  =0A=
 * =0A=
 * @deprecated since 2002-12-03.=0A=
 *   Reasons:=0A=
 *   <ul>=0A=
 *     <li>JavaScript 1.3 isn't required anymore. =0A=
 *     <li>JavaScript constructors seem to work quite well now ;-).=0A=
 *   </ul>=0A=
 */=0A=
function newInstanceOf ( aClass )=0A=
{=0A=
  // ... and if this something might be a constructor function of a=0A=
  // class=0A=
  if ( typeof (aClass) !=3D "function" )=0A=
  {=0A=
    // an exception should be thrown, but to use the function on =0A=
    // client and server side, returns only null=0A=
    return null;=0A=
  }=0A=
=0A=
  // create a new instance of the wished class using the new keyword=0A=
  // CAUTION: only 5 parameters are allowed in a constructor!=0A=
  var myObj;=0A=
  switch ( arguments.length - 1 )=0A=
  {=0A=
  case 0:=0A=
    myObj =3D new aClass ();=0A=
    break;=0A=
  case 1:=0A=
    myObj =3D new aClass ( arguments[1] );=0A=
    break;=0A=
  case 2:=0A=
    myObj =3D new aClass ( arguments[1], arguments[2] );=0A=
    break;=0A=
  case 3:=0A=
    myObj =3D new aClass ( arguments[1], arguments[2], arguments[3] );=0A=
    break;=0A=
  case 4:=0A=
    myObj =3D new aClass ( arguments[1], arguments[2], arguments[3],=0A=
                         arguments[4] );=0A=
    break;=0A=
  case 5:=0A=
    myObj =3D new aClass ( arguments[1], arguments[2], arguments[3],=0A=
                         arguments[4], arguments[5] );=0A=
    break;=0A=
  default:=0A=
    return null;=0A=
  }=0A=
  return myObj;=0A=
}=0A=
=0A=
/** =0A=
 * This function implements ECMA conform inheritance for JavaScript=0A=
 * classes. This inheritance covers all topics concerning=0A=
 * prototyping, such as: =0A=
 * <UL>=0A=
 *   <LI>access to prototyped members of the baseClass.</LI> =0A=
 *   <LI>It adds a <code>static_</code> object holding all static=0A=
 *       properties and methods to the derivedClass. Takes also care=0A=
 *       about retrieving static members of the super class by=0A=
 *       accessing these via the using the  derived Class.</LI>=0A=
 *   <LI>It adds a handle to the base Class (super_) to enable access=0A=
 *       to eventually overridden baseClassfunctions.</LI>=0A=
 * </UL>=0A=
 * =0A=
 * Invariant: We cannot assign the <code>super_</code> property to=0A=
 *   the <code>static_</code> or the prototype chain. The reason=0A=
 *   can be explained by the following example.=0A=
 * =0A=
 *   If one derives Class C from Class B and=0A=
 *                  Class B from Class A. Now he or she can=0A=
 *   instantiate an object o of Class C. Any method inherited from=0A=
 *   Class B called in the scope of object o will have Class B=0A=
 *   as <code>super</code> (because it was asigned to the prototype=0A=
 *   chain or the "static chain"). In fact the programmer will expect =0A=
 *   Class A in this case! </p>=0A=
 *   A possible solution: the super_ property will be assigned=0A=
 *   to the classes constructors and methods of super classes are=0A=
 *   called explicitly by method indirection. The following example=0A=
 *   shows this solution:=0A=
 * =0A=
 * <pre>=0A=
 * ClassB=0A=
 * {=0A=
 *   method aMethod ( ... )=0A=
 *   {=0A=
 *     // call super method ...=0A=
 *     this._indirectedmethod_ =3D ClassB.super_.aMethod;=0A=
 *     this._indirectedmethod_ ( ... );=0A=
 *     delete this._indirectedmethod_;=0A=
 *   }=0A=
 * }=0A=
 * </pre>=0A=
 *=0A=
 * Note: although this function and kind of class definition works=0A=
 * quite well it is recommended to use the class definition syntax=0A=
 * since object JavaScript 1.2.=0A=
 * =0A=
 * @since Object JavaScript 1.0=0A=
 * =0A=
 * @param derivedClass: Function: the constructor function of the=0A=
 *   class to derive=0A=
 * @param baseClass: Function: the constructor function of the base =
class =0A=
 */=0A=
function doInherit ( derivedClass, baseClass )=0A=
{=0A=
  if ( baseClass =3D=3D null )=0A=
  {=0A=
    if ( doInherit.base_ !=3D null )=0A=
      baseClass =3D doInherit.base_;=0A=
  }=0A=
  =0A=
  // Inheritance ... ?=0A=
  if ( baseClass !=3D null )=0A=
  {=0A=
    // ECMA Inheritance, nothing JavaScript specific used.=0A=
    // call the constructor with "__proto__" to give it a =0A=
    // chance to differ between calls for instantiation and =0A=
    // calls for inheritance (this one)=0A=
    derivedClass.prototype =3D new baseClass ( "__proto__" );=0A=
=0A=
    // "Repair" constructor (a JavaScript internally used property)=0A=
    derivedClass.prototype.constructor =3D derivedClass;=0A=
  =0A=
    // Linking back the Super Class:=0A=
    derivedClass.super_ =3D baseClass.prototype;=0A=
  }=0A=
  else=0A=
    derivedClass.prototype.constructor =3D derivedClass;=0A=
=0A=
  // Static part: always assign a default static_ object to a new class=0A=
  var static_constructor =3D function () {=0A=
    this.class_ =3D derivedClass;=0A=
  };=0A=
=0A=
  // Inherit the new static <b>OBJECT</b> from the=0A=
  // Baseclasses' static object (if existent).=0A=
  if ( baseClass !=3D null && baseClass.static_ !=3D null )=0A=
    static_constructor.prototype =3D baseClass.static_;=0A=
=0A=
  // Now construct the Static object (with the inheritance=0A=
  // defined above) and link it both to the derived class=0A=
  // AND to the prototype of this class!=0A=
  derivedClass.static_ =3D =0A=
    derivedClass.prototype.static_ =3D new static_constructor;=0A=
=0A=
  // now get the Class name ...=0A=
  if ( initPackage.lastPackage_ )=0A=
  {=0A=
    var cur_package =3D initPackage.packageList_ =
[initPackage.lastPackage_];=0A=
    var package_name =3D initPackage.lastPackage_ + ".";=0A=
    =0A=
    for ( var i in cur_package )=0A=
    {=0A=
      if ( cur_package [i] =3D=3D derivedClass )=0A=
      {=0A=
        derivedClass.prototype.static_.className_ =3D package_name + i;=0A=
        return derivedClass.prototype;=0A=
      }=0A=
    }=0A=
  }=0A=
=0A=
  // no Class name can be determined. In these cases we use=0A=
  // the "undefined" value.=0A=
  derivedClass.prototype.static_.className_ =3D "undefined";=0A=
  return derivedClass.prototype;=0A=
}=0A=
=0A=
/** =0A=
 * Initializes a <code>package</code> within the current scope.=0A=
 * The scope depends on the current environment e.g. the=0A=
 * browser JavaScript engine. <p>=0A=
 *=0A=
 * This implementation uses the browser's <code>window</code> object=0A=
 * as the default scope. <b>Note</b> that each Frame or Frameset has=0A=
 * its own window object and its own function definitions. Hence you=0A=
 * have to load classes and initialize packages in each window,=0A=
 * framesets and obviously all (i)frames where the class mechanism is=0A=
 * used.=0A=
 * =0A=
 * @param String: aPackageName: a string defining a package=0A=
 *   name with sub-packages e.g. "com.hw.util".=0A=
 * =0A=
 * @return Object: the package object that serves as an associative=0A=
 *   array for classes. =0A=
 */=0A=
function initPackage ( aPackageName )=0A=
{=0A=
  initPackage.lastPackage_ =3D aPackageName;=0A=
=0A=
  if ( initPackage.packageList_ [aPackageName] )=0A=
    return initPackage.packageList_ [aPackageName];=0A=
  =0A=
  var packages =3D aPackageName.split ( "." );=0A=
  var root_pkg_name =3D packages [0];=0A=
  var cur_package =3D window [root_pkg_name];=0A=
=0A=
  if ( !cur_package )=0A=
    cur_package =3D window [root_pkg_name] =3D {};=0A=
  initPackage.rootPackageList_ [root_pkg_name] =3D cur_package;=0A=
=0A=
  for ( var i =3D 1; i < packages.length; ++i )=0A=
  {=0A=
    if ( cur_package [ packages [i] ] =3D=3D null )=0A=
      cur_package [ packages [i] ] =3D {};=0A=
    cur_package =3D cur_package [ packages [i] ];=0A=
  }=0A=
  =0A=
  initPackage.packageList_ [aPackageName] =3D cur_package;=0A=
=0A=
  if (aPackageName.indexOf("com.hyperwave.") =3D=3D 0 || aPackageName =
=3D=3D "com.hyperwave") {=0A=
    window.hw =3D window.com.hyperwave;=0A=
    initPackage.rootPackageList_.hw =3D window.com.hyperwave;=0A=
  }=0A=
=0A=
  return cur_package;=0A=
}=0A=
=0A=
/** =0A=
 * Initialize the Packaging system and create the <code>ojs.object</code>=0A=
 * class.=0A=
 */=0A=
initPackage.packageList_ =3D {};=0A=
initPackage.rootPackageList_ =3D {};=0A=
initPackage.lastPackage_ =3D null;=0A=
=0A=
/**=0A=
 * Take care about initializing package "ojs" (in case that =
addTopToClasspath =0A=
 * was not used).=0A=
 */ =0A=
initPackage("ojs");=0A=
=0A=
  /** =0A=
   * Constructor for all JavaScript Objects. This constructor is =0A=
   * considered to be empty because any check for "__proto__" would=0A=
   * be senseless.=0A=
   */=0A=
  ojs.Object =3D function ()=0A=
  {=0A=
  };=0A=
  class$ =3D doInherit ( ojs.Object );=0A=
  =0A=
  /** =0A=
   * Returns true if a class is an instance of another class. The=0A=
   * other class might be given by a class object (strong) or a class=0A=
   * string (weak). Strong means, that the class is of this type and=0A=
   * the class is defined in the same scope. A weak check might result=0A=
   * in a result that is true even the class is defined in another=0A=
   * scope (or window).=0A=
   * =0A=
   * @signature (aClass:Function)=0A=
   * @signature (aClassName:string)=0A=
   * =0A=
   * @param aClass a class defined by its constructor function like=0A=
   *   <code>ojs.Object</code>.=0A=
   * @param aClassName a class defined by its class name like=0A=
   * <code>&quot;ojs.Object&quot;</code>.=0A=
   */=0A=
  class$.instanceOf =3D function ( aClass )=0A=
  {=0A=
    if ( typeof aClass =3D=3D "function" )=0A=
    {=0A=
      var class_iter =3D this.constructor;=0A=
      while ( class_iter !=3D null )=0A=
      {=0A=
        if ( class_iter.static_ =3D=3D aClass.static_ )=0A=
          return true;=0A=
        class_iter =3D class_iter.super_;=0A=
      }=0A=
    }=0A=
    else if ( typeof aClass =3D=3D "string" )=0A=
    {=0A=
      var class_iter =3D this.constructor;=0A=
      while ( class_iter !=3D null )=0A=
      {=0A=
        if ( class_iter.static_.getClassName () =3D=3D aClass )=0A=
          return true;=0A=
        class_iter =3D class_iter.super_;=0A=
      }=0A=
    }=0A=
    =0A=
    return false;=0A=
  };=0A=
  =0A=
  /** =0A=
   * Returns a function that redirects to the given method=0A=
   * in the specified scope. This can be used in event handlers or other=0A=
   * techniqeus that require callback functions.=0A=
   *=0A=
   * @param aScope: Object: the object that provides the scope=0A=
   * @param aMethod: Function: the function that should be called in the =0A=
   * given scope=0A=
   *  =0A=
   * @return Function: a function that redirects to the given method=0A=
   * in the specified scope=0A=
   */=0A=
  class$.static_.getMethodRedirector =3D function ( aScope, aMethod )=0A=
  {=0A=
    return function()=0A=
    {=0A=
      return aMethod.apply(aScope, arguments);=0A=
    };=0A=
  };=0A=
=0A=
=0A=
  class$.static_.__cloneableTypes__ =3D {addKeyValue: function (key, =
value) {=0A=
    this[key] =3D value;=0A=
  }};=0A=
  class$.static_.__cloneableTypes__.addKeyValue("undefined", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("null", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("string", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("number", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("boolean", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("array", 1);=0A=
  class$.static_.__cloneableTypes__.addKeyValue("object", 1);=0A=
  delete class$.static_.__cloneableTypes__.addKeyValue;=0A=
  /** =0A=
   * Returns a clone of the object. Useful to avoid cross-frame =
references.=0A=
   * Besides primitive objects (strings, numbers, booleans=0A=
   * and linear arrays of such types) also "real" objects are supported. =
If such and=0A=
   * object is given, first it is checked for the existance of a =
<code>clone</code>=0A=
   * method which is called if it found. Otherwise this method is called =
recursively=0A=
   * for all properties of the object (which makes it obvious that only =
own data structures=0A=
   * should be cloned, not references to DOM objects or a window).=0A=
   * =0A=
   * @param anObject: Object: the object that should be cloned=0A=
   * @param aWindowScope: Object | void: the browser window object that =
defines the target frame/window=0A=
   *   where the clone should be created (default is <code>window</code>)=0A=
   *=0A=
   * @return Object: a clone of the given object=0A=
   */=0A=
  class$.static_.clone =3D function ( anObject, aWindowScope )=0A=
  {=0A=
    var scope =3D aWindowScope || window;=0A=
    var type =3D class$.static_.getType(anObject);=0A=
    switch ( type )=0A=
    {=0A=
      case "undefined": =0A=
        return void(0);=0A=
      case "null": =0A=
        return null;=0A=
      case "string": =0A=
        return scope.String(anObject);=0A=
      case "number": =0A=
        return scope.Number(anObject);=0A=
      case "boolean": =0A=
        return scope.Boolean(anObject);=0A=
      case "array": =0A=
        var a =3D scope.newInstanceOf(scope.Array);=0A=
        for ( var i =3D 0; i < anObject.length; ++i )=0A=
          a[i] =3D class$.static_.clone(anObject[i], scope);=0A=
        return a;=0A=
      case "object":=0A=
        if ( anObject instanceof Date )=0A=
          return anObject.clone(scope);=0A=
        if ( anObject.clone && (class$.static_.getType(anObject.clone) =
=3D=3D "function") )=0A=
          return anObject.clone(scope);=0A=
        var o =3D scope.newInstanceOf(scope.Object);=0A=
        for ( var i in anObject )=0A=
        {=0A=
          if ( anObject.hasOwnProperty && !anObject.hasOwnProperty(i) ) =
// the first check is for Safari?!=0A=
            continue;=0A=
          if ( =
this.__cloneableTypes__[class$.static_.getType(anObject[i])] )=0A=
            o[i] =3D class$.static_.clone(anObject[i], scope);=0A=
        }=0A=
        return o;=0A=
      default: throw "Unsupported object type for clone: " + type;=0A=
    }=0A=
  };=0A=
=0A=
  /** =0A=
   * Returns the full qualified class name of the class.=0A=
   * =0A=
   * @return string: a string containing the class name.=0A=
   */=0A=
  class$.static_.getClassName =3D function ()=0A=
  {=0A=
    return this.className_;=0A=
  };=0A=
=0A=
  /**=0A=
   * Returns the type of the given object. It can be used if =
<code>typeof</code> is not exact=0A=
   * enough. The following return strings are supported (they should be =
self explanatory):=0A=
   * <ul>=0A=
   *   <li>undefined</li>=0A=
   *   <li>null</li>=0A=
   *   <li>string</li>=0A=
   *   <li>number</li>=0A=
   *   <li>boolean</li>=0A=
   *   <li>array</li>=0A=
   *   <li>function</li>=0A=
   *   <li>object (for everything else)</li>=0A=
   * </ul>=0A=
   * =0A=
   * @param anObject: Object: the object for determining its type=0A=
   =0A=
   * @return String: the type of anObject=0A=
   */=0A=
  class$.static_.getType =3D function ( anObject ) =0A=
  {=0A=
    var index, id;=0A=
    var type_of_result =3D typeof anObject; =0A=
=0A=
    if (type_of_result =3D=3D "undefined")=0A=
      return type_of_result;=0A=
    if (anObject =3D=3D null)=0A=
      return "null";=0A=
    if ((type_of_result =3D=3D "object" || anObject.constructor =3D=3D =
"[function]") || (anObject.constructor =3D=3D "(Internal function)")) =0A=
    {=0A=
      // Konqueror only returns "[function]" whereas Safari returns =
"(Internal function)"=0A=
      var ctor_str =3D (anObject.constructor + "").toLowerCase();=0A=
      var type_str =3D null;=0A=
=0A=
      function doIt ( theReference, theType )=0A=
      {=0A=
        if ( anObject.constructor =3D=3D=3D theReference.constructor ||  =
       // rest=0A=
             ctor_str.indexOf("function " + theType) >=3D 0 ) // IE with =
addTopToClasspath=0A=
        {=0A=
          type_str =3D theType;=0A=
          return true;=0A=
        }=0A=
        return false;=0A=
      }=0A=
      =0A=
      if ( doIt ( [], "array" ) )=0A=
        return type_str;=0A=
      else if ( doIt ( "", "string" ) )=0A=
        return type_str;=0A=
      else if ( doIt ( true, "boolean" ) )=0A=
        return type_str;=0A=
      else if ( doIt ( new Number(1), "number" ) )=0A=
        return type_str;=0A=
=0A=
//      if (anObject.constructor =3D=3D=3D new Function().constructor ||=0A=
//          (document.all && (typeof anObject.constructor =3D=3D =
"undefined" || typeof anObject.constructor =3D=3D "object") && (anObject =
+ "").indexOf("function(") >=3D 0)) // IE=0A=
      if ( (typeof anObject.call !=3D "undefined") && (typeof =
anObject.apply !=3D "undefined") )=0A=
        return "function";=0A=
      else=0A=
        return "object";=0A=
    }=0A=
    else=0A=
    {=0A=
      return type_of_result;=0A=
    }=0A=
  };=0A=
  doInherit.base_ =3D ojs.Object;=0A=
   =0A=
/** =0A=
 * Loads a class or a package into the current scope. The function=0A=
 * was prepared for dynamic class loading and is deprecated now.=0A=
 * =0A=
 * @param String: aClassName: a string defining a class name=0A=
 *   or even a whole package.=0A=
 * =0A=
 * @deprecated since Object JavaScript 1.2.=0A=
 *  Reasons:=0A=
 *  <ul>=0A=
 *    <li>=0A=
 *      Dynamic class loading is considered to be too complex because=0A=
 *      on the server side the constraints will provide a JavaScript=0A=
 *      hell even for very experienced programmers. On the client side=0A=
 *      class loading can only be done synchronously which is in fact=0A=
 *      only a technique that can be done during the loading of a page=0A=
 *      or by applets. During page loading we cannot use constructors=0A=
 *      or constructor functions because an additional (dynamically=0A=
 *      written) &lt;script src...&gt; will only be valid in the next=0A=
 *      script block. Applets could be used synchronously but only=0A=
 *      after applet initialization. Hence we should keep our hands=0A=
 *      from such techniques. If ever we could re-use the "loadClass"=0A=
 *      mechanism to do this.=0A=
 *  </ul>=0A=
 * @see #addTopToClasspath()=0A=
 */=0A=
function loadClass ( aClassName )=0A=
{=0A=
}=0A=
=0A=
/** =0A=
 * This function implements ECMA conform inheritance for JavaScript=0A=
 * classes like <code>doInherit</code> does. The underlying method is=0A=
 * a little bit different from doInherit because we write a class=0A=
 * within a function body. This body looks like:=0A=
 *=0A=
 * <pre>=0A=
 * function xyz ( class$ )=0A=
 * {=0A=
 *   class$.method =3D function ( ... )=0A=
 *   {=0A=
 *   }=0A=
 * }=0A=
 * </pre>=0A=
 *=0A=
 * This function is called <b>class definition function</b>. It is=0A=
 * associated with a class name by means of=0A=
 * <code>defineClass</code>. Here all necessary constructs for a=0A=
 * <i>real</i> ECMA conform inheritance are produced and the=0A=
 * constructor (that is either explicitly defined with a method called=0A=
 * constructor or that is otherwise implicitly constructed) is=0A=
 * accociated with the package and the class name.</p>=0A=
 * =0A=
 * <p>This implementation relies on the internals of <code>doInherit=0A=
 * </code> because the needs of this function are somewhat different.=0A=
 * <code>doInherit</code> implies that it has a constructor function=0A=
 * and returns the class prototype. <code>defineClass</code> implies=0A=
 * that the static object is inherited correctly and no class=0A=
 * constructor exists. Hence we have to copy the internals of =0A=
 * <code>doInherit</code> Another dependency is the <code>initPackage=0A=
 * </code> function - this function is used to initialize the=0A=
 * classes' packages.=0A=
 *=0A=
 * @signature (String aClassName, Function theDefinition)=0A=
 * @signature (String aClassName, String baseClass, Function=0A=
 *   theDefinition)=0A=
 * @signature (String aClassName, Function baseClass, Function=0A=
 *   theDefinition)=0A=
 *=0A=
 * @param aClassName a string defining the whole qualified class name=0A=
 * @param theDefinition the definition function of the class to be=0A=
 *   defined=0A=
 * @param baseClass the super class of the new class=0A=
 * =0A=
 * @since Object JavaScript 1.2=0A=
 */=0A=
function defineClass ( aClassName, arg2, arg3 )=0A=
{=0A=
  if ( defineClass.classCache_ [aClassName] )=0A=
  {=0A=
    // class already defined=0A=
    var text =3D "Illegal State: class " + aClassName + " already =
defined.\n" +=0A=
               "Further double includes will be ignored.";=0A=
    if ( !defineClass.ignoreClassDuplicates_ )=0A=
    {=0A=
      defineClass.ignoreClassDuplicates_ =3D true;=0A=
      alert(text);=0A=
      throw text;=0A=
    }=0A=
    // in case double includes should be ignored silently return=0A=
    return;=0A=
  }=0A=
=0A=
  // Rename unnamed parameters =0A=
  var baseClass;=0A=
  var theDefinition =3D arg2;=0A=
  if ( arg3 )=0A=
  {=0A=
    theDefinition =3D arg3;=0A=
    baseClass =3D arg2;=0A=
  }=0A=
=0A=
  // Separate Class and Package Name ...=0A=
  var sep =3D /^((.*)\.)?([^.]+)$/;=0A=
  var arr =3D sep.exec ( aClassName );=0A=
  var package_name =3D arr [2];=0A=
  var unqualified_class_name =3D arr [3];=0A=
  var class_package;=0A=
=0A=
  if ( package_name )=0A=
    class_package =3D initPackage ( package_name );=0A=
  else {=0A=
    initPackage("__default__");=0A=
    class_package =3D window;=0A=
  }=0A=
=0A=
  // get the *real* baseClass object. But be aware of classes that=0A=
  // have not been created by defineClass ...=0A=
  if ( baseClass =3D=3D null )=0A=
    baseClass =3D doInherit.base_;=0A=
  else=0A=
    if ( typeof baseClass =3D=3D "string" )=0A=
    {=0A=
      var desired =3D defineClass.classCache_ [baseClass];=0A=
      if ( desired )=0A=
        baseClass =3D desired;=0A=
      else=0A=
        try=0A=
        {=0A=
          var class_function;=0A=
          class_function =3D eval ( baseClass );=0A=
//          if ( typeof class_function !=3D "function" )=0A=
//            class_function =3D top.eval ( baseClass );=0A=
          if ( typeof class_function !=3D "function" )=0A=
            throw baseClass + " is not a function";=0A=
          baseClass =3D class_function;=0A=
        }=0A=
        catch ( e )=0A=
        {=0A=
          var text =3D "'" + baseClass + "' is not a class (" + e + ")";=0A=
          alert(text);=0A=
          throw text;=0A=
        }=0A=
    }=0A=
//else if ( typeof baseClass =3D=3D "undefined" ) =0A=
//  baseClass =3D top.eval(baseClass.static_.getClassName());=0A=
  =0A=
  // Step 1: Static - always assign a default static_ object to a new=0A=
  // class.=0A=
  var static_constructor =3D function() {};=0A=
  // [The former technique of using the Function constructor does not =
work with Konqueror/Safari.]=0A=
=0A=
  var base_static_onclassload, base_static_onfinalization;=0A=
=0A=
  // Inherit the new static <b>OBJECT</b> from the=0A=
  // Baseclasses' static object (if existent).=0A=
  if ( baseClass !=3D null && baseClass.static_ !=3D null )=0A=
  {=0A=
    static_constructor.prototype =3D baseClass.static_;=0A=
    base_static_onclassload =3D baseClass.static_.onClassLoad;=0A=
    base_static_onfinalization =3D baseClass.static_.onFinalization;=0A=
  }=0A=
=0A=
  // ECMA Inheritance, nothing JavaScript specific used.=0A=
  // call the constructor with "__proto__" to give it a =0A=
  // chance to differ between calls for instantiation and =0A=
  // calls for inheritance (this one)=0A=
  var class_prototype;=0A=
  if ( baseClass !=3D null )=0A=
    class_prototype =3D new baseClass ( "__proto__" );=0A=
  else=0A=
    class_prototype =3D {};=0A=
=0A=
  // Step 2: Initialize the "class" object and call the class=0A=
  // definition function.=0A=
  class_prototype.super_ =3D baseClass.prototype;=0A=
  class_prototype.superConstructor_ =3D baseClass;=0A=
  class_prototype.static_ =3D new static_constructor;=0A=
  class_prototype.static_.className_ =3D aClassName;=0A=
  var mark_constructor =3D class_prototype.constructor;=0A=
=0A=
  theDefinition ( class_prototype );=0A=
=0A=
  // Step 3: get/make the constructor (if any) and "wire" the prototype=0A=
  // chain.=0A=
  if ( class_prototype.constructor =3D=3D mark_constructor )=0A=
    class_prototype.constructor =3D =0A=
      function () =0A=
      { =0A=
        if (baseClass)=0A=
          baseClass.apply (this, arguments);=0A=
      };=0A=
=0A=
  var derived_class;=0A=
  defineClass.classCache_ [aClassName]=0A=
    =3D class_package [unqualified_class_name]=0A=
    =3D derived_class =0A=
      =3D class_prototype.constructor;=0A=
  derived_class.prototype =3D class_prototype;=0A=
=0A=
  if ( !package_name ) {=0A=
    =
initPackage.packageList_["__default__"][unqualified_class_name]=3Dderived=
_class;=0A=
  }=0A=
=0A=
=0A=
  // Step 4: Link the static object both to the derived class=0A=
  // AND to the prototype of this class!=0A=
  derived_class.static_ =3D =0A=
    derived_class.prototype.static_ =3D class_prototype.static_;=0A=
  derived_class.super_ =3D baseClass.prototype;=0A=
=0A=
  // Step 5: Call the static_.onClassLoad method (if it exists)=0A=
  if ( class_prototype.static_.onClassLoad !=3D base_static_onclassload )=0A=
    class_prototype.static_.onClassLoad ();=0A=
  =0A=
  // Step 6: register the static finalizer method (if it exists)=0A=
  if ( class_prototype.static_.onFinalization !=3D =
base_static_onfinalization )=0A=
    defineClass.finalizerList_[defineClass.finalizerList_.length] =3D =0A=
      { function_: class_prototype.static_.onFinalization, scope_: =
class_prototype.static_ };=0A=
      =0A=
  class_package =3D null;=0A=
}=0A=
defineClass.classCache_ =3D {};=0A=
defineClass.finalizerList_ =3D [];=0A=
defineClass.ignoreClassDuplicates_ =3D true;=0A=
=0A=
//--------------------------------------------------------------------=0A=
//                   Class Finalization & Logging=0A=
//--------------------------------------------------------------------=0A=
=0A=
defineClass.doLog =3D function ( aText )=0A=
{=0A=
  if ( typeof top.debug_ !=3D "undefined" )=0A=
  {=0A=
    top.debug_.debug ( aText ); // change level to info or whatever=0A=
  }=0A=
};=0A=
=0A=
// Internal window load handler. Necessary for IE to be able to "move" =
the unload handler=0A=
// from "onbeforeunload" to "onunload". (The beforeunload event is =
triggered even if the user=0A=
// closes the window before the load event has been triggered, but =
causes problems in IE 6 SP2=0A=
// with content disposition.)=0A=
defineClass.loadHandler =3D function( anEvent )=0A=
{=0A=
  defineClass.doLog ( "Start of loadHandler(), window:" + window.name );=0A=
=0A=
  // dispatch the uda load event via the uda window instance=0A=
  try=0A=
  {=0A=
    if (com.hyperwave.uda && com.hyperwave.uda.core && =
com.hyperwave.uda.core.Window) {=0A=
      var staticUdaWindow_ =3D com.hyperwave.uda.core.Window.static_;=0A=
    }=0A=
    else {=0A=
      var staticUdaWindow_ =3D null;=0A=
    }=0A=
  }=0A=
  catch ( e )=0A=
  {=0A=
    // no classes, no uda window=0A=
    defineClass.doLog ( "Load event could not be dispatched because UDA =
not loaded" );=0A=
  }=0A=
  if ( staticUdaWindow_ )=0A=
  {=0A=
    staticUdaWindow_.dispatchLoadEvent(window, anEvent ? anEvent : =
window.event);=0A=
    defineClass.doLog ( "Load event dispatched successfully" );=0A=
  }=0A=
  =0A=
  if ( window.detachEvent ) // browser dependency - only in IE we need =
to change the internal unload handler=0A=
  {=0A=
    window.attachEvent("onunload", defineClass.unloadHandler);=0A=
    window.detachEvent("onbeforeunload", defineClass.unloadHandler);=0A=
    defineClass.doLog ( "changed internal event from beforeunlod to =
unload" );=0A=
  }=0A=
  defineClass.doLog ( "End of loadHandler(), window:" + window.name );=0A=
};=0A=
=0A=
//Internal window unload handler. Necessary to be able to include the =
finalizer mechanism.=0A=
defineClass.unloadHandler =3D function( anEvent )=0A=
{=0A=
  defineClass.doLog ( "Start of unloadHandler(), window:" + window.name =
);=0A=
=0A=
  // dispatch the uda unload event via the uda window instance=0A=
  try=0A=
  {=0A=
    if (com.hyperwave.uda && com.hyperwave.uda.core && =
com.hyperwave.uda.core.Window) {=0A=
      var staticUdaWindow_ =3D com.hyperwave.uda.core.Window.static_;=0A=
    }=0A=
    else {=0A=
      var staticUdaWindow_ =3D null;=0A=
    }    =0A=
  }=0A=
  catch ( e )=0A=
  {=0A=
    // no classes, no uda window=0A=
    defineClass.doLog ( "Unload event could not be dispatched because =
UDA not loaded" );=0A=
  }=0A=
  if ( staticUdaWindow_ )=0A=
  {=0A=
    staticUdaWindow_.dispatchUnloadEvent(window, anEvent ? anEvent : =
window.event);=0A=
    defineClass.doLog ( "Unload event dispatched successfully" );=0A=
  }=0A=
  =0A=
  defineClass.finalize(window);=0A=
  if ( window.detachEvent )=0A=
    window.detachEvent("onbeforeunload", defineClass.unloadHandler);=0A=
  else if ( window.removeEventListener )=0A=
    window.removeEventListener("unload", defineClass.unloadHandler, =
false);=0A=
  else=0A=
    window["onunload"] =3D null;=0A=
=0A=
  if ( window.CollectGarbage )=0A=
    window.CollectGarbage ();    =0A=
  defineClass.doLog ( "End of unloadHandler(), window:" + window.name );=0A=
};=0A=
=0A=
// The finalizer method.=0A=
defineClass.finalize =3D function( aWindow )=0A=
{=0A=
  defineClass.doLog ( "Start finalize(), window:" + window.name + ", =
aWindow: " + aWindow.name );=0A=
=0A=
  // call all registered <code>static_.onFinalization</code> methods=0A=
  for ( var i =3D 0; i < defineClass.finalizerList_.length; ++i )=0A=
  {=0A=
    try=0A=
    {=0A=
      defineClass.doLog ( "Finalize Class:" + =
defineClass.finalizerList_[i].scope_.getClassName() );=0A=
      =
defineClass.finalizerList_[i].function_.call(defineClass.finalizerList_[i=
].scope_, aWindow);=0A=
    }=0A=
    catch ( e )=0A=
    {=0A=
      defineClass.doLog ( "Error during finalization, Class:" + =
defineClass.finalizerList_[i].scope_.getClassName() );=0A=
    }=0A=
  }=0A=
    =0A=
  // if we are within the frameset with addTopToClasspath also notify top=0A=
  if ( window !=3D top )=0A=
  {=0A=
    if ( top.defineClass )=0A=
      top.defineClass.finalize ( window );=0A=
    registry$._registry =3D [];=0A=
  }=0A=
  else if ( window =3D=3D aWindow && window =3D=3D top )=0A=
    registry$._registry =3D [];=0A=
  defineClass.doLog ( "End finalize(), window:" + window.name + ", =
aWindow: " + aWindow.name );=0A=
};=0A=
=0A=
// Add the internal load and unload event handler:=0A=
if ( window.attachEvent )  //# browser dependency IE=0A=
{=0A=
  window.attachEvent("onload", defineClass.loadHandler);=0A=
  window.attachEvent("onbeforeunload", defineClass.unloadHandler);=0A=
}=0A=
else if ( window.addEventListener && !(ua_isSafari$ || ua_isKonqueror$)) =
 //# browser dependency W3C=0A=
{=0A=
  window.addEventListener("load", defineClass.loadHandler, false);=0A=
  window.addEventListener("unload", defineClass.unloadHandler, false);=0A=
}=0A=
else //# browser dependency Konqueror compatible=0A=
{=0A=
  window.onload =3D defineClass.loadHandler;=0A=
  window.onunload =3D defineClass.unloadHandler;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
//                   Window Close Overloading=0A=
//--------------------------------------------------------------------=0A=
if ( window.CollectGarbage )  // online necessary in IE (and dangerous =
in Mozilla)=0A=
{=0A=
  window.close =3D function ()=0A=
  {=0A=
    closeChecker.close_ =3D true;=0A=
  };=0A=
  =0A=
  function closeChecker ()=0A=
  {=0A=
    if ( closeChecker.close_ )=0A=
    {=0A=
      defineClass.doLog ( "Triggered closeChecker(), window:" + =
window.name );=0A=
      clearInterval ( closeChecker.id_ );=0A=
  =0A=
      document.open ();=0A=
      document.writeln ( "<script>window.close();<\/script>" );=0A=
      document.close ();=0A=
      =0A=
      defineClass.doLog ( "End closeChecker, window:" + window.name );=0A=
    }=0A=
  }=0A=
  =0A=
  closeChecker.id_ =3D setInterval ( closeChecker, 250 );=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
//                        Unique ID Generator=0A=
//--------------------------------------------------------------------=0A=
function getUniqueId()=0A=
{=0A=
  if ( window !=3D top && top.getUniqueId )=0A=
    return top.getUniqueId();=0A=
  else=0A=
    return getUniqueId._uniqueIdCounter$++;=0A=
}=0A=
getUniqueId._uniqueIdCounter$ =3D new Date().valueOf();=0A=
=0A=
//--------------------------------------------------------------------=0A=
//                       Global Object Registry=0A=
//--------------------------------------------------------------------=0A=
function registry$()=0A=
{=0A=
}=0A=
registry$._registry =3D [];=0A=
=0A=
/**=0A=
 * Puts an object into the registry. This object is associated with a =
browser window.=0A=
 * The method returns the unique identifier that can be used in =
<code>registry$.get</code>.=0A=
 * The registry is distributed over the frames of a frameset in a way =
that each frame holds=0A=
 * the objects that are associated with this frame.<p>=0A=
 * Mind that if an object has already been put into the registry it will =
be contained twice=0A=
 * which should be avoided (but due to performance issues there is no =
lookup before adding it)!=0A=
 *=0A=
 * @param anObject: object: an object that should be stored in the =
registry and associated with=0A=
 *   the returned id=0A=
 * @param aWindow: object | void: an optional argument that defines the =
window where the object resides,=0A=
 *   the default is the window where Object.js is loaded=0A=
 *=0A=
 * @return int: a unique identifier for the registered object=0A=
 */=0A=
registry$.put =3D function(anObject, aWindow)=0A=
{=0A=
  var win =3D aWindow || window;=0A=
  if ( (win !=3D window) && win.registry$ )=0A=
    return win.registry$.put(anObject, win);=0A=
  else =0A=
  {=0A=
    var id =3D getUniqueId();=0A=
    registry$._registry[id] =3D anObject;=0A=
    return id;=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * Returns the object registered with the given identifier or =
<code>null</code> if none is found.=0A=
 * The identifier should be obtained when registering via =
<code>registry$.put</code>.<br>=0A=
 * This implementation first looks for an entry in the local registry =
and if none is found it starts=0A=
 * with the lookup in the top frame, which searches all its subframes.=0A=
 *=0A=
 * @param anId: int: a unique identifier that was returned by =
<code>registry$.put</code>=0A=
 *=0A=
 * @return Object: the object registered with the given identifier or =
<code>null</code>=0A=
 *   if none is found=0A=
 */=0A=
registry$.get =3D function(anId)=0A=
{=0A=
  if ( registry$._registry[anId] )      //1st, search in local frame=0A=
    return registry$._registry[anId];=0A=
  else if ( top.registry$ )             //2nd, search via top registry =
(if there is one)=0A=
    return top.registry$._get(anId);=0A=
  else                                  //3rd, search in sub frames =
(very unlikely)=0A=
    return registry$._get(anId);=0A=
};=0A=
=0A=
/**=0A=
 * Helper method that returns the object registered with the given =
identifier or <code>null</code> if none is found.=0A=
 * The identifier should be obtained when registering via =
<code>registry$.put</code>.<br>=0A=
 * This implementation first looks for an entry in the local registry =
and if none is found it starts=0A=
 * with the lookup in all its subframes (even recursive in those that =
did not load Object.js).=0A=
 *=0A=
 * @param anId: int: a unique identifier that was returned by =
<code>registry$.put</code>=0A=
 * @param aFrame: Object: an optional frame reference that is used =
internally=0A=
 *=0A=
 * @return Object: the object registered with the given identifier or =
<code>null</code>=0A=
 *   if none is found=0A=
 */=0A=
registry$._get =3D function(anId, aFrame)=0A=
{=0A=
  var aFrame =3D aFrame || window;=0A=
  =0A=
  if ( registry$._registry[anId] )=0A=
    return registry$._registry[anId];=0A=
  else if ( aFrame.frames && (aFrame.frames.length > 0) )=0A=
  {=0A=
    // search in all frames:=0A=
    for ( var i =3D 0; i < aFrame.frames.length; ++i )=0A=
    {=0A=
      if ( aFrame.frames[i].registry$ && =
aFrame.frames[i].registry$._registry )=0A=
      {=0A=
        var obj =3D aFrame.frames[i].registry$._get(anId);=0A=
        if ( obj )=0A=
          return obj;=0A=
      }=0A=
      else=0A=
      {=0A=
        var obj =3D registry$._get(anId, aFrame.frames[i]);=0A=
        if ( obj )=0A=
          return obj;=0A=
      }=0A=
    }=0A=
    return null;=0A=
  }=0A=
  return null;=0A=
};=0A=
=0A=
/**=0A=
 * Removes the object that was registered with the given identifier from =
the registry. =0A=
 * If there is no such object, the registry is not touched. If such an =
object exists=0A=
 * it is returned (otherwise <code>null</code> is returned).=0A=
 *=0A=
 * @param anId: int: a unique identifier that was returned by =
<code>registry$.put</code>=0A=
 *=0A=
 * @return Object: the object registered with the given identifier that =
has been removed =0A=
 *   or <code>null</code> if none is found=0A=
 */=0A=
registry$.remove =3D function(anId)=0A=
{=0A=
  if ( top.registry$ )=0A=
    return top.registry$._remove(anId);=0A=
  else=0A=
    return registry$._remove(anId); =0A=
};=0A=
 =0A=
/**=0A=
 * Helper method that removes the object that was registered with the =
given identifier =0A=
 * from the registry. If there is no such object, the registry is not =
touched. If such an object exists=0A=
 * it is returned (otherwise <code>null</code> is returned).=0A=
 *=0A=
 * @param anId: int: a unique identifier that was returned by =
<code>registry$.put</code>=0A=
 * @param aFrame: Object: an optional frame reference that is used =
internally=0A=
 *=0A=
 * @return Object: the object registered with the given identifier that =
has been removed =0A=
 *   or <code>null</code> if none is found=0A=
 */=0A=
registry$._remove =3D function(anId, aFrame)=0A=
{=0A=
  var aFrame =3D aFrame || window;=0A=
   =0A=
  if ( registry$._registry[anId] )=0A=
  {=0A=
    var obj =3D registry$._registry[anId];=0A=
    delete registry$._registry[anId];=0A=
    return obj;=0A=
  }=0A=
  else if ( aFrame.frames && aFrame.frames.length > 0 )=0A=
  {=0A=
    // search in all frames:=0A=
    for ( var i =3D 0; i < aFrame.frames.length; ++i )=0A=
    {=0A=
      if ( aFrame.frames[i].registry$ && =
aFrame.frames[i].registry$._registry )=0A=
      {=0A=
        var obj =3D aFrame.frames[i].registry$._remove(anId);=0A=
        if ( obj )=0A=
          return obj;=0A=
      }=0A=
      else=0A=
        return registry$._remove(anId, aFrame.frames[i]);=0A=
    }=0A=
    return null;=0A=
  }=0A=
};=0A=
 =0A=
//--------------------------------------------------------------------=0A=
//                   HAF Compatibility Library=0A=
//--------------------------------------------------------------------=0A=
// The following functions are used to extend the default behavior=0A=
// of the JavaScript Engine. These are mostly encoders and decoders=0A=
// for UTF8 and escaped UTF8.=0A=
=0A=
// IMPORTANT:=0A=
// Note that these functions are to be synched in ojs.js, ojs1.js=0A=
// and within the Clientlib (Object.js).=0A=
=0A=
// Global variable that is true if lambda expressions are=0A=
// supoorted.=0A=
=0A=
=0A=
/**=0A=
 * Encodes a character string (that exists of UCS2 characters) to=0A=
 * a character string that is UTF8 encoded. The characters of the=0A=
 * source string are transcoded to their one, two or three "byte"=0A=
 * representation in UTF8. As a consequence the final string contains=0A=
 * only characters with codes between 0 and 255.<p>=0A=
 *=0A=
 * For example: the German umlaut &?uml; (small "o" with quotes) has=0A=
 *   the UCS2 (Unicode) character code 246. Constructing a string=0A=
 *   with this character can be done by=0A=
 *     <code>String.fromCharCode (246)</code>.=0A=
 *   If this string is converted with this function this character=0A=
 *   is transcoded to its 2-byte representation in UTF-8 (195, 182).=0A=
 *   The resulting string will contain 2 characters with the character=0A=
 *   codes above.=0A=
 *=0A=
 * This implementation uses two strategies:=0A=
 * <ul>=0A=
 *   <li>For IS6.2 and lower it uses JavaScript Lambda Expressions to get=0A=
 *     better performance for long strings (in comparision to normal=0A=
 *     string operations).=0A=
 *   <li>For DANTE+ the built in method "fromEncoding" (C++) is used=0A=
 *     to get another boost (approx. 30 times faster).=0A=
 * </ul>=0A=
 *=0A=
 * @param theText: string: The text that has to be transcoded to=0A=
 *   UTF8.=0A=
 * @return string: the converted string.=0A=
 */=0A=
encodeUtf8 =3D function ( theText )=0A=
{=0A=
  return theText.replace ( /(.)|(\s)/g, encodeUtf8.lambdaEncode );=0A=
};=0A=
=0A=
// Internal Lambda Funtion for encodeUTF8. This Lambda function=0A=
// matches any character and translates the character to one=0A=
// two or three byte representations concerning to the UTF8=0A=
// algorithm. Note that this function must be kept in sync=0A=
// with the regular expression of the caller.=0A=
encodeUtf8.lambdaEncode =3D function ( c1 )=0A=
{=0A=
  var c =3D c1.charCodeAt(0);=0A=
=0A=
  // alle Zeichen von 0-127 =3D> 1byte=0A=
  if (c < 128)=0A=
    return c1;=0A=
=0A=
  // alle Zeichen von 127 bis 2047 =3D> 2byte=0A=
  if (c < 2048)=0A=
    return ( String.fromCharCode((c >> 6) | 192)=0A=
             + String.fromCharCode((c & 63) | 128) );=0A=
=0A=
  // alle Zeichen von 2048 bis 66536 =3D> 3byte=0A=
  return ( String.fromCharCode((c >> 12) | 224)=0A=
           + String.fromCharCode(((c >> 6) & 63) | 128)=0A=
           + String.fromCharCode((c & 63) | 128) );=0A=
};=0A=
=0A=
/**=0A=
 * Checks whether a string is UTF8 encoded or not. This is done=0A=
 * with a Regular Expression that matches UTF8-patterns.The following=0A=
 * constraints have to be fulfilled:=0A=
 *=0A=
 * <ul>=0A=
 *   <li>The string has to contain only characters with codes between 0 =
and=0A=
 *     255.=0A=
 *   <li>The patterns must be conform to the UTF8 encoding for UCS2. This=0A=
 *     means that only 1, 2 or 3 Byte representations are allowed.=0A=
 * </ul>=0A=
 *=0A=
 * @param theText: string: The text that has to be checked.=0A=
 * @return boolean: true if the text is a UTF-8 text.=0A=
 */=0A=
function testUtf8 ( theText )=0A=
{=0A=
  pattern =3D=0A=
    =
/([\x00-\x7F])|([\xC0-\xDF][\x80-\xBF])|([\xE0-\xEF][\x80-\xBF][\x80-\xBF=
])/g;=0A=
  var res =3D theText.replace ( pattern, "" );=0A=
  return res.length =3D=3D 0;=0A=
}=0A=
=0A=
/**=0A=
 * Decodes an UTF-8 encoded string into the internal JavaScript=0A=
 * (UCS-2) representation. It forms the inverse function of=0A=
 * <code>encodeUtf8</code>.=0A=
 *=0A=
 * This implementation uses either lambda expressions or simple=0A=
 * array operations.=0A=
 *=0A=
 * @param theText: string: a text that should be decoded from=0A=
 *   UTF-8 representation back to "JavaScript".=0A=
 * @return string: the decoded string. Note that the=0A=
 *   original text will be returned if the text is not a "real"=0A=
 *   UTF-8 string.=0A=
 */=0A=
decodeUtf8 =3D function (theText)=0A=
{=0A=
  if ( !testUtf8 ( theText ) )=0A=
    return theText;=0A=
  pattern =3D =
/([\xC0-\xDF][\x80-\xBF])|([\xE0-\xEF][\x80-\xBF][\x80-\xBF])/g;=0A=
=0A=
  return theText.replace ( pattern, decodeUtf8.lambdaDecode );=0A=
};=0A=
=0A=
// Internal lambda function that matches the two byte or three=0A=
// byte sequences and constructs the original character.=0A=
// The parameters of these function depend on the regular expression=0A=
// of the decodeUtf8 function.=0A=
=0A=
decodeUtf8.lambdaDecode =3D function ( whole, two, three )=0A=
{=0A=
  if ( two )=0A=
  {=0A=
    c =3D two.charCodeAt (0);=0A=
    c2 =3D two.charCodeAt(1);=0A=
    return String.fromCharCode(((c & 31) << 6) | (c2 & 63));=0A=
  }=0A=
=0A=
  if ( three )=0A=
  {=0A=
    c =3D three.charCodeAt (0);=0A=
    c2 =3D three.charCodeAt(1);=0A=
    c3 =3D three.charCodeAt(2);=0A=
    return String.fromCharCode(((c & 15) << 12) | ((c2 & 63) << 6) | (c3 =
& 63));=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * Encodes an arbitrary URI path by encoding its path components.=0A=
 * The path will be splitted and then encoded by means of=0A=
 * "encodeURIComponent". Finally it will be returned by=0A=
 * joining the segments with slashes.=0A=
 *=0A=
 * @param aURI: string: the path segments that should be encoded=0A=
 * @return string: the encoded path information=0A=
 */=0A=
=0A=
function encodeURIPath ( aURI )=0A=
{=0A=
  var components =3D aURI.split('/');=0A=
  for (var i=3D0; i<components.length; i++) {=0A=
=0A=
    components[i] =3D encodeURIComponent(components[i]);=0A=
  }=0A=
  return components.join('/');=0A=
}=0A=
=0A=
/** =0A=
 * IE 5.5 compatibility library.=0A=
 * This library defines the two methods <code>apply</code> and=0A=
 * <code>call</code> for IE 5.5. Note that since IE 6.0 and obviously=0A=
 * for all Netscape derivates this will work well. The code for both=0A=
 * functions is similar to <code>newInstanceOf</code> and is=0A=
 * deprecated per definition.=0A=
 */=0A=
=0A=
if ( !Function.prototype.apply )=0A=
  Function.prototype.apply =3D function ( theObject, theArguments )=0A=
  {=0A=
    theObject.$f$ =3D this;=0A=
    var ret;=0A=
    switch ( theArguments.length )=0A=
    {=0A=
      case 0:=0A=
        ret =3D theObject.$f$ ();=0A=
        break;=0A=
      case 1:=0A=
        ret =3D theObject.$f$ ( theArguments [0] );=0A=
        break;=0A=
      case 2:=0A=
        ret =3D theObject.$f$ ( theArguments [0], theArguments [1] );=0A=
        break;=0A=
      case 3:=0A=
        ret =3D theObject.$f$ ( theArguments [0], theArguments [1], =
theArguments [2] );=0A=
        break;=0A=
      case 4:=0A=
        ret =3D theObject.$f$ ( theArguments [0], theArguments [1], =
theArguments [2], theArguments [3] );=0A=
        break;=0A=
      case 5:=0A=
        ret =3D theObject.$f$ ( theArguments [0], theArguments [1], =
theArguments [2], theArguments [3], theArguments [4] );=0A=
        break;=0A=
    }=0A=
    delete theObject.$f$;=0A=
    return ret;=0A=
  };=0A=
  =0A=
if ( !Function.prototype.call )=0A=
  Function.prototype.call =3D function ( theObject )=0A=
  {=0A=
    theObject.$f$ =3D this;=0A=
    var ret;=0A=
    switch ( arguments.length )=0A=
    {=0A=
      case 1:=0A=
        ret =3D theObject.$f$ ();=0A=
        break;=0A=
      case 2:=0A=
        ret =3D theObject.$f$ ( arguments [1] );=0A=
        break;=0A=
      case 3:=0A=
        ret =3D theObject.$f$ ( arguments [1], arguments [2] );=0A=
        break;=0A=
      case 4:=0A=
        ret =3D theObject.$f$ ( arguments [1], arguments [2], arguments =
[3] );=0A=
        break;=0A=
      case 5:=0A=
        ret =3D theObject.$f$ ( arguments [1], arguments [2], arguments =
[3], arguments [4] );=0A=
        break;=0A=
      case 6:=0A=
        ret =3D theObject.$f$ ( arguments [1], arguments [2], arguments =
[3], arguments [4], arguments [5] );=0A=
        break;=0A=
    }=0A=
    delete theObject.$f$;=0A=
    return ret;=0A=
  };=0A=
=0A=
/**=0A=
 * Returns an array holding all functions that participate in the =
current execution stack.=0A=
 * The first element holds the last entry in the stack and so on (as it =
is typical for stack traces).=0A=
 * Attention: Does not work for Safari at the moment=0A=
 * (no arguments.caller and only provides the ECMA properties name and =
message for error objects),=0A=
 * it always returns an empty array there.<p>=0A=
 * Example:<br>=0A=
 * <code>=0A=
 * function a(str1, str2) {=0A=
 *   return b(str1);=0A=
 * }=0A=
 *   =0A=
 * function b(aString) {=0A=
 *   return c(aString);=0A=
 * }=0A=
 *   =0A=
 * c =3D function(anotherString) {=0A=
 *   return getStackTrace();=0A=
 * }=0A=
 * </code>=0A=
 * Calling <code>a(x,y)</code> returns the following entries:=0A=
 * <code>=0A=
 * anonymous(anotherString)=0A=
 * b(aString) =0A=
 * a(str1, str2)=0A=
 * </code>=0A=
 * Remark: The Mozilla implementation does not hold the function =
parameters as abstract variables=0A=
 * but the concrete values.=0A=
 *=0A=
 * @return String[]: an array of stack trace entries=0A=
 */=0A=
function getStackTrace()=0A=
{=0A=
  // per default, we ignore one stack trace entry (the one of =
getStackTrace itself):=0A=
  var ignoredEntries =3D arguments.length > 0 ? arguments[0] : 1;=0A=
  var ret_val =3D [];=0A=
  var regexp =3D /function([^{}]+)/;=0A=
=0A=
  if ( typeof(arguments.caller) !=3D "undefined" )=0A=
  { // IE, not ECMA=0A=
    // FIXXXME: arguments.caller is null in the case of OJS 1.2 (works =
if getStackTrace is a simple function)=0A=
    for (var a =3D arguments.caller; a !=3D null; a =3D a.caller) =0A=
    {=0A=
      var func =3D a.callee.toString().match( regexp )[0];=0A=
      ret_val[ret_val.length] =3D ((func =3D=3D null) || (func.length =
=3D=3D 0) ? "anonymous" : func);=0A=
      if ( a.caller =3D=3D a )=0A=
      {=0A=
        ret_val[ret_val.length] =3D "*";=0A=
        break;=0A=
      }=0A=
    }=0A=
  }=0A=
  else =0A=
  { // Mozilla, not ECMA - fake an exception so we can get Mozilla's =
error stack=0A=
    var test_exception;=0A=
    try=0A=
    {=0A=
      this_throws.an_exception;=0A=
    }=0A=
    catch(test_exception)=0A=
    {=0A=
      var m, name;=0A=
=0A=
      if ( !test_exception || !test_exception.stack ) // Safari=0A=
        return ret_val;=0A=
=0A=
      var stacklist =3D test_exception.stack.split("\n");=0A=
=0A=
      for ( var i =3D 0; i < stacklist.length - 1; ++i )=0A=
      {=0A=
        var framedata =3D stacklist[i];=0A=
=0A=
        m =3D framedata.match(/^(\w*)\s*\(\s*([^\)]*)/);=0A=
=0A=
        if ( !m || m.length < 2 )=0A=
          continue;=0A=
=0A=
        name =3D m[1] || "anonymous";=0A=
=0A=
        ret_val[ret_val.length] =3D name + "(" + (m.length > 2 ? m[2] : =
"") + ")";=0A=
      }=0A=
      // remove ignored entries=0A=
      if ( ignoredEntries )=0A=
        ret_val =3D ret_val.slice(ignoredEntries);=0A=
    }=0A=
  }=0A=
  return ret_val;=0A=
}=0A=
=0A=
/**=0A=
 * Safari compatibility library.=0A=
 * This library defines the method <code>hasOwnProperty</code> which =
returns=0A=
 * <code>true</code> if an object has a noninherited property with the =
given name.=0A=
 */=0A=
if ( !Object.prototype.hasOwnProperty )=0A=
{=0A=
  Object.prototype.hasOwnProperty =3D function ( thePropertyName )=0A=
  {=0A=
    return (typeof this[thePropertyName] !=3D "undefined") && =
(this.constructor.prototype[thePropertyName] =3D=3D null);=0A=
  };=0A=
}=0A=
=0A=
// Timestamp/TimeOfDay/DayMonthYear data types.=0A=
/**=0A=
 * Extends the Date type with member variable <code>type_</code>.=0A=
 * Allows to define the type during construction.=0A=
 * =0A=
 * @param type: int: The type represented by this Date instance. =
Possible values are=0A=
 *   0 for unmodified Date behavior, 1 for TimeStamp, 2 for YearMonthDay =
and 3 for TimeOfDay.=0A=
 *   =0A=
 * @return Date: the Date instance itself=0A=
 */=0A=
Date.prototype.initType =3D function(type)=0A=
{=0A=
  this.type_ =3D type;=0A=
  return this;=0A=
};=0A=
=0A=
/**=0A=
 * Returns the type of the Date instance.=0A=
 * =0A=
 * @return int: The type represented by this Date instance. Possible =
values are=0A=
 *   0 for unmodified Date behavior, 1 for TimeStamp, 2 for YearMonthDay =
and 3 for TimeOfDay.=0A=
 */=0A=
Date.prototype.getType =3D function()=0A=
{=0A=
  if ( !this.type_ )=0A=
    return 0;=0A=
  return this.type_;=0A=
};=0A=
=0A=
//Make Date Objects "cloneable"=0A=
Date.prototype.clone =3D function ( scope ) =0A=
{=0A=
  var scope =3D scope || window;=0A=
  return scope.newInstanceOf ( scope.Date, this.valueOf () ).initType( =
this.getType() ); =0A=
};=0A=
=0A=
//Rename all windows if mode is not disabled =0A=
//(by setting global variable <code>gRenameWindows_</code> to =
<code>false</code>):=0A=
if (typeof gRenameWindows_ !=3D "undefined" && gRenameWindows_ =3D=3D=3D =
true)=0A=
{=0A=
  if ( window !=3D top && window.name )=0A=
    window.name =3D window.name + "_" + top.name;=0A=
  else if ( window =3D=3D top && (!window.name || =
(window.name.indexOf("hw_top_") < 0)) )=0A=
    window.name =3D ("hw_top_" + document.location.host + "_" + =
document.location.pathname.replace(/\/.*^/, "")).replace(/\W/g, "") + =
getUniqueId();=0A=
}=0A=
=0A=
var gChangeLevel1=3D{addKeyValue: function (key, value) {=0A=
    this[key] =3D value;=0A=
  }};=0A=
gChangeLevel1.addKeyValue("\u0041", "a");=0A=
gChangeLevel1.addKeyValue("\u0061", "a");=0A=
gChangeLevel1.addKeyValue("\u00c6", "ae");=0A=
gChangeLevel1.addKeyValue("\u00e6", "ae");=0A=
gChangeLevel1.addKeyValue("\u00e1", "a");=0A=
gChangeLevel1.addKeyValue("\u00c1", "a");=0A=
gChangeLevel1.addKeyValue("\u00e0", "a");=0A=
gChangeLevel1.addKeyValue("\u00c0", "a");=0A=
gChangeLevel1.addKeyValue("\u00e2", "a");=0A=
gChangeLevel1.addKeyValue("\u00c2", "a");=0A=
gChangeLevel1.addKeyValue("\u00e5", "a");=0A=
gChangeLevel1.addKeyValue("\u00c5", "a");=0A=
gChangeLevel1.addKeyValue("\u00e4", "a");=0A=
gChangeLevel1.addKeyValue("\u00c4", "a");=0A=
gChangeLevel1.addKeyValue("\u00e3", "a");=0A=
gChangeLevel1.addKeyValue("\u00c3", "a");=0A=
gChangeLevel1.addKeyValue("\u0043", "c");=0A=
gChangeLevel1.addKeyValue("\u0063", "c");=0A=
gChangeLevel1.addKeyValue("\u00e7", "c");=0A=
gChangeLevel1.addKeyValue("\u00c7", "c");=0A=
gChangeLevel1.addKeyValue("\u0044", "d");=0A=
gChangeLevel1.addKeyValue("\u0064", "d");=0A=
gChangeLevel1.addKeyValue("\u00d0", "d");=0A=
gChangeLevel1.addKeyValue("\u00f0", "d");=0A=
gChangeLevel1.addKeyValue("\u0065", "e");=0A=
gChangeLevel1.addKeyValue("\u0045", "e");=0A=
gChangeLevel1.addKeyValue("\u00e9", "e");=0A=
gChangeLevel1.addKeyValue("\u00c9", "e");=0A=
gChangeLevel1.addKeyValue("\u00e8", "e");=0A=
gChangeLevel1.addKeyValue("\u00c8", "e");=0A=
gChangeLevel1.addKeyValue("\u00ea", "e");=0A=
gChangeLevel1.addKeyValue("\u00ca", "e");=0A=
gChangeLevel1.addKeyValue("\u00eb", "e");=0A=
gChangeLevel1.addKeyValue("\u00cb", "e");=0A=
gChangeLevel1.addKeyValue("\u0049", "i");=0A=
gChangeLevel1.addKeyValue("\u0069", "i");=0A=
gChangeLevel1.addKeyValue("\u00ed", "i");=0A=
gChangeLevel1.addKeyValue("\u00cd", "i");=0A=
gChangeLevel1.addKeyValue("\u00ec", "i");=0A=
gChangeLevel1.addKeyValue("\u00cc", "i");=0A=
gChangeLevel1.addKeyValue("\u00ee", "i");=0A=
gChangeLevel1.addKeyValue("\u00ce", "i");=0A=
gChangeLevel1.addKeyValue("\u00ef", "i");=0A=
gChangeLevel1.addKeyValue("\u00cf", "i");=0A=
gChangeLevel1.addKeyValue("\u004f", "o");=0A=
gChangeLevel1.addKeyValue("\u006f", "o");=0A=
gChangeLevel1.addKeyValue("\u00d8", "o");=0A=
gChangeLevel1.addKeyValue("\u00f8", "o");=0A=
gChangeLevel1.addKeyValue("\u00f3", "o");=0A=
gChangeLevel1.addKeyValue("\u00d3", "o");=0A=
gChangeLevel1.addKeyValue("\u00f2", "o");=0A=
gChangeLevel1.addKeyValue("\u00d2", "o");=0A=
gChangeLevel1.addKeyValue("\u00f4", "o");=0A=
gChangeLevel1.addKeyValue("\u00d4", "o");=0A=
gChangeLevel1.addKeyValue("\u00f5", "o");=0A=
gChangeLevel1.addKeyValue("\u00f6", "o");=0A=
gChangeLevel1.addKeyValue("\u00d6", "o");=0A=
gChangeLevel1.addKeyValue("\u0053", "s");=0A=
gChangeLevel1.addKeyValue("\u0073", "s");=0A=
gChangeLevel1.addKeyValue("\u00df", "ss");=0A=
gChangeLevel1.addKeyValue("\u0055", "u");=0A=
gChangeLevel1.addKeyValue("\u0075", "u");=0A=
gChangeLevel1.addKeyValue("\u00fa", "u");=0A=
gChangeLevel1.addKeyValue("\u00da", "u");=0A=
gChangeLevel1.addKeyValue("\u00f9", "u");=0A=
gChangeLevel1.addKeyValue("\u00d9", "u");=0A=
gChangeLevel1.addKeyValue("\u00fb", "u");=0A=
gChangeLevel1.addKeyValue("\u00db", "u");=0A=
gChangeLevel1.addKeyValue("\u00fc", "u");=0A=
gChangeLevel1.addKeyValue("\u00dc", "u");=0A=
gChangeLevel1.addKeyValue("\u0059", "y");=0A=
gChangeLevel1.addKeyValue("\u0079", "y");=0A=
gChangeLevel1.addKeyValue("\u00fd", "y");=0A=
gChangeLevel1.addKeyValue("\u00dd", "y");=0A=
gChangeLevel1.addKeyValue("\u00ff", "y");=0A=
gChangeLevel1.addKeyValue("\u00f1", "n");=0A=
gChangeLevel1.addKeyValue("\u00d1", "n");=0A=
gChangeLevel1.addKeyValue("-", "");=0A=
gChangeLevel1.addKeyValue("'", "");=0A=
gChangeLevel1.addKeyValue("!", "");=0A=
gChangeLevel1.addKeyValue('"', "");=0A=
gChangeLevel1.addKeyValue("#", "");=0A=
gChangeLevel1.addKeyValue("$", "");=0A=
gChangeLevel1.addKeyValue("%", "");=0A=
gChangeLevel1.addKeyValue("&", "");=0A=
gChangeLevel1.addKeyValue("'", "");=0A=
gChangeLevel1.addKeyValue("(", "");=0A=
gChangeLevel1.addKeyValue(")", "");=0A=
gChangeLevel1.addKeyValue("*", "");=0A=
gChangeLevel1.addKeyValue("+", "");=0A=
gChangeLevel1.addKeyValue(",", "");=0A=
gChangeLevel1.addKeyValue("-", "");=0A=
gChangeLevel1.addKeyValue(".", "");=0A=
gChangeLevel1.addKeyValue("/", "");=0A=
gChangeLevel1.addKeyValue(":", "");=0A=
gChangeLevel1.addKeyValue(";", "");=0A=
gChangeLevel1.addKeyValue("<", "");=0A=
gChangeLevel1.addKeyValue("=3D", "");=0A=
gChangeLevel1.addKeyValue(">", "");=0A=
gChangeLevel1.addKeyValue("?", "");=0A=
gChangeLevel1.addKeyValue("@", "");=0A=
gChangeLevel1.addKeyValue("[", "");=0A=
gChangeLevel1.addKeyValue("\\", "");=0A=
gChangeLevel1.addKeyValue("]", "");=0A=
gChangeLevel1.addKeyValue("^", "");=0A=
gChangeLevel1.addKeyValue("_", "");=0A=
gChangeLevel1.addKeyValue("`", "");=0A=
gChangeLevel1.addKeyValue("{", "");=0A=
gChangeLevel1.addKeyValue("|", "");=0A=
gChangeLevel1.addKeyValue("}", "");=0A=
gChangeLevel1.addKeyValue("~", "");=0A=
delete gChangeLevel1.addKeyValue;=0A=
=0A=
var gChangeLevel2=3D{addKeyValue: function (key, value) {=0A=
    this[key] =3D value;=0A=
  }};=0A=
gChangeLevel2.addKeyValue("\u0041", "a\000");//A=0A=
gChangeLevel2.addKeyValue("\u0061", "a\000");//a=0A=
gChangeLevel2.addKeyValue("\u00c6", "ae");//=C3=86=0A=
gChangeLevel2.addKeyValue("\u00e6", "ae");//=C3=A6=0A=
gChangeLevel2.addKeyValue("\u00e1", "a\001");//=C3=A1=0A=
gChangeLevel2.addKeyValue("\u00c1", "a\001");//=C3=81=0A=
gChangeLevel2.addKeyValue("\u00e0", "a\002");//=C3=A0=0A=
gChangeLevel2.addKeyValue("\u00c0", "a\002");//=C3=80=0A=
gChangeLevel2.addKeyValue("\u00e2", "a\003");//=C3=A2=0A=
gChangeLevel2.addKeyValue("\u00c2", "a\003");//=C3=82=0A=
gChangeLevel2.addKeyValue("\u00e5", "a\004");//=C3=A5=0A=
gChangeLevel2.addKeyValue("\u00c5", "a\004");//=C3=85=0A=
gChangeLevel2.addKeyValue("\u00e4", "a\005");//=C3=A4=0A=
gChangeLevel2.addKeyValue("\u00c4", "a\005");//=C3=84=0A=
gChangeLevel2.addKeyValue("\u00e3", "a\006");//=C3=A3=0A=
gChangeLevel2.addKeyValue("\u00c3", "a\006");//=C3=83=0A=
gChangeLevel2.addKeyValue("\u0043", "c\000");//C=0A=
gChangeLevel2.addKeyValue("\u0063", "c\000");//c=0A=
gChangeLevel2.addKeyValue("\u00e7", "c\001");//=C3=A7=0A=
gChangeLevel2.addKeyValue("\u00c7", "c\001");//=C3=87=0A=
gChangeLevel2.addKeyValue("\u0044", "d\000");//D=0A=
gChangeLevel2.addKeyValue("\u0064", "d\000");//d=0A=
gChangeLevel2.addKeyValue("\u00d0", "d\000");//=C3=90=0A=
gChangeLevel2.addKeyValue("\u00f0", "d\000");//=C3=B0=0A=
gChangeLevel2.addKeyValue("\u0065", "e\000");//e=0A=
gChangeLevel2.addKeyValue("\u0045", "e\000");//E=0A=
gChangeLevel2.addKeyValue("\u00e9", "e\001");//=C3=A9=0A=
gChangeLevel2.addKeyValue("\u00c9", "e\001");//=C3=89=0A=
gChangeLevel2.addKeyValue("\u00e8", "e\002");//=C3=A8=0A=
gChangeLevel2.addKeyValue("\u00c8", "e\002");//=C3=88=0A=
gChangeLevel2.addKeyValue("\u00ea", "e\003");//=C3=AA=0A=
gChangeLevel2.addKeyValue("\u00ca", "e\003");//=C3=8A=0A=
gChangeLevel2.addKeyValue("\u00eb", "e\004");//=C3=AB=0A=
gChangeLevel2.addKeyValue("\u00cb", "e\004");//=C3=8B=0A=
gChangeLevel2.addKeyValue("\u0049", "i\000");//I=0A=
gChangeLevel2.addKeyValue("\u0069", "i\000");//i=0A=
gChangeLevel2.addKeyValue("\u00ed", "i\001");//=C3=AD=0A=
gChangeLevel2.addKeyValue("\u00cd", "i\001");//=C3=8D=0A=
gChangeLevel2.addKeyValue("\u00ec", "i\002");//=C3=AC=0A=
gChangeLevel2.addKeyValue("\u00cc", "i\002");//=C3=8C=0A=
gChangeLevel2.addKeyValue("\u00ee", "i\003");//=C3=AE=0A=
gChangeLevel2.addKeyValue("\u00ce", "i\003");//=C3=8E=0A=
gChangeLevel2.addKeyValue("\u00ef", "i\004");//=C3=AF=0A=
gChangeLevel2.addKeyValue("\u00cf", "i\004");//=C3=8F=0A=
gChangeLevel2.addKeyValue("\u004f", "o\000");//O=0A=
gChangeLevel2.addKeyValue("\u006f", "o\000");//o=0A=
gChangeLevel2.addKeyValue("\u00d8", "o\000");//=C3=98=0A=
gChangeLevel2.addKeyValue("\u00f8", "o\000");//=C3=B8=0A=
gChangeLevel2.addKeyValue("\u00f3", "o\001");//=C3=B3=0A=
gChangeLevel2.addKeyValue("\u00d3", "o\001");//=C3=93=0A=
gChangeLevel2.addKeyValue("\u00f2", "o\002");//=C3=B2=0A=
gChangeLevel2.addKeyValue("\u00d2", "o\002");//=C3=92=0A=
gChangeLevel2.addKeyValue("\u00f4", "o\003");//=C3=B4=0A=
gChangeLevel2.addKeyValue("\u00d4", "o\003");//=C3=94=0A=
gChangeLevel2.addKeyValue("\u00f5", "o\004");//=C3=B5=0A=
gChangeLevel2.addKeyValue("\u00f6", "o\005");//=C3=B6=0A=
gChangeLevel2.addKeyValue("\u00d6", "o\005");//=C3=96=0A=
gChangeLevel2.addKeyValue("\u0053", "s\000");//S=0A=
gChangeLevel2.addKeyValue("\u0073", "s\000");//s=0A=
gChangeLevel2.addKeyValue("\u00df", "ss");//=C3=9F=0A=
gChangeLevel2.addKeyValue("\u0055", "u\001");//U=0A=
gChangeLevel2.addKeyValue("\u0075", "u\001");//u=0A=
gChangeLevel2.addKeyValue("\u00fa", "u\001");//=C3=BA=0A=
gChangeLevel2.addKeyValue("\u00da", "u\001");//=C3=9A=0A=
gChangeLevel2.addKeyValue("\u00f9", "u\002");//=C3=B9=0A=
gChangeLevel2.addKeyValue("\u00d9", "u\002");//=C3=99=0A=
gChangeLevel2.addKeyValue("\u00fb", "u\003");//=C3=BB=0A=
gChangeLevel2.addKeyValue("\u00db", "u\003");//=C3=9B=0A=
gChangeLevel2.addKeyValue("\u00fc", "u\004");//=C3=BC=0A=
gChangeLevel2.addKeyValue("\u00dc", "u\004");//=C3=9C=0A=
gChangeLevel2.addKeyValue("\u0059", "y\000");//Y=0A=
gChangeLevel2.addKeyValue("\u0079", "y\000");//y=0A=
gChangeLevel2.addKeyValue("\u00fd", "y\001");//=C3=BD=0A=
gChangeLevel2.addKeyValue("\u00dd", "y\001");//=C3=9D=0A=
gChangeLevel2.addKeyValue("\u00ff", "y\002");//=C3=BF=0A=
gChangeLevel2.addKeyValue("\u00f1", "n\001");//=C3=B1=0A=
gChangeLevel2.addKeyValue("\u00d1", "n\001");//=C3=91=0A=
gChangeLevel2.addKeyValue("-", "");=0A=
gChangeLevel2.addKeyValue("'", "");=0A=
gChangeLevel2.addKeyValue("!", "");=0A=
gChangeLevel2.addKeyValue('"', "");=0A=
gChangeLevel2.addKeyValue("#", "");=0A=
gChangeLevel2.addKeyValue("$", "");=0A=
gChangeLevel2.addKeyValue("%", "");=0A=
gChangeLevel2.addKeyValue("&", "");=0A=
gChangeLevel2.addKeyValue("'", "");=0A=
gChangeLevel2.addKeyValue("(", "");=0A=
gChangeLevel2.addKeyValue(")", "");=0A=
gChangeLevel2.addKeyValue("*", "");=0A=
gChangeLevel2.addKeyValue("+", "");=0A=
gChangeLevel2.addKeyValue(",", "");=0A=
gChangeLevel2.addKeyValue("-", "");=0A=
gChangeLevel2.addKeyValue(".", "");=0A=
gChangeLevel2.addKeyValue("/", "");=0A=
gChangeLevel2.addKeyValue(":", "");=0A=
gChangeLevel2.addKeyValue(";", "");=0A=
gChangeLevel2.addKeyValue("<", "");=0A=
gChangeLevel2.addKeyValue("=3D", "");=0A=
gChangeLevel2.addKeyValue(">", "");=0A=
gChangeLevel2.addKeyValue("?", "");=0A=
gChangeLevel2.addKeyValue("@", "");=0A=
gChangeLevel2.addKeyValue("[", "");=0A=
gChangeLevel2.addKeyValue("\\", "");=0A=
gChangeLevel2.addKeyValue("]", "");=0A=
gChangeLevel2.addKeyValue("^", "");=0A=
gChangeLevel2.addKeyValue("_", "");=0A=
gChangeLevel2.addKeyValue("`", "");=0A=
gChangeLevel2.addKeyValue("{", "");=0A=
gChangeLevel2.addKeyValue("|", "");=0A=
gChangeLevel2.addKeyValue("}", "");=0A=
gChangeLevel2.addKeyValue("~", "");=0A=
delete gChangeLevel2.addKeyValue;=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * creates an simple compareable string out of an internationalized =
string=0A=
 * This is done using EOR conform rules=0A=
 *=0A=
 * @param aStr: string: an arbitrary stringthe path segments that should =
be encoded=0A=
 * @return string: the by >< compareable representation of aStr=0A=
 */=0A=
function intStrKeyLevel1(aStr)=0A=
{  // create internationalised sortable string=0A=
  var return_str=3DintStrKeyLevel1.cache_[aStr];=0A=
  if (return_str) // return chached version of the string if present=0A=
    return return_str;=0A=
  var =
theStr=3DaStr.replace(LANG_OBJECTJS_REGEXP_WHITESPACESLINESTART,"");=0A=
  var =
theStr=3DtheStr.replace(LANG_OBJECTJS_REGEXP_WHITESPACESLINEEND,"");=0A=
=0A=
var aRegExp=3Dnew =
RegExp("[\u0041\u0061\u00c6\u00e6\u00e1\u00c1\u00e0\u00c0\u00e2\u00c2\u00=
e5\u00c5\u00e4\u00c4\u00e3\u00c3\u0043\u0063\u00e7\u00c7\u0044\u0064\u00d=
0\u00f0\u00e9\u0065\u0045\u00c9\u00e8\u00c8\u00ea\u00ca\u00eb\u00cb\u0049=
\u0069\u00ed\u00cd\u00ec\u00cc\u00ee\u00ce\u00ef\u00cf\u004f\u006f\u00d8\=
u00f8\u00f3\u00d3\u00f2\u00d2\u00f4\u00d4\u00f5\u00f6\u00d6\u0053\u0073\u=
00df\u0055\u0075\u00fa\u00da\u00f9\u00d9\u00fb\u00db\u00fc\u00dc\u0059\u0=
079\u00fd\u00dd\u00ff\u00f1\u00d1\\-\\'\\!\\\"\\#\\%\\&\\'\\(\\)\\*\\+,\\=
.\\/\\:\\;\\<\\=3D\\>\\?\\@\\[\\\\\\]\\^\\_\\`\\{\\|\\}\\~]","g");=0A=
  var return_str=3DtheStr.replace ( aRegExp, intStrKeyLevel1.lamdaExp );=0A=
  intStrKeyLevel1.cache_[aStr]=3Dreturn_str;=0A=
  return return_str;=0A=
}=0A=
=0A=
intStrKeyLevel1.cache_=3D{};=0A=
intStrKeyLevel1.lamdaExp =3D function (key) {=0A=
  var ret=3DgChangeLevel1[key];=0A=
  if (typeof ret !=3D"undefined")=0A=
    return ret;=0A=
  else=0A=
    return key;=0A=
};=0A=
 =0A=
=0A=
function intStrKeyLevel2(aStr)=0A=
{  // create internationalised sortable string=0A=
  var return_str=3DintStrKeyLevel2.cache_[aStr];=0A=
  if (return_str) // return chached version of the string if present=0A=
    return return_str;=0A=
  var =
theStr=3DaStr.replace(LANG_OBJECTJS_REGEXP_WHITESPACESLINESTART,"");=0A=
  var =
theStr=3DtheStr.replace(LANG_OBJECTJS_REGEXP_WHITESPACESLINEEND,"");=0A=
=0A=
  var aRegExp=3Dnew =
RegExp("[\u0041\u0061\u00c6\u00e6\u00e1\u00c1\u00e0\u00c0\u00e2\u00c2\u00=
e5\u00c5\u00e4\u00c4\u00e3\u00c3\u0043\u0063\u00e7\u00c7\u0044\u0064\u00d=
0\u00f0\u00e9\u0065\u0045\u00c9\u00e8\u00c8\u00ea\u00ca\u00eb\u00cb\u0049=
\u0069\u00ed\u00cd\u00ec\u00cc\u00ee\u00ce\u00ef\u00cf\u004f\u006f\u00d8\=
u00f8\u00f3\u00d3\u00f2\u00d2\u00f4\u00d4\u00f5\u00f6\u00d6\u0053\u0073\u=
00df\u0055\u0075\u00fa\u00da\u00f9\u00d9\u00fb\u00db\u00fc\u00dc\u0059\u0=
079\u00fd\u00dd\u00ff\u00f1\u00d1\\-\\'\\!\\\"\\#\\%\\&\\'\\(\\)\\*\\+\\,=
\\.\\/\\:\\;\\<\\=3D\\>\\?\\@\\[\\\\\\]\\^\\_\\`\\{\\|\\}\\~]","g");=0A=
=0A=
  return_str=3D theStr.replace ( aRegExp, intStrKeyLevel2.lamdaExp );=0A=
  intStrKeyLevel2.cache_[aStr]=3Dreturn_str;=0A=
  return return_str;=0A=
}=0A=
=0A=
intStrKeyLevel2.cache_=3D{};=0A=
intStrKeyLevel2.lamdaExp =3D function (key) {=0A=
  var ret=3DgChangeLevel2[key];=0A=
  if (typeof ret !=3D"undefined")=0A=
    return ret;=0A=
  else=0A=
    return key;=0A=
};=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * compares two strings using EOR conform rules=0A=
 *=0A=
 * @param a,b: string: the two strings to compare=0A=
 * @return string: -1,0,1 as used for sorting=0A=
 */=0A=
function compareIntStrings(a,b)=0A=
{=0A=
  var aa=3DintStrKeyLevel1(a);=0A=
  var bb=3DintStrKeyLevel1(b);=0A=
  if (aa>bb) return 1; =0A=
  else if (aa<bb) return -1;=0A=
  =0A=
  var aa=3DintStrKeyLevel2(a);=0A=
  var bb=3DintStrKeyLevel2(b);=0A=
  if (aa>bb) return 1; =0A=
  else if (aa<bb) return -1;=0A=
  else return 0;=0A=
}=0A=
/* End of  "Object.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/hw.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        hw.js=0A=
 *  Created:     2010-02-19 by sweber=0A=
 *  Description: This file contains some utility functions=0A=
 *               for working with the com.hyperwave... classes.=0A=
 *               All functions are accessable by =
com.hyperwave.<functionname>=0A=
 *               or (if provided by) hw.<functionname>.=0A=
 *               e.g. <code>hw.getFramework();</code>=0A=
 *=0A=
 *  $Id: hw.js 161071 2011-01-20 12:29:44Z sweber $=0A=
 * </file>=0A=
 */=0A=
initPackage("com.hyperwave");=0A=
=0A=
/**=0A=
 * This function returns the client side global framework.=0A=
 * If nothing will be found, <code>null</code> will be returned.=0A=
 *=0A=
 * @return com.hyperwave.framework.Framework|null: the Framework=0A=
 */=0A=
com.hyperwave.getFramework =3D function () {=0A=
  var framework_class =3D this._getFramework(window);=0A=
  if (framework_class) {=0A=
    return framework_class.static_.getInstance();=0A=
  }=0A=
  return null;=0A=
}=0A=
=0A=
/**=0A=
 * This is a helper function that recursively searches for the =
Framework-class.=0A=
 *=0A=
 * @return com.hyperwave.framework.Framework|null: the Framework-class=0A=
 */=0A=
com.hyperwave._getFramework =3D function (theWindow) {=0A=
  if (theWindow.top.Framework) {=0A=
    return theWindow.top.Framework;=0A=
  }=0A=
  if (theWindow.top.opener && !theWindow.top.opener.closed) {=0A=
    return this._getFramework(theWindow.top.opener);=0A=
  } =0A=
  return null;=0A=
};=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/util/IncludeManager.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        IncludeManager.js=0A=
 *  Created:     2010-04-30 by sweber=0A=
 *=0A=
 *  $Id:$=0A=
 * </file>=0A=
 */=0A=
initPackage("com.hyperwave.util");=0A=
/** =0A=
 * This class is the client side helper class to retrive included =
resources.=0A=
 * On server side you can include `.xml` and `.lrc` file using the =
include manager.=0A=
 * These resources can be retrived using this `IncludeManager` on client =
side.=0A=
 *=0A=
 * <xmp>=0A=
 * // on server side=0A=
 * =
writeln(includemanager.getDynamicSet("%vd%/components/test/langres/test.%=
lang%.xml"));=0A=
 *=0A=
 * // on client side=0A=
 * var my_reader =3D =
hw.util.IncludeManager.static_.getResource("%vd%/components/test/langres/=
test.%lang%.xml");=0A=
 * alert(my_reader.getRes("message1"));=0A=
 * </xmp>=0A=
 *=0A=
 * @author sweber=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.util.IncludeManager">=0A=
=0A=
/**=0A=
 * The IncludeManager constructor.=0A=
 *=0A=
 */=0A=
com.hyperwave.util.IncludeManager =3D function ()=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__")=0A=
    return;=0A=
=0A=
  this.map_ =3D {};=0A=
  this.placeholders_ =3D {};=0A=
  this.unique_ =3D null;=0A=
  this.prefix_ =3D null;=0A=
};=0A=
class$ =3D doInherit(com.hyperwave.util.IncludeManager);=0A=
=0A=
class$.static_.lastIncluded_ =3D null;=0A=
=0A=
/**=0A=
 * This method returns the instance of this class.=0A=
 *=0A=
 * @return: com.hyperwave.util.IncludeManager: this class instance=0A=
 */=0A=
class$.static_.getInstance =3D function () {=0A=
  return this.singleton_ || (this.singleton_ =3D new =
com.hyperwave.util.IncludeManager());=0A=
};=0A=
=0A=
/**=0A=
 * This method is the setter method to define a included resource.=0A=
 *=0A=
 * @param theKey: string: the file name=0A=
 * @param theResource: CSResourceReader: the resource=0A=
 */=0A=
class$._setResource =3D function (theKey, theResource) {=0A=
  this.map_[theKey] =3D theResource;=0A=
};=0A=
=0A=
/**=0A=
 * The static equivalent to dynamic `_setResource`.=0A=
 *=0A=
 * @param theKey: string: the file name=0A=
 * @param theResource: CSResourceReader: the resource=0A=
 */=0A=
class$.static_._setResource =3D function (theKey, theResource) {=0A=
  return this.getInstance()._setResource(theKey, theResource);=0A=
};=0A=
=0A=
/**=0A=
 * This method returns the included resource reader by the given file =
name.=0A=
 *=0A=
 * @param theKey: string: the file name as used at server side=0A=
 */=0A=
class$.getResource =3D function (theKey) {=0A=
  if (this.map_[theKey]) {=0A=
    return this.map_[theKey]();=0A=
  }=0A=
  else {=0A=
    return null;=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * The static equivalent to dynamic `getResource`.=0A=
 *=0A=
 * @param theKey: string: the file name as used at server side=0A=
 */=0A=
class$.static_.getResource =3D function (theKey) {=0A=
  return this.getInstance().getResource(theKey);=0A=
};=0A=
=0A=
class$.loadResource =3D function (theFile) {=0A=
  var params =3D =
"#(UIClass:com.hyperwave.util.IncludeManager)(Method:static_.getResource)=
";=0A=
  var src =3D ["/hw_temporary_objects;internal",=0A=
             "action=3Djs.execute.action",=0A=
             "Parameter=3D" + encodeURIComponent(params),=0A=
             "file=3D" + encodeURIComponent(theFile),=0A=
             "cachekeY=3D" + encodeURIComponent(this.unique_)].join("&");=0A=
=0A=
  document.writeln('<script type=3D"text/javascript" src=3D"' + src + =
'"></script>');=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$.getSrc =3D function (theInclude) {=0A=
  return this._processInclude(this._resolvePlaceholders(theInclude));=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$._resolvePlaceholders =3D function (theString) {=0A=
  var this_ =3D this;=0A=
  return theString.replace(/\%(\w+)\%/g,=0A=
                           function (theMatch, theKey) {=0A=
                             if (theKey in this_.placeholders_) {=0A=
                               return this_.placeholders_[theKey];=0A=
                             }=0A=
                             else {=0A=
                               return theMatch;=0A=
                             }=0A=
                           });=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$._processInclude =3D function (theInclude) {=0A=
  return [theInclude.charAt(0) =3D=3D "/" ? "" : this.prefix_,=0A=
          theInclude,=0A=
          theInclude.indexOf("?") =3D=3D -1 ? "?" : "&",=0A=
          "cachekeY=3D",=0A=
          this.unique_].join("");=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$.setPrefix =3D function (thePrefix) {=0A=
  this.prefix_ =3D thePrefix;=0A=
  return this;=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$.setUnique =3D function (theUnique) {=0A=
  this.unique_ =3D theUnique;=0A=
  return this;=0A=
};=0A=
=0A=
// this function has to the equal with server side function=0A=
class$.setPlaceholder =3D function (theName, theValue) {=0A=
  this.placeholders_[theName] =3D theValue;=0A=
  return this;=0A=
};=0A=
=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/cslib.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: cookie.js 152677 2010-01-29 12:00:08Z merge $=0A=
 */=0A=
function setCookie(name, value, expire, domain) {=0A=
  var cookie =3D getCookie(name);=0A=
  if (cookie !=3D value)=0A=
    document.cookie =3D name + "=3D" + encodeURIComponent(""+value) +=0A=
                      ((expire =3D=3D null) ? "" : ("; expires=3D" + =
expire.toGMTString())) +=0A=
                      ";path=3D/" +=0A=
                      ((domain) ? ";domain=3D" + domain : "");=0A=
}=0A=
function getCookie(Name){=0A=
   var search =3D Name + "=3D";=0A=
   var cookie=3Dnull;=0A=
   if (document.cookie.length > 0) { // if there are any cookies=0A=
     offset =3D document.cookie.indexOf(search);=0A=
     if (offset !=3D -1) { // if cookie exists=0A=
       offset +=3D search.length;=0A=
                         // set index of beginning of value=0A=
       end =3D document.cookie.indexOf(";", offset);=0A=
                         // set index of end of cookie value=0A=
       if (end =3D=3D -1)=0A=
          end =3D document.cookie.length;=0A=
       var cookie_value =3D document.cookie.substring(offset, end);=0A=
       if ( !cookie_value )=0A=
         cookie_value =3D "";=0A=
       return decodeURIComponent(cookie_value);=0A=
     }=0A=
   }=0A=
   return cookie;=0A=
}=0A=
=0A=
function hw_reloadFunc(){=0A=
  window.location.reload();=0A=
}=0A=
=0A=
var ahwcookie=3DgetCookie("HW_Reload");=0A=
if(ahwcookie !=3D null){=0A=
  var cstate =3D ahwcookie.split(':');=0A=
  if (cstate=3D=3D"yes"){=0A=
    setCookie("HW_Reload","no",null);=0A=
    if (navigator.appName=3D=3D"Netscape" || =
(navigator.platform.toLowerCase().indexOf('mac')!=3D-1))=0A=
      window.onload=3Dhw_reloadFunc;=0A=
    else=0A=
      window.location.reload();=0A=
  }=0A=
}=0A=
=0A=
/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        windowlib.js=0A=
 *  Created:     2002-04-07 by sweber=0A=
 *  Description: file for virtual folders html dialogs (vf compatibility)=0A=
 *               window communication functions=0A=
 *=0A=
 *  $Id: windowlib.js 154835 2010-05-04 15:20:21Z sweber $=0A=
 * </file>=0A=
 */=0A=
=0A=
if (!window.FILE_WINDOWLIBJS_INCLUDED) {=0A=
  /**=0A=
   * This function returns true if the ui is generated in Hyperwave =
Explorer.=0A=
   *=0A=
   * @return: boolean: is hwe context or not=0A=
   */=0A=
  function isHwe() {=0A=
  	if(top.external && typeof top.external.HWEisHWEBrowser =3D=3D =
"boolean" && top.external.HWEisHWEBrowser) {=0A=
  		return true;=0A=
  	}=0A=
  	else {=0A=
  		return false;=0A=
  	}=0A=
  }=0A=
  =0A=
  /**=0A=
   * This function returns the current version of the Hyperwave Explorer =
if the=0A=
   * ui is generated in hwe.=0A=
   *=0A=
   * @return: string: the hwe version=0A=
   */=0A=
  function getHweVersion() {=0A=
  	if(isHwe()) {=0A=
  		return top.external.HWEGetHWEVersion();=0A=
  	}=0A=
  	else {=0A=
  	  return "";=0A=
  	}=0A=
  }=0A=
    =0A=
  /**=0A=
   * close the current window=0A=
   *=0A=
   * @return: ...: return value of window.close()=0A=
   */=0A=
  function window_close() {=0A=
    if (isHwe()) {=0A=
  	 return top.external.HWECloseWindow(0);=0A=
    }=0A=
=0A=
    return top.close();=0A=
  }=0A=
  =0A=
  /**=0A=
   * change the window size=0A=
   *=0A=
   * @param x: number: width of window=0A=
   * @param y: number: height of window=0A=
   *=0A=
   * @return: ...: return value of resize=0A=
   */=0A=
  function window_resizeTo(x, y) {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWEResizeTo(x, y);=0A=
    }=0A=
    try=0A=
    {=0A=
      return top.resizeTo(x, y);=0A=
    }=0A=
    catch (e) {};=0A=
  }=0A=
=0A=
  /**=0A=
   * change the window size=0A=
   *=0A=
   * @param x: number: width of window=0A=
   * @param y: number: height of window=0A=
   *=0A=
   * @return: ...: return value of resize=0A=
   */=0A=
  function window_resizeBy(x, y) {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWEResizeBy(x, y);=0A=
    }=0A=
=0A=
    return top.resizeBy(x, y);=0A=
  }=0A=
=0A=
  function window_moveTo(x, y) {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWEMoveTo(x, y);=0A=
    }=0A=
=0A=
    return top.moveTo(x, y);=0A=
  }=0A=
=0A=
  function window_moveBy(x, y) {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWEMoveBy(x, y);=0A=
    }=0A=
=0A=
    return top.moveBy(x, y);=0A=
  }=0A=
=0A=
  function window_focus() {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWESetFocus("");=0A=
    }=0A=
=0A=
    return top.focus();=0A=
  }=0A=
=0A=
  /**=0A=
   * This function executes a reload in listview.=0A=
   */=0A=
  function listview_reload() {=0A=
    if (isHwe()) {=0A=
    	return top.external.HWEListviewReload("");=0A=
    }=0A=
    =0A=
    var ref =3D _getListView();=0A=
    if (ref !=3D null) {=0A=
      ref.location.replace(ref.location + "");=0A=
      return true;=0A=
    }=0A=
    else {=0A=
      return false;=0A=
    }=0A=
  }=0A=
  =0A=
  /**=0A=
   * This function loads an object path into the listview.=0A=
   */=0A=
  function listview_navigate(theObjectPath) {=0A=
    if (isHwe()) {=0A=
      return top.external.HWEListviewNavigate(theObjectPath);=0A=
    }=0A=
    =0A=
    var ref =3D _getListView();=0A=
    if (ref !=3D null) {=0A=
      ref.location.href =3D theObjectPath;=0A=
      return true;=0A=
    }=0A=
    else {=0A=
      return false;=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * opens a new window=0A=
   *=0A=
   * @param url: string: url of page=0A=
   * @param name: string: window name=0A=
   * @param style: string: the window style=0A=
   *=0A=
   * @return: object: the window object=0A=
   */=0A=
  function window_open(url, name, style) {=0A=
    if (isHwe()) {=0A=
  	 return top.external.HWEOpenWindow(url, name || "", style || "", =
arguments[3] || false /* replace */, arguments[4] || false /* modal */);=0A=
    }=0A=
    =0A=
    return open(url, name, style);=0A=
  }=0A=
=0A=
  /**=0A=
   * set a string into a form element of another window (e.g. opener)=0A=
   *=0A=
   * @param args: object: function parameters=0A=
   * @param args.windowName: string: the name of the window ("opener" is =
default)=0A=
   * @param args.formName: string: name of the formular=0A=
   * @param args.elementName: string: name of the element=0A=
   * @param args.elementValue: string: value of the element to set=0A=
   * @param args.setFocus: boolean: set focus after execute the given =
element=0A=
   * @param args.type: string("set"|"get"): is it a set or a get =
operation?=0A=
   *=0A=
   * @return (type =3D=3D "set"): boolean: operation successfull=0A=
   * @return (type =3D=3D "get"): strint: value of the field=0A=
   */=0A=
  function window_transfer(args)=0A=
  {=0A=
    var pars =3D args || {};=0A=
    if (isHwe()) {=0A=
      if (pars.type =3D=3D "set")=0A=
      {=0A=
        var ret =3D top.external.HWESetFormElementValue("parent", =
pars.formName, pars.elementName, pars.elementValue);=0A=
=0A=
        var form_str =3D 'document.forms["' + pars.formName + '"]';=0A=
        var elem_str =3D form_str + '.elements["' + pars.elementName + =
'"]';=0A=
        var func_str =3D elem_str + '.onchange';=0A=
        var code =3D ["if (" + form_str + " && " + elem_str + " && " + =
func_str + ") {",=0A=
                    "  " + func_str + "()",=0A=
                    "}"];=0A=
        top.external.HWEExecScript("parent", code.join("\n"));=0A=
=0A=
        if (pars.setFocus) { // set focus=0A=
        	top.external.HWESetFocus("parent", pars.formName, =
pars.elementName);=0A=
        }=0A=
        return ret;=0A=
      }=0A=
      else if (pars.type =3D=3D "get")=0A=
      {=0A=
        return top.external.HWEGetFormElementValue("parent", =
pars.formName, pars.elementName);=0A=
      }=0A=
      throw 'Error: No type or unsupported type for function =
"window_transfer" given.';=0A=
    }=0A=
    =0A=
    var the_window =3D top.opener;=0A=
    if (!the_window || typeof(the_window) !=3D "object" || =
the_window.closed)=0A=
    { // window doesn't exist or is unknown=0A=
      return pars.type =3D=3D "get" ? "" : false;=0A=
    }=0A=
    var the_form =3D eval("the_window.document." + pars.formName);=0A=
    if (!the_form || typeof(the_form) !=3D "object")=0A=
    { // form doesn't exist=0A=
      return pars.type =3D=3D "get" ? "" : false;=0A=
    }=0A=
    var the_element =3D the_form[pars.elementName];=0A=
    if (!the_element || typeof(the_element) !=3D "object")=0A=
    { // form doesn't exist=0A=
      return pars.type =3D=3D "get" ? "" : false;=0A=
    }=0A=
    if (pars.type =3D=3D "set")=0A=
    { // assign the value=0A=
      the_element.value =3D pars.elementValue;=0A=
      if (pars.setFocus &&=0A=
         (typeof the_element.focus =3D=3D "function" || /* non-msie */=0A=
          typeof the_element.focus =3D=3D "object" && the_element.focus =
&& the_element.focus.call /* msie */))=0A=
      { // set focus=0A=
        try {=0A=
          the_element.focus();=0A=
        }=0A=
        catch (exc) {}=0A=
      }=0A=
      if (the_element.onchange)=0A=
      { // trigger onchange=0A=
        the_element.onchange();=0A=
      }=0A=
      return true;=0A=
    }=0A=
    else if (pars.type =3D=3D "get")=0A=
    { // return the value=0A=
      return the_element.value || "";=0A=
    }=0A=
    throw "Error: No type for function \"window_transfer\" given.";=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * returns the selected objects from the main window=0A=
   *=0A=
   * @param args: object: function parameters=0A=
   * @param args.errMsg: string: error message=0A=
   *=0A=
   * @return: array: array of selected objects=0A=
   */=0A=
  function window_getSelectedObjects(args) {=0A=
    if (isHwe()) {=0A=
      return eval(top.external.HWEGetSelectedObjectsString());=0A=
    }=0A=
    =0A=
    if (top.opener && typeof top.opener =3D=3D "object" && =
!top.opener.closed) {=0A=
      var g_listing =3D top.opener.top.gListing;=0A=
      if (typeof g_listing !=3D "undefined") {=0A=
        return g_listing.getSelectedObjects();=0A=
      }=0A=
    }=0A=
    else if (args && args.errMsg) {=0A=
      alert(errMsg);=0A=
    }=0A=
    return [];=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * parse a string to get the form name and element name=0A=
   *=0A=
   * @param str: string: string to parse (e.g. "insertform['x']" or =
"insertform.x")=0A=
   *=0A=
   * @return object: return object=0A=
   * @return object.formName: name of form (e.g. "insertform")=0A=
   * @return object.elementName: name of element (e.g. "x")=0A=
   */=0A=
  function window_parseFormAndElementName(str)=0A=
  {=0A=
    var ret_obj =3D {formName: "", elementName: ""};=0A=
    var tmp =3D str.match(/(^.+\[\d+\])\s*([\.\[])(.+)/); // was form =
name  specfied with forms[0] or forms[1] etc. ?=0A=
    if (tmp =3D=3D null) {=0A=
      tmp =3D str.match(/([^\.\[\s]+)\s*([\.\[])(.+)/); // no, form name =
was specified as string like "myform"=0A=
    }=0A=
  =0A=
    ret_obj.formName =3D tmp[1];=0A=
    if (tmp[2] =3D=3D ".")=0A=
    {=0A=
      var idx =3D str.lastIndexOf(".");=0A=
      ret_obj.formName =3D str.substring(0,idx).replace(/\s+/g,"");=0A=
      ret_obj.elementName =3D str.substring(idx + 1).replace(/\s+/g,"");=0A=
    }=0A=
    else if (tmp[2] =3D=3D "[")=0A=
    {=0A=
      ret_obj.elementName =3D tmp[3].match(/([\"\'])(.+)\1/)[2];=0A=
    }=0A=
    return ret_obj;=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * is a special escaping function (for passing string through urls)=0A=
   * @see: ./hwlib.js=0A=
   *=0A=
   * @param str: string: string to escape=0A=
   * @return string: escaped string=0A=
   */=0A=
  function window_escape(str)=0A=
  {=0A=
    return encodeURIComponent(str).replace(/~/g, "%7E").replace(/\%/g, =
"~");=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * the special unescaping function (for passing string through urls)=0A=
   * @see: ./hwlib.js=0A=
   *=0A=
   * @param str: string: escaped string=0A=
   * @return string: unescaped string=0A=
   */=0A=
  function window_unescape(str)=0A=
  {=0A=
    return decodeURIComponent(str.replace(/\~/g, "%"));=0A=
  }=0A=
  =0A=
  var window_old_status_ =3D null;=0A=
  function window_setStatus(str)=0A=
  {=0A=
    var is_IE =3D typeof(document.all) !=3D "undefined";=0A=
    if (is_IE)=0A=
    {=0A=
      window_old_status_ =3D status;=0A=
      if (!str)=0A=
      {=0A=
        str =3D document.location.href;=0A=
        var action_separator =3D (str.indexOf(";") > 0 ? =
str.indexOf(";") : str.length);=0A=
        str =3D str.substring(0,action_separator);=0A=
      }=0A=
      window.status =3D decodeURIComponent(str);=0A=
      return true;=0A=
    }=0A=
    return false;=0A=
  }=0A=
  =0A=
  function window_resetStatus()=0A=
  {=0A=
    if (window_old_status_ !=3D null)=0A=
    {=0A=
      status =3D window_old_status_;=0A=
    }=0A=
    return true;=0A=
  }=0A=
  =0A=
  /**=0A=
   * This function loads an url into the opener location.=0A=
   *=0A=
   * @param args: object: parameter object=0A=
   * @param args.url: string | void: the target url (if empty the =
current url will be used -> reload)=0A=
   * @param args.op: boolean | false: set location in opener window=0A=
   * @return boolean: success or not=0A=
   */=0A=
  function window_setLocation(args)=0A=
  {=0A=
    var args =3D args || {};=0A=
    try {=0A=
      var ref =3D top;=0A=
      if (args.op) {=0A=
        // execute on opener=0A=
        try {=0A=
          ref =3D top.opener.top.frames.HW_Subframe.frames.HW_Mainframe;=0A=
        }=0A=
        catch (e) {=0A=
          ref =3D top.opener;=0A=
        }=0A=
      }=0A=
  =0A=
      if (args.url) {=0A=
        ref.location.href =3D args.url;=0A=
      }=0A=
      else {=0A=
        ref.location.replace(ref.location.href);=0A=
      }=0A=
    }=0A=
    catch (e) {=0A=
      return false;=0A=
    }=0A=
    return true;=0A=
  }=0A=
  =0A=
  /**=0A=
   * Reloads the opener window.=0A=
   *=0A=
   * @param args.keepUrl: boolean | false: should the url be the same as =
before the reload.=0A=
   *                                       otherwise the action will be =
truncated=0A=
   * @return boolean: success or not=0A=
   */=0A=
  function window_reloadOpener(args)=0A=
  {=0A=
    var args =3D args || {};=0A=
    try {=0A=
      if (top.window.opener) {=0A=
        var locRef =3D top.window.opener.location;=0A=
  =0A=
        if (top.window.opener.top.frames.HW_Subframe &&=0A=
            =
top.window.opener.top.frames.HW_Subframe.frames.HW_Mainframe) {=0A=
          locRef =3D =
top.window.opener.top.frames.HW_Subframe.frames.HW_Mainframe.location;=0A=
        }=0A=
  =0A=
        var openloc =3D locRef.href;=0A=
  =0A=
        if (!args.keepUrl) {=0A=
          var intidx =3D openloc.indexOf(';internal');=0A=
          if (intidx !=3D -1) {=0A=
            openloc =3D openloc.substring(0, intidx);=0A=
          }=0A=
          openloc +=3D ';internal&Parameter=3D' + new Date().valueOf();=0A=
          var context =3D top.window.opener.top.gCurrentContext;=0A=
          if (context) {=0A=
            openloc +=3D "&ctx=3D" + context;=0A=
          }=0A=
        }=0A=
  =0A=
        locRef.replace(openloc);=0A=
      }=0A=
    }=0A=
    catch (e) {=0A=
      return false;=0A=
    }=0A=
    return true;=0A=
  }=0A=
  =0A=
  /**=0A=
   * debug function for client side debug=0A=
   */=0A=
  function window_debug() {=0A=
    function htmlEscape(str) {=0A=
      return (str + "").replace(/(\<|\>|\&|\"|\'|\n|\r)/g,=0A=
                                function (match, c) {=0A=
                                  if (c =3D=3D "<") {=0A=
                                    return "&lt;";=0A=
                                  }=0A=
                                  if (c =3D=3D ">") {=0A=
                                    return "&gt;";=0A=
                                  }=0A=
                                  if (c =3D=3D "&") {=0A=
                                    return "&amp;";=0A=
                                  }=0A=
                                  if (c =3D=3D '"') {=0A=
                                    return "&quot;";=0A=
                                  }=0A=
                                  return "&#" + c.charCodeAt(0) + ";";=0A=
                                });=0A=
    }=0A=
    =0A=
    if (window_debug.window) {=0A=
      var win =3D window_debug.window;=0A=
      var doc =3D win.document;=0A=
    }=0A=
    else {=0A=
      window_debug.window =3D window.open("", "debug", =
"height=3D800,width=3D300,top=3D0,left=3D0,resizable=3Dyes,scrollbars=3Dy=
es");=0A=
      var win =3D window_debug.window;=0A=
      var doc =3D win.document;=0A=
      var start_html =3D ["",=0A=
                        "<html>",=0A=
                        "<head>",=0A=
                        "<title>DEBUG</title>",=0A=
                        "</head>",=0A=
                        "<body style=3D'font-family: courier; font-size: =
80%; margin: 0px;'>",=0A=
                        ""].join("");=0A=
      =0A=
      doc.open();=0A=
      doc.writeln(start_html);=0A=
    }=0A=
=0A=
    var ctr =3D win.ctr_ || (win.ctr_ =3D 0);=0A=
    win.ctr_ ++;=0A=
=0A=
    var style =3D "border-bottom: 1px dashed gray; padding-bottom: 1px; =
white-space: pre-wrap;";=0A=
    if (window_debug.last_date !=3D document.lastModified) {=0A=
      window_debug.last_date =3D document.lastModified;=0A=
      style +=3D " border-top: 1px dashed red;";=0A=
    }=0A=
    try {=0A=
      var stack =3D new Error().stack || "";=0A=
      stack =3D stack.replace(/^\(/mg, "???(");=0A=
      stack =3D stack.replace(/^/mg, " ~ ");=0A=
    }=0A=
    catch (exc) {=0A=
      var stack =3D "";=0A=
    }=0A=
=0A=
    var id =3D "stack_" + ctr;=0A=
    var oc =3D "var s =3D document.getElementById('" + id + "').style; =
s.display =3D s.display =3D=3D 'none' ? 'block' : 'none';";=0A=
=0A=
    doc.write("<div style=3D'" + htmlEscape(style) + "' onclick=3D'" + =
htmlEscape(oc) + "'>");=0A=
    for (var i =3D 0; i < arguments.length; i ++) {=0A=
      var type =3D typeof arguments[i];=0A=
      var curr =3D htmlEscape(arguments[i]);=0A=
      curr =3D =
curr.replace(/\b(window|document|onload|onunload|onresize)\b|(\-+(\&gt\;)=
+|(\&lt\;)+\-+)/g,=0A=
                          function (match, m1, m2) {=0A=
                            if (m1) {=0A=
                              return "<u>" + m1 + "</u>";=0A=
                            }=0A=
                            if (m2) {=0A=
                              return "<b style=3D'color: red;'>" + m2 + =
"</b>";=0A=
                            }=0A=
                            return match;=0A=
                          });=0A=
      if (type =3D=3D "string") {=0A=
        doc.write(curr);=0A=
      }=0A=
      else {=0A=
        doc.write("<i title=3D'" + htmlEscape(type) + "'>" + curr + =
"</i>");=0A=
      }=0A=
    }=0A=
    doc.writeln("</div>");=0A=
    doc.writeln("<div id=3D'" + htmlEscape(id) + "' style=3D'display: =
none; font-weight: bold; white-space: pre-wrap;'>" + htmlEscape(stack) + =
"</div>");=0A=
    =0A=
    win.scrollTo(0, 1e6);=0A=
  }=0A=
=0A=
  /* This is an object to hold some debug functions - kind of oop */=0A=
  $debug =3D {};=0A=
=0A=
  $debug.writeln =3D window_debug;=0A=
  =0A=
  /**=0A=
   * This function returns some properties of a given object.=0A=
   *=0A=
   * <xmp>=0A=
   * $debug.getProperties(x, ["x", "y"]); // returns "x =3D ...\ny =3D =
..."=0A=
   * $debug.getProperties(obj, ["client", "offset", "scroll"], ["Width", =
"Height", "Top", "Left"]);=0A=
   *   // returns "clientWith =3D ...\nclientHeight =3D ...\nclientTop =
=3D ...\nclientLeft =3D ...\n..."=0A=
   * </xmp>=0A=
   * =0A=
   * @param obj: Object: the object to test=0A=
   * @param propName1: string[]: list of property names=0A=
   * @param propName2: string[]|void: list of property postfixes=0A=
   * @return: string: the debug information=0A=
   */=0A=
  $debug.getProperties =3D function (obj, propName1, propName2) {=0A=
    var res =3D [];=0A=
    (propName1 || []).each(function (prop1) {=0A=
        (propName2 || [""]).each(function (prop2) {=0A=
            var key =3D prop1 + prop2;=0A=
            res.push([key, obj[key]].join(" =3D "));=0A=
          });=0A=
      });=0A=
    return res.join("\n");=0A=
  };=0A=
=0A=
  /**=0A=
   * This method returns all dimension properties of an object.=0A=
   * e.g. clientWith, clientHeight, ...=0A=
   *=0A=
   * @param obj: Object: the object to test=0A=
   * @return: string: the debug information=0A=
   */=0A=
  $debug.getDimensions =3D function (obj) {=0A=
    return "id =3D " +obj.identify() +=0A=
      "\n" +=0A=
      $debug.getProperties(obj, ["client", "offset", "scroll"], =
["Width", "Height", "Top", "Left"]) +=0A=
      "\n" +=0A=
      "style_width =3D " + obj.getStyle("width") +=0A=
      "\n" +=0A=
      "style_height =3D " + obj.getStyle("height") +=0A=
      "\n" +=0A=
      "width =3D " + obj.getWidth() +=0A=
      "\n" +=0A=
      "height =3D " + obj.getHeight();=0A=
  };=0A=
=0A=
  /**=0A=
   * This method calls a given function periodically and write the output=0A=
   * into a debug window.=0A=
   *=0A=
   * @param func: function: the debug function=0A=
   */=0A=
  $debug.watchFunction =3D function (func, _id) {=0A=
    var id =3D _id || "watch_object_" + new Date().valueOf();=0A=
=0A=
    var cache =3D this.watchFunction.cache || (this.watchFunction.cache =
=3D {});=0A=
    var win =3D cache[id];=0A=
=0A=
    if (!cache[id] || cache[id].closed) {=0A=
      cache[id] =3D window.open("about:blank", id, =
"height=3D300,width=3D300");=0A=
      var win_ =3D cache[id];=0A=
      addToOnunload(function () { win_.close(); });=0A=
    }=0A=
    var win =3D cache[id];=0A=
    var doc =3D win.document;=0A=
    =0A=
    doc.open("text/plain");=0A=
    doc.writeln(func());=0A=
    doc.close();=0A=
    =0A=
    if (!_id) {=0A=
      var interval =3D setInterval(function () {=0A=
          try {=0A=
            $debug.watchFunction(func, id);=0A=
          }=0A=
          catch (exc) {=0A=
            clearInterval(interval);=0A=
          }=0A=
        }, 1000);=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   * This method write request properties of a given object to a=0A=
   * debug window periodically. This is similar as method `getProperties`=0A=
   * but the output is directly written into a debug window.=0A=
   *=0A=
   * @param obj: Object: the object to test=0A=
   * @param propName1: string[]: list of property names=0A=
   * @param propName2: string[]|void: list of property postfixes=0A=
   */=0A=
  $debug.watchObject =3D function (obj, propName1, propName2) {=0A=
    this.watchFunction(function () {=0A=
        return $debug.getProperties(obj, propName1, propName2);=0A=
      });=0A=
  };=0A=
  =0A=
  /**=0A=
   * This function calls an other function in opener window and returns =
the return value.=0A=
   * Only strings can be handled by this function.=0A=
   * Maybe you can use eval() and =
com.hyperwave.util.ObjectExt.static_.toSource() on client side.=0A=
   * Up to 9 parameters can be handled.=0A=
   *=0A=
   * @param theFunctionName: string: the function name to call in opener=0A=
   * @param p1: string | void: the 1st parameter=0A=
   * @param p2: string | void: the 2nd parameter=0A=
   * @param p3: string | void: the 3rd parameter=0A=
   * @param p4: string | void: the 4th parameter=0A=
   * @param p5: string | void: the 5th parameter=0A=
   * @param p6: string | void: the 6th parameter=0A=
   * @param p7: string | void: the 7th parameter=0A=
   * @param p8: string | void: the 8th parameter=0A=
   * @param p9: string | void: the 9th parameter=0A=
   *=0A=
   * @return string: the return value=0A=
   */=0A=
  function window_executeInOpener(theFunctionName) {=0A=
    if (isHwe()) {=0A=
      var code =3D theFunctionName + "(";=0A=
      for (var i =3D 1; i < arguments.length; i ++)=0A=
      {=0A=
        code +=3D 'decodeURIComponent("';=0A=
        code +=3D encodeURIComponent(arguments[i]);=0A=
        code +=3D '")';=0A=
        if (i < (arguments.length-1))=0A=
        {=0A=
          code +=3D ", ";=0A=
        }=0A=
      }=0A=
      code +=3D ")";=0A=
      return =
decodeURIComponent(top.external.HWEExecScriptFunction('parent', code));=0A=
    }=0A=
    =0A=
    // parameter check=0A=
    if (arguments.length > 10) {=0A=
      throw 'To much arguments for function call "' + theFunctionName + =
'" in window_executeInOpener!';=0A=
    }=0A=
  =0A=
    if (typeof theFunctionName !=3D 'string') {=0A=
      throw 'Wrong parameters for window_executeInOpener! 1st argument =
must be typeof string.';=0A=
    }=0A=
    =0A=
    for (var i =3D 1; i < arguments.length; i ++) {=0A=
      if (typeof arguments[i] !=3D 'undefined' && typeof arguments[i] =
!=3D 'string') {=0A=
        throw 'Wrong parameters for window_executeInOpener! ' + i + '. =
argument must be typeof string.';=0A=
      }=0A=
    }=0A=
  =0A=
    try {=0A=
      if (navigator.appName =3D=3D "Microsoft Internet Explorer") { // =
apply didn't worked in FF=0A=
        var ret =3D top.opener[theFunctionName].call(top.opener, =
arguments[1] || ''=0A=
                                                             , =
arguments[2] || ''=0A=
                                                             , =
arguments[3] || ''=0A=
                                                             , =
arguments[4] || ''=0A=
                                                             , =
arguments[5] || ''=0A=
                                                             , =
arguments[6] || ''=0A=
                                                             , =
arguments[7] || ''=0A=
                                                             , =
arguments[8] || ''=0A=
                                                             , =
arguments[9] || '');=0A=
      }=0A=
      else { // call didn't worked in IE=0A=
        var new_args =3D [];=0A=
        for (var i =3D 1; i < arguments.length; i ++) {=0A=
          new_args.push(arguments[i]);=0A=
        }=0A=
        var ret =3D top.opener[theFunctionName].apply(top.opener, =
new_args);=0A=
      }=0A=
    }=0A=
    catch (e) {=0A=
      // If something goes wrong here, check the function called above. =
It seems it is not possible=0A=
      // to catch an error or exception of the opener window. So an =
exception can happen but cannot be catched here.=0A=
      throw 'Error calling function "' + theFunctionName + '" in =
window_executeInOpener!\n\n' + e;=0A=
    }=0A=
  =0A=
    if (typeof ret =3D=3D 'undefined' || ret =3D=3D null) {=0A=
      ret =3D '';=0A=
    }=0A=
    else if (typeof ret =3D=3D 'boolean' || typeof ret =3D=3D 'number') {=0A=
      ret =3D ret.toString();=0A=
    }=0A=
    else if (typeof ret !=3D 'string') {=0A=
      throw 'Wrong return value of called function "' + theFunctionName =
+ '" in window_executeInOpener! Must be typeof string.';=0A=
    }=0A=
  =0A=
    return ret;=0A=
  }=0A=
  =0A=
  /**=0A=
   * This is a shortcut to function window_transfer with type "get".=0A=
   * @param theFormName: string: the form name=0A=
   * @param theElementName: string: the element name=0A=
   *=0A=
   * @return string: the element value=0A=
   */=0A=
  function window_getFormValueFromOpener(theFormName, theElementName) {=0A=
    return window_transfer({type: "get",=0A=
                            formName: theFormName,=0A=
                            elementName: theElementName});=0A=
  }=0A=
  =0A=
  /**=0A=
   * This is a shortcut to function window_transfer with type "set".=0A=
   * @param theFormName: string: the form name=0A=
   * @param theElementName: string: the element name=0A=
   * @param theElementValue: string: the element value=0A=
   *=0A=
   * @return boolean: success or not=0A=
   */=0A=
  function window_setFormValueInOpener(theFormName, theElementName, =
theElementValue) {=0A=
    return window_transfer({type: "set",=0A=
                            formName: theFormName,=0A=
                            elementName: theElementName,=0A=
                            elementValue: theElementValue});=0A=
  }=0A=
  =0A=
  /**=0A=
   * This function returns the reference to the listview.=0A=
   *=0A=
   * @return: window|null: the window reference to listview=0A=
   */=0A=
  function _getListView() {=0A=
    var ref =3D top;=0A=
    try {=0A=
      while (ref.name !=3D "HW_Mainwindow") {=0A=
        if (!ref.opener || ref.opener.closed) {=0A=
          return;=0A=
        }=0A=
        ref =3D ref.opener.top;=0A=
      }=0A=
      =0A=
      if (ref.frames.HW_Subframe &&=0A=
          ref.frames.HW_Subframe.frames.HW_Mainframe) {=0A=
        ref =3D ref.frames.HW_Subframe.frames.HW_Mainframe;=0A=
      }=0A=
      else {=0A=
        ref =3D null;=0A=
      }=0A=
    }=0A=
    catch (exc) {=0A=
      // alert(exc + "");=0A=
      ref =3D null;=0A=
    }=0A=
    return ref;=0A=
  }=0A=
  =0A=
  isHWE =3D isHwe;=0A=
  getHWEVersion =3D getHweVersion;=0A=
  =0A=
  function adjustForHWE() {=0A=
    if (isHwe()) {=0A=
      // tell the HWE, that the JS compatibility code is already defined=0A=
      if (typeof top.external.HWESetCompatibilityVersion !=3D =
"undefined") { // necessary because type is "unknown"?!=0A=
        top.external.HWESetCompatibilityVersion(1);=0A=
      }=0A=
=0A=
      // for web context, this function is defined in =
webapp/lib/reloadandclose.html=0A=
      // function defined as anonymous so that javascript interpreter =
does not overwrite the function definition=0A=
      // in reloadandclose.html (function definition are searched on =
parsing js files and used regarless the=0A=
      // if statement is true or false) see also HVF/PR-866=0A=
      window_reloadandclose =3D function () {=0A=
        return top.external.HWECloseWindow(1);=0A=
      };=0A=
=0A=
      // the following function is not provided in templates=0A=
      hwvfSendMsg =3D function (recipient, msg, bAppend) {=0A=
        top.external.HWESendMessage(recipient, msg, bAppend || false);=0A=
      };=0A=
    }=0A=
=0A=
    if (isHwe()) {=0A=
      //hwvfListViewNavigate =3D listViewNavigate =3D listview_navigate;=0A=
      //hwvfListViewReload =3D listViewReload =3D listview_reload;=0A=
      window.open =3D hwvfWindowOpen =3D window_open;=0A=
      window.focus =3D hwvfFocus =3D window_focus;=0A=
      window.moveBy =3D hwvfWindowMoveBy =3D window_moveBy;=0A=
      window.moveTo =3D hwvfWindowMoveTo =3D window_moveTo;=0A=
      window.resizeBy =3D hwvfWindowResizeBy =3D window_resizeBy;=0A=
      window.resizeTo =3D hwvfWindowResizeTo =3D window_resizeTo;=0A=
      window.close =3D hwvfclose =3D window_close;=0A=
=0A=
      hwvfreloadandclose =3D window_reloadandclose;=0A=
      hwvfWindowTransfer =3D window_transfer;=0A=
      hwvfGetSelectedObjects =3D window_getSelectedObjects;=0A=
      hwvfExecuteInOpener =3D window_executeInOpener;=0A=
    }=0A=
  };=0A=
  adjustForHWE();=0A=
  =0A=
}=0A=
window.FILE_WINDOWLIBJS_INCLUDED =3D true;=0A=
=0A=
/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        cswindowlib.js=0A=
 *  Created:     2003-05-16 by sweber=0A=
 *  Description: collection of function to handle the window events =
"onload", "onunload", "onresize"=0A=
 *=0A=
 *  $Id: cswindowlib.js 153885 2010-03-24 17:54:55Z sweber $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * This function sizes the iframe with the passed id so that the whole =
content is visible.=0A=
 * Is for example used in cluster handling and for (full) collection =
heads=0A=
 *=0A=
 * @param theFrame: object: iframe object that should be sized=0A=
 */=0A=
=0A=
function sizeframe(theFrame)=0A=
{=0A=
  function findFooter() {=0A=
    var divs =3D document.getElementsByTagName("div");=0A=
    for (var i =3D divs.length - 1; i >=3D 0; i --) {=0A=
      if (divs[i].className =3D=3D "DisplayAreaFooter") {=0A=
        return divs[i];=0A=
      }=0A=
    }=0A=
    return null;=0A=
  }=0A=
=0A=
  if (theFrame.contentWindow.document.body.tagName =3D=3D "FRAMESET" ||=0A=
      theFrame.hw_displayAsFrameSet) {=0A=
    var footer =3D findFooter();=0A=
    if (footer && document.getElementsByTagName("iframe").length =3D=3D =
1) {=0A=
      // if the current view contains just one iframe,=0A=
      // than the frameset should be sized=0A=
      // that the footer is visible without any scrollbars=0A=
      addToOnresize(function () {=0A=
            theFrame.style.height =3D (document.body.offsetHeight - =
footer.offsetHeight) + "px";=0A=
        })(); // return value is the function itself and will be =
executed once immediatly=0A=
    }=0A=
    else {=0A=
      theFrame.style.height =3D "100%";=0A=
    }=0A=
    var d_ =3D theFrame.ownerDocument;=0A=
    var w_ =3D d_.defaultView || d_.parentWindow;=0A=
    if (w_.frameElement) {=0A=
      w_.frameElement.hw_displayAsFrameSet =3D true;=0A=
    }=0A=
    return;=0A=
  }=0A=
=0A=
  try {=0A=
    var doc =3D theFrame.contentWindow.document;=0A=
    var dummy =3D doc.createElement("div");=0A=
    doc.body.appendChild(dummy);=0A=
=0A=
    var has_body_style =3D false;=0A=
    try { // maybe we get an access denied when an external style sheet =
is linked=0A=
      if (doc.styleSheets) {=0A=
        for (var i =3D 0; i < doc.styleSheets.length; i ++) {=0A=
          var rules =3D doc.styleSheets[i].cssRules || =
doc.styleSheets[i].rules; // one for FF and one for IE=0A=
          for (var j =3D 0; j < rules.length; j ++) {=0A=
            var a_rule =3D rules[j];=0A=
            if (a_rule.selectorText &&=0A=
                a_rule.selectorText.toLowerCase() =3D=3D "body") {=0A=
              var dummy2 =3D doc.createElement("div");=0A=
  =0A=
              if (a_rule.style.margin && =
a_rule.style.margin.match(/[1-9]/)) { // has a value not zero=0A=
                has_body_style =3D true;=0A=
                dummy2.style.margin =3D a_rule.style.margin;=0A=
              }=0A=
              if (a_rule.style.borderWidth && =
a_rule.style.borderWidth.match(/[1-9]/)) {=0A=
                has_body_style =3D true;=0A=
                dummy2.style.border =3D a_rule.style.border;=0A=
              }=0A=
              if (a_rule.style.padding && =
a_rule.style.padding.match(/[1-9]/)) {=0A=
                has_body_style =3D true;=0A=
                dummy2.style.padding =3D a_rule.style.padding;=0A=
              }=0A=
  =0A=
              if (has_body_style) {=0A=
                dummy.appendChild(dummy2);=0A=
              }=0A=
            }=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
    catch (exc) {=0A=
    }=0A=
=0A=
    var height1=3Ddummy.offsetTop + (has_body_style ? dummy.offsetHeight =
: 0);=0A=
    var height2=3Ddoc.body.scrollHeight;=0A=
    if (height2<=3D300)=0A=
    {  // 300 is the initial height of iframe. When the size is less =
than this=0A=
       // the scroll information is no longer correct=0A=
      height2=3Dheight1;=0A=
    }=0A=
=0A=
    var new_height =3D Math.max(height1, height2);=0A=
    theFrame.style.height =3D new_height + "px";=0A=
    doc.body.removeChild(dummy);=0A=
    doc.body.style.overflowX =3D "auto";=0A=
    doc.body.style.overflowY =3D "hidden";=0A=
=0A=
    var test_height =3D Math.max(doc.body.scrollHeight, =
doc.body.parentNode.scrollHeight);=0A=
    if (test_height > new_height) {=0A=
      theFrame.style.height =3D test_height + "px";=0A=
    }=0A=
    return;=0A=
  }=0A=
  catch (e) {=0A=
  }=0A=
  =0A=
  try=0A=
  {=0A=
    var id =3D theFrame.id;=0A=
    var element=3Ddocument.getElementById(id);=0A=
    if (navigator.appName.indexOf("Netscape")!=3D-1)=0A=
    {=0A=
      try=0A=
      {=0A=
        var h=3Deval(id+".document.body.offsetHeight");=0A=
      }=0A=
      catch(e)=0A=
      { // in this case [id].document is not defined, we assume the =
initial height=0A=
        h=3D300;=0A=
      }=0A=
      =0A=
      if (h!=3D300)=0A=
      {=0A=
        element.style.height =3D (h + 35) + "px";=0A=
      }=0A=
      else=0A=
      {=0A=
        element.style.height =3D (h+element.contentWindow.scrollMaxY+35) =
+ "px";=0A=
      }=0A=
    }=0A=
    else=0A=
    {=0A=
      var element2=3Deval(id);=0A=
      element.style.height =3D element2.document.body.scrollHeight + =
"px";=0A=
    }=0A=
  }=0A=
  catch(e) {=0A=
  }=0A=
}=0A=
=0A=
function hw_htmlEscape(string)=0A=
{=0A=
  if (typeof string !=3D "string")=0A=
    string +=3D "";=0A=
  return string.=0A=
  replace(/&/g, "&amp;").=0A=
  replace(/</g, "&lt;").=0A=
  replace(/>/g, "&gt;").=0A=
  replace(/\"/g, "&quot;").=0A=
  replace(/\'/g, "&#39;");=0A=
}=0A=
=0A=
function hw_htmlUnescape(string)=0A=
{=0A=
  if (typeof string !=3D "string")=0A=
    string +=3D "";=0A=
=0A=
  return =
string.replace(/&(lt|gt|quot|amp|#(\d{1,5})|#x([0-9a-fA-F]{1,4}));/g,=0A=
                        function (match, key, deccode, hexcode) {=0A=
                          if (hexcode) {=0A=
                            return String.fromCharCode(parseInt(hexcode, =
16));=0A=
                          }=0A=
                          if (deccode) {=0A=
                            return String.fromCharCode(parseInt(deccode, =
10));=0A=
                          }=0A=
                          if (key =3D=3D "amp") {=0A=
                            return "&";=0A=
                          }=0A=
                          if (key =3D=3D "quot") {=0A=
                            return "\"";=0A=
                          }=0A=
                          if (key =3D=3D "gt") {=0A=
                            return ">";=0A=
                          }=0A=
                          if (key =3D=3D "lt") {=0A=
                            return "<";=0A=
                          }=0A=
                          return match;=0A=
                        });=0A=
}=0A=
=0A=
/* this function escapes ALL characters with an char code <=3D31 and =
char code >=3D127=0A=
 * by &#charcode;=0A=
 */=0A=
function hw_htmlEscapeStrong(string)=0A=
{=0A=
  if (typeof string !=3D "string")=0A=
    string +=3D "";=0A=
  string =3D hw_htmlEscape(string);=0A=
  =0A=
  var ret =3D "";=0A=
  var string_length =3D string.length;=0A=
  for (var i=3D0; i<string_length; i++)=0A=
  {=0A=
    var charcode =3D string.charCodeAt(i);=0A=
    if (charcode < 32 || charcode > 126)=0A=
    {=0A=
      ret +=3D "&#x" + charcode.toString(16) + ";";=0A=
    }=0A=
    else=0A=
    {=0A=
      ret +=3D string.charAt(i);=0A=
    }=0A=
  }=0A=
  return ret;=0A=
}=0A=
=0A=
/* this function escapes the string if it is not already escaped=0A=
 */=0A=
function hw_htmlEscapeStrongIfNotEncoded(string)=0A=
{=0A=
  if (hw_isHtmlEscaped(string)) {=0A=
    return string;=0A=
  }=0A=
  else {=0A=
    return hw_htmlEscapeStrong(string);=0A=
  }=0A=
}=0A=
=0A=
/* this function tests if the string is already escaped=0A=
 */=0A=
function hw_isHtmlEscaped(string)=0A=
{=0A=
  if (typeof string !=3D "string")=0A=
    return false;=0A=
  =0A=
  if (string.indexOf("&") !=3D -1) {=0A=
    if (string.indexOf("&amp;")  !=3D -1 ||=0A=
        string.indexOf("&lt;")  !=3D -1 ||=0A=
        string.indexOf("&gt;")  !=3D -1 ||=0A=
        string.indexOf("&quot;")  !=3D -1 ||=0A=
        string.indexOf("&#39;")  !=3D -1) {=0A=
      return true;=0A=
    }=0A=
    if (string.search(/\&\#x\d{2,4};/) !=3D -1) {=0A=
      return true;=0A=
    }=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
=0A=
/**=0A=
 * This function escape a string for use in js strings.=0A=
 * mode 0: CR -> \r, LF -> \n, \ -> \\, ' -> \', " -> \"=0A=
 * mode 1: CR -> \r, LF -> \n, \ -> \\=0A=
 *=0A=
 * @param string: string: string to escape=0A=
 * @param mode: number | 0: mode for escapenig=0A=
 *=0A=
 * @return: string: escaped string=0A=
 */=0A=
function escapeString(string, mode)=0A=
{=0A=
  if (!string)=0A=
    return "";=0A=
  if (mode & 1) {=0A=
    var re =3D /([\r\n\\])/g;=0A=
  }=0A=
  else {=0A=
    var re =3D /([\"\'\r\n\\])/g;=0A=
  }=0A=
  return string.replace(re, function (theMatch, theChar) {=0A=
    switch (theChar) {=0A=
      case "\r": return "\\r";=0A=
      case "\n": return "\\n";=0A=
      default: return "\\" + theChar;=0A=
    }=0A=
  });=0A=
}=0A=
=0A=
/**=0A=
 * This function unescape a string as complement to escapeString.=0A=
 * mode 0: \r -> CR, \n -> LF, \\ -> \, \' -> ', \" -> "=0A=
 * mode 1: \r -> CR, \n -> LF, \\ -> \=0A=
 *=0A=
 * @param string: string: string to unescape=0A=
 * @param mode: number | void (0): mode for unescapenig=0A=
 *=0A=
 * @return: string: unescaped string=0A=
 */=0A=
function unescapeString(string, mode)=0A=
{=0A=
  if (!string)=0A=
    return "";=0A=
  if (mode & 1) {=0A=
    var re =3D /\\([\\nr])/g;=0A=
  }=0A=
  else {=0A=
    var re =3D /\\([\"\'\\nr])/g;=0A=
  }=0A=
  return string.replace(re, function (theMatch, theChar) {=0A=
    switch (theChar) {=0A=
      case "r": return "\r";=0A=
      case "n": return "\n";=0A=
      default: return theChar;=0A=
    }=0A=
  });=0A=
}=0A=
=0A=
/**=0A=
 * This function checks the given number and returns a number=0A=
 * greater equals 0.=0A=
 *=0A=
 * @param x: number: a number=0A=
 * @return: a number at least 0=0A=
 */=0A=
function hw_min0(x) {=0A=
  if (isNaN(x)) {=0A=
    return 0;=0A=
  }=0A=
  else {=0A=
    return Math.max(0, x - 0);=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * This function returns a px value derived from the given input=0A=
 * but at least 0.=0A=
 *=0A=
 * @param x: number: a number to be converted to `x`px=0A=
 * @return: string: the px value=0A=
 */=0A=
function hw_min0px(x) {=0A=
  return hw_min0(x) + "px";=0A=
}=0A=
=0A=
if (!window.FILE_CSWINDOWLIBJS_INCLUDED) {=0A=
=0A=
  window.HW_pageLoaded =3D false;=0A=
=0A=
  CSWINDOWLIBJS_CATCHERRORS =3D false;=0A=
  // global onload array=0A=
  ONLOAD_ARRAY_FIRST =3D [];=0A=
  ONLOAD_ARRAY =3D [];=0A=
  ONLOAD_ARRAY_LAST =3D [];=0A=
=0A=
  // global onunload array=0A=
  ONUNLOAD_ARRAY_FIRST =3D [];=0A=
  ONUNLOAD_ARRAY =3D [];=0A=
  ONUNLOAD_ARRAY_LAST =3D [];=0A=
  =0A=
  // global onresize array=0A=
  ONRESIZE_ARRAY_FIRST =3D [];=0A=
  ONRESIZE_ARRAY =3D [];=0A=
  ONRESIZE_ARRAY_LAST =3D [];=0A=
  =0A=
  function cswindowlib_doIt(execArray) {=0A=
    for (var i =3D 0; i < execArray.length; i ++) {=0A=
      var exec =3D execArray[i];=0A=
=0A=
      if (CSWINDOWLIBJS_CATCHERRORS) {=0A=
        try {=0A=
          if (typeof exec =3D=3D "string") {=0A=
            eval(exec);=0A=
          }=0A=
          else {=0A=
            exec();=0A=
          }=0A=
        }=0A=
        catch (e) {=0A=
          alert(e.name + ': ' + e.message);=0A=
        }=0A=
      }=0A=
      else {=0A=
        if (typeof exec =3D=3D "string") {=0A=
          eval(exec);=0A=
        }=0A=
        else {=0A=
          exec();=0A=
        }=0A=
      }=0A=
    }=0A=
  }=0A=
  =0A=
  // overwrite the onload function=0A=
  Event.observe(window, "load", function () {=0A=
    cswindowlib_doIt(ONLOAD_ARRAY_FIRST);=0A=
    cswindowlib_doIt(ONLOAD_ARRAY);=0A=
    cswindowlib_doIt(ONLOAD_ARRAY_LAST);=0A=
=0A=
    window.HW_pageLoaded =3D true;=0A=
    });=0A=
  =0A=
  // overwrite the onunload function=0A=
  Event.observe(window, "beforeunload", function () {=0A=
      Event.stopObserving(window, "beforeunload", arguments.callee);=0A=
=0A=
      ONUNLOAD_ARRAY.unshift(window.onunload || function () {});=0A=
      =0A=
      window.onunload =3D function () {=0A=
        window.HW_pageLoaded =3D false;=0A=
        =0A=
        cswindowlib_doIt(ONUNLOAD_ARRAY_FIRST);=0A=
        cswindowlib_doIt(ONUNLOAD_ARRAY);=0A=
        cswindowlib_doIt(ONUNLOAD_ARRAY_LAST);=0A=
      };=0A=
    });=0A=
   =0A=
  // overwrite the onresize function=0A=
  Event.observe(window, "resize", function () {=0A=
    cswindowlib_doIt(ONRESIZE_ARRAY_FIRST);=0A=
    cswindowlib_doIt(ONRESIZE_ARRAY);=0A=
    cswindowlib_doIt(ONRESIZE_ARRAY_LAST);=0A=
    });=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * handler for onload's=0A=
   *=0A=
   * @param aFuncStr: string: string to eval onload=0A=
   * @param aHint: enum string: enum that handles when the function will =
be called=0A=
   *                    addToOnload.FIRST : the function is called =
before functions with aHint NORMAL or LAST=0A=
   *                    addToOnload.NORMAL: the function is called after =
functions with aHint FIRST and=0A=
   *                              befor functions with aHint LAST=0A=
   *                    addToOnload.LAST  : the function is called after =
functions with aHint FIRST or NORMAL=0A=
   */=0A=
  function addToOnload(aFuncStr,aHint) {=0A=
    if (aFuncStr) {=0A=
      if (aHint && aHint=3D=3DaddToOnload.FIRST)=0A=
      {=0A=
        ONLOAD_ARRAY_FIRST[ONLOAD_ARRAY_FIRST.length] =3D aFuncStr;=0A=
      }=0A=
      else if (aHint && aHint=3D=3DaddToOnload.LAST)=0A=
      {=0A=
        ONLOAD_ARRAY_LAST[ONLOAD_ARRAY_LAST.length] =3D aFuncStr;=0A=
      }=0A=
      else=0A=
      {=0A=
        ONLOAD_ARRAY[ONLOAD_ARRAY.length] =3D aFuncStr;=0A=
      }=0A=
    }=0A=
    return aFuncStr;=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * handler for onunload's=0A=
   *=0A=
   * @param aFuncStr: string: string to eval onunload=0A=
   * @param aHint: enum string: enum that handles when the function will =
be called=0A=
   *                    addToOnunload.FIRST : the function is called =
before functions with aHint NORMAL or LAST=0A=
   *                    addToOnunload.NORMAL: the function is called =
after functions with aHint FIRST and=0A=
   *                              befor functions with aHint LAST=0A=
   *                    addToOnunload.LAST  : the function is called =
after functions with aHint FIRST or NORMAL=0A=
   */=0A=
  function addToOnunload(aFuncStr,aHint) {=0A=
    if (aFuncStr) {=0A=
      if (aHint && aHint=3D=3DaddToOnunload.FIRST)=0A=
      {=0A=
        ONUNLOAD_ARRAY_FIRST[ONUNLOAD_ARRAY_FIRST.length] =3D aFuncStr;=0A=
      }=0A=
      else if (aHint && aHint=3D=3DaddToOnunload.LAST)=0A=
      {=0A=
        ONUNLOAD_ARRAY_LAST[ONUNLOAD_ARRAY_LAST.length] =3D aFuncStr;=0A=
      }=0A=
      else=0A=
      {=0A=
        ONUNLOAD_ARRAY[ONUNLOAD_ARRAY.length] =3D aFuncStr;=0A=
      }=0A=
    }=0A=
    return aFuncStr;=0A=
  }=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * handler for onresize's=0A=
   *=0A=
   * @param aFuncStr: string: string to eval onresize=0A=
   * @param aHint: enum string: enum that handles when the function will =
be called=0A=
   *                    addToOnresize.FIRST : the function is called =
before functions with aHint NORMAL or LAST=0A=
   *                    addToOnresize.NORMAL: the function is called =
after functions with aHint FIRST and=0A=
   *                              befor functions with aHint LAST=0A=
   *                    addToOnresize.LAST  : the function is called =
after functions with aHint FIRST or NORMAL=0A=
   */=0A=
  function addToOnresize(aFuncStr,aHint) {=0A=
    if (aFuncStr) {=0A=
      if (aHint && aHint=3D=3DaddToOnresize.FIRST)=0A=
      {=0A=
        ONRESIZE_ARRAY_FIRST[ONRESIZE_ARRAY_FIRST.length] =3D aFuncStr;=0A=
      }=0A=
      else if (aHint && aHint=3D=3DaddToOnresize.LAST)=0A=
      {=0A=
        ONRESIZE_ARRAY_LAST[ONRESIZE_ARRAY_LAST.length] =3D aFuncStr;=0A=
      }=0A=
      else=0A=
      {=0A=
        ONRESIZE_ARRAY[ONRESIZE_ARRAY.length] =3D aFuncStr;=0A=
      }=0A=
    }=0A=
    return aFuncStr;=0A=
  }=0A=
=0A=
  //define constants to use for the addToxxx functions=0A=
  =0A=
  addToOnresize.FIRST =3D addToOnunload.FIRST =3D addToOnload.FIRST =
=3D"FIRST";=0A=
  addToOnresize.NORMAL =3D addToOnunload.NORMAL =3D addToOnload.NORMAL =
=3D"NORMAL";=0A=
  addToOnresize.LAST =3D addToOnunload.LAST =3D addToOnload.LAST =
=3D"LAST";=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Calling this function, an interval will be started checking the=0A=
   * opener window. When the opener window is closed, the current window=0A=
   * will be closed automatically.=0A=
   */=0A=
  function closeOnOpenerClose()=0A=
  {=0A=
    function checkOpener() {=0A=
      try {=0A=
        if (!window.opener || window.opener.closed) {=0A=
          window_close();=0A=
        }=0A=
      }=0A=
      catch (e) {=0A=
        window_close();=0A=
      }=0A=
    }=0A=
    setInterval(checkOpener, 250);=0A=
  }=0A=
}=0A=
=0A=
addToOnload(adjustForHWE,addToOnload.FIRST);=0A=
=0A=
window.FILE_CSWINDOWLIBJS_INCLUDED =3D true;=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/util/KeyValueMap.js?cachekeY=515488b2-en

/*=0A=
 * <file>=0A=
 *  Name:    KeyValueMap.js=0A=
 *  Purpose: Creates a Key-Value map which maps string keys=0A=
 *           to arrays of string values.=0A=
 *=0A=
 *  Created: 1999-09-01=0A=
 *  $Id: KeyValueMap.js 162833 2011-05-05 11:05:55Z sweber $=0A=
 * </file>=0A=
*/=0A=
initPackage ( "com.hyperwave.util" );=0A=
=0A=
//------------------------------------------------------------=0A=
/**=0A=
 * A class for managing maps from string keys to arrays=0A=
 * of values for parameter definitions.=0A=
 *=0A=
 * @author Christian Fessl=0A=
 * @author Simon Zwoelfer=0A=
**/=0A=
//------------------------------------------------------------=0A=
// <JSClass Name=3D"KeyValueMap">=0A=
=0A=
  //----------------------------------------------------------=0A=
  /**=0A=
   * Constructor for this class.=0A=
   * @examplecall my_obj =3D new KeyValueMap()=0A=
  **/=0A=
  com.hyperwave.util.KeyValueMap =3D function ( theParams )=0A=
  {=0A=
    if ( theParams =3D=3D "__proto__" && typeof theParams =3D=3D =
"string" )=0A=
      return;=0A=
=0A=
    this.map_ =3D new Object(); // hold the key-value pairs=0A=
    this.serialize_ =3D false; // do not serialize values by default=0A=
    this.valueSort_ =3D true; // sort values of each key before sending =
by default=0A=
    this.isCaseInsensitive_ =3D false;=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.util.KeyValueMap );=0A=
	=0A=
  /**=0A=
   * Solves some problems occuring by bad firewalls.=0A=
   * ";" --> "%3B" and "&" --> "%26" were converted by some firewalls.=0A=
   * Now they are converted back to their original values.=0A=
   *=0A=
   * @param  String: aParametersString: the parameters part of an URL=0A=
   * @return String: the converted parameters part of the URL=0A=
  **/=0A=
  class$._solveFirewallProblem =3D function (aParametersString)=0A=
  {=0A=
    var converted_par_str =3D "";=0A=
    var split =3D aParametersString.split("=3D");=0A=
=0A=
    if (split.length > 0)=0A=
    {=0A=
      converted_par_str +=3D split[0] + "=3D";=0A=
      for (var k=3D0; k<split.length; k++)=0A=
      {=0A=
        var and_position =3D split[k].lastIndexOf("%26");=0A=
        if (and_position !=3D -1)=0A=
        {=0A=
          var prev_value =3D split[k].substring(0,and_position);=0A=
          var next_key   =3D split[k].substr(and_position+3);=0A=
          converted_par_str +=3D prev_value + "&" +  next_key + "=3D";=0A=
        }=0A=
      }=0A=
      converted_par_str +=3D split[split.length-1];=0A=
    }=0A=
=0A=
    return converted_par_str;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns only the parameter part of an URL.=0A=
   * @param  String: anUrl: the URL called by the browser=0A=
   * @return String: the parameter string of the URL=0A=
   * @examplecall=0A=
   *   =
this._getKeyValueMapFromUrl("http://www.server.com;p1=3D1&p2=3D2&p3=3D3")=0A=
   *   results in "p1=3D1&p2=3D2&p3=3D3"=0A=
  **/=0A=
  class$._getParameterStringFromUrl =3D function (anUrl)=0A=
  {=0A=
    var par_str =3D "";=0A=
=0A=
    var found_position_of_questionmark =3D anUrl.indexOf("?");=0A=
    var found_position_of_semicolon =3D anUrl.indexOf(";");=0A=
    var found_position_of_unescaped_semicolon =3D anUrl.indexOf("%3B");=0A=
    var found_position_of_hash =3D anUrl.indexOf("#");=0A=
=0A=
    if (found_position_of_hash !=3D -1) {=0A=
      var url_ =3D anUrl.substr(0, found_position_of_hash);=0A=
    }=0A=
    else {=0A=
      var url_ =3D anUrl;=0A=
    }=0A=
=0A=
    if (found_position_of_questionmark !=3D -1) {=0A=
      if (found_position_of_semicolon !=3D -1) {=0A=
        var pos =3D found_position_of_semicolon;=0A=
        if (found_position_of_questionmark < =
found_position_of_semicolon) {=0A=
          pos =3D found_position_of_questionmark;=0A=
        }=0A=
        par_str =3D url_.substr(pos + 1);=0A=
        par_str =3D par_str.replace(";", "&");=0A=
        par_str =3D par_str.replace("?", "&");=0A=
      }=0A=
      else {=0A=
        par_str =3D url_.substr(found_position_of_questionmark + 1);=0A=
      }=0A=
    }=0A=
    else {=0A=
      if (found_position_of_semicolon !=3D -1) {=0A=
        par_str =3D url_.substr(found_position_of_semicolon + 1);=0A=
      }=0A=
      else {=0A=
        if (found_position_of_unescaped_semicolon !=3D -1) {=0A=
          // firewall problem by ";" --> "%3B" and "&" --> "%26"=0A=
          par_str =3D url_.substr(found_position_of_unescaped_semicolon =
+ 3);=0A=
          par_str =3D this._solveFirewallProblem(par_str);=0A=
        } // firewall problem solved=0A=
      }=0A=
    }=0A=
=0A=
    return par_str;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Adds a key value pair to the map. Note that all other=0A=
   * values remain in the map and are not changed. Regardless=0A=
   * to the existence of a same value the given value will=0A=
   * simply be added to the array of values for this key.=0A=
   * @param  String: aKey: contains the name which should have=0A=
   *   at leas the given value.=0A=
   * @param  String: aValue: is the value which should be=0A=
   *   added for the key.=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueField();=0A=
   *   my_params.addKeyValue ( "firstPar", 1 );=0A=
   *   my_params.addKeyValue ( "firstPar", 2 );=0A=
  **/=0A=
  class$.addKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      this.map_[aKey][this.map_[aKey].length] =3D aValue;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.map_[aKey] =3D new Array();=0A=
      this.map_[aKey][0] =3D aValue;=0A=
    }=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Deletes a key and ist associated values from the map.=0A=
   * @param  String: aKey: the key which should be deleted.=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueField();=0A=
   *   my_params.addUrlParameters ( window.location.href );=0A=
   *=0A=
   *   // assure that there is no Key: "line":=0A=
   *   my_params.deleteKey ( "line" );=0A=
  **/=0A=
  class$.deleteKey =3D function (aKey)=0A=
  {=0A=
    if (this.map_[aKey])=0A=
      delete this.map_[aKey];=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Assures that the map contains exactly one key (with the name=0A=
   * aKey) with one corresponsing value=0A=
   * @param  String: aKey: contains the name which should have=0A=
   *   the given value.=0A=
   * @param  String: aValue: defines the value.=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueField();=0A=
   *   my_params.addKeyValue ( "firstPar", 1 );=0A=
   *   my_params.addKeyValue ( "firstPar", 2 );=0A=
   *=0A=
   *   // ... some processing with my_params ...=0A=
   *=0A=
   *   // now assure that firstPar has exactly one value:=0A=
   *   my_params.setKeyValue ( "firstPar", "only_this_value" );=0A=
=0A=
  **/=0A=
  class$.setKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    this.map_[aKey] =3D new Array();=0A=
    this.map_[aKey][0] =3D aValue;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Splits the parameter string into its keys and values=0A=
   * and adds them to the map as this is done in addUrlParameters.=0A=
   * Note: the values are added regardless to their existence within=0A=
   * the map!=0A=
   * @param  String: theParams: the Parameters in String represenation=0A=
   * @return Object of type Parameters=0A=
   * @examplecall=0A=
   *   var my_par =3D new KeyValueMap ();=0A=
   *   my_par.addParameters ( =
"key1=3Dvalue1&key1=3Dvalue2&key2=3Dvalue3" );=0A=
   *=0A=
  **/=0A=
  class$.addParameterString =3D function ( theParams )=0A=
  {=0A=
    if (theParams) {=0A=
      var my_key_values_array =3D theParams.split("&");=0A=
      for (var i=3D0; i<my_key_values_array.length; i++) {=0A=
        var key_value_pair =3D my_key_values_array [i].split("=3D");=0A=
        if (key_value_pair.length =3D=3D 2) {=0A=
          var temp_value =3D =
decodeURIComponent(key_value_pair[1].replace (/\+/g, ' '));=0A=
          if (this.serialize_ =3D=3D true) {=0A=
            eval("var evaluated_value =3D " + temp_value);=0A=
          }=0A=
          else {=0A=
            var evaluated_value =3D temp_value;=0A=
          }=0A=
          if (this.isCaseInsensitive_) {=0A=
            =
this.addKeyValue(decodeURIComponent(key_value_pair[0]).toLowerCase(),=0A=
                             evaluated_value );=0A=
          }=0A=
          else {=0A=
            this.addKeyValue(decodeURIComponent(key_value_pair[0]),=0A=
                             evaluated_value );=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Fetches all availabe parameters from the given URL string=0A=
   * and puts them into this KeyValueMap. The parameters are=0A=
   * detected with the following algorithm:=0A=
   * <ol>=0A=
   * <li>Detect the parameter string:=0A=
   *  <ul>=0A=
   *  <li>If there is a question mark, take the string after=0A=
   *      the question mark and process the parameters.=0A=
   *  <li>Otherwise: if there is a semicolon, treat all characters=0A=
   *      after the semicolon as parameter string and=0A=
   *      process them.=0A=
   *  <li>Otherwise: if there is an escaped semicolon (which=0A=
   *      is in fact the string "%3B" then take the characters=0A=
   *      which follow this string. In this case take care=0A=
   *      of escaped "=3D" and "&" characters too.=0A=
   *  </ul>=0A=
   * <li>Extract the parameters by splitting the whole=0A=
   *     string by its "&" characters. Subsequently use=0A=
   *     the first "=3D" character within the resulting=0A=
   *     string fragments as end for the key string=0A=
   *     and beginning for the value string. The=0A=
   *     general form of parameter strings is then:=0A=
   *     <pre>=0A=
   *      key1=3Dvalue11&key1=3Dvalue12&key...=0A=
   *     </pre>=0A=
   * </ul>=0A=
   * Note: the values are added regardless to their existence within=0A=
   * the map!=0A=
   *=0A=
   * @param  String: theUrl: the URL containing the parameters.=0A=
   *   which should be added.=0A=
   * @examplecall=0A=
   *   // Client Example: get URL of window, add=0A=
   *   //   a parameter and make a link ...=0A=
   *   var my_par =3D new KeyValueMap ();=0A=
   *   my_par.addUrlParameters ( window.location.href );=0A=
   *   my_par.addKeyValue ( "key10", "value10" );=0A=
   *   document.writeln ( "<a href=3D'" +=0A=
   *                      window.loaction.pathname + ";" +=0A=
   *                      my_par.getParameterString () );=0A=
  **/=0A=
  class$.addUrlParameters =3D function ( theUrl )=0A=
  {=0A=
    this.addParameterString(this._getParameterStringFromUrl(theUrl));=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Checks if a given key exists which has at least the=0A=
   * desired value.=0A=
   * @param String: aKey: contains the name of the parameter=0A=
   * @param Object: aValue: contains the desired value=0A=
   * @return Boolean: true, if the key aKey exists and one of=0A=
   *   its values is equal to aValue. Otherwise false will be=0A=
   *   returned.=0A=
   * @examplecall .containsKeyValue("my_key","my_value")=0A=
  **/=0A=
  class$.containsKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    var ret =3D false;=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      for (var i=3D0; i<this.map_[aKey].length; i++)=0A=
      {=0A=
        if (this.map_[aKey][i] =3D=3D aValue)=0A=
        {=0A=
          ret =3D true;=0A=
          break;=0A=
        }=0A=
      }=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns an array of strings containing all keys with at=0A=
   * least one value (domain set).=0A=
   * @return Array: an array of strings containing the keys=0A=
   *   which have at least one value.=0A=
   * @examplecall=0A=
   *   URL: http://www.server.com/module;p1=3D1&p1=3D2&p2=3D5&p3=3D10=0A=
   *=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   var my_keys =3D my_params.getKeys();=0A=
   *=0A=
   *   Result: my_keys =3D ["p1", "p2", "p3"]=0A=
   **/=0A=
  class$.getKeys =3D function ()=0A=
  {=0A=
    var ret =3D new Array();=0A=
    for (var x in this.map_)=0A=
    {=0A=
      ret[ret.length] =3D x;=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the number of keys with at least one value which=0A=
   * are present.=0A=
   * @return Integer: number of keys with at least one value=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   var number_of_keys =3D my_params.getNumberOfKeys();=0A=
   *   writeln("Number of Keys sent: " + number_of_keys);=0A=
   **/=0A=
  class$.getNumberOfKeys =3D function ()=0A=
  {=0A=
    var ret =3D 0;=0A=
    for (var x in this.map_)=0A=
    {=0A=
      ret =3D ret + 1;=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Checks if a given key with at least one value is present.=0A=
   * @param  String: aKey: contains the name of the parameter=0A=
   * @return Boolean: true, if <i>aKey</i> has at least one=0A=
   *   value within the map.=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   if ( my_params.containsKey("param1") )=0A=
   *   {=0A=
   *     writeln("param1 exists!");=0A=
   *   }=0A=
  **/=0A=
  class$.containsKey =3D function (aKey)=0A=
  {=0A=
    var ret =3D false;=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      ret =3D true;=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the number of values of a given key.=0A=
   * @param String: aKey: contains the name of the parameter=0A=
   * @return Integer: representing the number of values to that key=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   var number_of_values =3D my_params.getNumberOfValues("param1");=0A=
   *   writeln("Number of values to key: " + number_of_values);=0A=
   **/=0A=
  class$.getNumberOfValues =3D function (aKey)=0A=
  {=0A=
    var ret =3D 0;=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      ret =3D this.map_[aKey].length;=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns all values of a given key.=0A=
   * @param  String: aKey: contains the name of the parameter=0A=
   * @return Array: an array of strings containing all values=0A=
   *   of the given key.=0A=
   *   <b>Note</b> that this array can contain multiple=0A=
   *   entries with the same value.=0A=
   * @examplecall=0A=
   *   URL: http://www.server.com/module;p1=3D1&p1=3D2&p2=3D5&p3=3D10=0A=
   *=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   my_values =3D my_params.getAllValues("p1");=0A=
   *=0A=
   *   Result: my_values =3D ["1", "2"]=0A=
  **/=0A=
  class$.getAllValues =3D function (aKey)=0A=
  {=0A=
    var ret =3D new Array();=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      ret =3D this.map_[aKey];=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  /**=0A=
   * This is a shortcut for getAllValues.=0A=
   *=0A=
   * @see #getAllValues=0A=
   */=0A=
  class$.getValues =3D function (aKey)=0A=
  {=0A=
    return this.getAllValues(aKey);=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * If a key has exactly one value it will be returned, if there=0A=
   * are more than one values only one value will be selected in a=0A=
   * nondeterministic way.=0A=
   * @param String: aKey: contains the name of the parameter=0A=
   * @return Object: contains one value of the given key=0A=
   * @examplecall=0A=
   *   var my_params =3D new KeyValueMap();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   writeln( "param1: one value =3D " + =
my_params.getOneValue("param1") );=0A=
  **/=0A=
  class$.getOneValue =3D function (aKey)=0A=
  {=0A=
    var ret =3D null;=0A=
    if (this.map_[aKey])=0A=
    {=0A=
      if (this.map_[aKey].length > 0)=0A=
      {=0A=
        ret =3D this.map_[aKey][0];=0A=
      }=0A=
    }=0A=
    return ret;=0A=
  };=0A=
=0A=
  /**=0A=
   * This is a shortcut for getAllValue.=0A=
   *=0A=
   * @see #getAllValue=0A=
   */=0A=
  class$.getValue =3D function (aKey)=0A=
  {=0A=
    return this.getOneValue(aKey);=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Clones a KeyValueMap at the level of keys. This means, that=0A=
   * a new KeyValueMap will be returned with new keys BUT=0A=
   * references to the values. If the values are strings=0A=
   * or only key-manipulations are done this is sufficient.=0A=
   *=0A=
   * @param Array: theExclList: array of string keys which=0A=
   *   should not be contained in the resulting map.=0A=
   * @return KeyValueMap: a new KeyValueMap containing all=0A=
   *   keys and their corresponding values but the keys in=0A=
   *   the exclusion list=0A=
  **/=0A=
  class$.clone =3D function ( theExclList )=0A=
  {=0A=
    var out =3D new com.hyperwave.util.KeyValueMap;=0A=
    var look_up =3D {};=0A=
    if (theExclList) {=0A=
      for ( var i =3D 0; i < theExclList.length; ++i )=0A=
        look_up [theExclList [i]] =3D true;=0A=
    }=0A=
=0A=
    var key_array =3D this.getKeys ();=0A=
=0A=
    for ( var i =3D 0; i < key_array.length; ++i )=0A=
    {=0A=
      var key =3D key_array [i];=0A=
      if ( look_up [key] )=0A=
        continue;=0A=
=0A=
      var values =3D this.getAllValues (key);=0A=
      for ( var j =3D 0; j < values.length; ++j )=0A=
        out.addKeyValue ( key, values [j] );=0A=
    }=0A=
    return out;=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Create a parameter-string which is unique for this=0A=
   * set of parameters (sorted by keys and values). This=0A=
   * string can be appended to an URL for transmitting ...=0A=
   * Note: This function is the inverse function of=0A=
   *   addParameterString. It <i>can</i> be used=0A=
   *   to &quote;serialize&quote; the state of the=0A=
   *   object which can be later de-serialized with=0A=
   *   addParameterString of an empty object!=0A=
   * @param aPrefix: string | "?": the string prefix for the returned =
parameter string=0A=
   * @return String: the key-value pairs for an URL=0A=
   * @examplecall=0A=
   *   // Client Example: get URL of window, add=0A=
   *   //   a parameter and make a link ...=0A=
   *   var my_par =3D new KeyValueMap ();=0A=
   *=0A=
   *   my_par.addUrlParameters ( "key2=3D2&key2=3D1&key1=3D2" );=0A=
   *   writeln ( my_par.getParameterString () )=0A=
   *   // would give: "key1=3D2&key2=3D1&key2=3D2" !=0A=
  **/=0A=
  class$.getParameterString =3D function (aPrefix)=0A=
  {=0A=
    var key_array =3D this.getKeys ();=0A=
    if (key_array.length=3D=3D0) return "";=0A=
    var out_arr =3D [];=0A=
    key_array.sort ();=0A=
=0A=
    for ( var i =3D 0; i < key_array.length; ++i )=0A=
    {=0A=
      var key =3D key_array [i];=0A=
      var values =3D this.getAllValues (key);=0A=
      if (this.valueSort_)=0A=
        values.sort ();=0A=
      for ( var j =3D 0; j < values.length; ++j ) {=0A=
        if (this.serialize_ =3D=3D true)=0A=
          var temp_value =3D =
com.hyperwave.util.ObjectExt.static_.toSource(values [j]);=0A=
        else=0A=
          var temp_value =3D values[j];=0A=
        var encoded_value =3D (temp_value !=3D null) ? =
encodeURIComponent(temp_value).replace ( /\+/g, "%2B" ): "null";=0A=
        out_arr [out_arr.length] =3D key + "=3D" + encoded_value;=0A=
      }=0A=
    }=0A=
    return (typeof aPrefix =3D=3D "undefined" ? "?" : aPrefix) + =
out_arr.join ( "&" );=0A=
=0A=
  };=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns a string containing a description of the status of that =
object.=0A=
   * @param  void=0A=
   * @return String: containing the status of the Parameter-object.=0A=
   * @examplecall .debugGetObjectStatus()=0A=
  **/=0A=
  class$.debugGetObjectStatus =3D function ()=0A=
  {=0A=
    var out_arr =3D [];=0A=
    var key_array =3D this.getKeys ();=0A=
=0A=
    for ( var i =3D 0; i < key_array.length; ++i )=0A=
    {=0A=
      var key =3D key_array [i];=0A=
      out_arr [out_arr.length] =3D=0A=
        "'" + key + "' =3D> '" +=0A=
        this.getAllValues (key).join ( "', '" ) + "'";=0A=
    }=0A=
    return out_arr.join ( "\n" );=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method serializing is activated.=0A=
   * all values of KeyValuePairs are serialized using =
com.hyperwave.util.ObjectExt.static_.toSource() while calling=0A=
   * the method getParameterString. with this behaviour whole objects =
are represented as string=0A=
   * and can be sent to the serevr. When calling addUrlParameters those =
string representations=0A=
   * are tried to be evaluated using "eval" before assigning as value to =
a specified key.=0A=
   *=0A=
   * @examplecall:=0A=
   * //CLIENT=0A=
   * var a1 =3D {p1:"hallo", p2:[1,"3"]};=0A=
   * var map1 =3D new KeyValueMap();=0A=
   * map1.enableSerializing();=0A=
   * map1.addKeyValue( "a", a1 );=0A=
   * var url =3D "test?" + map1.getParameterString();=0A=
   * // SERVER=0A=
   * var map2 =3D new KeyValueMap();=0A=
   * map2.enableSerializing();=0A=
   * map2.addUrlParameters( url );=0A=
   * var a2 =3D map2.getOneValue( "a" );=0A=
   * // results:=0A=
   * // a2 =3D {p1:"hallo", p2:[1,"3"]}=0A=
   * // but (a1 =3D=3D a2) returns false!=0A=
  **/=0A=
  class$.enableSerializing =3D function ()=0A=
  {=0A=
    this.serialize_ =3D true;=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method serializing is deactivated.=0A=
   * @see KeyValueMap_enableSerializing() for further details.=0A=
  **/=0A=
  class$.disableSerializing =3D function ()=0A=
  {=0A=
    this.serialize_ =3D false;=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method keys are handled case insensitive=0A=
   * when added by method 'addUrlParameters'.=0A=
   * (converted to lower case)=0A=
  **/=0A=
  class$.isCaseInsensitive =3D function ()=0A=
  {=0A=
    this.isCaseInsensitive_ =3D true;=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method keys are handled case sensitive=0A=
   * when added by method 'addUrlParameters'.=0A=
   * (no longer converted to lower case)=0A=
  **/=0A=
  class$.isCaseSensitive =3D function ()=0A=
  {=0A=
    this.isCaseInsensitive_ =3D false;=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method all values of a given key are inserted=0A=
   * in sorted order when creating the parameter string =
(getParameterString()).=0A=
   * this is also the default behaviour.=0A=
  **/=0A=
  class$.enableSort =3D function ()=0A=
  {=0A=
    this.valueSort_ =3D true;=0A=
  };=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * after calling this method all values of a given key are inserted=0A=
   * in the order they appear when creating the parameter string =
(getParameterString()).=0A=
   * this is NOT the default behaviour (default: insert in sorted order).=0A=
  **/=0A=
  class$.disableSort =3D function ()=0A=
  {=0A=
    this.valueSort_ =3D false;=0A=
  };=0A=
=0A=
=0A=
  class$.cutParametersFromUrl =3D function (anUrl)=0A=
  {=0A=
    var ind =3D anUrl.indexOf(";");=0A=
    var ind2 =3D anUrl.indexOf("?");=0A=
    if ((ind=3D=3D-1) || ((ind2!=3D-1) && (ind2<ind))) ind=3Dind2;=0A=
    if (ind > -1){=0A=
      anUrl =3D anUrl.substring(0,ind);=0A=
    }=0A=
    return anUrl;=0A=
  };=0A=
=0A=
  /**=0A=
   * The method converts the <code>KeyValueMap</code> into a plain =
javascript object=0A=
   * holding the keys as properties and the SINGLE values as values.=0A=
   *=0A=
   * @return object: the converted <code>KeyValueMap</code> instance=0A=
   */=0A=
  class$.toObject =3D function () {=0A=
    var retobj =3D {};=0A=
    var keys =3D this.getKeys();=0A=
    for (var i=3D0; i<keys.length; i++) {=0A=
    	retobj[keys[i]] =3D this.getValue(keys[i]);=0A=
    }=0A=
    return retobj;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Keep Compatibility: make alias "KeyValueMap" for =
"com.hyperwave.util.KeyValueMap"=0A=
   */=0A=
  KeyValueMap =3D com.hyperwave.util.KeyValueMap;=0A=
=0A=
// </JSClass>=0A=
//------------------------------------------------------------=0A=
=0A=
/* End of KeyValueMap.js */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/standardpage/code/csframesetscripts.js?cachekeY=515488b2-en

function setHW_MainframeUrl(url)=0A=
{=0A=
  if (window.name=3D=3D"HW_Mainframe")=0A=
  {=0A=
    top.isHyperwaveDocument=3Dtrue;=0A=
    var theurl=3Durl;=0A=
    if (theurl.charAt(0)!=3D"/")=0A=
      theurl=3D"/"+theurl;=0A=
    setCookie("HW_MainframeUrl",theurl,null);=0A=
=0A=
    addToOnunload(function () {=0A=
      top.isHyperwaveDocument =3D false;=0A=
    });=0A=
  }=0A=
}=0A=
=0A=
function reload_navigation() {=0A=
  if (top.frames.length =3D=3D 0)=0A=
    return;=0A=
  =0A=
  if =
(top.FrameSetMediator.static_.getInstance().getTreeviewState().isOn() &&=0A=
      top.HW_Navigationframe &&=0A=
      top.HW_Navigationframe.location) {=0A=
    top.HW_Navigationframe.location.replace(=0A=
        =
top.com.hyperwave.util.IncludeManager.static_.getInstance().getSrc("webap=
p/components/frameset/ui/naviframe_static.html"));=0A=
  }=0A=
}=0A=
=0A=
function stripURL (anURL)=0A=
{=0A=
  var ret_url =3D anURL || "";=0A=
  if (ret_url.indexOf(";")!=3D-1)=0A=
     ret_url =3D ret_url.substring(0,ret_url.indexOf(";"));=0A=
  if (ret_url.indexOf("?")!=3D-1)=0A=
    ret_url =3D ret_url.substring(0,ret_url.indexOf("?"));=0A=
  return ret_url;=0A=
}=0A=
=0A=
=0A=
function checkFrameSet ()=0A=
{=0A=
  var add_url =3D "";=0A=
=0A=
  add_url +=3D (top.location.search.length > 1 ? top.location.search : =
'');=0A=
  add_url +=3D (top.location.hash.length > 1 ? top.location.hash : '');=0A=
=0A=
  var uri =3D gCurrentUrl;=0A=
  if (self.innerHeight=3D=3D0 && self.innerWidth=3D=3D0) {=0A=
    return;=0A=
  }=0A=
  if (top.frames.length=3D=3D0)=0A=
  {=0A=
    setCookie("HW_MainframeUrl", "", null);=0A=
=0A=
    var kvm =3D new com.hyperwave.util.KeyValueMap();=0A=
    kvm.addParameterString(top.location.href);=0A=
    if (kvm.containsKey("action")) {=0A=
      setCookie("HW_RequestedUrlA", kvm.getOneValue("action"), null);=0A=
      setCookie("HW_RequestedUrlP", kvm.getOneValue("Parameter"), null);=0A=
    }=0A=
    else {=0A=
      setCookie("HW_RequestedUrlA", "", new Date(0));=0A=
      setCookie("HW_RequestedUrlP", "", new Date(0));=0A=
    }=0A=
=0A=
    uri =3D stripURL(uri);=0A=
    var context =3D =
(top.gCurrentContext!=3D"")?"&ctx=3D"+top.gCurrentContext:"";=0A=
    top.location.replace(uri + =
";internal&action=3Dbuildframes.action&Parameter=3D" + gUnique + context =
+ add_url);=0A=
  }=0A=
}=0A=
=0A=
function reload_userblock ()=0A=
{=0A=
  top.FrameSetMediator.static_.getInstance().applyEditMode();=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/cseditlinks.js?cachekeY=515488b2-en

var sel_mode =3D false;=0A=
var loaded =3D false;=0A=
=0A=
var bName =3D navigator.appName;=0A=
var bVer =3D parseInt(navigator.appVersion);=0A=
=0A=
=0A=
function reportmove()=0A=
{=0A=
  if (loaded && typeof document =3D=3D "object" && typeof gLW =
!=3D"undefined")=0A=
  {=0A=
    if (bName =3D=3D "Netscape")=0A=
    {=0A=
      var sel_text=3Dwindow.getSelection().toString();=0A=
      if (sel_text)=0A=
        gLW.SELTEXT=3Dsel_text;=0A=
    }=0A=
    else=0A=
    { // ie on windows=0A=
      if (sel_mode)=0A=
      {=0A=
        var rang=3Ddocument.selection.createRange();=0A=
        if (rang.text)=0A=
          gLW.SELTEXT=3Drang.text;=0A=
      }=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
function initializeLinkcreate()=0A=
{=0A=
  if (bName =3D=3D "Netscape")=0A=
  {=0A=
    if (typeof gLW !=3D "undefined")=0A=
      gLW.INBODY=3D"contained";=0A=
  }=0A=
  else=0A=
  { // ie on windows=0A=
    var divel =3D document.getElementById("thedocument");=0A=
    if(divel!=3Dnull)=0A=
    {=0A=
      el=3Ddivel;=0A=
      if (!divel.isTextEdit)=0A=
        el =3D divel.parentTextEdit;=0A=
      var rang;=0A=
      if (el !=3D null) {=0A=
        rang =3D el.createTextRange();=0A=
        rang.moveToElementText(divel);=0A=
        duprang=3Drang;=0A=
      }=0A=
    }=0A=
  }=0A=
  loaded=3Dtrue;=0A=
}=0A=
=0A=
var oldX=3D-100;=0A=
var oldY=3D-100=0A=
var inmd=3Dfalse;=0A=
function mousedown(e)=0A=
{=0A=
  if (inmd)=0A=
    return false;=0A=
  inmd=3Dtrue;=0A=
  if (bName =3D=3D "Netscape")=0A=
  {=0A=
    oldX=3De.pageX;=0A=
    oldY=3De.pageY;=0A=
  }=0A=
  inmd=3Dfalse;=0A=
  return true;=0A=
}=0A=
=0A=
function selectionstart()=0A=
{=0A=
  sel_mode=3Dtrue;=0A=
}=0A=
=0A=
inmu =3Dfalse;=0A=
function onmouseupreport(e)=0A=
{=0A=
  if (typeof gLW=3D=3D"undefined")=0A=
    return false;=0A=
  if (inmu)=0A=
    return false;=0A=
  inmu=3Dtrue;=0A=
  if (bName =3D=3D "Netscape")=0A=
  {=0A=
    if (oldY !=3D e.pageY || oldX !=3De.pageX)=0A=
    {=0A=
      if (sel_mode)=0A=
      {=0A=
        var sel_text=3D window.getSelection().toString();=0A=
        if (sel_text)=0A=
          gLW.SELTEXT=3Dsel_text;=0A=
      }=0A=
    }=0A=
    sel_mode=3Dfalse;=0A=
  }=0A=
  else =0A=
  {=0A=
    if (sel_mode)=0A=
    {=0A=
      reportmove();=0A=
      var rang =3D document.selection.createRange();=0A=
      var el =3D rang.parentElement();=0A=
      var divelement =3D document.all("thedocument");=0A=
      if(divelement=3D=3D null || (divelement!=3D null && =
divelement.contains(el)))=0A=
        gLW.INBODY=3D"contained";=0A=
      else=0A=
        gLW.INBODY=3D"not contained";=0A=
      sel_mode=3Dfalse;=0A=
    }=0A=
  }=0A=
  inmu=3Dfalse;=0A=
  return true;=0A=
}=0A=
=0A=
function getLinkWizData () {=0A=
  var data =3D {};=0A=
  data.SELTEXT =3D "";=0A=
  data.INBODY =3D "not contained";=0A=
  var cur =3D gOC.getCurrentObject();=0A=
  data.GOID =3D cur.G;=0A=
  data.THETITLE =3D cur.T;=0A=
  return data;=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/config/dmc.js?cachekeY=515488b2-en

//-------------------------------------------------------=0A=
// the default Ui Configuration=0A=
//-------------------------------------------------------=0A=
=0A=
function setDefaultDMCStyles()=0A=
{=0A=
  DMC=3D{};=0A=
  =0A=
  DMC.decoration=3D"low";=0A=
  =0A=
  if (typeof request!=3D"undefined")=0A=
  {=0A=
    var platform =3D request.agent.architecture;=0A=
    var agent    =3D request.agent.name;=0A=
  }=0A=
  else=0A=
  {=0A=
    var platform =3D navigator.platform;=0A=
    var agent    =3D navigator.appName;=0A=
  }=0A=
  platform =3D platform.toLowerCase();=0A=
  =0A=
  if (platform.indexOf('mac')!=3D-1 && agent.indexOf('Netscape')!=3D-1)=0A=
  {  //  Macintosh/Netscape =0A=
    DMC.FontFace=3D"Verdana,Arial,Helvetica";=0A=
    DMC.FontSize=3D"";=0A=
    DMC.FontSizeAbs=3D"70%";=0A=
  }=0A=
  else=0A=
  {=0A=
    if (platform.indexOf('win')!=3D-1) =0A=
    {  // Windows=0A=
      DMC.FontFace=3D"Verdana,Arial,Helvetica";=0A=
      DMC.FontSize=3D"";=0A=
      DMC.FontSizeAbs=3D"70%";=0A=
    }=0A=
    else=0A=
    {  // Unix, Macintosh/IE=0A=
      DMC.FontFace=3D"Verdana,Arial,Helvetica";=0A=
      DMC.FontSize=3D"";=0A=
      DMC.FontSizeAbs=3D"70%";=0A=
    }=0A=
  }=0A=
  =0A=
  //item settings=0A=
  DMC.ItemColor=3D"black";=0A=
  DMC.ItemBGColor=3D"#DCE4EC";=0A=
  DMC.ItemBGColorLight=3D"#E0E0E0";=0A=
  DMC.ItemSelColor=3D"black";=0A=
  DMC.ItemSelBGColor=3D"#FFFFFF";=0A=
  DMC.ItemDisColor=3D"#A0A0A0";=0A=
  =0A=
  DMC.BorderColor1=3D"white";=0A=
  DMC.BorderColor2=3D"#808080";=0A=
  DMC.BorderColor3=3D"black";=0A=
  =0A=
  //default icons=0A=
  =
DMC.CheckedIcon=3D"/wavemaster.internal/webapp/uistyle/icons/checked.gif"=
;=0A=
  =
DMC.CheckedIconInv=3D"/wavemaster.internal/webapp/uistyle/icons/checkedi.=
gif";=0A=
  DMC.ChildTIcon=3D"/wavemaster.internal/webapp/uistyle/icons/empty.gif";=0A=
  =
DMC.ChildTIconInv=3D"/wavemaster.internal/webapp/uistyle/icons/empty.gif"=
;=0A=
  DMC.ChildLIcon=3D"/wavemaster.internal/webapp/uistyle/icons/chil.gif";=0A=
  =
DMC.ChildLIconInv=3D"/wavemaster.internal/webapp/uistyle/icons/chili.gif"=
;=0A=
  DMC.ChildIconWidth=3D"1";=0A=
  DMC.CheckedIconWidth=3D"7";=0A=
  DMC.IconWidth=3D"9";=0A=
  =0A=
  //menuborder icons=0A=
  DMC.MenuLTImg=3D"/wavemaster.internal/webapp/uistyle/icons/e_left.gif";=0A=
  DMC.MenuTBG=3D"/wavemaster.internal/webapp/uistyle/icons/s_top.gif";=0A=
  DMC.MenuTImg=3D"";=0A=
  DMC.MenuImgAlignT=3D"LEFT";=0A=
  =
DMC.MenuRTImg=3D"/wavemaster.internal/webapp/uistyle/icons/e_right.gif";=0A=
  DMC.MenuLBG=3D"/wavemaster.internal/webapp/uistyle/icons/s_left.gif";=0A=
  DMC.MenuLImg=3D"";=0A=
  DMC.MenuImgAlignL=3D"TOP";=0A=
  DMC.MenuRBG=3D"/wavemaster.internal/webapp/uistyle/icons/s_right.gif";=0A=
  DMC.MenuRImg=3D"";=0A=
  DMC.MenuImgAlignR=3D"TOP";=0A=
  =
DMC.MenuLBImg=3D"/wavemaster.internal/webapp/uistyle/icons/e_lleft.gif";=0A=
  DMC.MenuBBG=3D"/wavemaster.internal/webapp/uistyle/icons/s_bottom.gif";=0A=
  DMC.MenuBImg=3D"";=0A=
  DMC.MenuImgAlignB=3D"LEFT";=0A=
  =
DMC.MenuRBImg=3D"/wavemaster.internal/webapp/uistyle/icons/e_lright.gif";=0A=
  DMC.Opener=3D"/wavemaster.internal/webapp/uistyle/icons/anop.gif";=0A=
  =
DMC.Handle=3D"/wavemaster.internal/webapp/uistyle/icons/anopiesmall.gif";=0A=
  =
DMC.Handlei=3D"/wavemaster.internal/webapp/uistyle/icons/anopiesmalli.gif=
";=0A=
  =0A=
  //image actions for full decoration=0A=
  DMC.LTIUrl=3D"";=0A=
  DMC.TIUrl=3D"";=0A=
  DMC.RTIUrl=3D"";=0A=
  DMC.LIUrl=3D"";=0A=
  DMC.RIUrl=3D"";=0A=
  DMC.LBIUrl=3D"";=0A=
  DMC.BIUrl=3D"";=0A=
  DMC.RBIUrl=3D"";=0A=
  =0A=
  //menu bg image=0A=
  DMC.MenuBGImg=3D"";=0A=
  =0A=
  //itembg images=0A=
  DMC.ItemBGImg=3D"";=0A=
  DMC.ItemSelBGImg=3D"";=0A=
  =0A=
  DMC.MenuCaptionTopOff=3D"9";=0A=
  =0A=
  //default general style=0A=
  DGC=3D {};=0A=
  =0A=
  //snapshot values=0A=
  DGC.snapshotImg =
=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/snapshotfallb=
ack.gif"; //fallback img, used if there's no mstyle snapshotURL entry=0A=
  DGC.snapshotWidth =3D"210";=0A=
  DGC.snapshotHeight =3D"63";=0A=
  =0A=
  =0A=
  //popup dialog style=0A=
  DDC=3D {};=0A=
  DDC.inborder=3Dfalse;=0A=
  DDC.ignoreDlgCap=3Dfalse;=0A=
  DDC.ignoreDlgDescr=3Dtrue;=0A=
  DDC.ignoreDlgNecessary=3Dtrue;=0A=
  DDC.logo=3D"/wavemaster.internal/webapp/uistyle/icons/hwlogo.gif";=0A=
  DDC.logoBGColor=3D"#E6E6E6";=0A=
  DDC.capBGColor=3D"#000099";=0A=
  DDC.capStyle=3D"font-size:14pt;font-family:Arial, Geneva, =
Helvetica;color:white";=0A=
  DDC.descStyle=3D"font-size:8pt;font-family:Arial, Geneva, =
Helvetica;color:white";=0A=
  //DDC.boxwidth=3D"100%";=0A=
  DDC.BGColor=3D"white";=0A=
  DDC.ItemBGColor=3D"#EAEAEA";=0A=
  DDC.Color=3D"black";=0A=
  DDC.FontFace=3D"Arial, Geneva, Helvetica";=0A=
  DDC.Caption=3D{FontSize:"14pt"};=0A=
  DDC.CaptionC=3D{FontSize:"14pt",Color:"#003399"};=0A=
  DDC.Desc=3D{FontSize:"8pt",Color:"#003399"};=0A=
  DDC.AttrValue=3D{FontSize:"10pt",Color:"#003399"};=0A=
  DDC.Warning=3D{FontSize:"10pt",Color:"#D00000"};=0A=
  DDC.AttrName=3D{FontSize:"10pt"};=0A=
  DDC.ObjList=3D{FontSize:"10pt",TextDecoration:"none"};=0A=
  DDC.ObjListC=3D{FontSize:"10pt",Color:"#003399"};=0A=
  DDC.Metadata=3D{FontSize:"10pt",Color:"#666666"};=0A=
  DDC.Titlebar=3D{FontSize:"10pt",BGColor:"#D4D4D4"};=0A=
  DDC.Selection=3D{FontSize:"10pt",Color:"#666666",BGColor:"#FFFFFF"};=0A=
  DDC.decoration=3D"full";=0A=
  =
DDC.MenuLTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
topLeft.gif";=0A=
  =
DDC.MenuTBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/to=
p.gif";=0A=
  DDC.MenuTImg=3D"";=0A=
  =
DDC.MenuRTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
topRight.gif";=0A=
  DDC.MenuLImg=3D"";=0A=
  =
DDC.MenuLBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/le=
ft.gif";=0A=
  =
DDC.MenuRImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/r=
ight.gif";=0A=
  =
DDC.MenuRBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/ri=
ght.gif";=0A=
  =
DDC.MenuLBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
bottomLeft.gif";=0A=
  =
DDC.MenuRBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
bottomRight.gif";=0A=
  =
DDC.MenuBBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bo=
ttom.gif";=0A=
  DDC.MenuBGImg=3D"";=0A=
  DDC.MenuBImg=3D"";=0A=
  //top-images for tab=0A=
  =
DDC.MenuTBGTab=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg=
/tabTop.gif";=0A=
  =
DDC.MenuRTImgTab=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogi=
mg/tabTopRight.gif";=0A=
  =0A=
  //buttons used in dialogs=0A=
  =
DDC.UpImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/butt=
on_up.png";=0A=
  =
DDC.InvUpImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/b=
utton_up.png";=0A=
  =
DDC.DownImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bu=
tton_down.png";=0A=
  =
DDC.InvDownImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg=
/button_down.png";=0A=
  =
DDC.LeftImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bu=
tton_left.png";=0A=
  =
DDC.InvLeftImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg=
/button_left.png";=0A=
  =
DDC.RightImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/b=
utton_right.png";=0A=
  =
DDC.InvRightImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogim=
g/button_right.png";=0A=
  =
DDC.TopImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/but=
ton_top.png";=0A=
  =
DDC.InvTopImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
button_top.png";=0A=
  =
DDC.BottomImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/=
button_bottom.png";=0A=
  =
DDC.InvBottomImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialogi=
mg/button_bottom.png";=0A=
  =0A=
  //default portal style=0A=
  DPC=3D {};=0A=
  //tab preview image=0A=
  =
DPC.columnratioBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/dialog=
img/columnratioBG.gif";=0A=
  =
DPC.columnratioTrackImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/=
dialogimg/columnratioTrackImg.gif";=0A=
  =
DPC.columnratioTrackImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault=
/dialogimg/columnratioTrackImg2.gif";=0A=
  =
DPC.columnratioTrackImg3=3D"/wavemaster.internal/webapp/uistyle/hwdefault=
/dialogimg/columnratioTrackImg3.gif";=0A=
  =0A=
  // userblock style=0A=
  DUC =3D {};=0A=
  DUC.breadcrumbLeftImg =3D =
"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bc_left.gif";=0A=
  DUC.breadcrumbRightImg =3D =
"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bc_right.gif";=0A=
  DUC.breadcrumbImgWidth =3D 15;=0A=
  DUC.breadcrumbImgHeight =3D 7;=0A=
  DUC.breadcrumbSepImg =3D =
"/wavemaster.internal/webapp/uistyle/hwdefault/dialogimg/bc_sep.gif";=0A=
  DUC.breadcrumbSepImgWidth =3D 12;=0A=
  DUC.breadcrumbSepImgHeight =3D 7;=0A=
  =0A=
  //popup dialog style=0A=
  ADC=3D {};=0A=
  // old color was:=0A=
  // ADC.BGColor=3D"#DEDEDE";=0A=
  ADC.BGColor=3D"#EAEAEA";=0A=
  ADC.ItemBGColor=3D"white";=0A=
  ADC.Color=3D"black";=0A=
  ADC.FontFace=3D"Arial, Geneva, Helvetica";=0A=
  ADC.Caption=3D{FontSize:"14pt"};=0A=
  ADC.CaptionC=3D{FontSize:"14pt",Color:"#003399"};=0A=
  ADC.Desc=3D{FontSize:"8pt",Color:"#003399"};=0A=
  ADC.AttrValue=3D{FontSize:"10pt",Color:"#003399"};=0A=
  ADC.AttrName=3D{FontSize:"10pt"};=0A=
  ADC.ObjList=3D{FontSize:"10pt",TextDecoration:"none"};=0A=
  ADC.ObjListC=3D{FontSize:"10pt",Color:"#003399"};=0A=
  ADC.Metadata=3D{FontSize:"10pt",Color:"#666666"};=0A=
  ADC.Titlebar=3D{FontSize:"10pt",BGColor:"#D4D4D4"};=0A=
  ADC.Selection=3D{FontSize:"10pt",Color:"#666666",BGColor:"#FFFFFF"};=0A=
  ADC.decoration=3D"full";=0A=
  =
ADC.MenuLTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/top=
Left.gif";=0A=
  =
ADC.MenuTBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/top.g=
if";=0A=
  ADC.MenuTImg=3D"";=0A=
  =
ADC.MenuRTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/top=
Right.gif";=0A=
  ADC.MenuLImg=3D"";=0A=
  =
ADC.MenuLBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/left.=
gif";=0A=
  =
ADC.MenuRImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/righ=
t.gif";=0A=
  =
ADC.MenuRBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/right=
.gif";=0A=
  =
ADC.MenuLBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/bot=
tomLeft.gif";=0A=
  =
ADC.MenuRBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/bot=
tomRight.gif";=0A=
  =
ADC.MenuBBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/botto=
m.gif";=0A=
  =
ADC.MenuLBBGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/b=
ottomLeftBG.gif";   // out border=0A=
  =
ADC.MenuRBBGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/b=
ottomRightBG.gif";=0A=
  =
ADC.MenuLTBGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/t=
opLeftBG.gif";=0A=
  =
ADC.MenuMTBGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/t=
opBG.gif";=0A=
  =
ADC.MenuRTBGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/t=
opRightBG.gif";=0A=
  =
ADC.MenuLBBGImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/=
bottomLeftBG2.gif"; // in border=0A=
  =
ADC.MenuRBBGImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/=
bottomRightBG2.gif";=0A=
  =
ADC.MenuLTBGImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/=
topLeftBG2.gif";=0A=
  =
ADC.MenuMTBGImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/=
topBG2.gif";=0A=
  =
ADC.MenuRTBGImg2=3D"/wavemaster.internal/webapp/uistyle/hwdefault/adcimg/=
topRightBG2.gif";=0A=
  ADC.MenuBGImg=3D"";=0A=
  ADC.MenuBImg=3D"";=0A=
  ADC.capBGColor=3D"#000099";=0A=
  ADC.capStyle=3D"font-size:14pt; font-family:Arial, Geneva, Helvetica; =
color:#FFFFFF;";=0A=
  ADC.AttrNameBold=3D"font-size:10pt; font-family:Arial, Geneva, =
Helvetica, sans-serif; color:black; font-weight: bold;";=0A=
  =0A=
  //help dialog style=0A=
  DHC=3D {};=0A=
  =0A=
  DHC.inborder=3Dfalse;=0A=
  DHC.ignoreDlgCap=3Dfalse;=0A=
  DHC.ignoreDlgDescr=3Dtrue;=0A=
  DHC.ignoreDlgNecessary=3Dtrue;=0A=
  DHC.logo=3D"/wavemaster.internal/webapp/uistyle/icons/hwlogo.gif";=0A=
  DHC.logoBGColor=3D"#E6E6E6";=0A=
  DHC.capBGColor=3D"#000099";=0A=
  DHC.capStyle=3D"font-size:14pt;font-family:Arial, Geneva, =
Helvetica;color:white";=0A=
  DHC.descStyle=3D"font-size:8pt;font-family:Arial, Geneva, =
Helvetica;color:white";=0A=
  //DHC.boxwidth=3D"100%";=0A=
  DHC.BGColor=3D"white";=0A=
  DHC.Color=3D"black";=0A=
  DHC.FontFace=3D"Arial, Geneva, Helvetica";=0A=
  DHC.Caption=3D{FontSize:"14pt"};=0A=
  DHC.CaptionC=3D{FontSize:"14pt",Color:"#003399"};=0A=
  DHC.Desc=3D{FontSize:"8pt",Color:"#003399"};=0A=
  DHC.AttrValue=3D{FontSize:"10pt",Color:"#003399"};=0A=
  DHC.AttrName=3D{FontSize:"10pt",BGColor:"white"};=0A=
  DHC.ObjList=3D{FontSize:"10pt",TextDecoration:"none"};=0A=
  DHC.ObjListC=3D{FontSize:"10pt",Color:"#003399"};=0A=
  DHC.Metadata=3D{FontSize:"10pt",Color:"#666666"};=0A=
  DHC.Titlebar=3D{FontSize:"10pt",BGColor:"#D4D4D4"};=0A=
  DHC.Selection=3D{FontSize:"10pt",Color:"#666666",BGColor:"#FFFFFF"};=0A=
  DHC.decoration=3D"full";=0A=
  =
DHC.MenuLTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg=
/topLeft.gif";=0A=
  =
DHC.MenuTBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg/t=
op.gif";=0A=
  DHC.MenuTImg=3D"";=0A=
  =
DHC.MenuRTImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg=
/topRight.gif";=0A=
  DHC.MenuLImg=3D"";=0A=
  =
DHC.MenuLBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg/l=
eft.gif";=0A=
  =
DHC.MenuRImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg/=
right.gif";=0A=
  =
DHC.MenuRBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg/r=
ight.gif";=0A=
  =
DHC.MenuLBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg=
/bottomLeft.gif";=0A=
  =
DHC.MenuRBImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg=
/bottomRight.gif";=0A=
  =
DHC.MenuBBG=3D"/wavemaster.internal/webapp/uistyle/hwdefault/helpdlgimg/b=
ottom.gif";=0A=
  DHC.MenuBGImg=3D"";=0A=
  DHC.MenuBImg=3D"";=0A=
  =0A=
  DSC=3D{};=0A=
  DSC.DownImg=3D"/wavemaster.internal/webapp/uistyle/icons/seqdown1.gif";=0A=
  =
DSC.DownImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/seqdown2.gif"=
;=0A=
  =
DSC.DownImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/seqdown3.gif"=
;=0A=
  =0A=
  =
DSC.FirstImg=3D"/wavemaster.internal/webapp/uistyle/icons/seqfirst1.gif";=0A=
  =
DSC.FirstImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/seqfirst2.gi=
f";=0A=
  =
DSC.FirstImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/seqfirst3.gi=
f";=0A=
  =0A=
  DSC.PrevImg=3D"/wavemaster.internal/webapp/uistyle/icons/seqprev1.gif";=0A=
  =
DSC.PrevImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/seqprev2.gif"=
;=0A=
  =
DSC.PrevImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/seqprev3.gif"=
;=0A=
  =0A=
  DSC.NextImg=3D"/wavemaster.internal/webapp/uistyle/icons/seqnext1.gif";=0A=
  =
DSC.NextImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/seqnext2.gif"=
;=0A=
  =
DSC.NextImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/seqnext3.gif"=
;=0A=
  =0A=
  DSC.LastImg=3D"/wavemaster.internal/webapp/uistyle/icons/seqlast1.gif";=0A=
  =
DSC.LastImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/seqlast2.gif"=
;=0A=
  =
DSC.LastImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/seqlast3.gif"=
;=0A=
  =0A=
  DSC.UpImg=3D"/wavemaster.internal/webapp/uistyle/icons/sequp1.gif";=0A=
  DSC.UpImgInv=3D"/wavemaster.internal/webapp/uistyle/icons/sequp2.gif";=0A=
  DSC.UpImgDis=3D"/wavemaster.internal/webapp/uistyle/icons/sequp3.gif";=0A=
}=0A=
=0A=
setDefaultDMCStyles();=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/menu_dc/code/menucommon.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: menucommon.js 164656 2011-06-28 09:55:02Z cgoess $=0A=
 */=0A=
CLIENT_SIDE =3D typeof top !=3D "undefined";=0A=
REG_EXP_SPACE =3D new RegExp("\\s+", 'g');=0A=
=0A=
//menu implementation used serverside and clientside=0A=
=0A=
=0A=
function RegisterMenu(menu)=0A=
{=0A=
  var ret =3D 0;=0A=
  var menuarr;=0A=
  if (CLIENT_SIDE) {=0A=
    if (!top.menuRegistry_) {=0A=
      top.menuRegistry_ =3D [];=0A=
    }=0A=
    var top_registry =3D top.menuRegistry_;  // use local reference to =
improve performance=0A=
=0A=
    // find next free array slot for menu=0A=
    var i =3D 0;=0A=
    while (top_registry[i]) {=0A=
      i++;=0A=
    }=0A=
    top_registry[i] =3D menu;=0A=
    ret =3D i;=0A=
  }=0A=
  return ret;=0A=
}=0A=
=0A=
function UnRegisterMenu(theMenuId) {=0A=
  top.menuRegistry_[theMenuId] =3D null;=0A=
}=0A=
=0A=
function getRegisteredMenu(id)=0A=
{=0A=
  var menuarr;=0A=
  if (CLIENT_SIDE) {=0A=
    if (!top.menuRegistry_) {=0A=
      top.menuRegistry_ =3D [];=0A=
    }=0A=
    menuarr =3D top.menuRegistry_;=0A=
  }=0A=
  else {=0A=
    menuarr =3D menus;=0A=
  }=0A=
  return menuarr[id];=0A=
}=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * ###Contructor for a Menu###=0A=
   *=0A=
   * @param close: bool: This parameter is only necessary for the top =
level menu.=0A=
   *    If this value is not set the top level menu is not hided if the =
mouse leaves=0A=
   *    this menu. This is the case for the normal menu in the user =
block.=0A=
   *    If the value is true, the menu is hided when the mouse leaves =
the menu. This=0A=
   *    should for example set for context menues opened by an icon.=0A=
   * @param obj: String: ###PARAMETER DESCRIPTION###=0A=
   * @param attrobj: Object: This parameter contains information about =
the object, where=0A=
   *    action should be performed. The members are:=0A=
   *      title: The title of the object=0A=
   *      url: The url of the object. This is typically the name of the =
object=0A=
   *      These values are used to create the necessary information in =
for example=0A=
   *      the mail link funktionality. This object can be set =
dynamically, befor=0A=
   *      a context menu is opened.=0A=
   * @param orientation: String: [top|left] This value defines the =
alignment of contained=0A=
   *      menuitems. If the orientation is top, menu items are aligend =
from left to right=0A=
   *      [item 1][item 2]...=0A=
   *      If the value is left, the menu items are aligned from top to =
bottom=0A=
   *      [item 1]=0A=
   *      [item 2]=0A=
   *      ...=0A=
   * @param frame: String: This parameter describes the HTML frame, =
where a submenu=0A=
   *      should be opened=0A=
   * @param executionframe: String: This parameter describes the HTML =
frame, where the=0A=
   *      objects (listing) is displayed. This is necessary when the =
frame parameter=0A=
   *      is not the frame where the objects are displayed.=0A=
   * @param frametop: bool: When frametop is true, the opened sub menu =
is placed at the=0A=
   *      top of the frame, and only the x coordinate is taken from the =
opening menu.=0A=
   *      If this value is false, the opened sub menu is placed at the =
left side of the=0A=
   *      frame, and only the y coordinate is taken from the openening =
menu.=0A=
   *      This seting is only relevant when frame is set.=0A=
   * @param relright: bool: When relright is true, the distancen from =
the right side of=0A=
   *      the frame is used to place the opened menu. This is necessary =
if the frame,=0A=
   *      where the sub menu is opened is not the left most frame.=0A=
   *      This seting is only relevant when frame is set.=0A=
   * @param container: String: This parameter spezifies, which frame =
contains a re-writeable=0A=
   *      html element (DIV in IE and Layer in NS).=0A=
   * @param cname: String: This parameter spezifies, which element =
should be used as constrained=0A=
   *      for the x position of the menu. This can be used in =
combination with the parameter=0A=
   *      relright=3D1.=0A=
   * @param containername: String: This parameter spezifies the name of =
the re-writeable=0A=
   *      html element.=0A=
   * @param width: String: This parameter spezifies the with of the =
menu. This value is used=0A=
   *      for the with attribute of an table. Typical values: "100%" or =
"600"=0A=
   * @param isiconbar: bool: When this value is set to true, menu items =
are visulized using,=0A=
   *      icons. If there is no icon configured for an menu item, the =
normal caption is displayed.=0A=
   * @param cssclass: String|void: defines the stylesheet class that =
should be used when=0A=
   *      creating the HTML; default: =
orientation=3D=3D"left"-->"MenuList", otherwise "MenuBar"=0A=
   */=0A=
function Menu(caption,p)=0A=
{=0A=
  this.id_ =3D CLIENT_SIDE ? RegisterMenu(this) : 0;=0A=
  this.caption_=3Dcaption.replace(REG_EXP_SPACE, "&nbsp;");=0A=
  this.items_=3Dnew Array();=0A=
  this.created_=3Dfalse;=0A=
  this.x_=3D0;=0A=
  this.y_=3D0;=0A=
  this.wasDown_=3Dfalse;=0A=
  this.width_=3Dnull;=0A=
  if (p.close)=0A=
  {=0A=
    this.close_=3Dp.close;=0A=
    this.child_=3Dthis;=0A=
  }=0A=
  else=0A=
    p.close_=3Dfalse;=0A=
  if (p.savepos)=0A=
    this.useCookies_=3Dp.savepos;=0A=
  else=0A=
    this.useCookies_=3Dfalse;=0A=
=0A=
  if (p.obj)=0A=
  {=0A=
    this.obj_=3Dp.obj;=0A=
    if (typeof navigator !=3D "undefined" && =
navigator.appVersion.indexOf("X11",0) =3D=3D -1){=0A=
      if (typeof keyShortcuts!=3D"undefined")=0A=
        keyShortcuts.setObj(p.obj);=0A=
    }=0A=
  }=0A=
  if (p.attrobj)=0A=
  {  // object:  attributes: title and url=0A=
    this.attrobj_=3Dp.attrobj;=0A=
  }=0A=
=0A=
  if (p.orientation)=0A=
    this.orientation_=3Dp.orientation;=0A=
  else=0A=
    this.orientation_=3D "left";=0A=
=0A=
  this.cssClass_=3Dp.cssclass;=0A=
  if (!this.cssClass_) {=0A=
    if (this.orientation_=3D=3D'left') {=0A=
      this.cssClass_=3D"MenuItem";=0A=
    }=0A=
    else {=0A=
      this.cssClass_=3D"MenuTitle";=0A=
    }=0A=
  }=0A=
=0A=
//    if (p.frame && p.frame.indexOf('[')!=3D0) {=0A=
//      this.frame_ =3D "."+p.frame;=0A=
//    }=0A=
//    else {=0A=
    this.frame_ =3D p.frame;=0A=
//    }=0A=
  this.executionframe_=3Dp.executionframe;=0A=
  this.container_=3Dp.container;=0A=
  this.containername_=3Dp.containername;=0A=
  if (p.inheritsizetoopener)=0A=
  {=0A=
    this.inheritSizeToOpener_ =3D true;=0A=
  }=0A=
  this.frametop_=3Dp.frametop;=0A=
  this.relright_=3Dp.relright;=0A=
  this.cname_=3Dp.cname;=0A=
  this.xpos_ =3D p.xpos;=0A=
  this.ypos_ =3D p.ypos;=0A=
  this.menualignment_ =3D p.menualignment;=0A=
=0A=
  if (p.width)=0A=
    this.width_=3Dp.width;=0A=
=0A=
  if (p.isiconbar)=0A=
    this.isiconbar_=3Dtrue;=0A=
  else=0A=
    this.isiconbar_=3Dfalse;=0A=
=0A=
  if (typeof p.showdisabledicons =3D=3D "undefined" || =
p.showdisabledicons)=0A=
    this.showdisabledicons_=3Dtrue;=0A=
  else=0A=
    this.showdisabledicons__=3Dfalse;=0A=
=0A=
  this.hanid_=3D-1;=0A=
  =0A=
  if (p.checkedchangedcallback)=0A=
  {=0A=
    if (typeof navigator !=3D "undefined")=0A=
    {=0A=
      if (typeof p.checkedchangedcallback =3D=3D 'string')=0A=
        this.checkedchangedcallback_=3Dnew =
Function('item',p.checkedchangedcallback);=0A=
      else=0A=
        this.checkedchangedcallback_=3Dp.checkedchangedcallback;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.checkedchangedcallback_=3Dp.checkedchangedcallback;=0A=
    }=0A=
  }=0A=
  else=0A=
    this.checkedchangedcallback_=3D"";=0A=
}=0A=
=0A=
Menu.prototype.destructor =3D function () {=0A=
  var items =3D this.items_;=0A=
  for (var i=3D0; i<items.length; i++) {=0A=
  	items[i].destructor();=0A=
  }=0A=
  if (CLIENT_SIDE) {=0A=
    Menu_clearTimeout(this.clmenId_);=0A=
    Menu_clearTimeout(this.clmenId2_);=0A=
    this.deleteVisual();=0A=
    UnRegisterMenu(this.id_);=0A=
    this.restoreOpenerSize();=0A=
  }=0A=
};=0A=
=0A=
Menu.prototype.getMenuItemByName =3D function (name)=0A=
{=0A=
  //iterate over all items=0A=
  for (var i=3D0;i<this.items_.length;i++)=0A=
  {=0A=
    if (this.items_[i].name_ =3D=3D name)=0A=
    {=0A=
      return this.items_[i];=0A=
    }=0A=
    if (this.items_[i].child_)=0A=
    { // if item has submenus, update these aswell=0A=
      this.items_[i].child_.getMenuItemByName(name);=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
function hw_addHand(p)=0A=
{=0A=
  if (!p)=0A=
    p=3D{};=0A=
  p.ishandlel=3Dtrue;=0A=
  newItem=3Dnew MenuItem("hand",p);=0A=
  newItem.menu_=3Dthis;=0A=
  this.items_[this.items_.length]=3DnewItem;=0A=
  this.hanid_=3Dthis.items_.length-1;=0A=
};=0A=
Menu.prototype.addHand=3Dhw_addHand;=0A=
=0A=
function hw_add(caption,p)=0A=
{=0A=
  if (!p.quickTestId && p.child) {=0A=
    p.quickTestId =3D p.child.caption_;=0A=
  }=0A=
  =0A=
  newItem=3D new MenuItem(caption,p);=0A=
  newItem.menu_=3Dthis;=0A=
  this.items_[this.items_.length]=3DnewItem;=0A=
  if (newItem.child_)=0A=
    this.hasChild_=3Dtrue;=0A=
}=0A=
Menu.prototype.add=3Dhw_add;=0A=
=0A=
function hw_addItem(item)=0A=
{=0A=
  if (typeof item!=3D"undefined" && item)=0A=
  {=0A=
    newItem=3D item;=0A=
    newItem.menu_=3Dthis;=0A=
    this.items_[this.items_.length]=3DnewItem;=0A=
    if (newItem.child_)=0A=
      this.hasChild_=3Dtrue;=0A=
  }=0A=
}=0A=
Menu.prototype.addItem=3Dhw_addItem;=0A=
=0A=
function hw_addSep()=0A=
{=0A=
  newItem=3D new MenuItem("",{isseperator:true});=0A=
  newItem.menu_=3Dthis;=0A=
  this.items_[this.items_.length]=3DnewItem;=0A=
}=0A=
Menu.prototype.addSep=3Dhw_addSep;=0A=
=0A=
function hw_addHSpace()=0A=
{=0A=
  newItem=3D new MenuItem("",{isspace:true});=0A=
  newItem.menu_=3Dthis;=0A=
  this.items_[this.items_.length]=3DnewItem;=0A=
}=0A=
Menu.prototype.addHSpace=3Dhw_addHSpace;=0A=
=0A=
Menu.prototype.length=3Dfunction()=0A=
{=0A=
  return this.items_.length;=0A=
};=0A=
=0A=
//------------------------------------------------------------=0A=
// MenuItem implementations=0A=
//------------------------------------------------------------=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This is the contructor of a Menu Item=0A=
   *=0A=
   * @param maillink: bool: When this parameter is true, the in a parent =
menu=0A=
   *    passed attrobj is used to create a mailto link.=0A=
   * @param save: bool: When this parameter is true, the in a parent menu=0A=
   *    passed attrobj is used to fire the save.action and the save as =
dialog=0A=
   *    of the browser is triggered.=0A=
   * @param isseperator: bool: When this parameter is true, the item is =
displayed as=0A=
   *    seperator=0A=
   * @param isspace: bool: If this parameter is true, the item is =
dispayed without=0A=
   *    a caption but with maximal width requirements.=0A=
   * @param nohighlite: bool: When this parameter is true, there is no =
highlighting done=0A=
   *    on the item=0A=
   * @param isdisabled: bool: When this parameter is true, the the item =
is displayed=0A=
   *    "grayed". If it is has icons, and is displayed in an iconbar, =
the icondisabled=0A=
   *    is used.=0A=
   * @param icon: String: This icon is displayed as icon of the menu.=0A=
   *      Note: this is normally done by parameter cssclass, but is =
necessary if the menuitem is created dynamically.=0A=
   * @param cssclass: String: the css class that is set for the menu =
item. See master css for examples (for example hw_delete)=0A=
   * @param act: String: This action is added as "action" parameter, =
when the url is created=0A=
   * @param actp: String: This parameter is added as "action parameter" =
parameter, the=0A=
   *    url is created.=0A=
   * @param actmult: String: Same as act, but is used when more then one =
objects are selected.=0A=
   * @param actpmult: String: Same as actp, but is used when more then =
one objects are selected.=0A=
   * @param operation: String: ---=0A=
   * @param submit: bool: ---=0A=
   * @param target: String: When this parameter is set, the resulting =
page is displayed in an new=0A=
   *    window with the name of the value of "target".=0A=
   * @param targetmult: String: Same as target, but is used when more =
then one objects are selected.=0A=
   * @param winstyle: String: A newly opened window is opened with this =
style. The spezification is=0A=
   *    the same as the one used for the JavaScript command =
"window.open()".=0A=
   * @param name: String: The name attributes for form values of the =
checked objects=0A=
   * @param namemult: String: Same as name, but is used when more then =
one objects are selected.=0A=
   * @param op: bool: When this value is set to true, the function move =
is called.=0A=
   * @param opobj: bool: Same as op, but the "request.object" is the =
selected object.=0A=
   * @param url: String: The url, which is called, when the icon is =
clicked.=0A=
   * @param status: String: The value of this property is displayed in =
the status bar of the browser=0A=
   *    window, when the mouse moves over the item.=0A=
   * @param exec: String: The name of a function, which is called, when =
the item is clicked.=0A=
   * @param child: Menu: The child menu, which should be opened, when =
the item is clicked.=0A=
   * @param key: String: The shorcut key, which could be used to =
aktivate the menu item.=0A=
   * @param quickTestId: String|void: the html-id of the anchors around =
menu entries. These ids are=0A=
   *   used for automated testing using the QuickTest-suite.=0A=
   * @param cssclass: String|void: defines the stylesheet class that =
should be used when=0A=
   *   creating the HTML;=0A=
   * @param queryparameter: Object|void: this object will be passed as =
query parameters (after the=0A=
   *   question mark); it is only supported in case of `act` is =
specified.=0A=
   * @param onselectionchanged: Function|void: allows to add register a =
callback function that is called=0A=
   *   after the selection of the associated selection model has =
changed. By returning the values=0A=
   *   <code>true</code> and <code>false</code> the function defines =
whether the menu entry is=0A=
   *   enabled (<code>true</code>) or disabled <code>false</code>.=0A=
   */=0A=
=0A=
function MenuItem(caption, p)=0A=
{=0A=
  this.id_ =3D CLIENT_SIDE ? RegisterMenu(this) : 0;=0A=
  =0A=
  if (p.quickTestId) {=0A=
    this.quickTestId_ =3D p.quickTestId;=0A=
  }=0A=
  =0A=
  this.child_=3Dnull;=0A=
  this.menu_=3Dnull;=0A=
  this.offsetComputed_=3Dfalse;=0A=
  this.key_=3D"";=0A=
=0A=
  if (p.keepspaces) {=0A=
    this.keepspaces_=3Dp.keepspaces;=0A=
    this.caption_=3Dcaption;=0A=
  } else {=0A=
    this.caption_=3Dcaption.replace(REG_EXP_SPACE, "&nbsp;");=0A=
  }=0A=
=0A=
  if (typeof p.contexthelp =3D=3D "boolean")=0A=
  {=0A=
    this.iscontexthelp_=3Dp.contexthelp;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.iscontexthelp_=3Dfalse;=0A=
  }=0A=
=0A=
  if (p.menugroup)=0A=
  {=0A=
    this.menugroup_ =3D p.menugroup;=0A=
  }=0A=
  =0A=
  if (p.selectionminimum)=0A=
  {=0A=
    this.selectionminimum_=3Dp.selectionminimum;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.selectionminimum_=3D-1;=0A=
  }=0A=
  if (p.selectionmaximum)=0A=
  {=0A=
    this.selectionmaximum_=3Dp.selectionmaximum;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.selectionmaximum_=3D1e6;=0A=
  }=0A=
=0A=
  this.alignprevitem_=3Dp.alignprevitem;=0A=
=0A=
  if (p.print)=0A=
  {=0A=
    this.print_=3Dtrue;=0A=
  }=0A=
  if (p.maillink)=0A=
  {=0A=
    this.maillink_=3Dtrue;=0A=
    if (p.noversionlink || typeof HW_Settings !=3D "undefined" && =
HW_Settings.NO_VERSIONINFO_IN_MAILED_LINKS)=0A=
    {=0A=
      this.noversionlink_=3Dtrue;=0A=
    }=0A=
  }=0A=
  if (p.save)=0A=
  {=0A=
    this.save_=3Dtrue;=0A=
  }=0A=
  if (p.download)=0A=
  {=0A=
    this.download_=3Dtrue;=0A=
  }=0A=
=0A=
  if (typeof p.isseperator =3D=3D "boolean")=0A=
  {=0A=
    this.isseperator_=3Dp.isseperator;=0A=
    if (this.isseperator_)=0A=
    {=0A=
      this.caption_=3D"seperator";=0A=
      return;=0A=
    }=0A=
  }=0A=
  else=0A=
    this.isseperator_=3Dfalse;=0A=
=0A=
  if (typeof p.isspace =3D=3D "boolean")=0A=
  {=0A=
    this.isspace_=3Dp.isspace;=0A=
    if (this.isspace_)=0A=
      return;=0A=
  }=0A=
  else=0A=
    this.isspace_=3Dfalse;=0A=
=0A=
  if (typeof p.nohighlite =3D=3D "boolean")=0A=
    this.nohi_=3Dp.nohighlite;=0A=
  else=0A=
    this.nohi_=3Dfalse;=0A=
=0A=
  if (typeof p.ishandlel =3D=3D "boolean")=0A=
    this.ishanl_=3D p.ishandlel;=0A=
  else=0A=
    this.ishanl_=3Dfalse;=0A=
=0A=
  if (typeof p.istoggle =3D=3D "boolean")=0A=
    this.istoggle_=3D p.istoggle;=0A=
  else=0A=
    this.istoggle_=3Dfalse;=0A=
=0A=
  if (typeof p.issingleselect =3D=3D "boolean" && p.issingleselect)=0A=
  {=0A=
    this.istoggle_=3D true;=0A=
    this.issingleselect_=3D true;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.issingleselect_=3D false;=0A=
  }=0A=
  =0A=
  if (typeof p.ischecked =3D=3D "boolean")=0A=
  {=0A=
    this.ischecked_=3Dp.ischecked;=0A=
    this.istoggle_=3Dtrue;=0A=
  }=0A=
  else=0A=
    this.ischecked_=3Dfalse;=0A=
  =0A=
  if (typeof p.isdisabled =3D=3D "string" && typeof navigator=3D=3D =
"undefined")=0A=
  {=0A=
    this.isdisabled_=3Dp.isdisabled;=0A=
  }=0A=
  else=0A=
  {=0A=
    if (typeof p.isdisabled =3D=3D "boolean")=0A=
    {=0A=
      this.isdisabled_=3Dp.isdisabled;=0A=
    }=0A=
    else if (typeof p.isdisabled =3D=3D "string" && typeof navigator =
!=3D "undefined")=0A=
    { // eval is no problem on clientside=0A=
      eval("this.isdisabled_ =3D " + p.isdisabled + ";");=0A=
    }=0A=
    else=0A=
    {=0A=
      this.isdisabled_=3Dfalse;=0A=
    }=0A=
  }=0A=
=0A=
  if (p.cssclass)=0A=
  {=0A=
    this.cssclass_=3Dp.cssclass;=0A=
  }=0A=
  if (p.queryparameter)=0A=
  {=0A=
    this.queryparameter_=3Dp.queryparameter;=0A=
  }=0A=
=0A=
  if (p.icon)=0A=
  {=0A=
    this.icon_=3Dp.icon;=0A=
  }=0A=
  else if (p.icondefault)=0A=
  { // this is for backward compatibility=0A=
    this.icon_=3Dp.icondefault;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.icon_=3D"";=0A=
  }=0A=
=0A=
  if (p.iwidth)=0A=
    this.iwidth_=3Dp.iwidth;=0A=
=0A=
  if (p.iheight)=0A=
    this.iheight_=3Dp.iheight;=0A=
=0A=
  if (p.act)=0A=
    this.act_=3Dp.act;=0A=
  else=0A=
    this.act_=3D"";=0A=
  if (p.actp)=0A=
    this.actp_=3Dp.actp;=0A=
  else=0A=
    this.actp_=3D"";=0A=
=0A=
  if (p.actmult)=0A=
    this.actmult_=3Dp.actmult;=0A=
  else=0A=
    this.actmult_=3D"";=0A=
  if (p.actpmult)=0A=
    this.actpmult_=3Dp.actpmult;=0A=
  else=0A=
    this.actpmult_=3D"";=0A=
=0A=
  if (p.operation)=0A=
    this.operation_=3Dp.operation;=0A=
  else=0A=
    this.operation_=3D"";=0A=
=0A=
  if (typeof p.submit =3D=3D "boolean")=0A=
    this.submit_=3Dp.submit;=0A=
  else=0A=
    this.submit_=3Dfalse;=0A=
=0A=
  if (p.target)=0A=
    this.target_=3Dp.target;=0A=
  else=0A=
    this.target_=3D"";=0A=
=0A=
  if (typeof p.targetmult !=3D "undefined")=0A=
    this.targetmult_=3Dp.targetmult;=0A=
  else=0A=
    this.targetmult_=3Dthis.target_;=0A=
=0A=
  if (p.name)=0A=
    this.name_=3Dp.name;=0A=
  else=0A=
    this.name_=3D"";=0A=
=0A=
  if (p.namemult)=0A=
    this.namemult_=3Dp.namemult;=0A=
  else=0A=
    this.namemult_=3D"";=0A=
=0A=
  if (p.winstyle)=0A=
  {=0A=
    if (CLIENT_SIDE && typeof p.winstyle =3D=3D "string")=0A=
    {=0A=
      eval("p.winstyle =3D " + p.winstyle + ";");=0A=
    }=0A=
    this.winstyle_=3Dp.winstyle;=0A=
  }=0A=
=0A=
  if (p.op)=0A=
    this.op_=3Dp.op;=0A=
  else=0A=
    this.op_=3Dfalse;=0A=
=0A=
  if (p.opobj)=0A=
    this.opobj_=3Dp.opobj;=0A=
  else=0A=
    this.opobj_=3Dfalse;=0A=
=0A=
  if (p.url)=0A=
    this.url_=3Dp.url;=0A=
  else=0A=
    this.url_=3D"";=0A=
=0A=
  if (p.status)=0A=
    this.status_=3Dp.status;=0A=
  else=0A=
    this.status=3D"";=0A=
=0A=
  if (p.exec)=0A=
  {=0A=
    if (typeof navigator !=3D "undefined")=0A=
    {=0A=
      if (typeof p.exec =3D=3D 'string')=0A=
        this.exec_=3Dnew Function('item',p.exec);=0A=
      else=0A=
        this.exec_=3Dp.exec;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.exec_=3Dp.exec;=0A=
    }=0A=
  }=0A=
  else=0A=
    this.exec_=3D"";=0A=
=0A=
  if (p.shiftexec)=0A=
  {=0A=
    if (typeof navigator !=3D "undefined")=0A=
    {=0A=
      if (typeof p.shiftexec =3D=3D 'string')=0A=
        this.shiftexec_=3Dnew Function('item',p.shiftexec);=0A=
      else=0A=
        this.shiftexec_=3Dp.shiftexec;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.shiftexec_=3Dp.shiftexec;=0A=
    }=0A=
  }=0A=
  else=0A=
    this.shiftexec_=3D"";=0A=
=0A=
  this.onselectionchanged_ =3D p.onselectionchanged ? =
p.onselectionchanged : null;=0A=
  =0A=
  if (p.child)=0A=
  {=0A=
    if (CLIENT_SIDE && typeof p.child =3D=3D "string")=0A=
    {=0A=
      eval("p.child =3D " + p.child + ";");=0A=
    }=0A=
    this.child_=3Dp.child;=0A=
    this.child_.parentItem_=3Dthis;=0A=
  }=0A=
  else=0A=
    this.child_=3D0;=0A=
  if (typeof navigator !=3D "undefined")=0A=
  {=0A=
    if (navigator.appVersion.indexOf("X11",0) =3D=3D -1)=0A=
    {=0A=
      if (!this.isdisabled_ && p.key && typeof =
keyShortcuts!=3D"undefined")=0A=
      {=0A=
        this.key_=3Dp.key;=0A=
        keyShortcuts.add(p);=0A=
      }=0A=
    }=0A=
  }=0A=
  else=0A=
  {=0A=
    if (p.key)=0A=
      this.key_=3Dp.key;=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * Getter method for the name of the menu item.=0A=
 * =0A=
 * @returns string: the peviously defined name of the menu item=0A=
 */=0A=
MenuItem.prototype.getName =3D function () {=0A=
  return this.name_;=0A=
};=0A=
=0A=
/**=0A=
 *  Destructor of the menu item. Performs all necessary steps to remove =
the menu item=0A=
 *  and its children from the client side.=0A=
 */=0A=
MenuItem.prototype.destructor =3D function () {=0A=
  if (this.child_) {=0A=
    this.child_.destructor();=0A=
  }=0A=
  if (CLIENT_SIDE) {=0A=
    Menu_clearTimeout(this.clTimId_);=0A=
    Menu_clearTimeout(this.shtim_);=0A=
    UnRegisterMenu(this.id_);=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * Sets the html-id of the anchors around menu entries. These ids are =
used for automated=0A=
 * testing using the QuickTest-suite.=0A=
 * =0A=
 * @param theId: string: the quicktest id=0A=
 */=0A=
MenuItem.prototype.setQuickTestId =3D function (theId) {=0A=
  this.quickTestId_ =3D theId;=0A=
};=0A=
=0A=
/**=0A=
 * This function can be used as sort function for arrays of menu items=0A=
 * The menu items are compared using their caption=0A=
 *=0A=
 * @param m1: MenuItem: the first menu item=0A=
 * @param m2: MenuItem: the second menu item=0A=
 */=0A=
=0A=
MenuItem.compare =3D function (m1,m2)=0A=
{=0A=
  if (m1.caption_<m2.caption_)=0A=
  {=0A=
    return -1;=0A=
  }=0A=
  else if (m2.caption_<m1.caption_)=0A=
  {=0A=
    return 1;=0A=
  }=0A=
  else=0A=
  {=0A=
    return 0;=0A=
  }=0A=
};=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/menu_dc/code/menu.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: menu.js 162683 2011-04-27 11:40:56Z cgoess $=0A=
 */=0A=
//-------------------------------------------------------=0A=
// the implementation of the menu=0A=
//-------------------------------------------------------=0A=
=0A=
HWbName =3D navigator.appName;=0A=
vishide=3D"hidden";=0A=
visshow=3D"visible";=0A=
=0A=
var clsleep=3D500; // timeout for closing a menu=0A=
=0A=
var firsttime =3D true;=0A=
var prebMenus =3D new Array();=0A=
prebMenus[0]=3D1;=0A=
=0A=
function getAction(theActionName, theActionParameter, theQueryParameter)=0A=
{=0A=
  var action_name =3D theActionName || "";=0A=
  var action_param =3D theActionParameter || "";=0A=
  var query_param =3D theQueryParameter || {};=0A=
  =0A=
  var ret =3D [";internal"];=0A=
=0A=
  if (action_name) {=0A=
    ret.push("&action=3D", action_name, ".action");=0A=
  }=0A=
=0A=
  if (action_param) {=0A=
    ret.push("&Parameter=3D", action_param);=0A=
  }=0A=
=0A=
  var query_part =3D [];=0A=
  for (var i in query_param) {=0A=
    query_part.push(encodeURIComponent(i) + "=3D" + =
encodeURIComponent(query_param[i]));=0A=
  }=0A=
  if (query_part.length) {=0A=
    ret.push("?", query_part.join("&"));=0A=
  }=0A=
=0A=
  return ret.join("");=0A=
}=0A=
=0A=
//-------------------------------------------------------=0A=
//Menu Implementations=0A=
//-------------------------------------------------------=0A=
=0A=
var HWMenuUnloaded=3Dfalse;=0A=
=0A=
function Menu_setTimeout(func,tim,win)=0A=
{=0A=
  var thewin=3Dwin||window;=0A=
  var timeouts;=0A=
  if (typeof top!=3D"undefined")=0A=
  {=0A=
    if (!top.menuTimeOutRegistry_) {=0A=
      top.menuTimeOutRegistry_ =3D {};=0A=
    }=0A=
    timeouts =3D top.menuTimeOutRegistry_;=0A=
  }=0A=
  else=0A=
  {=0A=
    menuTimeOutRegistry_ =3D {};=0A=
    timeouts =3D menuTimeOutRegistry_;=0A=
  }=0A=
=0A=
  var timerid=3Dthewin.setTimeout(func,tim);=0A=
  timeouts[timerid]=3Dthewin;=0A=
  return timerid;=0A=
}=0A=
=0A=
function Menu_clearTimeout(id)=0A=
{=0A=
  var timeouts;=0A=
  if (typeof top!=3D"undefined") {=0A=
    timeouts =3D top.menuTimeOutRegistry_;=0A=
  }=0A=
  else {=0A=
    timeouts =3D menuTimeOutRegistry_;=0A=
  }=0A=
  if (id) {=0A=
    var thewin=3Dtimeouts[id];=0A=
    if (typeof thewin !=3D"undefined")=0A=
      thewin.clearTimeout(id);=0A=
    delete timeouts[id];=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * @deprecated there for backwards compatibility;=0A=
 * use Menu.destructor() and MenuItem.destructor() on each menu instance=0A=
 * for menu clean up=0A=
 */=0A=
function Menu_clearallTimeouts()=0A=
{=0A=
  HWMenuUnloaded=3Dtrue;=0A=
=0A=
  if (typeof hwbar!=3D "undefined") {=0A=
    hwbar.destructor();=0A=
  }=0A=
=0A=
  if (typeof hwiconbar!=3D "undefined") {=0A=
    hwiconbar.destructor();=0A=
  }=0A=
=0A=
  if (typeof ms !=3D "undefined" && typeof ms.sonunload =3D=3D =
"function")=0A=
    ms.sonunload();=0A=
}=0A=
=0A=
=0A=
Menu.prototype.deleteVisual=3Dfunction()=0A=
{=0A=
  if (this.menuLayer_)=0A=
  {=0A=
    if (this.container_)=0A=
    {=0A=
      $(this.menuLayer_).remove();=0A=
    }=0A=
    else=0A=
    {=0A=
      $(this.menuLayer_).up().remove();=0A=
    }=0A=
    =0A=
  }=0A=
  for (var i=3D0;i<this.items_.length;i++)=0A=
  {=0A=
    if (this.items_[i].child_)=0A=
    { // if item has submenus, update these aswell=0A=
      this.items_[i].child_.deleteVisual();=0A=
      this.items_[i].iLay_=3Dnull;=0A=
    }=0A=
  }=0A=
=0A=
  // delete references to domobjects to prevent memory leaks=0A=
  this.frame_=3Dnull;=0A=
  this.theCont_=3Dnull;=0A=
  this.theDocument=3Dnull;=0A=
  this.theWindow_=3Dnull;=0A=
  this.menuCont_=3Dnull;=0A=
  this.menuLayer_=3Dnull;=0A=
};=0A=
=0A=
Menu.prototype.updateSelection=3Dfunction(count)=0A=
{=0A=
  //iterate over all items and call updateSelection on them=0A=
  for (var i=3D0;i<this.items_.length;i++)=0A=
  {=0A=
    this.items_[i].updateSelection(count);=0A=
    if (this.items_[i].child_)=0A=
    { // if item has submenus, update these as well=0A=
      this.items_[i].child_.updateSelection(count);=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
Menu.prototype.getObject=3Dfunction(it)=0A=
{=0A=
  var cur =3D this;=0A=
  while(!cur.obj_ && cur.parentItem_ && cur.parentItem_.menu_)=0A=
    cur=3Dcur.parentItem_.menu_;=0A=
  return cur.obj_?cur.obj_:"";=0A=
};=0A=
=0A=
Menu.prototype.getAttrObject=3Dfunction(it)=0A=
{=0A=
  var cur =3D this;=0A=
  while(!cur.attrobj_ && cur.parentItem_ && cur.parentItem_.menu_)=0A=
    cur=3Dcur.parentItem_.menu_;=0A=
  return cur.attrobj_?cur.attrobj_:null;=0A=
};=0A=
=0A=
Menu.prototype.action=3Dfunction(it)=0A=
{=0A=
  var ret=3D"";=0A=
  if (!it.opobj_ || typeof move !=3D"function")=0A=
    ret=3Dthis.getObject();=0A=
  var action =3D getAction(it.act_,it.actp_, it.queryparameter_);=0A=
  if (ret.indexOf(";internal") !=3D -1 && action.indexOf(";internal") =
!=3D -1) {=0A=
    action =3D action.replace(/\;internal/, "");=0A=
  }=0A=
  ret+=3Daction;=0A=
  return ret;=0A=
};=0A=
=0A=
Menu.prototype.actionmult=3Dfunction(it)=0A=
{=0A=
  return this.getObject() + getAction(it.actmult_, it.actpmult_, =
it.queryparameter_);=0A=
};=0A=
=0A=
Menu.prototype.clWasDown=3Dfunction ()=0A=
{=0A=
  this.wasDown_=3Dfalse;=0A=
  if (!this.parentItem_)=0A=
  {=0A=
    hw.getFramework().getDisplayManager().showHideLayers();=0A=
  }=0A=
  for (var itemcont=3D0; itemcont< this.items_.length; itemcont++)=0A=
  {=0A=
    var it=3Dthis.items_[itemcont];=0A=
    if (it.child_)=0A=
      it.child_.clWasDown();=0A=
  }=0A=
};=0A=
=0A=
Menu.prototype.MenuToString =3D function ()=0A=
{=0A=
  var str=3D[];=0A=
=0A=
  str[str.length]=3D'<ul class=3D"hw_menu';=0A=
  if (this.orientation_=3D=3D"top")=0A=
  {=0A=
    str[str.length]=3D" hw_horizontal";=0A=
  }=0A=
  else=0A=
  {=0A=
    str[str.length]=3D" hw_vertical";=0A=
  }=0A=
=0A=
  str[str.length]=3D'" style=3D"position:absolute" =
id=3D"menu'+this.id_+'" menuid=3D"'+this.id_+'">';=0A=
=0A=
  for (var itemcont=3D0; itemcont< this.items_.length; itemcont++)=0A=
  {=0A=
    var it=3Dthis.items_[itemcont];=0A=
    str[str.length]=3Dit.toString();=0A=
    it.isdisplayed_=3Dtrue;=0A=
  }=0A=
  =0A=
  str[str.length]=3D'</ul>';=0A=
  return {str:str.join(''),prelayerstr:"",postlayerstr:""};=0A=
};=0A=
=0A=
=0A=
Menu.prototype.createNewMenuRep=3D function(obj)=0A=
{=0A=
  this.createNewMenuRepDOM(obj);=0A=
};=0A=
=0A=
Menu.prototype.showAt=3D function(x,y,p2,visi)=0A=
{=0A=
  if(this.close_)=0A=
  {=0A=
    hw.getFramework().getDisplayManager().hideHideLayers();=0A=
    menuLeave(this.id_,3000);=0A=
  }=0A=
=0A=
  var p=3Dp2||{};=0A=
  p.ma=3Dp.ma||"l";=0A=
  vis=3Dvisshow;=0A=
  if (typeof visi!=3D"undefined")=0A=
    vis=3Dvisi;=0A=
=0A=
  if(vis=3D=3Dvisshow)=0A=
    this.isvis_=3Dtrue;=0A=
  else=0A=
    this.isvis_=3Dfalse;=0A=
=0A=
  if (!this.created_)=0A=
  {=0A=
    var obj=3Dthis.MenuToString();=0A=
    this.createNewMenuRep(obj);=0A=
  }=0A=
=0A=
  var ox=3Dx;=0A=
  if (p.ma=3D=3D"r") {=0A=
=0A=
    x=3Dx-this.width_;=0A=
  }=0A=
  if (p.may=3D=3D"b") {=0A=
=0A=
    y=3Dy-this.height_;=0A=
  }=0A=
=0A=
  var compy=3Dthis.clientHeight()+this.getScrollTop();=0A=
=0A=
  if (compy<y+this.height_ && this.orientation_=3D=3D"left")=0A=
    y=3Dcompy-this.height_;=0A=
=0A=
  var compx=3Dthis.clientWidth();=0A=
  if (p.relright)=0A=
  {=0A=
    if (x>compx)=0A=
    {=0A=
      if (p.positionConstraints && p.positionConstraints.left)=0A=
      {=0A=
        x=3DMath.max(compx,p.positionConstraints.left);=0A=
      }=0A=
      else=0A=
      {=0A=
        x=3Dcompx;=0A=
      }=0A=
    }=0A=
  }=0A=
  else=0A=
  {=0A=
    if (x+this.width_>compx)=0A=
    { // menu is displayed out of range of the frame=0A=
      if (p.positionConstraints && p.positionConstraints.left)=0A=
      {=0A=
        x=3DMath.max(compx-this.width_,p.positionConstraints.left);=0A=
      }=0A=
      else=0A=
      {=0A=
        x=3Dcompx-this.width_;=0A=
      }=0A=
    }=0A=
  }=0A=
  if (x<0) x=3D0;=0A=
  if (y<0) y=3D0;=0A=
=0A=
  if (p.positionConstraints)=0A=
  {=0A=
    if (p.positionConstraints.left)=0A=
    {=0A=
      if (x<p.positionConstraints.left)=0A=
        x=3Dp.positionConstraints.left;=0A=
    }=0A=
    if (p.positionConstraints.right)=0A=
    {=0A=
      if (x+this.width_>p.positionConstraints.right)=0A=
        x=3Dp.positionConstraints.left-this.width_;=0A=
    }=0A=
  }=0A=
=0A=
  this.showAtDOM(x,y,vis,p.relright);=0A=
=0A=
  this.x_=3Dx;=0A=
  this.y_=3Dy;=0A=
  if (!this.created_)=0A=
    this.created_=3Dtrue;=0A=
};=0A=
=0A=
Menu.prototype.hide=3D function()=0A=
{=0A=
  if (this.menuLayer_) {=0A=
    // workaround for NN7:=0A=
    // move layer out of the visible area instead of setting visibility;=0A=
    // otherwise 508-support does not work=0A=
    this.menuLayer_.style.top=3DgetCoordValue(-10000);=0A=
    this.menuLayer_.style.left=3DgetCoordValue(-10000);=0A=
//      this.menuLayer_.style.visibility=3Dvishide;=0A=
  }=0A=
  this.isvis_=3Dfalse;=0A=
  this.focusMenu_ =3D null;=0A=
  this.focusElement_ =3D null;=0A=
  this.focusId_ =3D null;=0A=
  if (!this.parentItem_)=0A=
    this.saveStat();=0A=
};=0A=
=0A=
Menu.prototype.visibility =3D function ()=0A=
{=0A=
  if (!this.menuLayer_)=0A=
    return vishide;=0A=
  if (parseInt(this.menuLayer_.style.top) =3D=3D -10000) {  // see =
hide-method=0A=
    return vishide;=0A=
  }=0A=
  return visshow;=0A=
};=0A=
=0A=
Menu.prototype.x=3D function()=0A=
{=0A=
  return this.x_;=0A=
};=0A=
=0A=
Menu.prototype.y=3D function()=0A=
{=0A=
  return this.y_;=0A=
};=0A=
=0A=
Menu.prototype.saveStat=3Dfunction()=0A=
{=0A=
  if (this.useCookies_) {=0A=
    state =3D this.isvis_+'^'+this.x_+'^'+this.y_;=0A=
    setCookie(this.caption_,state,null);=0A=
  }=0A=
};=0A=
=0A=
Menu.prototype.restorStat=3Dfunction()=0A=
{=0A=
  var isopen =3D1;=0A=
  var cookie=3Dnull;=0A=
  if (this.useCookies_) cookie=3DgetCookie(this.caption_);=0A=
  if(cookie =3D=3D null) {=0A=
    this.x_=3D0;=0A=
    this.y_=3D0;=0A=
    return -1;=0A=
  }=0A=
  else {=0A=
    var cstate =3D cookie.split(':');=0A=
    var vals=3Dcstate[0].split('^');=0A=
    isopen =3D eval(vals[0]);=0A=
    if (isopen)=0A=
    {=0A=
      this.x_=3DparseInt(vals[1]);=0A=
      this.y_=3DparseInt(vals[2]);=0A=
    }=0A=
    else=0A=
      isopen=3D0;=0A=
  }=0A=
  return isopen;=0A=
};=0A=
=0A=
Menu.prototype.focus =3D function()=0A=
{=0A=
  this.focusMenu_ =3D null;=0A=
  if (this.focusElement_) {=0A=
    // top.debugWindow('set existing focus: Id: '+this.focusId_);=0A=
    this.focusElement_.focus();=0A=
    return true;=0A=
  }=0A=
  else {=0A=
    var first_element =3D =
this.theDocument_.getElementById(this.firstAnchorId_);=0A=
    if (first_element) {=0A=
      var menu_id =3D first_element.getAttribute('menuid');=0A=
      this.focusId_      =3D menu_id;=0A=
      // top.debugWindow('set focus to first element: Id: =
'+this.focusId_);=0A=
      this.focusElement_ =3D first_element;=0A=
      this.focusElement_.focus();=0A=
      return true;=0A=
    }=0A=
  }=0A=
  return false;=0A=
};=0A=
=0A=
Menu.prototype.blur =3D function (theFocusMenu)=0A=
{=0A=
  // top.debugWindow('>>> blur()');=0A=
  this.focusMenu_ =3D theFocusMenu;=0A=
=0A=
  if (this.focusElement_) {=0A=
    this.focusElement_.blur();=0A=
    return true;=0A=
  }=0A=
  return false;=0A=
};=0A=
=0A=
Menu.prototype.focusNext =3D function ()=0A=
{=0A=
  // top.debugWindow('>>> focusNext()');=0A=
  var current_id =3D this.focusId_;=0A=
  var next_anchor_id;=0A=
  var items =3D this.items_;=0A=
  var current_found =3D false;=0A=
  =0A=
  for (var i=3D0; i<items.length; i++) {=0A=
=0A=
    if (items[i].id_=3D=3Dcurrent_id) {=0A=
      current_found =3D true;=0A=
      continue;=0A=
    }=0A=
    if (current_found && items[i].anchorId_) {=0A=
      next_anchor_id =3D items[i].anchorId_;=0A=
      break;=0A=
    }=0A=
  }=0A=
  if (!next_anchor_id) {=0A=
    next_anchor_id =3D this.firstAnchorId_;=0A=
  }=0A=
  var next_element =3D this.theDocument_.getElementById(next_anchor_id);=0A=
  var menu_id =3D next_element.getAttribute('menuid');=0A=
  this.focusId_      =3D menu_id;=0A=
  // top.debugWindow('set focus to next element: Id: '+this.focusId_);=0A=
  this.focusElement_ =3D next_element;=0A=
  this.focusElement_.focus();=0A=
  // top.debugWindow('<<< focusNext()');=0A=
  return true;=0A=
};=0A=
=0A=
Menu.prototype.focusPrevious =3D function ()=0A=
{=0A=
  // top.debugWindow('>>> focusPrevious()');=0A=
  var current_id =3D this.focusId_;=0A=
  var next_anchor_id;=0A=
  var items =3D this.items_;=0A=
  var current_found =3D false;=0A=
  =0A=
  for (var i=3Ditems.length-1; i>=3D0; i--) {=0A=
    if (items[i].id_=3D=3Dcurrent_id) {=0A=
      current_found =3D true;=0A=
      continue;=0A=
    }=0A=
    if (current_found && items[i].anchorId_) {=0A=
      next_anchor_id =3D items[i].anchorId_;=0A=
      break;=0A=
    }=0A=
  }=0A=
  if (!next_anchor_id) {=0A=
    next_anchor_id =3D this.lastAnchorId_;=0A=
  }=0A=
  var next_element =3D this.theDocument_.getElementById(next_anchor_id);=0A=
  var menu_id =3D next_element.getAttribute('menuid');=0A=
  this.focusId_      =3D menu_id;=0A=
  // top.debugWindow('set focus to previous element: Id: =
'+this.focusId_);=0A=
  this.focusElement_ =3D next_element;=0A=
  this.focusElement_.focus();=0A=
  // top.debugWindow('<<< focusPrevious()');=0A=
  return true;=0A=
};=0A=
=0A=
//------------------------------------------------------------=0A=
// MenuItem implementations=0A=
//------------------------------------------------------------=0A=
=0A=
function hideItem(itemid)=0A=
{=0A=
  var menuitem=3DgetRegisteredMenu(itemid);=0A=
  if (menuitem.clTimId_)=0A=
    Menu_clearTimeout(menuitem.clTimId_);=0A=
  if (menuitem.child_ && !menuitem.isdisabled_)=0A=
    menuitem.child_.hide();=0A=
  if (menuitem.lowlightItem)=0A=
    menuitem.lowlightItem();=0A=
}=0A=
=0A=
function showItem(itemid)=0A=
{=0A=
  var menuitem=3DgetRegisteredMenu(itemid);=0A=
  menuitem.showChild();=0A=
  if (menuitem.shtim_)=0A=
    Menu_clearTimeout(menuitem.shtim_);=0A=
  menuitem.shtim_=3Dnull;=0A=
}=0A=
=0A=
closeId_=3D0;=0A=
theclmen=3Dnull;=0A=
=0A=
function showPageLayers(tid)=0A=
{=0A=
  if (typeof tid=3D=3D"undefined") return;=0A=
  var amen=3DgetRegisteredMenu(tid);=0A=
  if (amen.clmenId_)=0A=
    Menu_clearTimeout(amen.clmenId_);=0A=
  amen.clWasDown();=0A=
}=0A=
=0A=
=0A=
MenuItem.prototype.setClose=3Dfunction(timeout)=0A=
{=0A=
  var functionString=3D"hideItem("+this.id_+")";=0A=
  var sleep=3Dclsleep;=0A=
  if (this.menu_.orientation_=3D=3D"top"){ sleep=3D250; }=0A=
  if (typeof timeout!=3D"undefined"){sleep=3Dtimeout;}=0A=
  if (this.clTimId_!=3Dnull)=0A=
    Menu_clearTimeout(this.clTimId_);=0A=
  this.clTimId_=3DMenu_setTimeout(functionString,sleep,window);=0A=
  if (this.menu_.parentItem_)=0A=
  {=0A=
    this.menu_.parentItem_.setClose(sleep);=0A=
  }=0A=
  else=0A=
  {=0A=
    functionString=3D"showPageLayers("+this.menu_.id_+")";=0A=
    if (this.menu_.clmenId_!=3Dnull)=0A=
      Menu_clearTimeout(this.menu_.clmenId_);=0A=
    this.menu_.clmenId_=3DMenu_setTimeout(functionString,clsleep,window);=0A=
    if (this.menu_.close_)=0A=
    {=0A=
      functionString=3D"hideItem("+this.menu_.id_+")";=0A=
      if (this.menu_.clmenId2_!=3Dnull)=0A=
        Menu_clearTimeout(this.menu_.clmenId2_);=0A=
      =
this.menu_.clmenId2_=3DMenu_setTimeout(functionString,clsleep,window);=0A=
    }=0A=
=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.clearClose=3Dfunction()=0A=
{=0A=
  if (this.menu_.clmenId_!=3Dnull)=0A=
  {=0A=
    Menu_clearTimeout(this.menu_.clmenId_);=0A=
    this.menu_.clmenId_=3Dnull;=0A=
  }=0A=
  if (this.clTimId_!=3Dnull)=0A=
    Menu_clearTimeout(this.clTimId_);=0A=
  this.clTimId_=3Dnull;=0A=
=0A=
  if (this.menu_.clmenId2_!=3Dnull)=0A=
  {=0A=
    Menu_clearTimeout(this.menu_.clmenId2_);=0A=
    this.menu_.clmenId2_=3Dnull;=0A=
  }=0A=
  if (this.clTimId2_!=3Dnull)=0A=
    Menu_clearTimeout(this.clTimId2_);=0A=
  this.clTimId2_=3Dnull;=0A=
=0A=
  if (this.menu_.parentItem_)=0A=
    this.menu_.parentItem_.clearClose();=0A=
};=0A=
=0A=
function handleClicked(id)=0A=
{=0A=
  var men=3DgetRegisteredMenu(id);=0A=
  var ret=3Dtrue;=0A=
  if (men.hanid_ !=3D -1 && men.items_[men.hanid_].exec_)=0A=
    ret=3Dmen.items_[men.hanid_].exec_(id);=0A=
  if (ret)=0A=
    men.hide();=0A=
}=0A=
=0A=
function movestart(obj)=0A=
{=0A=
  if (HWbName!=3D"Netscape")=0A=
  {=0A=
    window.event.cancelBubble=3Dtrue;=0A=
    window.event.returnValue =3D false;=0A=
  }=0A=
  men=3DgetRegisteredMenu(obj.menuid).menu_;=0A=
//  men.startMove(obj.menuid);=0A=
  return false;=0A=
}=0A=
=0A=
function itemClicked(obj, anEvent)=0A=
{=0A=
  var menuid =3D obj.getAttribute('menuid');=0A=
  var it=3DgetRegisteredMenu(menuid);=0A=
=0A=
  if (it.dynamicallyDisabled_)=0A=
  { // item is disabled because nothing is selected or the item action =
can not be=0A=
  // applied to the selected objects=0A=
    return false;=0A=
  }=0A=
  if (it.ishanl_)=0A=
  {=0A=
    handleClicked(it.menu_.id_);=0A=
    return false;=0A=
  }=0A=
=0A=
  var oldwd=3Dit.menu_.wasDown_;=0A=
  it.menu_.wasDown_=3Dtrue;=0A=
  if (!oldwd)=0A=
  {=0A=
    itemEnter(obj);=0A=
    if (it.child_) {=0A=
      hw.getFramework().getDisplayManager().hideHideLayers();=0A=
    }=0A=
  }=0A=
  if (it.isdisabled_)=0A=
    return false;=0A=
=0A=
  if (anEvent)=0A=
    anEvent.cancelBubble =3D true;=0A=
=0A=
  if (it.maillink_)=0A=
  {=0A=
    it.mailLink();=0A=
    return false;=0A=
  }=0A=
=0A=
  if (it.save_)=0A=
  {=0A=
    it.save();=0A=
    return false;=0A=
  }=0A=
=0A=
  if (it.istoggle_)=0A=
  {=0A=
    if (it.menu_.checkedchangedcallback_)=0A=
    {=0A=
      it.setChecked(!it.ischecked_);=0A=
      it.menu_.checkedchangedcallback_(it,it.menu_.getAttrObject());=0A=
      if (it.issingleselect_)=0A=
      {=0A=
        for (var u=3D0;u<it.menu_.items_.length;u++)=0A=
        {=0A=
          var item=3Dit.menu_.items_[u];=0A=
          if (item.issingleselect_)=0A=
          {=0A=
            if (item.name_ !=3D it.name_)=0A=
            {=0A=
              item.setChecked(!it.ischecked_);=0A=
            }=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
    it.setClose(0);=0A=
  }=0A=
  =0A=
  if (anEvent.shiftKey && it.shiftexec_)=0A=
  {=0A=
    it.shiftexec_(it,it.menu_.getAttrObject());=0A=
    it.setClose(0);=0A=
  }=0A=
  else if (it.exec_) {=0A=
    it.exec_(it,it.menu_.getAttrObject());=0A=
    it.setClose(0);=0A=
  }=0A=
=0A=
  var theurl=3D"";=0A=
  if (it.act_)=0A=
    theurl=3Dit.menu_.action(it);=0A=
  else if (it.url_)=0A=
    theurl=3Dit.url_;=0A=
=0A=
  var theurlmult=3D"";=0A=
  if (it.actmult_)=0A=
    theurlmult=3Dit.menu_.actionmult(it);=0A=
      =0A=
  if ( !it.url_ && theurl.length && top.gChildContext )=0A=
  {=0A=
    if (theurl.indexOf(';internal')=3D=3D-1)=0A=
      theurl +=3D ';internal';=0A=
    theurl +=3D "&ctx=3D" + top.gChildContext;=0A=
  }=0A=
=0A=
  if (theurl.length)=0A=
  {=0A=
    // ERS - bug fix (#2492): allow submit selected objects from the =
iconbar items=0A=
    var itFrame =3D null;=0A=
    if (it.menu_ && it.menu_.executionframe_)=0A=
    {=0A=
      itFrame =3D eval("top.frames."+it.menu_.executionframe_);=0A=
    }=0A=
    else=0A=
    {=0A=
      itFrame =3D eval("top.frames."+it.menu_.frame_);=0A=
    }=0A=
    var move_func;=0A=
    if (typeof move =3D=3D "function") {=0A=
      move_func =3D move;=0A=
    }=0A=
    if (itFrame && itFrame.move) {=0A=
      move_func =3D itFrame.move;=0A=
    }=0A=
=0A=
    if((it.op_ || it.opobj_) && typeof move_func =3D=3D "function") {=0A=
      var move_params =3D {=0A=
        target: it.target_,=0A=
        targetmult: it.targetmult_,=0A=
        url: theurl,=0A=
        urlmult: theurlmult,=0A=
        onsel: it.opobj_,=0A=
        submit: it.submit_,=0A=
        name: it.name_,=0A=
        namemult: it.namemult_,=0A=
        winstyle: it.winstyle_,=0A=
        attrobj: it.menu_.getAttrObject(),=0A=
        action: it.act_=0A=
      };=0A=
      move_func((it.operation_!=3D"") ? it.operation_ : it.actp_, =
move_params);=0A=
    }=0A=
    else=0A=
    {=0A=
      if (it.target_){=0A=
        var opdlg_func;=0A=
        if (typeof opDlg =3D=3D "function") {=0A=
          opdlg_func =3D opDlg;=0A=
        }=0A=
        if (itFrame && itFrame.opDlg) {=0A=
          opdlg_func =3D itFrame.opDlg;=0A=
        }=0A=
        if (typeof opdlg_func =3D=3D "function") {=0A=
          if (it.winstyle_)=0A=
            opdlg_func(theurl,it.target_,it.winstyle_);=0A=
          else=0A=
            opdlg_func(theurl,it.target_);=0A=
        }=0A=
        else=0A=
        {=0A=
          var exec_window =3D itFrame ? itFrame : window;=0A=
          var h =3D exec_window.screen.height;=0A=
          h*=3D0.75;=0A=
          =
exec_window.open(theurl,it.target_,"status=3Dyes,toolbar=3Dno,scrollbars=3D=
yes,resizable=3Dyes,width=3D640,height=3D"+h);=0A=
        }=0A=
      }=0A=
      else {=0A=
        if (it.menu_ && (it.menu_.frame_ || it.menu_.executionframe_))=0A=
        {=0A=
          var menu_frame =3D =
eval("top.frames."+it.menu_.executionframe_?it.menu_.executionframe_:it.m=
enu_.frame_);=0A=
          menu_frame.location.href=3Dtheurl;=0A=
        }=0A=
        else=0A=
        {=0A=
          window.location.href=3Dtheurl;=0A=
        }=0A=
      }=0A=
    }=0A=
    it.setClose(0);=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
function itemEnter(obj, anEvent)=0A=
{=0A=
  var mitem=3DgetRegisteredMenu(obj.getAttribute('menuid'));=0A=
  itemEnterDOM(obj, anEvent);=0A=
=0A=
  if (mitem.status_)=0A=
    window.status=3Dmitem.status_;=0A=
}=0A=
=0A=
function itemLeave(obj, anEvent)=0A=
{=0A=
  var menuid =3D obj.getAttribute('menuid');=0A=
  var mitem=3DgetRegisteredMenu(menuid);=0A=
  itemLeaveDOM(obj, anEvent);=0A=
}=0A=
=0A=
function menuEnter(itemid, anEvent)=0A=
{=0A=
  var menu=3DgetRegisteredMenu(itemid);=0A=
  if (anEvent)=0A=
    anEvent.cancelBubble =3D true;=0A=
=0A=
  if (menu.clmenId_!=3Dnull)=0A=
  {=0A=
    Menu_clearTimeout(menu.clmenId_);=0A=
    menu.clmenId_=3Dnull;=0A=
  }=0A=
  if (menu.clmenId2_!=3Dnull)=0A=
  {=0A=
    Menu_clearTimeout(menu.clmenId2_);=0A=
    menu.clmenId2_=3Dnull;=0A=
  }=0A=
=0A=
  if (menu.parentItem_)=0A=
    menu.parentItem_.clearClose();=0A=
}=0A=
=0A=
function menuLeave(itemid, timeout2, anEvent)=0A=
{=0A=
  var timeout=3Dtimeout2||clsleep;=0A=
  if (anEvent) {=0A=
    anEvent.cancelBubble =3D true;=0A=
  }=0A=
  var menu=3DgetRegisteredMenu(itemid);=0A=
  if (!menu.wasDown_ && !menu.close_)=0A=
    return;=0A=
  if (menu.parentItem_)=0A=
  {=0A=
    menu.parentItem_.setClose();=0A=
  }=0A=
  else=0A=
  {=0A=
    functionString=3D"showPageLayers("+menu.id_+")";=0A=
    if (menu.clmenId_!=3Dnull)=0A=
      Menu_clearTimeout(menu.clmenId_);=0A=
    menu.clmenId_=3DMenu_setTimeout(functionString,timeout,window);=0A=
    if (menu.close_)=0A=
    {=0A=
      functionString=3D"hideItem("+menu.id_+")";=0A=
      if (menu.clmenId2_!=3Dnull)=0A=
        Menu_clearTimeout(menu.clmenId2_);=0A=
      menu.clmenId2_=3DMenu_setTimeout(functionString,timeout,window);=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
MenuItem.prototype.updateSelection =3D function(count,selection)=0A=
{=0A=
  if (this.onselectionchanged_)=0A=
  {=0A=
    if (this.onselectionchanged_(this,this.menu_.getAttrObject()))=0A=
    {=0A=
      this.enable();=0A=
    }=0A=
    else=0A=
    {=0A=
      this.disable();=0A=
    }=0A=
    return;=0A=
  }=0A=
  =0A=
  var operation=3Dthis.operation_;=0A=
  // handle the document specific part=0A=
  // for example: checkin only for documents, that can be cheked in=0A=
  if (operation)=0A=
  {=0A=
    var attrobj=3Dthis.menu_.getAttrObject();=0A=
    if (typeof getAllowedCountForOperation =3D=3D "function")=0A=
    {=0A=
      var allowed_count =3D getAllowedCountForOperation(operation);=0A=
      if (!attrobj)=0A=
      {=0A=
        var numsel =3D num_of_selected(operation,false);=0A=
      }=0A=
      else=0A=
      {=0A=
        var numsel =3D =
num_of_selected_attrobject(operation,attrobj,false);=0A=
      }=0A=
      if (numsel.all =3D=3D -1 || (numsel.all =3D=3D 0 && allowed_count =
!=3D 0)) // "0" means optional parameter=0A=
      {=0A=
        this.disable();=0A=
      }=0A=
      else=0A=
      {=0A=
        this.enable();=0A=
      }=0A=
      return;=0A=
    }=0A=
  }=0A=
=0A=
  // handle the part that depends only on the selection count=0A=
  // for example "copy to"=0A=
  if (count>=3Dthis.selectionminimum_ && count<=3Dthis.selectionmaximum_)=0A=
  {=0A=
    this.enable();=0A=
  }=0A=
  else=0A=
  {=0A=
    this.disable();=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.disable =3D function()=0A=
{=0A=
  this.dynamicallyDisabled_=3Dtrue;=0A=
 =0A=
  if(this.iLay_)=0A=
  {=0A=
    $(this.iLay_).addClassName("hw_disabled");=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.enable =3D function()=0A=
{=0A=
  this.dynamicallyDisabled_=3Dfalse;=0A=
  =0A=
  if(!this.isdisabled_ && this.iLay_)=0A=
  {=0A=
    $(this.iLay_).removeClassName("hw_disabled");=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.setChecked =3D function(ischecked)=0A=
{=0A=
  if (this.istoggle_)=0A=
  {=0A=
    this.ischecked_=3Dischecked;=0A=
    if(this.iLay_)=0A=
    {=0A=
      if (this.ischecked_)=0A=
      {=0A=
        $(this.iLay_).addClassName("hw_checked");=0A=
      }=0A=
      else=0A=
      {=0A=
        $(this.iLay_).removeClassName("hw_checked");=0A=
      }=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.isChecked =3D function () {=0A=
  return this.ischecked_;=0A=
};=0A=
=0A=
MenuItem.prototype.toString =3D function()=0A=
{=0A=
  return this.toStringDOM();=0A=
};=0A=
=0A=
MenuItem.prototype.showChild =3D function()=0A=
{=0A=
  if (this.child_ && !this.isdisabled_)=0A=
  {=0A=
    var _focus =3D false;=0A=
    if (this.menu_ && this.menu_.frame_)=0A=
    {=0A=
      this.child_.frame_=3Dthis.menu_.frame_;=0A=
      if (this.menu_.container_)=0A=
      {=0A=
        this.child_.frametop_=3Dthis.menu_.frametop_;=0A=
      }=0A=
    }=0A=
    if (this.menu_)=0A=
    {=0A=
      this.child_.executionframe_=3Dthis.menu_.executionframe_;=0A=
    }=0A=
    if (!this.child_.created_) {=0A=
      var _focus =3D true;=0A=
      this.child_.showAt(this.menuRight(),this.menuTop(),{},vishide);=0A=
    }=0A=
    if (this.menu_.orientation_=3D=3D"left") {=0A=
      var _focus =3D true;=0A=
      =
this.child_.showAt(this.menuRight(),this.menuTop()-this.child_.itemOffset=
y_);=0A=
    }=0A=
    else=0A=
    {=0A=
      var _focus =3D true;=0A=
      var left;=0A=
      if (this.menu_.relright_)=0A=
        left=3Dthis.menuLeft()+this.child_.itemOffsetx_;=0A=
      else=0A=
        left=3Dthis.menuLeft()-this.child_.itemOffsetx_;=0A=
      =
this.child_.showAt(left,this.menuBottom(),{relright:this.menu_.relright_}=
);=0A=
    }=0A=
    this.child_.wasDown_=3Dtrue;=0A=
=0A=
    if (_focus && (this.enterEvent=3D=3D"focus" || =
this.enterEvent=3D=3D"keypress")) {=0A=
      this.menu_.blur(this.child_);=0A=
      this.child_.focus();=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.highlighteItem =3D function()=0A=
{=0A=
  if (this.dynamicallyDisabled_)=0A=
  {=0A=
    return;=0A=
  }=0A=
  =0A=
  if (this.menu_ && this.menu_.isiconbar_ && this.icon_)=0A=
  {=0A=
    if (!this.isdisabled_)=0A=
    {=0A=
      $(this.iLay_).addClassName('hw_active');=0A=
    }=0A=
  }=0A=
  else=0A=
  {=0A=
    $(this.iLay_).addClassName('hw_active');=0A=
  }=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
    {=0A=
      prevItem.highlighteItem();=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.getPostMenuItem=3Dfunction()=0A=
{=0A=
  for (var icount=3D0;icount<this.menu_.items_.length-1;icount++)=0A=
  {=0A=
    if (this.menu_.items_[icount].id_=3D=3Dthis.id_)=0A=
    {=0A=
      if (this.menu_.items_[icount+1].alignprevitem_)=0A=
      {=0A=
        return getRegisteredMenu(this.menu_.items_[icount+1].id_);=0A=
      }=0A=
    }=0A=
  }=0A=
  return false;=0A=
};=0A=
=0A=
MenuItem.prototype.lowlightItem =3D function()=0A=
{=0A=
  if (this.dynamicallyDisabled_)=0A=
  {=0A=
    return;=0A=
  }=0A=
=0A=
  $(this.iLay_).removeClassName('hw_active');=0A=
=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
    {=0A=
      prevItem.lowlightItem();=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.mailLink =3D function()=0A=
{=0A=
  var attrobj=3Dthis.menu_.getAttrObject();=0A=
  if (!attrobj)=0A=
  {=0A=
    alert("No Object provided");=0A=
    return;=0A=
  }=0A=
  var title=3Dattrobj.title;=0A=
  if (!title)=0A=
  {=0A=
    alert("No Object Title provided");=0A=
    return;=0A=
  }=0A=
  var url=3Dattrobj.url||"";=0A=
  if (!url)=0A=
  {=0A=
    alert("No Object URL provided");=0A=
    return;=0A=
  }=0A=
  if (top.frames.HW_DataRequestFrame)=0A=
  {=0A=
    var object_url =3D url; // url may contain already an action (e.g. =
image.action)=0A=
                          // and internal part (e.g. for version =
controlled documents)=0A=
    =0A=
    // HWIS/PR-6681: cut off '?', currently only docbin has such a part =
and we do not need/want it there=0A=
    if (object_url.indexOf("?") !=3D -1) {=0A=
      object_url =3D object_url.substring(0, object_url.indexOf("?"));=0A=
    }=0A=
=0A=
    if (this.noversionlink_)=0A=
    {=0A=
      object_url =3D object_url.replace(/\&version=3D\d+\.\d+/,"");=0A=
    }=0A=
    =0A=
    if (object_url.indexOf(";internal") !=3D -1) {=0A=
      object_url =3D object_url.replace(/&action\=3D/, =
"&redirect_action=3D"); // rename possible action part from url=0A=
      object_url =3D object_url.replace(/\;internal/, =
";internal&action=3Dsend_cs_email.action");=0A=
    }=0A=
    else {=0A=
      object_url +=3D ';internal&action=3Dsend_cs_email.action';=0A=
    }=0A=
    top.frames.HW_DataRequestFrame.location.href =3D object_url;=0A=
  }=0A=
  else=0A=
  {=0A=
    url =3D window.location.protocol+"\/\/"+window.location.host + =
encodeURIPath(url);=0A=
=0A=
    var decode_url =3D "mailto:?subject=3DLink to '";=0A=
    decode_url +=3D decodeURIComponent(title).replace(/&/g,"+");=0A=
    decode_url +=3D "'&body=3D";=0A=
    decode_url +=3D url;=0A=
    window.location.href =3D decode_url;=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.save =3D function()=0A=
{=0A=
  var attrobj=3Dthis.menu_.getAttrObject();=0A=
  if (!attrobj)=0A=
  {=0A=
    alert("No Object provided");=0A=
    return;=0A=
  }=0A=
  var url=3Dattrobj.url||"";=0A=
  if (!url)=0A=
  {=0A=
    alert("No Object URL provided");=0A=
    return;=0A=
  }=0A=
  //HWIS/PR-6681: cut off '?', currently only docbin has such a part and =
we do not need/want it there=0A=
  if (url.indexOf("?") !=3D -1) {=0A=
    url =3D url.substring(0, url.indexOf("?"));=0A=
  }=0A=
  =0A=
  var idx =3D url.indexOf(";internal&action=3D"); // cutoff action=0A=
  if (idx !=3D -1) {=0A=
    url =3D url.substring(0,idx);=0A=
  }=0A=
=0A=
  var idx =3D url.indexOf(";internal&"); // handle version links e.g. =
/PDF.pdf;internal&version=3D1.3=0A=
  if (idx !=3D -1) {=0A=
    fullurl =3D url + "&action=3Dsave.action";=0A=
  }=0A=
  else {=0A=
    fullurl =3D url + ";internal&action=3Dsave.action";=0A=
  }=0A=
=0A=
  if (top.frames.HW_DataRequestFrame) {=0A=
    top.frames.HW_DataRequestFrame.location.href =3D fullurl;=0A=
  }=0A=
  else {=0A=
    window.location.href=3Dfullurl;=0A=
  }=0A=
};=0A=
=0A=
MenuItem.prototype.menuTop=3Dfunction()=0A=
{=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
      return prevItem.menuTop_;=0A=
  }=0A=
  return this.menuTop_;=0A=
};=0A=
=0A=
MenuItem.prototype.menuBottom=3Dfunction()=0A=
{=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
      return prevItem.menuBottom_;=0A=
  }=0A=
  return this.menuBottom_;=0A=
};=0A=
=0A=
MenuItem.prototype.menuLeft=3Dfunction()=0A=
{=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
      return prevItem.menuLeft_;=0A=
  }=0A=
  return this.menuLeft_;=0A=
};=0A=
=0A=
MenuItem.prototype.menuRight=3Dfunction()=0A=
{=0A=
  if (typeof this.alignprevitem_!=3D "undefined")=0A=
  {=0A=
    var prevItem=3Dthis.getPrevMenuItem();=0A=
    if (prevItem)=0A=
      return prevItem.menuRight_;=0A=
  }=0A=
  return this.menuRight_;=0A=
};=0A=
=0A=
MenuItem.prototype.getPrevMenuItem=3Dfunction()=0A=
{=0A=
  var found=3D0;=0A=
  var itemid=3Dthis.menu_.items_[0].id_;=0A=
  for (var icount=3D0;icount<this.menu_.items_.length;icount++)=0A=
  {=0A=
    if (this.menu_.items_[icount].id_=3D=3Dthis.id_)=0A=
    {=0A=
      found=3D1;=0A=
      break;=0A=
    }=0A=
    itemid=3Dthis.menu_.items_[icount].id_;=0A=
  }=0A=
  return getRegisteredMenu(itemid);=0A=
};=0A=
=0A=
function debugnl(str)=0A=
{=0A=
  if (typeof HW_debugnl=3D=3D"function")=0A=
    HW_debugnl(str);=0A=
}=0A=
=0A=
function getCoordValue (aNumber)=0A=
{=0A=
  return aNumber + "px";=0A=
}=0A=
=0A=
function CSMenuObserver (theParams)=0A=
{=0A=
  if ( theParams =3D=3D "__proto__" )=0A=
    return;=0A=
  this.menu_=3DtheParams.menu;=0A=
  this.menu_.updateSelection(0);=0A=
}=0A=
=0A=
=0A=
class$ =3D doInherit (CSMenuObserver);=0A=
  =0A=
  /**=0A=
   * @see com.hyperwave.ui.UIObserverIFC#userAction=0A=
   * =0A=
   * Implementation of the observer-interface for the gui-selection =
model .=0A=
   */=0A=
  class$.userAction =3D function (theSelectionModel) {=0A=
    // finally update the menu whith the number of selected objects=0A=
    if (typeof this.menu_ !=3D "undefined")=0A=
      var selection =3D theSelectionModel.getSelection();=0A=
      this.menu_.updateSelection(selection.length);=0A=
  };=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyle/hwdefault/mstyle.js?cachekeY=515488b2-en

//HWUI40 Style: 'hwdefault'=0A=
=0A=
HW_ui_stylePath =3D "/wavemaster.internal/webapp/uistyle/hwdefault";=0A=
if (typeof getDynamicResourceFileName =3D=3D "function") {=0A=
  HW_ui_stylePath =3D getDynamicResourceFileName(HW_ui_stylePath);=0A=
}=0A=
=0A=
HW_ui_style =3D HW_ui_stylePath+"/mstyle.js"=0A=
HW_ui_styleCaption =3D {en:"Hyperwave Blue 2005",ge:"Hyperwave Blau =
2005"};=0A=
=0A=
mbstyle=3D{};=0A=
mbstyle.decoration=3D"none";=0A=
=0A=
mbstyle.FontFace=3D"Verdana,Arial,Helvetica";=0A=
mbstyle.FontSizeAbs=3D"70%";=0A=
=0A=
// DANTE-Menu=0A=
mbstyle.ChildTIcon=3D"/wavemaster.internal/webapp/uistyle/icons/empty.gif=
";=0A=
mbstyle.ChildTIconInv=3D"";=0A=
mbstyle.ChildTIconWidth=3D"9";=0A=
mbstyle.ChildTIconHeight=3D"11";=0A=
mbstyle.ChildLIcon=3D"/wavemaster.internal/webapp/uistyle/icons/pc_arrow.=
gif";=0A=
mbstyle.ChildLIconInv=3D"";=0A=
mbstyle.ChildLIconWidth=3D"9";=0A=
mbstyle.ChildLIconHeight=3D"11";=0A=
mbstyle.CheckedIcon=3D"/wavemaster.internal/webapp/uistyle/icons/checked.=
gif";=0A=
mbstyle.CheckedIconInv=3D"";=0A=
mbstyle.CheckedIconWidth=3D"7";=0A=
mbstyle.IconbarDefaultHeight=3D"12";=0A=
mbstyle.IconbarDefaultWidth=3D"16";=0A=
// end DANTE-Menu=0A=
=0A=
mbstyle.Opener=3D"/wavemaster.internal/webapp/uistyle/icons/empty.gif";=0A=
=0A=
//item settings=0A=
mbstyle.ItemColor=3D"#000000";=0A=
mbstyle.ItemSelColor=3D"black";=0A=
mbstyle.ItemDisColor=3D"#A0A0A0";=0A=
=0A=
//******************************************************************=0A=
// in the default UI the default menu configuration (DMC) used=0A=
//******************************************************************=0A=
mitstyle=3DDMC;=0A=
mitstyle.ItemBGColor =3D"#DCE4EC";=0A=
=0A=
// DANTE-Menu=0A=
mitstyle.ChildTIcon=3D"/wavemaster.internal/webapp/uistyle/icons/empty.gi=
f";=0A=
mitstyle.ChildTIconInv=3D"";=0A=
mitstyle.ChildTIconWidth=3D"9";=0A=
mitstyle.ChildTIconHeight=3D"11";=0A=
mitstyle.ChildLIcon=3D"/wavemaster.internal/webapp/uistyle/icons/pc_arrow=
.gif";=0A=
mitstyle.ChildLIconInv=3D"";=0A=
mitstyle.ChildLIconWidth=3D"9";=0A=
mitstyle.ChildLIconHeight=3D"11";=0A=
mitstyle.CheckedIcon=3D"/wavemaster.internal/webapp/uistyle/icons/checked=
.gif";=0A=
mitstyle.CheckedIconInv=3D"";=0A=
mitstyle.CheckedIconWidth=3D"7";=0A=
mitstyle.IconbarDefaultHeight=3D"12";=0A=
mitstyle.IconbarDefaultWidth=3D"24";=0A=
// used only for MacIE=0A=
mitstyle.ItemSelBGColor=3D"#FFFFFF";=0A=
mitstyle.ItemBGColor=3D"#dce4ec";=0A=
// end DANTE-Menu=0A=
=0A=
//style for (collection)listing=0A=
listyle=3D{};=0A=
listyle.headBGColor =3D "white";=0A=
listyle.attribColor=3D"#999999";=0A=
listyle.ItemBGColor=3D"#C0C0C0";=0A=
listyle.ItemColor=3D"black";=0A=
listyle.TreeView=3D{};=0A=
listyle.TreeView.style=3D"text-decoration:none; =
font-size:10pt;font-family:Arial, Geneva, Helvetica;color:black;";=0A=
listyle.TreeAttr=3D{};=0A=
listyle.TreeAttr.style=3D"font-size:9pt;font-family:Arial, Geneva, =
Helvetica;color:#404040;";=0A=
listyle.Update=3D{};=0A=
listyle.Update.style=3D"text-decoration:none; font-family: Tahoma, =
Arial, Helvetica, sans-serif; font-size:11px; font-style:normal; =
font-weight:normal; color:#FF0000;";=0A=
=0A=
adstyle=3DADC;=0A=
// use default-style except the background color of the dialog caption=0A=
adstyle.capBGColor=3D"#A7A9B3";=0A=
adstyle.logo =3D "/wavemaster.internal/webapp/uistyle/icons/hwlogo.gif";=0A=
=0A=
seqstyle=3DDSC;=0A=
=0A=
//style for portal display=0A=
pstyle=3DDPC;=0A=
=0A=
//Styles for the portal, tabs and tracks=0A=
pstyle.decoration=3D"full";=0A=
=0A=
//portal icons=0A=
pstyle.TrackRoleImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/port=
al/icon_role.png";=0A=
pstyle.TabRoleActiveImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/=
portal/icon_role.png";=0A=
pstyle.TabRoleInactiveImg=3D"/wavemaster.internal/webapp/uistyle/hwdefaul=
t/portal/icon_role.png";=0A=
pstyle.TrackConfigureImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault=
/portal/edit.png";=0A=
pstyle.TrackAboutImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/por=
tal/about.png";=0A=
pstyle.TrackMinimizeImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/=
portal/minimize.png";=0A=
pstyle.TrackMaximizeImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/=
portal/maximize.png";=0A=
pstyle.TrackDeactivateImg=3D"/wavemaster.internal/webapp/uistyle/hwdefaul=
t/portal/close.png";=0A=
pstyle.TrackRelatedObjectImg=3D"/wavemaster.internal/webapp/uistyle/hwdef=
ault/portal/related_object.png";=0A=
=0A=
// style for the userblock in frameset=0A=
ubstyle =3D DUC;=0A=
ubstyle.decoration=3D"full";=0A=
ubstyle.SearchBGColor =3D "#A7A9B3";=0A=
ubstyle.def =3D {};=0A=
ubstyle.def.style =3D "font-family: Verdana, Arial, Helvetica, =
sans-serif; font-size: 10px; color: #FFFFFF; text-decoration: none; =
font-weight: bold";=0A=
ubstyle.formelements =3D {};=0A=
ubstyle.formelements.style =3D "background-color: #FFFFFF; font-family: =
Verdana, Arial, Helvetica, sans-serif; font-size: 10px; color: #000000";=0A=
ubstyle.username =3D {};=0A=
ubstyle.username.style =3D "font-family: Verdana, Arial, Helvetica, =
sans-serif; font-size: 10px; color: #FFFFFF";=0A=
ubstyle.search =3D {};=0A=
ubstyle.search.style =3D "font-family: Verdana, Arial, Helvetica, =
sans-serif; font-size: 10px; font-weight: bold; color: #FFFFFF;";=0A=
ubstyle.searchform =3D {};=0A=
ubstyle.searchform.style =3D "font-family: Verdana, Arial, Helvetica, =
sans-serif; font-size: 10px";=0A=
ubstyle.toolbar =3D {};=0A=
ubstyle.toolbar.style =3D "font-family: Verdana, Arial, Helvetica, =
sans-serif; font-size: 10px; color: #FFFFFF; text-decoration: none; =
font-weight: bold";=0A=
ubstyle.search.hover =3D "color: #CC0000;"=0A=
=0A=
// --> eCS 1.5=0A=
ubstyle.IconeCS=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/tb=
_ecs.gif";=0A=
// <-- eCS 1.5=0A=
=0A=
// define images and icons=0A=
ubstyle.BGImg=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/bg.g=
if";=0A=
ubstyle.Empty=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/empt=
y.gif";=0A=
// toolbar=0A=
ubstyle.IconHome=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/t=
b_home.png";=0A=
ubstyle.IconHome1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/=
tb_home1.png";=0A=
ubstyle.IconUp=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/tb_=
upbutton.png";=0A=
ubstyle.IconUp1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/tb=
_upbutton1.png";=0A=
ubstyle.IconLogin=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/=
tb_login.png";=0A=
ubstyle.IconLogin1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg=
/tb_login1.png";=0A=
ubstyle.IconPrefs=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/=
tb_prefs.png";=0A=
ubstyle.IconPrefs1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg=
/tb_prefs1.png";=0A=
ubstyle.IconHelp=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/t=
b_help.png";=0A=
ubstyle.IconHelp1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/=
tb_help1.png";=0A=
ubstyle.IconEditMode=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubi=
mg/tb_editmode.png";=0A=
ubstyle.IconEditMode1=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ub=
img/tb_editmode1.png";=0A=
ubstyle.tbStartDelim=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubi=
mg/tb_startdelim.png";=0A=
ubstyle.tbSeperator=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubim=
g/tb_seperator.png";=0A=
=0A=
/*=0A=
 * Add for ERMS=0A=
 */=0A=
ubstyle.IconPrint=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg/=
tb_print.gif";=0A=
ubstyle.IconFiling=3D"/wavemaster.internal/webapp/uistyle/hwdefault/ubimg=
/tb_filing.gif";=0A=
/*=0A=
 * End Add for ERMS=0A=
 */=0A=
=0A=
// dialog style=0A=
dstyle=3DDDC;=0A=
// use default-style except the background color of the dialog caption=0A=
dstyle.capBGColor=3D"#A7A9B3";=0A=
dstyle.logo =3D "/wavemaster.internal/webapp/uistyle/icons/hwlogo.gif";=0A=
=0A=
// help style=0A=
hlpstyle=3DDHC;=0A=
// use default-style except the background color of the dialog caption=0A=
hlpstyle.capBGColor=3D"#A7A9B3";=0A=
hlpstyle.logo =3D dstyle.logo;=0A=
=0A=
//general style=0A=
gstyle =3D {};=0A=
gstyle.snapshotImg =
=3D"wavemaster.internal/webapp/uistyle/hwdefault/snapshot.gif";=0A=
gstyle.frameBorderColor =3D"#ffffff"; // for the subframeset: NOTE this =
setting has only an effect in IE. Firefox/Mozilla do ignore it.=0A=
=0A=
//HWUI40 Style: 'hwdefault'  --- END ---=0A=
=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/menu_dc/code/openclosemenudom.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: openclosemenudom.js 159800 2010-11-18 12:49:49Z jschipf $=0A=
 */=0A=
var hwmenfirsttime=3Dtrue;=0A=
function openMenu(mx,my,p){=0A=
  if (typeof p =3D=3D "undefined")=0A=
    p=3D{};=0A=
  if (typeof p.h =3D=3D "undefined")=0A=
    p.h=3Dtrue;=0A=
=0A=
  var x=3D3;=0A=
  var y=3D3;=0A=
  var op;=0A=
  p.oname=3Dp.oname||p.mname;=0A=
=0A=
  var oname =3D p.oname || "opener";=0A=
  if (p.mname) {=0A=
    helpm=3Deval(p.mname);=0A=
  }=0A=
  else if (p.menu)=0A=
  {=0A=
    helpm=3Dp.menu;=0A=
  }=0A=
  else=0A=
  {=0A=
    helpm=3Dhwbar;=0A=
  }=0A=
=0A=
  var xpo =3D helpm.xpos_;=0A=
  var ypo =3D helpm.ypos_;=0A=
=0A=
  if (typeof xpo =3D=3D "undefined")=0A=
  {=0A=
    var xpo=3Dp.xp=3Dp.xp||"l";=0A=
  }=0A=
  if (typeof ypo =3D=3D "undefined")=0A=
  {=0A=
    var ypo=3Dp.yp=3Dp.yp||"t";=0A=
  }=0A=
=0A=
  if (p.obj)=0A=
  {=0A=
    helpm.obj_=3D"/"+p.obj;=0A=
  }=0A=
  if (p.attrobj)=0A=
  {=0A=
    helpm.attrobj_=3Dp.attrobj;=0A=
    helpm.updateSelection(1);=0A=
  }=0A=
  if (helpm.cname_ && !p.cname)=0A=
  {=0A=
    p.cname=3Dhelpm.cname_;=0A=
  }=0A=
=0A=
  if (helpm.container_)=0A=
  {=0A=
    if (!top.frames[helpm.container_]) { // if the frame does not yet =
exist do nothing=0A=
      return;=0A=
    }=0A=
    if (helpm.opTim_)=0A=
    {=0A=
      Menu_clearTimeout(helpm.opTim_);=0A=
      helpm.opTim_=3Dnull;=0A=
    }=0A=
=0A=
    try {=0A=
      var referto =3D eval("top.frames."+helpm.container_+".document");=0A=
    }=0A=
    catch (e) {=0A=
      var referto =3D null;=0A=
    }=0A=
    =0A=
    if (!(referto && referto.getElementById(oname))) {=0A=
=0A=
      var function_args =3D [];=0A=
      if (p.oname) {=0A=
        function_args.push('oname:"'+p.oname+'"');=0A=
      }=0A=
      if (p.cname) {=0A=
        function_args.push('cname:"'+p.cname+'"');=0A=
      }=0A=
      if (p.mname) {=0A=
        function_args.push('mname:"'+p.mname+'"');=0A=
      }=0A=
      if (p.ma) {=0A=
        function_args.push('ma:"'+p.ma+'"');=0A=
      }=0A=
      helpm.opTim_=3DMenu_setTimeout('openMenu(-1,-1,{' + =
functionString.join(",") + '})',200,window);=0A=
      return;=0A=
    }=0A=
  }=0A=
  else=0A=
  {=0A=
    var referto =3D document;=0A=
  }=0A=
=0A=
  op=3Dreferto.getElementById(oname);=0A=
  =0A=
  // if the container for the menu doesn't exists=0A=
  // stop processing creating the menu=0A=
  if (op =3D=3D null) {=0A=
    return;=0A=
  }=0A=
=0A=
  if (typeof mx !=3D"undefined" && mx!=3D-1)=0A=
  {=0A=
    x=3Dmx;=0A=
    y=3Dmy;=0A=
    if (p.h && !helpm.inheritSizeToOpener_)=0A=
      op.style.visibility=3Dvishide;=0A=
  }=0A=
  else=0A=
  {=0A=
    var offsets =3D computeCumulativeOffset(op, helpm);=0A=
    x =3D offsets[0];=0A=
    y =3D offsets[1];=0A=
    var xo=3Dx;=0A=
    var yo=3Dy;=0A=
    if (xpo=3D=3D"r")x+=3Dop.offsetWidth;=0A=
    if (ypo=3D=3D"b")y+=3Dop.offsetHeight;=0A=
    if (p.h && !helpm.inheritSizeToOpener_)=0A=
      op.style.visibility=3Dvishide;=0A=
  }=0A=
=0A=
  if (p.cname)=0A=
  {=0A=
    var opleft=3Dreferto.getElementById(p.cname);=0A=
    var cleft=3Dnull;=0A=
    if (opleft) {=0A=
      var offsets =3D computeCumulativeOffset(opleft, helpm);=0A=
      cleft =3D offsets[0];=0A=
    }=0A=
  }=0A=
=0A=
  if (helpm.relright_)=0A=
  {=0A=
    // finally register the menu for resize handling=0A=
    registerMenuResize(helpm,p);=0A=
  }=0A=
=0A=
  if (helpm.items_.length>0) {=0A=
=0A=
    if (p.element) {=0A=
      helpm.openerElement_ =3D p.element;=0A=
    }=0A=
    =0A=
    helpm.openerDiv_=3Dop;=0A=
    var h_ma =3D helpm.menualignment_;=0A=
    if (typeof h_ma =3D=3D "undefined")=0A=
      h_ma =3D p.ma =3D p.ma || "r";=0A=
    =
helpm.showAt(x,y,{ma:h_ma,may:p.may,positionConstraints:{left:cleft}});=0A=
    helpm.saveStat();=0A=
    if (p.event && p.event.type=3D=3D"keypress") {=0A=
      helpm.focus();=0A=
    }=0A=
  }=0A=
=0A=
}=0A=
function closeMenu()=0A=
{=0A=
  hwbar.hide();=0A=
  document.getElementById("opener").style.visibility=3Dvisshow;=0A=
  return false;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * This function registers the passed menu parameter, to recall openMenu =
with,=0A=
 * when the browser window is resized=0A=
 * It furter registers the onresize Handler=0A=
 *=0A=
 * @param p: object used in openMenu()=0A=
 * @param menu: the menu which should be opened. it is used to check if =
the=0A=
 *     function was already called with for this menu.=0A=
 * @return: none=0A=
 */=0A=
=0A=
function registerMenuResize(menu,p)=0A=
{=0A=
  if (!arguments.callee.resizeAdded_) {=0A=
    arguments.callee.resizeAdded_ =3D true;=0A=
    addToOnresize(hw_menuOnresize);=0A=
  }=0A=
=0A=
  if (typeof gRegisteredMenus =3D=3D "undefined")=0A=
  {=0A=
    gRegisteredMenus=3D[];=0A=
  }=0A=
  for (var menucount=3D0;menucount<gRegisteredMenus.length;menucount++)=0A=
  {=0A=
    if (gRegisteredMenus[menucount].menu=3D=3Dmenu)=0A=
      return;=0A=
  }=0A=
  gRegisteredMenus.push({menu: menu, p: p});=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * This function is called on resize of the browser window=0A=
 * It is registered in header_menu.html. as a result of this function=0A=
 * the menus are positioned correctly. Do to this, the function=0A=
 * openMenu() is reused.=0A=
 * This is only necessary for IE because for Netscape onresize the=0A=
 * the whole page is reloaded=0A=
 *=0A=
 * @param none=0A=
 * @return: none=0A=
 */=0A=
function hw_menuOnresize()=0A=
{=0A=
  // check if there are registered menus=0A=
  if (typeof gRegisteredMenus!=3D"undefined" && gRegisteredMenus.length)=0A=
  { // go thru all registered menus=0A=
    for (var menucount=3D0;menucount<gRegisteredMenus.length;menucount++)=0A=
    { // and call open menu with the passed parameters=0A=
      openMenu(-1,-1,gRegisteredMenus[menucount].p);=0A=
    }=0A=
  }=0A=
  // call saved onresize=0A=
  if (typeof ms !=3D "undefined" && typeof ms.sonresize =3D=3D =
"function")=0A=
    ms.sonresize();=0A=
}
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/menu_dc/code/menudom.js?cachekeY=515488b2-en

/**
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * $Id: menudom.js 166046 2011-10-12 16:16:15Z wpinitsc $
 */
HWbName =3D navigator.appName;

function itemEnterDOM(obj, anEvent)
{
  var menuid =3D obj.getAttribute('menuid');
  var mitem=3DgetRegisteredMenu(menuid);
  if (mitem.shtim_!=3Dnull)
    Menu_clearTimeout(mitem.shtim_);
  mitem.clearClose();
  if (!mitem.isseperator_ && !mitem.nohi)
    mitem.highlighteItem();
  if(!mitem.menu_.wasDown_ && !mitem.ishanl_ && !mitem.menu_.close_)
    return;

  functionString=3D"showItem("+mitem.id_+")";
  var sleep=3Dclsleep;
  if (mitem.menu_.orientation_=3D=3D"top"){sleep=3D100;};
  if (mitem.enterEvent!=3D"focus") {
    mitem.shtim_=3DMenu_setTimeout(functionString,sleep,window);
  }
  else {
    if (!anEvent || (anEvent && anEvent.type=3D=3D"keypress")) {
      mitem.shtim_=3DMenu_setTimeout(functionString,0,window);
    }
  }
  if (mitem.menu_.parentItem_)
    mitem.menu_.parentItem_.highlighteItem();
  if (anEvent) {
    anEvent.cancelBubble =3D true;
  }
}

function itemLeaveDOM(obj, anEvent)
{
  var menuid =3D obj.getAttribute('menuid');
  var mitem=3DgetRegisteredMenu(menuid);
  if (mitem.shtim_)
    Menu_clearTimeout(mitem.shtim_);
  mitem.shtim_=3Dnull;
  if (mitem.menu_.isvis_)
    mitem.lowlightItem();

  if (anEvent) {
    anEvent.cancelBubble =3D true;
  }
  if(!mitem.menu_.wasDown_ && !mitem.ishanl_ && !mitem.menu_.close_)
    return;
  mitem.setClose();
  window.status=3D"";
}

function onMouseOverTD(anObj, anEvent) {

  var mitem=3DgetRegisteredMenu(anObj.getAttribute('menuid'));
  mitem.enterEvent =3D anEvent.type;
  itemEnter(anObj, anEvent);
}


function onMouseOutTD(anObj, anEvent) {

  var mitem=3DgetRegisteredMenu(anObj.getAttribute('menuid'));
  if (!mitem)
    return;
  mitem.enterEvent =3D "";
  itemLeave(anObj, anEvent);
}

function onClickTD(anObj, anEvent) {

  var mitem=3DgetRegisteredMenu(anObj.getAttribute('menuid'));
  if (true) {
    itemClicked(anObj, anEvent);
  }
  return false;
}



function onFocusAnchor (anObj, anEvent)
{
  var menu_id =3D anObj.getAttribute('menuid');
  var mitem=3DgetRegisteredMenu(menu_id);
  if (!mitem)
    return true;

  if (mitem.menu_.visibility()=3D=3Dvishide) {
    return true;
  }

  if (mitem.enterEvent)
    return true;

  mitem.enterEvent =3D anEvent.type;
  var id =3D anObj.id;

  if (mitem.menu_.focusMenu_ && =
mitem.menu_.focusMenu_.visibility()!=3Dvishide) {
    anObj.blur();
    mitem.menu_.focusMenu_.focus();
    return true;
  }

  if (id.indexOf("dummy")=3D=3D-1) {

    mitem.menu_.focusElement_ =3D anObj;
    mitem.menu_.focusId_ =3D menu_id;
    itemEnter(anObj, anEvent);
  }
  else {
    if ((anEvent.shiftKey && document.all) || (!anEvent.altKey && =
!document.all)) {
      anObj.blur();
      mitem.menu_.focusPrevious();
    }
    else {
      anObj.blur();
      mitem.menu_.focusNext();
    }
  }
  return true;
}


function onBlurAnchor(anObj, anEvent) {

  var menu_id =3D anObj.getAttribute('menuid');
  var mitem=3DgetRegisteredMenu(menu_id);
  if (!mitem)
    return;

  if (mitem.enterEvent) {

    if (anObj.id.indexOf('dummy')=3D=3D-1) {
      itemLeave(anObj, anEvent);
    }
    mitem.enterEvent =3D "";
  }
}

function onKeyPressAnchor(anObj, anEvent) {

  var menuid =3D anObj.getAttribute('menuid');
  var mitem=3DgetRegisteredMenu(menuid);

  if (anEvent.keyCode =3D=3D 27) { // escape-key
    if (mitem.menu_.parentItem_ || mitem.menu_.openerElement_) {
      if (mitem.menu_.menuLayer_) {
        mitem.menu_.hide();
      }
      if (mitem.menu_.parentItem_) {
        mitem.menu_.blur(mitem.menu_.parentItem_.menu_);
        mitem.menu_.parentItem_.menu_.focus();
      }
      else {

        if (mitem.menu_.openerElement_) {

          mitem.menu_.openerElement_.focus();
          mitem.menu_.blur();
        }
      }
    }
  }
  else {
    if (anEvent.keyCode =3D=3D 13) { // return/enter-key

      itemClicked(anObj, anEvent);
      itemEnter(anObj, anEvent);
    }
  }
  return true;
}

MenuItem.prototype.createAnchorId =3D function () {
  if (this.quickTestId_) {
    return 'a_'+this.quickTestId_;
  }
  return 'a_'+this.id_;
};

MenuItem.prototype.toStringDOM =3D function()
{
  var menu_id =3D ' menuid=3D"'+this.id_+'"';

  if (this.isStartAnchor_ || this.isEndAnchor_) {
    var handler =3D "";
  }
  else {
      var handler =3D
        'onclick=3D"return onClickTD(this, self.event||arguments[0])" '+
        'onmouseover=3D"onMouseOverTD(this, self.event||arguments[0])" =
'+
        'onmouseout=3D"onMouseOutTD(this, self.event||arguments[0])"'+
        'id=3D"menuitem'+this.id_+'" menuid=3D"'+this.id_+'"';
  }

  var str=3D[];
  str[str.length]=3D'<li id=3D"menuitem'+this.id_+'" ' +handler;

  str[str.length]=3D' class=3D"';

  if (this.isspace_)
  {
    str[str.length]=3D'hw_space';
  }
  else if (this.isseperator_)
  {
    str[str.length]=3D"hw_separator";
  }
  else if (this.ischecked_)
  {
    str[str.length]=3D"hw_checked";
  }
  if (this.cssclass_)
  {
    str[str.length] =3D " "+this.cssclass_;
  }

  if (this.child_)
  {
    str[str.length]=3D" hw_haschildren";
  }

  if (this.dynamicallyDisabled_ || this.isdisabled_)
  {
    str[str.length]=3D' hw_disabled';
  }
  str[str.length]=3D'"';

  str[str.length]=3D'>';
  if (this.isseperator_)
  {
    str[str.length]=3D'&nbsp;';
  }
  else
  {
    str[str.length]=3D'<a "'+this.createAnchorId()+'" href=3D"#" =
title=3D"'+this.caption_+'"><span';
    if (!this.cssclass_ && this.icon_)
    {
      str[str.length]=3D' style=3D"padding-left: =
26px;background-position:left center; background-image: =
url(\''+this.icon_+'\')"';
    }

    str[str.length]=3D'>'+this.caption_+'</span></a>';
  }

  str[str.length]=3D'</li>';
  return str.join('');
};

function alertObj(obj,pref)
{
  var pref=3Dpref||"";
  var str=3D"";
  for (var a in obj)
  {
    if (a.indexOf("on")!=3D-1)
    {
      str+=3Dpref+a+">";
      str+=3Dobj[a];
      str+=3D"<\n";
    }
  }
  return str;
}

Menu.prototype.createNewMenuRepDOM=3D function(obj)
{
  var orientation =3D this.orientation_;

  var str=3Dobj.prelayerstr+obj.str+obj.postlayerstr;
  if (this.container_)
  { // the menu has to be displayed in an other frame in an object named =
hw_menuContainer
    if (!this.theCont_)
    {
      if (this.container_=3D=3D"top")
      {
        var containername=3Dthis.containername_ || "hw_menuContainer";
        this.theCont_=3Deval("top."+containername);
        this.theDocument_ =3D top.document;
        this.theWindow_ =3D top;
      }
      else
      {
        var containername=3Dthis.containername_ || "hw_menuContainer";
        =
this.theCont_=3Deval("top.frames."+this.container_+"."+containername);
        this.theDocument_ =3D =
eval("top.frames."+this.container_+".document");
        this.theWindow_ =3D eval("top.frames."+this.container_);
      }
    }
    WriteToPageRepl(str,this.theCont_);
  }
  else if (this.frame_)
  { // menu has to be displayed in an other frame
    if (!this.theCont_)
    {
      if (this.frame_=3D=3D"top")
      {
        this.theCont_=3Dtop;
        this.theDocument_=3Dtop.document;
        this.theWindow_=3Dtop;
      }
      else
      {
        this.theCont_=3Deval("top.frames."+this.frame_);
        this.theDocument_=3Deval("top.frames."+this.frame_+".document");
        this.theWindow_=3Deval("top.frames."+this.frame_);
      }
    }
    WriteToPage(str,this.theCont_);
  }
  else
  { // display menu in the same page
    if (!this.theCont_)
    {
      this.theCont_=3Deval("window");
      this.theDocument_=3Deval("window.document");
      this.theWindow_=3Deval("window");
    }
    WriteToPage(str,this.theCont_);
  }

  this.menuCont_=3Dthis.theCont_;

  this.menuLayer_=3D this.theDocument_.getElementById('menu'+this.id_);

  for (var itemcont=3D0; itemcont< this.items_.length; itemcont++)
  {
    var it=3D this.items_[itemcont];
    if (it.isdisplayed_)
    {  // the item is displayed. For some reasons (iconbar and disabled) =
this may be not the case
      it.iLay_=3Dthis.theDocument_.getElementById("menuitem"+it.id_);
        // no need to get reference to child-image when no inverted =
version is defined
    }
  }

  this.maxItemWidth_=3Dthis.menuLayer_.offsetWidth;

  this.width_=3Dthis.menuLayer_.offsetWidth;
  this.height_=3Dthis.menuLayer_.offsetHeight || 35;
  this.inheritSizeToOpener();

  //compute first itemoffsets
  if (this.items_.length)
  {
    var firstitem =3D this.items_[0];
    this.itemOffsetx_ =3D computeOffsetLeft(firstitem.iLay_,"UL");
    this.itemOffsety_ =3D computeOffsetTop(firstitem.iLay_,"UL");
  }
  else
  {
    this.itemOffsetx_=3D0;
    this.itemOffsety_=3D0;
  }
};

Menu.prototype.initTheDocument=3D function()
{
  if (this.container_)
  { // the menu has to be displayed in an other frame in an object named =
hw_menuContainer
    if (!this.theCont_)
    {
      if (this.container_=3D=3D"top")
      {
        var containername=3Dthis.containername_ || "hw_menuContainer";
        this.theCont_=3Deval("top."+containername);
        this.theDocument_ =3D top.document;
        this.theWindow_ =3D top;
      }
      else
      {
        var containername=3Dthis.containername_ || "hw_menuContainer";
        =
this.theCont_=3Deval("top.frames."+this.container_+"."+containername);
        this.theDocument_ =3D =
eval("top.frames."+this.container_+".document");
        this.theWindow_ =3D eval("top.frames."+this.container_);
      }
    }
  }
  else if (this.frame_)
  { // menu has to be displayed in an other frame
    if (!this.theCont_)
    {
      if (this.frame_=3D=3D"top")
      {
        this.theCont_=3Dtop;
        this.theDocument_=3Dtop.document;
        this.theWindow_=3Dtop;
      }
      else
      {
        this.theCont_=3Deval("top.frames."+this.frame_);
        this.theDocument_=3Deval("top.frames."+this.frame_+".document");
        this.theWindow_=3Deval("top.frames."+this.frame_);
      }
    }
  }
  else
  { // display menu in the same page
    if (!this.theCont_)
    {
      this.theCont_=3Deval("window");
      this.theDocument_=3Deval("window.document");
      this.theWindow_=3Deval("window");
    }
  }
};

Menu.prototype.inheritSizeToOpener =3D function() {
  if (this.inheritSizeToOpener_ &&
      this.openerDiv_) {
    if (typeof this.openerDivWidth_ !=3D "number" /* store only once */) =
{  // fixes problem in case of no more menu
      this.openerDivWidth_ =3D this.openerDiv_.offsetWidth;
      this.openerDivHeight_ =3D this.openerDiv_.offsetHeight;
    }
    this.openerDiv_.style.width =3D this.width_+"px";
    this.openerDiv_.style.height =3D this.height_+"px";
  }
};

Menu.prototype.restoreOpenerSize=3Dfunction()
{
  if (this.inheritSizeToOpener_ && this.openerDiv_
      && typeof this.openerDivWidth_ !=3D "undefined" && typeof =
this.openerDivHeight_ !=3D "undefined")
  {
    this.openerDiv_.style.width=3D this.openerDivWidth_+"px";
    this.openerDiv_.style.height=3D this.openerDivHeight_+"px";
  }
};

Menu.prototype.clientHeight=3Dfunction()
{
  var y =3D 0;
  if (this.theWindow_ && this.theWindow_.innerHeight) // all except =
Explorer
  {
	y =3D this.theWindow_.innerHeight;
  }
  else {
    if (this.theDocument_ &&
        this.theDocument_.documentElement &&
        this.theDocument_.documentElement.offsetHeight)    // Explorer 6 =
Strict Mode
    {
      y =3D this.theDocument_.documentElement.offsetHeight;
    }
    else {
      if (this.theDocument_ && this.theDocument_.body) // other =
Explorers
      {
        y =3D this.theDocument_.body.offsetHeight;
      }
    }
  }
  return y;
};

Menu.prototype.clientWidth=3Dfunction()
{
  var x =3D 0;
  if (this.theWindow_ && this.theWindow_.innerWidth) // all except =
Explorer
  {
	x =3D this.theWindow_.innerWidth;
  }
  else {
    if (this.theDocument_ &&
        this.theDocument_.documentElement &&
        this.theDocument_.documentElement.offsetWidth)    // Explorer 6 =
Strict Mode
    {
      x =3D this.theDocument_.documentElement.offsetWidth;
    }
    else {
      if (this.theDocument_ && this.theDocument_.body) // other =
Explorers
      {
        x =3D this.theDocument_.body.offsetWidth;
      }
    }
  }
  return x;
};

Menu.prototype.getScrollTop =3D function()
{
  var pos =3D 0;
  if (this.theWindow_ && this.theWindow_.innerHeight) {
    pos =3D this.theWindow_.pageYOffset;
  }
  else {
    if (!this.theDocument_) return pos;

    if (this.theDocument_.scrollTop) {
      pos =3D this.theDocument_.scrollTop;
    }
  	else {
      if (this.theDocument_.documentElement &&
          this.theDocument_.documentElement.scrollTop) {
        pos =3D this.theDocument_.documentElement.scrollTop;
      }
      else {
        if (this.theDocument_.body) {
          pos =3D this.theDocument_.body.scrollTop;
        }
      }
    }
  }
  return pos;
};

Menu.prototype.getScrollLeft =3D function()
{
  var pos =3D 0;
  if (this.theWindow_ && this.theWindow_.innerWidth) {
    pos =3D this.theWindow_.pageXOffset;
  }
  else {
    if (!this.theDocument_) return pos;

    if (this.theDocument_.scrollLeft) {
      pos =3D this.theDocument_.scrollLeft;
    }
  	else {
      if (this.theDocument_.documentElement &&
          this.theDocument_.documentElement.scrollLeft) {
        pos =3D this.theDocument_.documentElement.scrollLeft;
      }
      else {
        if (this.theDocument_.body) {
          pos =3D this.theDocument_.body.scrollLeft;
        }
      }
    }
  }
  return pos;
};

Menu.prototype.showAtDOM=3Dfunction(x,y,vis,relright)
{
  if (this.frame_ && !this.container_)
  {
    if (this.frametop_)
    {
      y=3Dthis.getScrollTop()+2 ;
    }
    if (this.relright_)
    {
      x=3Dthis.getScrollLeft()+2;
    }
  }

  var x_vis_area_start =3D this.getScrollLeft();
  var x_vis_area_end   =3D x_vis_area_start+this.clientWidth();

  var xo=3Dx;
  if (relright)
  { // position is relative from the right window corner
    x=3Dx_vis_area_end-x;
  }

  var menu_overlap=3D4;

  if (this.orientation_=3D=3D"left") {
    if (x>x_vis_area_end-this.maxItemWidth_-25)
    {
      if (this.parentItem_ && =
this.parentItem_.menu_.orientation_=3D=3D"left") {
        x=3Dthis.parentItem_.menuLeft()-this.maxItemWidth_+menu_overlap;
      }
      else {
        x=3Dx_vis_area_end-this.maxItemWidth_-25;
      }
    }
    else
    {
      x=3Dx-menu_overlap;
    }
    if (x<x_vis_area_start) {
      x =3D x_vis_area_start;
    }
  }

  this.menuLayer_.style.top=3DgetCoordValue(y);
  this.menuLayer_.style.left=3DgetCoordValue(x);
  this.menuLayer_.style.visibility =3D vis;
  for (var itemcont=3D0; itemcont< this.items_.length; itemcont++)
  {
    var it =3D this.items_[itemcont];
    if (it.isdisplayed_)
    {  // the item is displayed. For some reasons (iconbar and disabled) =
this may be not the case
      it.offsetTop_  =3D computeOffsetTop(it.iLay_,"UL");
      it.offsetLeft_ =3D computeOffsetLeft(it.iLay_,"UL");
      it.offsetComputed_ =3D true;

      it.menuTop_    =3D it.offsetTop_ + y;
      if (this.container_)
      {
        it.menuLeft_=3Dthis.clientWidth()-(x+it.offsetLeft_);
      }
      else
      {
        it.menuLeft_=3Dx+it.offsetLeft_;
      }
      it.menuBottom_=3Dit.menuTop_+it.iLay_.offsetHeight;
      it.menuRight_=3Dit.menuLeft_+parseInt(this.maxItemWidth_);
    }
  }
};

function WriteToPageRepl(str,thecont) {
  if (typeof thecont=3D=3D"undefined") return;
  thecont.innerHTML=3Dstr;
}

function WriteToPage(str,thecont) {
  if (typeof thecont=3D=3D"undefined") return;

  var the_temp =3D thecont.document.getElementById("MENU_CONTAINER");
  var div_available =3D true;

  if (!the_temp) {
    the_temp =3D thecont.document.createElement("DIV");
    the_temp.id =3D "MENU_CONTAINER";
    the_temp.constructedContainers_ =3D 0;
    the_temp.usedContainers_ =3D 0;
    thecont.document.body.appendChild(the_temp);
  }

  var target_container =3D =
thecont.document.getElementById("MENU_CONTAINER_"+the_temp.usedContainers=
_);
  if (!target_container) {

    var target_container =3D thecont.document.createElement("DIV");
    target_container.id =3D "MENU_CONTAINER_"+the_temp.usedContainers_;
    the_temp.constructedContainers_++;
    the_temp.appendChild(target_container);
    var div_available =3D false;
  }
  the_temp.usedContainers_++;
  target_container.innerHTML =3D str;
  return target_container;
}

function computeOffsetTop(elem,stoptag,count)
{
  var el2=3Delem;
  var c=3D1;
  if (count!=3Dnull)
    c=3Dcount;
  var off=3Del2.offsetTop;
  while ((el2=3Del2.offsetParent))
  {
    if (el2.tagName=3D=3Dstoptag && !(--c) || el2.tagName=3D=3D"BODY" || =
el2.tagName=3D=3D"HTML") break;
    off+=3Del2.offsetTop;
  }
  return off;
}

function computeOffsetLeft(elem,stoptag,count)
{
  var el2=3Delem;
  var c=3D1;
  if (count!=3Dnull)
    c=3Dcount;
  var off=3Del2.offsetLeft;

  try {
    while ((el2=3Del2.offsetParent))
    {
      if (el2.tagName=3D=3Dstoptag && !(--c) || el2.tagName=3D=3D"BODY" =
|| el2.tagName=3D=3D"HTML") break;
      off+=3Del2.offsetLeft;
    }
  }
  catch (exc) {
// <FIXXXXXME date=3D"2010-10-22" author=3D"sweber">
// find the reason for the "unspecific error" in IE7 here
// </FIXXXXXME>
  }
  return off;
}

function computeCumulativeOffset(anElement, menu) {
  var ret =3D [0, 0];

  var _document =3D anElement.ownerDocument;
  var _window =3D _document.defaultView /* FF */ || =
_document.parentWindow /* IE */;

  var elem_offset =3D _window.$(anElement).cumulativeOffset();
  var elem_scroll_offset =3D =
_window.$(anElement).cumulativeScrollOffset();

  if (!menu.created_)
  {
    menu.initTheDocument();
  }

  var window_scroll_offset =3D [menu.getScrollLeft(), =
menu.getScrollTop()];

ret[0] =3D elem_offset[0] - elem_scroll_offset[0] + =
window_scroll_offset[0];
ret[1] =3D elem_offset[1] - elem_scroll_offset[1] + =
window_scroll_offset[1];

  return ret;
};

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/menu_dc/code/keyfunctions.js?cachekeY=515488b2-en

function KeyShort(param)=0A=
{=0A=
  if (param.exec)=0A=
  {=0A=
    if (typeof param.exec =3D=3D 'string')=0A=
      this.exec_=3Dnew Function('item',param.exec);=0A=
    else=0A=
      this.exec_=3Dparam.exec;=0A=
  }=0A=
  else=0A=
    this.exec_=3D"";=0A=
=0A=
  if (param.act)=0A=
    this.act_=3Dparam.act;=0A=
  else=0A=
    this.act_=3D"";=0A=
  if (param.actp)=0A=
    this.actp_=3Dparam.actp;=0A=
  else=0A=
    this.actp_=3D"";=0A=
=0A=
  if (param.actmult)=0A=
    this.actmult_=3Dparam.actmult;=0A=
  else=0A=
    this.actmult_=3D"";=0A=
  if (param.actpmult)=0A=
    this.actpmult_=3Dparam.actpmult;=0A=
  else=0A=
    this.actpmult_=3D"";=0A=
=0A=
  if (param.operation)=0A=
    this.operation_=3Dparam.operation;=0A=
  else=0A=
    this.operation_=3D"";=0A=
=0A=
  if (param.target)=0A=
    this.target_=3Dparam.target;=0A=
  else=0A=
    this.target_=3D"";=0A=
=0A=
  if (param.winstyle)=0A=
    this.winstyle_=3Dparam.winstyle;=0A=
=0A=
  if (param.url)=0A=
    this.url_=3Dparam.url;=0A=
  else=0A=
    this.url_=3D"";=0A=
=0A=
  if (param.opobj)=0A=
    this.opobj_=3Dparam.opobj;=0A=
  else=0A=
    this.opobj_=3Dfalse;=0A=
}=0A=
=0A=
KeyShort.prototype.exec=3Dfunction(obj)=0A=
{=0A=
  if (this.exec_){=0A=
    this.exec_();=0A=
  }=0A=
  var theurl=3D"";=0A=
  if (this.act_)=0A=
  {=0A=
    if (!this.opobj_ || typeof move !=3D"function")=0A=
      theurl=3Dobj;=0A=
    theurl+=3DgetAction(this.act_,this.actp_);=0A=
  }=0A=
  else if (this.url_)=0A=
    theurl=3Dthis.url_;=0A=
=0A=
  var theurlmult=3D"";=0A=
  if (this.actmult_)=0A=
    theurlmult=3Dobj+getAction(this.actmult_,this.actpmult_);=0A=
=0A=
  if (theurl.length)=0A=
  {=0A=
    if((this.op_ || this.opobj_) && typeof move=3D=3D"function")=0A=
    {=0A=
      =
move((this.operation_!=3D"")?this.operation_:this.actp_,{target:this.targ=
et_,url:theurl,urlmult:theurlmult,onsel:this.opobj_});=0A=
    }=0A=
    else=0A=
    {=0A=
      if (this.target_){=0A=
        if (typeof opDlg =3D=3D"function")=0A=
        {=0A=
          if (this.winstyle_)=0A=
            opDlg(theurl,this.target_,this.winstyle_);=0A=
          else=0A=
          {=0A=
            opDlg(theurl,this.target_);=0A=
          }=0A=
        }=0A=
        else=0A=
        {=0A=
          var h=3Dwindow.screen.height;=0A=
          h*=3D0.75;=0A=
          =
window.open(theurl,this.target_,"status=3Dyes,toolbar=3Dno,scrollbars=3Dy=
es,resizable=3Dyes,width=3D640,height=3D"+h);=0A=
        }=0A=
      }=0A=
      else {window.location.href=3Dtheurl;}=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
function KeyShorts()=0A=
{=0A=
  this.obj_=3D"";=0A=
  this.keyShorts_=3Dnew Array();=0A=
}=0A=
=0A=
KeyShorts.prototype.setObj=3Dfunction(obj)=0A=
{=0A=
  this.obj_=3Dobj;=0A=
}=0A=
=0A=
KeyShorts.prototype.add=3Dfunction(param)=0A=
{=0A=
  if (param.key)=0A=
  {=0A=
    this.keyShorts_[param.key]=3Dnew KeyShort(param);=0A=
    if (param.obj)=0A=
      this.obj_=3Dparam.obj;=0A=
  }=0A=
}=0A=
=0A=
KeyShorts.prototype.exec=3Dfunction(letter)=0A=
{=0A=
  if (this.keyShorts_[letter])=0A=
  {=0A=
    this.keyShorts_[letter].exec(this.obj_);=0A=
  }=0A=
}=0A=
=0A=
var keyShortcuts=3Dnew KeyShorts();=0A=
=0A=
function keypressed(e)=0A=
{=0A=
  var key=3DgetKeyObject(e);=0A=
  if (key.shiftKey && key.ctrlKey && key.keyCode!=3D0)=0A=
  {=0A=
    keyShortcuts.exec(key.letter);=0A=
  }=0A=
=0A=
  if (typeof kp !=3D "undefined" && kp.sonkeypress)=0A=
      return kp.sonkeypress(e);=0A=
  else if (navigator.appName=3D=3D"Netscape")=0A=
    return routeEvent(e); // return if handled=0A=
  else=0A=
    window.event.returnValue =3D true;=0A=
  return true;=0A=
}=0A=
=0A=
function getKeyObject(e)=0A=
{=0A=
  if (navigator.appName=3D=3D"Netscape")=0A=
    return new KeyObject(e);=0A=
  else=0A=
    return new KeyObject(window.event);=0A=
}=0A=
=0A=
function KeyObject(e)=0A=
{=0A=
  this.ALT_MASK=3D1;=0A=
  this.CONTROL_MASK=3D2;=0A=
  this.SHIFT_MASK=3D4;=0A=
  if (navigator.appName=3D=3D"Netscape")=0A=
  {=0A=
    this.keyCode=3De.which;=0A=
    this.ctrlKey=3D(e.modifiers&Event.CONTROL_MASK)?true:false;=0A=
    this.shiftKey=3D(e.modifiers&Event.SHIFT_MASK)?true:false;=0A=
    this.altKey=3D(e.modifiers&Event.ALT_MASK)?true:false;=0A=
  }=0A=
  else=0A=
  {=0A=
    this.keyCode=3De.keyCode;;=0A=
    this.ctrlKey=3De.ctrlKey;=0A=
    this.shiftKey=3De.shiftKey;=0A=
    this.altKey=3De.altKey;=0A=
  }=0A=
  =
this.modifiers=3D(this.ctrlKey?0:this.CONTROL_MASK)||(this.shiftKey?0:thi=
s.SHIFT_MASK)||(this.altKey?0:this.ALT_MASK);=0A=
  if (navigator.appName=3D=3D"Netscape")=0A=
  {=0A=
    var inc=3D0;=0A=
    if (this.ctrlKey && this.keyCode<32 && this.keyCode>0)=0A=
      inc=3D64;=0A=
    this.letter=3DString.fromCharCode(this.keyCode+inc);=0A=
  }=0A=
  else=0A=
  this.letter=3DString.fromCharCode(this.keyCode);=0A=
}=0A=
=0A=
if (navigator.appVersion.indexOf("X11",0) =3D=3D -1)=0A=
{=0A=
  if (navigator.appName=3D=3D"Netscape")=0A=
  {=0A=
    window.captureEvents(Event.KEYDOWN);=0A=
    window.onkeydown=3Dkeypressed;=0A=
  }=0A=
  else=0A=
  {=0A=
    window.document.onkeydown=3Dkeypressed;=0A=
  }=0A=
}=0A=
=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/csdialog.js?cachekeY=515488b2-en

function getWindowNamePostfixForServer () {=0A=
=0A=
  if (top.gPostFixForServer)=0A=
    return top.gPostFixForServer;=0A=
  else=0A=
    if (top.opener && typeof top.opener.top.gPostFixForServer =3D=3D =
"string")=0A=
      return top.opener.top.gPostFixForServer;=0A=
  return "";=0A=
}=0A=
=0A=
function opDlg (url, target, winstylep) {=0A=
  if (typeof window_open =3D=3D "undefined") {=0A=
    window_open =3D function (p1, p2, p3) {=0A=
      return window.open(p1, p2, p3);=0A=
    };=0A=
  }=0A=
=0A=
  if (target=3D=3D"_top") {=0A=
    top.location.href =3D url;=0A=
    return false;=0A=
  }=0A=
=0A=
  if (target=3D=3D"HW_Mainwindow" || target=3D=3D"HW_Mainframe") {=0A=
    // try to navigate in frameset and in case main frame cannot=0A=
    // be found open an extra window=0A=
    if(typeof listview_navigate =3D=3D "function")=0A=
    {=0A=
      if (!listview_navigate(url))=0A=
      {=0A=
        return window_open(url,"HW_Mainframe");=0A=
      }=0A=
    }=0A=
    else=0A=
    {=0A=
      return window_open(url,"HW_Mainframe");=0A=
    }=0A=
    return false;=0A=
  }=0A=
=0A=
  if (target=3D=3D"HW_DataRequestFrame") {=0A=
    if (top.frames.HW_DataRequestFrame) {=0A=
      top.frames.HW_DataRequestFrame.location.href =3D url;=0A=
      return false;=0A=
    }=0A=
    else {=0A=
      if ((top.window.opener && typeof(top.window.opener) =3D=3D =
"object" && !window.opener.closed)=0A=
          && (opener.top.frames.HW_DataRequestFrame)) {=0A=
        opener.top.frames.HW_DataRequestFrame.location.href =3D url;=0A=
        return false;=0A=
      }=0A=
      else=0A=
        return window_open(url,"HW_DataRequestFrame");=0A=
    }=0A=
  }=0A=
  var winstyle=3Dwinstylep||{};=0A=
=0A=
  if (!winstyle.minHeight) winstyle.minHeight=3D100;=0A=
  if (!winstyle.maxHeight) winstyle.maxHeight=3Dwindow.screen.height;=0A=
  if (!winstyle.minWidth) winstyle.minWidth=3D100;=0A=
  if (!winstyle.maxWidth) winstyle.maxWidth=3Dwindow.screen.width;=0A=
=0A=
  var h =3D ""+((typeof winstyle.height !=3D "undefined") ? =
winstyle.height : window.screen.height*0.80);=0A=
  if (h.indexOf("%")>=3D0)=0A=
    h =3D =
parseInt(h.substring(0,h.indexOf("%")))/100*window.screen.height;=0A=
  h=3DMath.min(h,winstyle.maxHeight);=0A=
  h=3DMath.max(h,winstyle.minHeight);=0A=
=0A=
  var w =3D ""+((typeof winstyle.width !=3D "undefined") ? =
winstyle.width : 800);=0A=
  if (w.indexOf("%")>=3D0)=0A=
    w =3D =
parseInt(w.substring(0,w.indexOf("%")))/100*window.screen.width;=0A=
  w=3DMath.min(w,winstyle.maxWidth);=0A=
  w=3DMath.max(w,winstyle.minWidth);=0A=
=0A=
  var win=3Dwindow;=0A=
  if (target)=0A=
    target =3D target.replace(/\W+/g,'_'); // remove not allowed =
charcters=0A=
  var target_ip_port_dep =3D target+getWindowNamePostfixForServer();=0A=
  if ((self.name =3D=3D target_ip_port_dep || self.name=3D=3Dtarget || =
target=3D=3D"")) {=0A=
    self.location.href=3Durl;=0A=
  }=0A=
  else {=0A=
    var t =3D Math.round(screen.availHeight / 2 - h / 2);=0A=
    var l =3D Math.round(screen.availWidth / 2 - w / 2);=0A=
=0A=
    if (typeof winstyle=3D=3D"undefined") {=0A=
      win =3D window_open(url,target_ip_port_dep,=0A=
                        =
"status=3Dyes,toolbar=3Dno,scrollbars=3Dyes,resizable=3Dyes,width=3D"+w+"=
,height=3D"+h+"top=3D"+t+",left"+l);=0A=
    }=0A=
    else=0A=
    {=0A=
      var winstyle_string=3D=0A=
        "status=3D"+((winstyle.status) ? winstyle.status : "yes")+=0A=
        ",toolbar=3D"+((winstyle.toolbar) ? winstyle.toolbar : "no")+=0A=
        ",scrollbars=3D"+((winstyle.scrollbars) ? winstyle.scrollbars : =
"yes")+=0A=
        ",resizable=3D"+((winstyle.resizable) ? winstyle.resizable : =
"yes")+=0A=
        ",location=3D"+((winstyle.location) ? winstyle.location : "no")+=0A=
        ",menubar=3D"+((winstyle.menubar) ? winstyle.menubar : "no");=0A=
      winstyle_string+=3D",top=3D"+ (winstyle.top || t);=0A=
      winstyle_string+=3D",left=3D"+ (winstyle.left || l);=0A=
      if (winstyle.copyhistory)=0A=
        winstyle_string+=3D ",copyhistory=3D"+ winstyle.copyhistory;=0A=
      winstyle_string+=3D",width=3D"+w+",height=3D"+h;=0A=
      win=3Dwindow_open(url,target_ip_port_dep,winstyle_string);=0A=
    }=0A=
  }=0A=
  return win;=0A=
}=0A=
  =0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/standardpage/code/csmodifyscripts.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: csmodifyscripts.js 161616 2011-02-24 13:29:40Z jschipf $=0A=
 */=0A=
function getLangres (anId, aScope, aDefault, pars) {=0A=
	var langres;=0A=
  if (typeof top.gLangresServer =3D=3D "object") {=0A=
    langres =3D top.gLangresServer;=0A=
  }=0A=
  else if (top.opener && typeof top.opener.top.gLangresServer =3D=3D =
"object") {=0A=
    langres =3D top.opener.top.gLangresServer;=0A=
  }=0A=
  if (!langres) {=0A=
    return aDefault;=0A=
  }=0A=
	if (!pars || !pars.resourceVars) {=0A=
	  return langres.getRes(anId, aScope, aDefault).replace("\\n","\n");=0A=
	}=0A=
=0A=
  var res =3D new top.com.hyperwave.res.Resource({templateKey_: anId + =
"Vars"});=0A=
  res.makeRoot();=0A=
  res.readAll(langres.readers_[aScope]);=0A=
  for (var i in pars.resourceVars) {=0A=
    res.setRes(i, '' + pars.resourceVars[i]);=0A=
  }=0A=
  var res =3D res.toString();=0A=
  if (res instanceof top.lang.Exception) {=0A=
	  return langres.getRes(anId, aScope, aDefault).replace("\\n","\n");=0A=
  }=0A=
  return res.toString().replace("\\n","\n");=0A=
}=0A=
=0A=
function selectAll(newstate) {=0A=
  var theForm=3DgetForm("bodyform");=0A=
  for(var i =3D 0; i < theForm.length; i++)=0A=
    if (typeof theForm.elements[i].checked!=3D"undefined")=0A=
      theForm.elements[i].checked =3D newstate;=0A=
}=0A=
=0A=
var HW_allcnt=3Dnew Object();=0A=
HW_allcnt.cnfmng=3D1;=0A=
HW_allcnt.delv=3D1;=0A=
HW_allcnt.freev=3D1;=0A=
HW_allcnt.setv=3D1;=0A=
HW_allcnt.hconf=3D1;=0A=
HW_allcnt.lmap=3D1;=0A=
HW_allcnt.replace=3D1;=0A=
HW_allcnt.rhist=3D1;=0A=
HW_allcnt.sconf=3D1;=0A=
HW_allcnt.vattrib=3D1;=0A=
HW_allcnt.vnotes=3D1;=0A=
HW_allcnt.vhist=3D1;=0A=
HW_allcnt.squery=3D1;=0A=
HW_allcnt.editloc=3D1;=0A=
HW_allcnt.sethome=3D1;=0A=
HW_allcnt.edtxt=3D1;=0A=
HW_allcnt.edhtml=3D1;=0A=
HW_allcnt.eddoc=3D1;=0A=
HW_allcnt.onedoc=3D1;=0A=
HW_allcnt.oneobj=3D1;=0A=
HW_allcnt.optionalParameter=3D0;=0A=
HW_allcnt.onenotlocked=3D1;=0A=
HW_allcnt.severalnotlocked=3D1e6;=0A=
HW_allcnt.onewriteable=3D1;=0A=
HW_allcnt.severalwriteable=3D1e6;=0A=
=0A=
function getAllowedCountForOperation(op)=0A=
{=0A=
  if (typeof HW_allcnt[op] !=3D "undefined")=0A=
    return HW_allcnt[op];=0A=
  else return 1e6;=0A=
}=0A=
=0A=
function getStatArray (theOperation) {=0A=
  var ostat=3Dnew Array();=0A=
  if (theOperation=3D=3D"rhist") ostat=3DArray("E");=0A=
  if (theOperation=3D=3D"cnfmng") ostat=3DArray("C","W");=0A=
  if (theOperation=3D=3D"hconf") ostat=3DArray("C");=0A=
  if (theOperation=3D=3D"sconf") ostat=3DArray("S","W");=0A=
  if (theOperation=3D=3D"squery") ostat=3DArray("W","Q");=0A=
  if (theOperation=3D=3D"editloc") ostat=3DArray("X", "Z");=0A=
  if (theOperation=3D=3D"vhist") ostat=3DArray("V");=0A=
  if (theOperation=3D=3D"freev") ostat=3DArray("R");=0A=
  if (theOperation=3D=3D"delv") ostat=3DArray("R");=0A=
  if (theOperation=3D=3D"setv") ostat=3DArray("E");=0A=
  if (theOperation=3D=3D"replace") ostat=3DArray("I");=0A=
  if (theOperation=3D=3D"check_in") ostat=3DArray("H");=0A=
  if (theOperation=3D=3D"check_out") ostat=3DArray("O");=0A=
  if (theOperation=3D=3D"eddoc") ostat=3DArray("T");=0A=
  if (theOperation=3D=3D"edit") ostat=3DArray("T","W","Q");=0A=
  if (theOperation=3D=3D"edhtml") ostat=3DArray("M");=0A=
  if (theOperation=3D=3D"edtxt") ostat=3DArray("T");=0A=
  if (theOperation=3D=3D"onedoc") ostat=3DArray("Z");=0A=
  if (theOperation=3D=3D"severaldocs") ostat=3DArray("Z");=0A=
  if (theOperation=3D=3D"severalobjs") ostat=3DArray("W");=0A=
  if (theOperation=3D=3D"copy" || theOperation=3D=3D"copys") =
ostat=3DArray("D");=0A=
// lock/unlock at the moment not possible with multiple selection=0A=
//    if (theop=3D=3D"lock") ostat=3D"L";=0A=
//    if (theop=3D=3D"unlock") ostat=3D"U";=0A=
=0A=
  if (theOperation=3D=3D"onenotlocked" || =
theOperation=3D=3D"severalnotlocked") {=0A=
    ostat=3DArray("N");=0A=
  }=0A=
=0A=
  if (theOperation=3D=3D"onewriteable" || =
theOperation=3D=3D"severalwriteable") {=0A=
    ostat=3DArray("W");=0A=
  }=0A=
  =0A=
  return ostat;=0A=
}=0A=
=0A=
function num_of_selected(theop, doAlert)=0A=
{=0A=
  if (typeof doAlert =3D=3D "undefined") {=0A=
    doAlert=3Dtrue;=0A=
  }=0A=
  // increases selected_couter whenever a checkbox is selected=0A=
  var retobj =3D {all:-1, dynamic:0};=0A=
  var theForm=3DgetForm("bodyform");=0A=
  var allobj=3Dtrue;=0A=
  =0A=
  var ostat =3D getStatArray(theop);=0A=
=0A=
  selected_counter =3D 0;=0A=
  var ncount=3D0;=0A=
  var dynamic_count =3D 0;=0A=
 =0A=
=0A=
  var length_form =3D 0;=0A=
  if (theForm) {=0A=
    length_form =3D theForm.length;=0A=
  }=0A=
  for(i =3D 0; i < length_form; i++) {=0A=
    var elem_ck =3D theForm.elements[i];=0A=
    var ename =3D elem_ck.name;=0A=
    if (elem_ck.checked =3D=3D true && ename.substring(0,8) =3D=3D =
"initname"=0A=
       || ename =3D=3D "docname")=0A=
    {=0A=
      var dstat=3Dename.substring(8,ename.length);=0A=
      var proceed =3D true;                               //in case of =
edit document, an object is=0A=
      if ((dstat.indexOf("I") !=3D -1) && theop=3D=3D"eddoc") =
//checkoutable proceed even if the document has=0A=
                                                        //not the proper =
state.=0A=
        proceed =3D false;=0A=
      if (dstat.indexOf("Y") !=3D -1)=0A=
        dynamic_count++; //count # checked dynamic objects=0A=
      if (ename!=3D"docname" && ostat.length) { // check state of =
checked element=0A=
        var found=3Dtrue;=0A=
        for (var c=3D0;c<ostat.length;c++)=0A=
        {=0A=
          if(theop!=3D"eddoc")=0A=
          {=0A=
            if (dstat.indexOf(ostat[c])=3D=3D-1)=0A=
            {=0A=
              found=3Dfalse;=0A=
              break;=0A=
            }=0A=
          }=0A=
          else=0A=
          {=0A=
            if (dstat.indexOf("W")=3D=3D-1)=0A=
            {=0A=
              found=3Dfalse;=0A=
              break;=0A=
            }=0A=
          }=0A=
        }=0A=
        // edit attributes, if object can be checked out!=0A=
        if (theop=3D=3D"mattrib")=0A=
        {=0A=
          if (dstat.indexOf("O")>=3D0)=0A=
          {=0A=
            found =3D true;=0A=
          }=0A=
          //"File Plan" object cannot be modified=0A=
          var elem_value =3D elem_ck.value;=0A=
          var cache_obj =3D gOC.getObject(elem_value);=0A=
          if (cache_obj.U =3D=3D escape("/ERMS File Plan")) {=0A=
            found =3D false;=0A=
          }=0A=
        }=0A=
        if (!found && proceed) {=0A=
          ncount++;=0A=
        }=0A=
        else {=0A=
          HWlastGOid =3D elem_ck.value;=0A=
        }=0A=
      }=0A=
      if (ename =3D=3D"docname" || !ostat.length)=0A=
      { // handle document case or when no stat is necessary=0A=
        HWlastGOid =3D elem_ck.value;=0A=
      }=0A=
      selected_counter++;=0A=
    }=0A=
  }=0A=
  if (selected_counter>0)=0A=
  {=0A=
    var allowedcount=3DgetAllowedCountForOperation(theop);=0A=
    selected_counter-=3Dncount;=0A=
    var text=3D"";=0A=
    =0A=
    if (theop=3D=3D"vattrib"){=0A=
      text =3D getLangres('dbDlgTxt1', 'stdp', "View Attributes")+':\n';=0A=
    }=0A=
    else if (theop=3D=3D"vnotes"){=0A=
      text =3D getLangres('dbDlgTxtm', 'stdp', "View Notes")+':\n';=0A=
    }=0A=
    else if (theop=3D=3D"lmap"){=0A=
      text =3D getLangres('dbDlgTxt2', 'stdp', "View Link Map")+':\n';=0A=
    }=0A=
    else if (theop=3D=3D"sconf"){=0A=
      text =3D getLangres('dbDlgTxt3', 'stdp', "This function can not be =
applied.\n\nPossible reasons:\n- No collection selected\n- No write =
access\n- No local collection")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"hconf"){=0A=
      text =3D getLangres('dbDlgTxt4', 'stdp', "This function can not be =
applied.\n\nPossible reasons:\n- No collection selected\n- No =
configuration available for this collection\n- No local =
collection")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"cnfmng"){=0A=
      text =3D getLangres('dbDlgTxt5', 'stdp', "This function can not be =
applied.\n\nPossible reasons:\n- No collection selected\n- No =
configuration available for this collection\n- No write access\n- No =
local collection")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"mattrib"){=0A=
      text =3D getLangres('dbDlgTxt6', 'stdp', "Some of the selected =
objects can not be modified.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object not checked out")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"squery"){=0A=
      text =3D getLangres('dbDlgTxtl', 'stdp', "This function can not be =
applied.\n\nPossible reasons:\n- No Saved Query selected\n- No write =
access\n- No local Saved Query")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"editloc"){=0A=
      text =3D getLangres('dbDlgTxts', 'stdp', "The selected object can =
not be edited.\n\nPossible reasons:\n- Not a document\n- No write =
access\n- Not a local document\n- Document is locked by another =
user")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"replace"){=0A=
      text =3D getLangres('dbDlgTxt7', 'stdp', "Some of the selected =
objects can not be replaced.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object not checked out\n- Object is a =
collection")+'\n';=0A=
    }=0A=
    else if(theop=3D=3D"vhist" || theop=3D=3D"rhist" || =
theop=3D=3D"freev" || theop=3D=3D"delv" || theop=3D=3D"setv"){=0A=
      text =3D getLangres('dbDlgTxt8', 'stdp', "This function can not be =
applied.\n\nPossible reasons:\n- Not under version control\n- No write =
access\n- No local document")+'\n';=0A=
    }=0A=
    else if (theop=3D=3D"copy")=0A=
      text =3D getLangres('dbDlgTxt9', 'stdp', "You are about to make a =
physical copy.\nThis can not be done with documents from a remote =
server.")+'\n';=0A=
    else if (theop=3D=3D"check_in")=0A=
      text =3D getLangres('dbDlgTxta', 'stdp', "Some of the selected =
objects can not be checked in.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object already checked in\n- Object is a =
collection")+'\n';=0A=
    else if (theop=3D=3D"check_out")=0A=
      text =3D getLangres('dbDlgTxtd', 'stdp', "Some of the selected =
objects can not be checked out.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object already checked out")+'\n';=0A=
    else if (theop=3D=3D"eddoc")=0A=
      text =3D getLangres('dbDlgTxtn', 'stdp', "The selected document =
can not be edited.\n\nPossible reasons:\n- No write access\n- No local =
document\n- Document is version controlled\n- Document is locked by =
someone else")+'\n';=0A=
    else if (theop=3D=3D"edhtml")=0A=
      text =3D getLangres('dbDlgTxto', 'stdp', "The selected document =
can not be edited.\n\nPossible reasons:\n- No HTML document\n- HTML =
document contains a Frame Set definition\n- No local document\n- =
Document is version controlled\n- Document is locked by someone =
else")+'\n';=0A=
    else if (theop=3D=3D"edtxt")=0A=
      text =3D getLangres('dbDlgTxtu', 'stdp', "The selected document =
can not be edited.\n\nPossible reasons:\n- Not an HTML or Text =
document\n- Not a local document\n- Document is locked by another =
user")+'\n';=0A=
    else if (theop=3D=3D"onedoc" || theop=3D=3D"severaldocs")=0A=
      text =3D getLangres('dbDlgTxtp', 'stdp', "This function can only =
be applied to documents.")+'\n';=0A=
    else if (theop=3D=3D"onenotlocked" || theop=3D=3D"severalnotlocked")=0A=
      text =3D getLangres('dbDlgTxtt', 'stdp', "This function can only =
be applied to unlocked objects.")+'\n';=0A=
=0A=
    if (selected_counter=3D=3D0){=0A=
      text +=3D '\n'+getLangres('dbDlgTxte', 'stdp', "The function can =
not be applied to any of the selected objects")+'.';=0A=
      if (doAlert)=0A=
      {=0A=
        alert(text);=0A=
      }=0A=
      return retobj;=0A=
    }=0A=
=0A=
    if (selected_counter>allowedcount && allowedcount !=3D 0) // "0" =
means optional parameter=0A=
    {=0A=
      text+=3D'\n'+getLangres('dbDlgTxtf', 'stdp', "The function can not =
be applied to more than %number% object(s)")+'';=0A=
      if (doAlert)=0A=
      {=0A=
        alert(text.replace(/%number%/,allowedcount));=0A=
      }=0A=
      return retobj;=0A=
    }=0A=
    else if (ncount){=0A=
      text+=3D'\n'+getLangres('dbDlgTxtg', 'stdp', "Press \"OK\" to =
continue with the remaining objects")+'.';=0A=
      if (doAlert && confirm(text)) { // deselect objects are not =
operable=0A=
        for(i =3D 0; i < theForm.length; i++){=0A=
          var elem_ck =3D theForm.elements[i];=0A=
          var ename =3D elem_ck.name;=0A=
          if (ename.substring(0,8) =3D=3D "initname"){=0A=
            var dstat=3Dename.substring(8,ename.length);=0A=
            var found=3Dfalse;=0A=
            for (var c=3D0;c<ostat.length;c++){=0A=
              if (dstat.indexOf(ostat[c])=3D=3D-1){=0A=
                elem_ck.checked =3D false;=0A=
                break;=0A=
              }=0A=
            }=0A=
            //uncheck "ERMS File Plan" object if it was checked (PR-927)=0A=
            if (theop =3D=3D "mattrib" && !found && elem_ck.checked =
=3D=3D true) {=0A=
              var cache_obj =3D gOC.getObject(elem_ck.value);=0A=
              if (cache_obj.U =3D=3D escape("/ERMS File Plan")) {=0A=
                elem_ck.checked =3D false;=0A=
              }=0A=
            }=0A=
          }=0A=
        }=0A=
      }=0A=
      else=0A=
        return retobj;=0A=
    }=0A=
  }=0A=
  return {all:selected_counter, dynamic:dynamic_count};=0A=
}=0A=
/* <edit user=3D"PWE" date=3D"2006-12-11"> */=0A=
function forEachAlert(n,obj)=0A=
{=0A=
    var dump =3D "\n";=0A=
    for ( keyVar in obj )=0A=
    {=0A=
       dump +=3D "    " + keyVar + " [" + obj[keyVar] + "]\n";=0A=
    }=0A=
    //alert("obj =3D\n{"+dump+"}");=0A=
}=0A=
/* </edit> */=0A=
=0A=
// This function does basically the same as "num_of_selected" with the =
difference=0A=
// that it does not use the checkboxes to get the selected objects. The =
object=0A=
// that is used for "operation-allowed" checks is given with the =
parameter theAttrObject.=0A=
// The function is used by the context-menu in editmode.=0A=
function num_of_selected_attrobject (theop, theAttrObject,doAlert)=0A=
{=0A=
  var retobj =3D {all:-1, dynamic:0};=0A=
  var selected_object =3D theAttrObject;=0A=
  var ostat =3D getStatArray(theop);=0A=
  var selected_counter =3D 0;=0A=
  var dynamic_count =3D 0;=0A=
  var dstat =3D selected_object.status;=0A=
  =0A=
  if (dstat.indexOf("Y") !=3D -1)=0A=
    dynamic_count++; //count # checked dynamic objects=0A=
=0A=
  var selection_valid =3D true;=0A=
  if (theop=3D=3D"eddoc") {=0A=
    // in case of edit document, an object is=0A=
    // checkoutable proceed even if the document has=0A=
    // not the proper state.=0A=
    if (dstat.indexOf("I")=3D=3D-1 && dstat.indexOf("W")=3D=3D-1) {=0A=
      selection_valid =3D false;=0A=
    }=0A=
  }=0A=
  else {=0A=
    for (var c=3D0;c<ostat.length;c++) {=0A=
      if (dstat.indexOf(ostat[c])=3D=3D-1) {=0A=
        selection_valid =3D false;=0A=
        break;=0A=
      }=0A=
    }=0A=
  }=0A=
  if (selection_valid) {=0A=
    HWlastGOid =3D selected_object.goid;=0A=
    selected_counter++;=0A=
  }=0A=
  else {=0A=
    if(doAlert)=0A=
    {=0A=
      var text=3D"";=0A=
      if (theop=3D=3D"check_in")=0A=
        text =3D getLangres('dbDlgTxta_single', 'stdp', "The selected =
object can not be checked in.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object already checked in\n- Object is a =
collection")+'\n';=0A=
      else if (theop=3D=3D"check_out")=0A=
        text =3D getLangres('dbDlgTxtd_single', 'stdp', "The selected =
object can not be checked out.\n\nPossible reasons:\n- No local =
document\n- No write access\n- Object already checked out")+'\n';=0A=
      else if (theop=3D=3D"eddoc")=0A=
        text =3D getLangres('dbDlgTxtn', 'stdp', "The selected document =
can not be edited.\n\nPossible reasons:\n- No write access\n- No local =
document\n- Document is version controlled\n- Document is locked by =
someone else")+'\n';=0A=
=0A=
      text +=3D '\n'+getLangres('dbDlgTxte_single', 'stdp', "The =
function can not be applied to the selected object")+'.';=0A=
      alert(text);=0A=
    }=0A=
    return retobj;=0A=
  }=0A=
=0A=
  return {all:selected_counter, dynamic:dynamic_count};=0A=
}=0A=
=0A=
=0A=
var HWlastGOid =3D gCurrentGOid;=0A=
=0A=
/* <edit user=3D"PWE" date=3D"2006-12-11"> */=0A=
function forEachAlert(n,obj)=0A=
{=0A=
    var dump =3D "\n";=0A=
    for ( keyVar in obj )=0A=
    {=0A=
       dump +=3D "    " + keyVar + " [" + obj[keyVar] + "]\n";=0A=
    }=0A=
    //alert("obj =3D\n{"+dump+"}");=0A=
}=0A=
/* </edit> */=0A=
=0A=
function move(theop,p)=0A=
{=0A=
  if (!p.target)=0A=
    p.target=3D"";=0A=
  if (!p.url)=0A=
    p.url=3D"";=0A=
  var op=3D"move";=0A=
  if (typeof theop =3D=3D"string")=0A=
    op=3Dtheop;=0A=
  if (window.name =3D=3D "Verschieben")=0A=
    alert('\n'+getLangres('dbDlgTxth', 'stdp', "Please press \"move\" in =
the main window")+'.');=0A=
  else {=0A=
   if (p.attrobj && p.attrobj.goid) {=0A=
     var numsel =3D num_of_selected_attrobject(op, p.attrobj);=0A=
   }=0A=
   else {=0A=
     var numsel =3D num_of_selected(op);=0A=
   }=0A=
   if (numsel.all =3D=3D -1) return;=0A=
=0A=
    var allowed_count =3D getAllowedCountForOperation(theop);=0A=
    if (numsel.all =3D=3D 0 && allowed_count !=3D 0) // "0" means =
optional parameter=0A=
    {=0A=
      if (allowed_count=3D=3D1)=0A=
        alert('\n'+getLangres('dbDlgTxti', 'stdp', "In order to use this =
function exactly one object has to be selected")+'.');=0A=
      else=0A=
        alert('\n'+getLangres('dbDlgTxtj', 'stdp', "In order to use this =
function at least one object has to be selected")+'.');=0A=
    }=0A=
    else {=0A=
      var relurl=3Dp.url;=0A=
      var target=3Dp.target;=0A=
      if (relurl.indexOf("editdoc")!=3D-1 && numsel.all=3D=3D1 &&=0A=
          typeof gEditLocallyEnabled =3D=3D "boolean" && =
gEditLocallyEnabled &&=0A=
          typeof top.EditLocallyDialogController !=3D "undefined") { // =
in case the editlocally-component is not updated yet, behave like before=0A=
        var csobject =3D null;=0A=
        if (p.attrobj) {=0A=
          var csobject =3D top.gObjectCache.getObject(p.attrobj.goid);=0A=
        }=0A=
        else if (p.onsel) {=0A=
          var csobject =3D top.gObjectCache.getObject(HWlastGOid);=0A=
        }=0A=
        if (csobject && (csobject.DT =3D=3D "Generic" || csobject.DT =
=3D=3D "Image")) {=0A=
          =
top.EditLocallyDialogController.static_.openDocument(csobject.G, =
csobject.T);=0A=
          return;=0A=
        }=0A=
      }=0A=
      if(relurl.indexOf("editdoc")!=3D-1 && numsel.all>1) {=0A=
        relurl =3D relurl.replace(/editdoc/,"modifyobjects"); //change =
action=0A=
      }=0A=
      else if (numsel.all>1)=0A=
      { // multiple selection=0A=
        var felemNames=3Dp.namemult?p.namemult:p.name;=0A=
        if (felemNames)=0A=
        { // name indicates to call submitform=0A=
          submitform(theop);=0A=
          return;=0A=
        }=0A=
        target=3Dp.targetmult||p.target;=0A=
        relurl=3Dp.urlmult?p.urlmult:relurl;=0A=
      }=0A=
      else=0A=
      { // only one selected=0A=
        if (p.name)=0A=
        {=0A=
          submitform(theop);=0A=
          return;=0A=
        }=0A=
        if (p.onsel)=0A=
        {=0A=
          var obj =3D top.gObjectCache.getObject(HWlastGOid);=0A=
          =0A=
          var url =3D obj.U;=0A=
          var idx =3D url.indexOf(";internal");=0A=
          if (idx>0)=0A=
            url =3D url.substring(0,idx);=0A=
          var idx =3D url.indexOf("?");=0A=
          if (idx>0)=0A=
            url =3D url.substring(0,idx);=0A=
          =0A=
          // sometimes gCurrentVersionUrl and p.url contains ";internal"=0A=
          // (e.g. in case navigating on a version controlled document =
and selecting edit)=0A=
          //relurl=3D""+url+gCurrentVersionUrl+p.url;=0A=
          relurl =3D url + gCurrentVersionUrl;=0A=
          if (relurl.indexOf(";internal") !=3D -1 && =
p.url.indexOf(";internal") !=3D -1) {=0A=
            relurl +=3D p.url.replace(/\;internal/, "");=0A=
          }=0A=
          else {=0A=
            relurl +=3D p.url;=0A=
          }=0A=
        }=0A=
      }=0A=
=0A=
    /* <edit user=3D"PWE" date=3D"2006-12-07"> */=0A=
    // ----------------------------------------------------------=0A=
    // Add special "move assign to" functionality...=0A=
    // i.e. redirect to the user collection=0A=
    if( op =3D=3D "moveassignto" )=0A=
    {=0A=
        //alert("BEFORE  : relurl =3D=3D ["+relurl+"]");=0A=
        var idx =3D relurl.indexOf(";internal");=0A=
        if( idx > 0 )=0A=
        {=0A=
            relurl =3D relurl.substring(idx,relurl.length);=0A=
        }=0A=
        relurl =3D '/Documents/Users' + relurl;=0A=
        //alert("AFTER   : relurl =3D=3D ["+relurl+"]");=0A=
    }=0A=
    // ----------------------------------------------------------=0A=
    /* </edit> */=0A=
    =0A=
     /* BMBC code for File ePost */=0A=
    // ----------------------------------------------------------=0A=
    if( op =3D=3D "movefilepost" )=0A=
    {=0A=
        //alert("BEFORE  : relurl =3D=3D ["+relurl+"]");=0A=
        var idx =3D relurl.indexOf(";internal");=0A=
        if( idx > 0 )=0A=
        {=0A=
            relurl =3D relurl.substring(idx,relurl.length);=0A=
        }=0A=
        relurl =3D '/Documents' + relurl;=0A=
    }=0A=
    // ----------------------------------------------------------=0A=
    /* End of BMBC code for File ePost */=0A=
=0A=
      if (p.action =3D=3D "save")=0A=
      {=0A=
        if (top.frames.HW_DataRequestFrame) {=0A=
          top.frames.HW_DataRequestFrame.location.href =3D relurl;=0A=
        }=0A=
        else {=0A=
          window.location.href=3Drelurl;=0A=
        }=0A=
        return;=0A=
      }=0A=
=0A=
      var opDlgUrl=3Drelurl;=0A=
      if (p.submit && target!=3D"HW_DataRequestFrame" && =
target!=3D"HW_Mainwindow")=0A=
      { // open an empty dialog and submit the form to this dialog=0A=
        var opDlgUrl=3D"/wavemaster.internal/webapp/lib/empty.html";=0A=
      }=0A=
      if (target !=3D "_self" && target!=3D"HW_DataRequestFrame" && =
target!=3D"HW_Mainwindow") {=0A=
        if (p.winstyle) {=0A=
          opDlg(opDlgUrl,target,p.winstyle); }=0A=
        else {=0A=
          opDlg(opDlgUrl,target);=0A=
        }=0A=
      }=0A=
    =0A=
      if (p.submit)=0A=
      {  // and now submit the form=0A=
        submitform(op, {target: target, url: relurl, attrobj: =
p.attrobj});=0A=
      }=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
function submitform(action, params)=0A=
{=0A=
  // restore form element names renamed later in this function=0A=
  if (typeof g_new1_origelem !=3D "undefined")=0A=
  {=0A=
    g_new1_origelem.name =3D "new1";=0A=
    g_new1_origelem =3D undefined;=0A=
  }=0A=
  if (typeof g_new2_origelem !=3D "undefined")=0A=
  {=0A=
    g_new2_origelem.name =3D "new2";=0A=
    g_new2_origelem =3D undefined;=0A=
  }=0A=
=0A=
  var current_url =3D gCurrentUrl.replace(/[\;\?\#].*$/, "");=0A=
=0A=
  // clear unique-cache if it exists=0A=
  if (top.HW_treeview_unique)=0A=
    top.HW_treeview_unique=3D{};=0A=
=0A=
  nsbform=3Dtrue; // is querried by menu to determine if this function =
is present=0A=
  var pars=3Dparams||{};=0A=
  var theForm=3DgetForm("bodyform");=0A=
  confirmed =3D true;=0A=
=0A=
  // set the target to the default (it could have been overwritten by a =
DC method that doesn't trigger a reload of the=0A=
  // page -> DC target still in place !=0A=
  theForm.target =3D "";=0A=
=0A=
  var act_pars =3D ""; // action parameters=0A=
  if (action.indexOf("search") !=3D -1 && typeof ParameterHandler !=3D =
"undefined")=0A=
  { // check for a search action and whether the ParameterHandler is =
included=0A=
    // for menu search actions, we must count up the history length if =
present (stored in action parameters)=0A=
    var lpath =3D '' + location; // because of 'location.pathname' in IE =
was errornous -> Error: A null reference pointer was passed to the stub.=0A=
    var idx0 =3D lpath.indexOf(";internal&");=0A=
    if (idx0 !=3D -1) {=0A=
      var idx1 =3D lpath.indexOf("&Parameter=3D", idx0);=0A=
      if (idx1 !=3D -1) {=0A=
        idx1 +=3D 11;=0A=
        var idx2 =3D lpath.indexOf("&", idx1);=0A=
        if (idx2 =3D=3D -1) {=0A=
          idx2 =3D lpath.length;=0A=
        }=0A=
        act_pars =3D new =
ParameterHandler(decodeURIComponent(lpath.substring(idx1, idx2)));=0A=
        var hist =3D act_pars.get("HistoryLength");=0A=
        if (hist.length)=0A=
          act_pars.reset("HistoryLength", Number(hist[0]) + 1);=0A=
      }=0A=
    }=0A=
  }=0A=
  // in case of OrganizationalUnit we want to execute move=0A=
  if (action.indexOf("OrganizationalUnit")=3D=3D0)=0A=
    action=3Daction.replace("OrganizationalUnit","move");=0A=
    =0A=
    //if (action.indexOf("link") =3D=3D 0 || action.indexOf("copy") =
=3D=3D 0 || action=3D=3D"dcexecute"=0A=
    //  || action.indexOf("delete")=3D=3D0 || =
action.indexOf("move")=3D=3D0)=0A=
  	//{=0A=
	  //  theForm.new2.value =3D gMoveCopyParentGOid;=0A=
  	//  theForm.new2.name =3D "NOATTR_PARENT";=0A=
  	//}=0A=
=0A=
  if (action.indexOf("move")=3D=3D0) // handles "move" and "movesearch"=0A=
  {=0A=
    var numsel =3D num_of_selected(action);=0A=
    // ERS - add support for manage records=0A=
    // Added for ERMS=0A=
    if ((action.indexOf("Record") !=3D -1)=0A=
        || (action.indexOf("Class") !=3D -1)=0A=
        || (action.indexOf("Folder") !=3D -1)) {=0A=
      action =3D "move";=0A=
    }=0A=
    =0A=
    if (typeof gMoveObjectsUrl =3D=3D "string") {=0A=
      theForm.action =3D gMoveObjectsUrl;=0A=
    }=0A=
    else {=0A=
      theForm.action =3D =
current_url+";internal&action=3D"+action+".objects.action" + act_pars;=0A=
    }=0A=
    =0A=
    if (numsel.dynamic)=0A=
      confirmed =3D confirm(getLangres('dbDlgTxtr', 'stdp', "One or more =
of the selected objects are DYNAMIC.\nAre you sure you want to move all =
marked objects?"));=0A=
  } else if (action.indexOf("link") =3D=3D 0) {=0A=
    // ERS - add support for manage records=0A=
    if ((action.indexOf("Record") !=3D -1)=0A=
        || (action.indexOf("Class") !=3D -1)=0A=
        || (action.indexOf("Folder") !=3D -1)=0A=
        || (action.indexOf("objects") !=3D -1)) {=0A=
      action =3D "link";=0A=
    }=0A=
=0A=
    theForm.action =3D current_url+";internal&action=3D" + action + =
".objects.action" + act_pars;=0A=
  } else if (action.indexOf("copy") =3D=3D 0) {=0A=
    // ERS - add support for manage records=0A=
    if ((action.indexOf("Record") !=3D -1)=0A=
        || (action.indexOf("Class") !=3D -1)=0A=
        || (action.indexOf("Folder") !=3D -1)) {=0A=
      action =3D "copy";=0A=
    }=0A=
=0A=
    theForm.action =3D current_url+";internal&action=3D" + action + =
".action" + act_pars;=0A=
  } else if (action =3D=3D "copys") {=0A=
=0A=
    theForm.target=3D"dupset";=0A=
    theForm.new1.name =3D "duplicateState";=0A=
    theForm.new1.value =3D gDuplicateCheckLinks;=0A=
        =0A=
    theForm.action =3D =
current_url+";internal&action=3Dduplicate.set.action";=0A=
    opDlg("/wavemaster.internal/webapp/lib/empty.html","dupset");=0A=
  } else if (action =3D=3D "check_in" || action =3D=3D "check_out") {=0A=
    if (pars.attrobj) {=0A=
      var numsel =3D num_of_selected_attrobject(action, pars.attrobj);=0A=
      if (numsel.all>0) {=0A=
        singleSelectObject(pars.attrobj.goid);=0A=
      }=0A=
    }=0A=
    else {=0A=
      var numsel =3D num_of_selected(action);=0A=
    }=0A=
    if (numsel.all =3D=3D -1) return false;=0A=
    if (numsel.all =3D=3D 0)=0A=
    {=0A=
      alert('\n'+getLangres('dbDlgTxtj', 'stdp', "In order to use this =
function at least one object has to be selected")+'.');=0A=
      return false;=0A=
    }=0A=
    if (action =3D=3D "check_in")=0A=
      theForm.action =3D current_url+";internal&action=3Dcheckin.action";=0A=
    else if (action =3D=3D "check_out")=0A=
      theForm.action =3D =
current_url+";internal&action=3Dcheckout.action";=0A=
  }=0A=
  else if (action.indexOf("delete")=3D=3D0) // handles "delete" and =
"deletesearch"=0A=
  {=0A=
    var numsel =3D num_of_selected(action);=0A=
    if (numsel.all =3D=3D -1) return false;=0A=
    if (numsel.all =3D=3D 0){=0A=
      alert('\n'+getLangres('dbDlgTxtj', 'stdp', "In order to use this =
function at least one object has to be selected.", pars) + '.');=0A=
      return false;=0A=
    }=0A=
    if (typeof gDeleteObjectsUrl =3D=3D "string") {=0A=
      theForm.action =3D gDeleteObjectsUrl;=0A=
    }=0A=
    else {=0A=
      theForm.action =3D =
gDeleteParentUrl+";internal&action=3D"+action+".objects.action" + =
act_pars;=0A=
    }=0A=
      =0A=
    if (numsel.dynamic)=0A=
      confirmed =3D confirm(getLangres('dbDlgTxtq', 'stdp', "One or more =
of the selected objects are DYNAMIC.\nAre you sure you want to =
permanently delete all marked documents, collections and content?", =
pars));=0A=
    else=0A=
      confirmed =3D confirm(getLangres('dbDlgTxtk', 'stdp', "\nAre you =
sure you want to permanently delete all marked documents, collections =
and content?", pars));=0A=
  }=0A=
  else {=0A=
    theForm.action =3D pars.url;=0A=
=0A=
    if (pars.target !=3D "_self" && pars.target !=3D =
"HW_DataRequestFrame") {=0A=
      theForm.target =3D pars.target + getWindowNamePostfixForServer();=0A=
    }=0A=
    else {=0A=
      theForm.target =3D pars.target;=0A=
    }=0A=
  }=0A=
=0A=
  if (confirmed)=0A=
  {=0A=
    if (action.indexOf("link") =3D=3D 0 || action.indexOf("copy") =3D=3D =
0 || action=3D=3D"dcexecute"=0A=
      || action.indexOf("delete")=3D=3D0 || =
action.indexOf("move")=3D=3D0)=0A=
    {=0A=
      g_new2_origelem =3D theForm.new2; // needed in cancel case to =
restore the original name=0A=
      theForm.new2.value =3D gMoveCopyParentGOid;=0A=
      theForm.new2.name =3D "NOATTR_PARENT";=0A=
    }=0A=
    if (action =3D=3D "copys") {=0A=
      g_new1_origelem =3D theForm.new1; // needed in cancel case to =
restore the original name=0A=
      theForm.new1.value =3D gDuplicateCheckLinks;=0A=
      theForm.new1.name =3D "duplicateState";=0A=
    }=0A=
    =0A=
    //Duplicate/Create Shortcut in Searchresult dialog -> We want the =
main window to reload.=0A=
    if ((window.name!=3D"HW_Mainwindow" || window.name!=3D"HW_Mainframe")=0A=
      && (action =3D=3D "link" || action=3D=3D"copy"))=0A=
      theForm.target=3D"HW_Mainframe";=0A=
=0A=
    // Move/Delete in Searchresult dialog -> We want to submit the =
searchresult dialog=0A=
    if (action=3D=3D"linksearch" || action=3D=3D"copysearch" || =
action=3D=3D"movesearch" || action=3D=3D"deletesearch")=0A=
      theForm.target=3D"";=0A=
=0A=
    if (!pars.target || pars.target=3D=3D"HW_Mainframe")=0A=
      window.focus();=0A=
    if(typeof theForm.releaseprogress !=3D "undefined")=0A=
      theForm.releaseprogress.value=3D" ";=0A=
    =0A=
    if (action.indexOf("move")=3D=3D0)=0A=
    {// remove the current object from the objectcache to prevent wrong =
displays.=0A=
      removeCurrentObjectFromCache();=0A=
    }=0A=
    =0A=
    if (action =3D=3D "copy" || action =3D=3D "delete" ||=0A=
        action =3D=3D "move" || action =3D=3D "link" ||=0A=
        action =3D=3D "check_out" || action =3D=3D "check_in") {=0A=
      var med =3D {};=0A=
      med.onActionDone =3D function (result, data, window) {=0A=
        var continue_ =3D hw.getFramework().actionDone(result, data, =
window);=0A=
        if (continue_ !=3D=3D false) {=0A=
=0A=
          var curr_url =3D =
top.hw.util.Url.static_.parseUrl(location.href);=0A=
          if (curr_url.action =3D=3D "forcetemplates.action" ||=0A=
              curr_url.action =3D=3D "image.action") {=0A=
            var url =3D top.hw.util.Url.static_.getUrl({url: =
theForm.action, action: "forcetemplates.action"});=0A=
          }=0A=
          else {=0A=
            var url =3D top.hw.util.Url.static_.getUrl({url: =
theForm.action});=0A=
          }=0A=
          =
top.FrameSetMediator.static_.getInstance().getApplicationView().replace(u=
rl);=0A=
        }=0A=
=0A=
        return hw.getFramework().static_.STOP;=0A=
      };=0A=
      med.onActionError =3D function (result, data, window) {=0A=
=0A=
        var continue_ =3D hw.getFramework().actionError(result, data, =
window);=0A=
        if (continue_ !=3D=3D false) {=0A=
=0A=
          var dialog =3D hw.getFramework().displayError(result);=0A=
          dialog.addEventListener(dialog.static_.EVENTS.CLOSE, function =
() {=0A=
              =
top.FrameSetMediator.static_.getInstance().getApplicationView().refresh()=
;=0A=
            });=0A=
        }=0A=
        =0A=
        return hw.getFramework().static_.STOP;=0A=
      };=0A=
      hw.getFramework().ajaxRequest({form: theForm}, med, window);=0A=
      return;=0A=
    }=0A=
=0A=
    theForm.submit();=0A=
    return true;=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
function removeCurrentObjectFromCache()=0A=
{=0A=
  theForm=3DgetForm("bodyform");=0A=
  var length_form =3D 0;=0A=
  if (theForm) {=0A=
    length_form =3D theForm.length;=0A=
  }=0A=
  for(i =3D 0; i < length_form; i++) {=0A=
    var ename=3DtheForm.elements[i].name;=0A=
    if (ename =3D=3D "docname")=0A=
    { // this is the case when we are directly on an document, here we =
have to remove the object from the cs object cache=0A=
      top.gObjectCache.deleteObject(theForm.elements[i].value);=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
// selects the given object while deselecting all other =
objects/checkboxes=0A=
function singleSelectObject (theSelectionGOid) {=0A=
  // check the corresponding checkbox to submit the correct values=0A=
  var checkbox_elems =3D document.getElementsByTagName("input");=0A=
  for (var i=3D0; i<checkbox_elems.length; i++) {=0A=
    if (checkbox_elems[i].name.substring(0,8) =3D=3D "initname") {=0A=
    	if (checkbox_elems[i].value =3D=3D theSelectionGOid) {=0A=
    	  checkbox_elems[i].checked =3D true;=0A=
    	}=0A=
    	else {=0A=
    	  checkbox_elems[i].checked =3D false;=0A=
    	}=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
// opens selected documents in a new browser window=0A=
function openDocuments() {=0A=
  var numsel =3D num_of_selected("severaldocs");=0A=
  if (numsel.all < 1) {=0A=
    if (numsel.all =3D=3D 0) {=0A=
      alert(getLangres('dbDlgTxtj', 'stdp', "In order to use this =
function at least one object has to be selected"));=0A=
    }=0A=
    return;=0A=
  }=0A=
  var e =3D getForm("bodyform").elements;=0A=
  for (var i =3D 0; i <e.length; i ++) {=0A=
    var c =3D e[i];=0A=
    if (c.name.match(/^initname/) && c.checked) {=0A=
      opDlg("/"+top.gObjectCache.getObject(c.value).G + =
(top.gObjectCache.getObject(c.value).DT =3D=3D "text" ? =
"?hyperwave=3Daction=3Dplain.action" : ""), "doc" + c.value, {menubar: =
"yes"});=0A=
    }=0A=
  }=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/datefunctions.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id$=0A=
 */=0A=
function getLibResource(resid, fallback)=0A=
{=0A=
  if (typeof fallback !=3D "string") {=0A=
    fallback =3D resid;=0A=
  }=0A=
=0A=
  if (getLibResource.getRes) {=0A=
    return getLibResource.getRes(resid) || fallback;=0A=
  }=0A=
=0A=
  if (!getLibResource.cache_) {=0A=
    var filename =3D "webapp/lib/langres/dateformat.%lang%.xml";=0A=
    getLibResource.cache_ =3D new =
com.hyperwave.res.XMLResourceReader({xmlFileName_: filename});=0A=
  }=0A=
=0A=
  return getLibResource.cache_.getRes(resid) || fallback;=0A=
}=0A=
=0A=
if (typeof document !=3D "undefined") {=0A=
  var language=3Ddocument.cookie.match(/LANGUAGE=3D(..)/);=0A=
  document.writeln('<script type=3D"text/javascript" =
src=3D"/hw_temporary_objects;internal&action=3Dres.action?file=3Dwebapp/l=
ib/langres/dateformat.%lang%.xml&func=3DgetLibResource.getRes&lang=3D'+(l=
anguage ? language[1] : '--')+'"></script>');=0A=
}=0A=
=0A=
function SplitArr(str)=0A=
{=0A=
  return removeWhiteS(str).split(/\s+/);=0A=
}=0A=
=0A=
function removeWhiteS(str)=0A=
{=0A=
  return str.replace(/^\s+/, "").replace(/\s+$/, "");=0A=
}=0A=
=0A=
function leapYear(Year) {=0A=
  if ((Year % 4) =3D=3D 0 && (Year % 100) !=3D 0 || (Year % 400) =3D=3D =
0)=0A=
    return 1;=0A=
  else=0A=
    return 0;=0A=
}=0A=
=0A=
function norm(istr)=0A=
{=0A=
  istr +=3D "";=0A=
  if (istr.length < 2)=0A=
    return "0" + istr;=0A=
  return istr;=0A=
}=0A=
=0A=
function outDate(darr, how, friendly /* default is `true` */, ref_hints)=0A=
{=0A=
  ref_hints =3D ref_hints || {};=0A=
  if (darr.getDate) { // check whether function getDate exists -> it's a =
Date=0A=
    var dh =3D {Y: darr.getFullYear(),=0A=
              M: darr.getMonth() + 1,=0A=
              D: darr.getDate(),=0A=
              h: darr.getHours(),=0A=
              m: darr.getMinutes(),=0A=
              s: darr.getSeconds()};=0A=
  }=0A=
  else {=0A=
    var dh =3D {Y: darr.year - 0,=0A=
              M: darr.month - 0,=0A=
              D: darr.day - 0,=0A=
              h: darr.hour - 0,=0A=
              m: darr.minute - 0,=0A=
              s: darr.second - 0};=0A=
  }=0A=
  var tt_str =3D dh.h < 12 ? "AM" : "PM";=0A=
=0A=
  var contains_friendly =3D how.match(getFriendlyDate.regexp.f);=0A=
  var contains_normalfriendly =3D how.match(getFriendlyDate.regexp.F);=0A=
  var contains_tt =3D how.match(getFriendlyDate.regexp.tt);=0A=
  var dateString =3D how;=0A=
=0A=
  var is_today =3D dh.D =3D=3D getFriendlyDate.today.D && dh.M =3D=3D =
getFriendlyDate.today.M && dh.Y =3D=3D getFriendlyDate.today.Y;=0A=
  var is_year =3D dh.Y =3D=3D getFriendlyDate.today.Y;=0A=
=0A=
  if (contains_tt) {=0A=
    if (dh.h =3D=3D 24 && dh.m =3D=3D 0 && dh.s =3D=3D 0) {=0A=
      dh.h =3D 23;=0A=
      dh.m =3D 59;=0A=
      dh.s =3D 59;=0A=
    }=0A=
    if (dh.h > 12) {=0A=
      dh.h -=3D 12;=0A=
    }=0A=
    else if (dh.h =3D=3D 0) {=0A=
      dh.h =3D 12;=0A=
    }=0A=
  }=0A=
=0A=
  if (friendly =3D=3D=3D false) {=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.t, "$1");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.T, "$1");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.y, "$1");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.Y, "$1");=0A=
  }=0A=
  else {=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.t, is_today =
? "$1": "");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.T, is_today =
? "": "$1");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.y, is_year =
? "$1": "");=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.Y, is_year =
? "": "$1");=0A=
  }=0A=
=0A=
  dateString =3D dateString.replace(/m+/, norm(dh.m));=0A=
  dateString =3D dateString.replace(/s+/, norm(dh.s));=0A=
=0A=
  if ((contains_friendly || contains_normalfriendly) && friendly !=3D=3D =
false)=0A=
  { // we have a friendly date=0A=
    dateString =3D dateString.replace(/h+/, dh.h);=0A=
    var friendlyDate =3D getFriendlyDate(dh, ref_hints);=0A=
    if (friendlyDate && contains_friendly)=0A=
    {=0A=
      dateString =3D dateString.replace(getFriendlyDate.regexp.f, =
friendlyDate);=0A=
    }=0A=
    else=0A=
    {=0A=
      dateString =3D dateString.replace(getFriendlyDate.regexp.f, "$1");=0A=
      dateString =3D dateString.replace(getFriendlyDate.regexp.F, "$1");=0A=
      dateString =3D dateString.replace(/D+/, dh.D);=0A=
      dateString =3D dateString.replace(/Y+/, dh.Y);=0A=
      dateString =3D dateString.replace(/M+/, getFriendlyMonth(dh));=0A=
    }=0A=
  }=0A=
  else {=0A=
    dateString =3D dateString.replace(getFriendlyDate.regexp.f, "$1");=0A=
    dateString =3D dateString.replace(/h+/, norm(dh.h));=0A=
    dateString =3D dateString.replace(/D+/, norm(dh.D));=0A=
    dateString =3D dateString.replace(/Y+/, dh.Y);=0A=
    dateString =3D dateString.replace(/M+/, norm(dh.M));=0A=
  }=0A=
=0A=
  dateString =3D dateString.replace(getFriendlyDate.regexp.tt, tt_str);=0A=
  dateString =3D dateString.replace(getFriendlyDate.regexp.ESC, "$1");=0A=
=0A=
  return dateString;=0A=
}=0A=
=0A=
function setFriendlyDate()=0A=
{=0A=
  getFriendlyDate.current_date=3Dnew Date();=0A=
  getFriendlyDate.current_date.setHours(0);=0A=
  getFriendlyDate.current_date.setMinutes(0);=0A=
  getFriendlyDate.current_date.setSeconds(0);=0A=
  getFriendlyDate.current_date.setMilliseconds(0);=0A=
  getFriendlyDate.today =3D {Y: =
getFriendlyDate.current_date.getFullYear(),=0A=
                           M: getFriendlyDate.current_date.getMonth() + =
1,=0A=
                           D: getFriendlyDate.current_date.getDate()};=0A=
  getFriendlyDate.regexp =3D {t: /t\((.*?)t\)/g,=0A=
                            T: /T\((.*?)T\)/g,=0A=
                            y: /y\((.*?)y\)/g,=0A=
                            Y: /Y\((.*?)Y\)/g,=0A=
                            f: /f\((.*?)f\)/g,=0A=
                            F: /F\((.*?)F\)/g,=0A=
                            ESC: /\\([\s\S])/g,=0A=
                            tt: /tt\s*$/};=0A=
  if (typeof setTimeout !=3D "undefined")=0A=
  {=0A=
  // refresh current_date cache at the end of the day=0A=
    var tomorrow=3Dnew Date();=0A=
    tomorrow.setHours(24);=0A=
    tomorrow.setMinutes(0);=0A=
    tomorrow.setSeconds(0);=0A=
    tomorrow.setMilliseconds(0);=0A=
    var now=3Dnew Date();=0A=
    setTimeout(setFriendlyDate,tomorrow-now+1000);=0A=
  }=0A=
}=0A=
setFriendlyDate();=0A=
=0A=
=0A=
function getFriendlyDate(dateObject, ref_hints)=0A=
{=0A=
  ref_hints =3D ref_hints || {};=0A=
  var compare_date=3Dnew Date(parseInt(dateObject.Y,10),=0A=
                            parseInt(dateObject.M,10)-1,=0A=
                            parseInt(dateObject.D,10));=0A=
=0A=
  var =
the_difference=3D-(getFriendlyDate.current_date-compare_date)/86400000;//=
24*60*60*1000;=0A=
  if (the_difference=3D=3D1)=0A=
  {=0A=
    ref_hints.friendly =3D "tomorrow";=0A=
    return getLibResource("tomorrow");=0A=
  }=0A=
  if (the_difference=3D=3D0)=0A=
  {=0A=
    ref_hints.friendly =3D "today";=0A=
    return getLibResource("today");=0A=
  }=0A=
  if (the_difference=3D=3D-1)=0A=
  {=0A=
    ref_hints.friendly =3D "yesterday";=0A=
    return getLibResource("yesterday");=0A=
  }=0A=
  return "";=0A=
}=0A=
=0A=
getFriendlyMonth.cache_=3D{};=0A=
function getFriendlyMonth(dateObject)=0A=
{=0A=
  if (getFriendlyMonth.cache_[dateObject.M])=0A=
  {=0A=
    return getFriendlyMonth.cache_[dateObject.M];=0A=
  }=0A=
  var month=3DdateObject.M;=0A=
  if (typeof month =3D=3D "number" && month < 10)=0A=
  {=0A=
    month=3D"0"+month;=0A=
  }=0A=
  var friendlyMonth=3DgetLibResource("Month_"+month);=0A=
  getFriendlyMonth.cache_[dateObject.M]=3DfriendlyMonth;=0A=
  return friendlyMonth;=0A=
}=0A=
=0A=
function replaceFriendlyStuff (dateString,DateType)=0A=
{=0A=
  if (typeof dateString !=3D "string")=0A=
  {=0A=
    return dateString;=0A=
  }=0A=
  // replace friendly month=0A=
  for (var i=3D1 ; i<=3D12 ;i++)=0A=
  {=0A=
    var month_string=3D""+i;=0A=
    if (i<10)=0A=
    {=0A=
      month_string=3D"0"+i;=0A=
    }=0A=
    var current_month=3DgetLibResource("Month_"+month_string);=0A=
    dateString=3DdateString.replace(current_month,month_string);=0A=
  }=0A=
=0A=
  if (typeof gFriendlyCache =3D=3D "undefined")=0A=
  {=0A=
    gFriendlyCache=3D{};=0A=
    var today=3Dnew Date();=0A=
    var oneday=3D24*60*60*1000;=0A=
    var yesterday=3Dnew Date();=0A=
    yesterday.setTime(today.getTime() - oneday);=0A=
    var tomorrow=3Dnew Date();=0A=
    tomorrow.setTime(today.getTime() + oneday);=0A=
=0A=
    gFriendlyCache["today"]=3D{key: getLibResource("today"),=0A=
                             value:outDate(today,DateType.date,false)};=0A=
    gFriendlyCache["yesterday"]=3D{key: getLibResource("yesterday"),=0A=
                                 =
value:outDate(yesterday,DateType.date,false)};=0A=
    gFriendlyCache["tomorrow"]=3D{key: getLibResource("tomorrow"),=0A=
                                =
value:outDate(tomorrow,DateType.date,false)};=0A=
=0A=
  }=0A=
=0A=
  dateString=3DdateString.replace(=0A=
     gFriendlyCache["today"].key,=0A=
     gFriendlyCache["today"].value);=0A=
  dateString=3DdateString.replace(=0A=
     gFriendlyCache["yesterday"].key,=0A=
     gFriendlyCache["yesterday"].value);=0A=
  dateString=3DdateString.replace(=0A=
     gFriendlyCache["tomorrow"].key,=0A=
     gFriendlyCache["tomorrow"].value);=0A=
=0A=
  return dateString;=0A=
}=0A=
=0A=
//dateConv=0A=
//Convert date text=0A=
function dateConv (InString, =
DateType,TransformToGMT,UseClientLocalTime,dateOnly) {=0A=
  var RetArray =3D new Object();=0A=
  if (typeof InString =3D=3D "undefined") {=0A=
    RetArray.error =3D "No input string";=0A=
    return (RetArray);=0A=
  }=0A=
  if (InString.time) // it's an HW_API_Date=0A=
  {=0A=
    RetArray =3D {year: InString.year,=0A=
                month: InString.month,=0A=
                day: InString.day,=0A=
                hour: InString.hour,=0A=
                minute: InString.minute,=0A=
                second: InString.second};=0A=
    if (!dateOnly)=0A=
      transformGMTDate(RetArray,TransformToGMT,UseClientLocalTime);=0A=
    return RetArray;=0A=
  }=0A=
  if (typeof HW_UI_UseLocalDate !=3D"undefined" && !HW_UI_UseLocalDate)=0A=
    return InString;=0A=
=0A=
  var len =3D InString.length;=0A=
  if (len =3D=3D 0)=0A=
  {=0A=
    RetArray.error=3D"No date string";=0A=
    return (RetArray);=0A=
  }=0A=
  if (DateType=3D=3D=3DHWDate)=0A=
  {  // its a strict hw date=0A=
=0A=
    var theMatch=3DInString.match(/(\d{1,4})\/(\d{1,2})\/(\d{1,2})( =
(\d{1,2})\:(\d{1,2})\:(\d{1,2}))?/);=0A=
    if (theMatch)=0A=
    {=0A=
      RetArray =3D {=0A=
          year: theMatch[1],=0A=
          month: theMatch[2],=0A=
          day: theMatch[3],=0A=
          hour: theMatch[5]||0,=0A=
          minute: theMatch[6]||0,=0A=
          second: theMatch[7]||0=0A=
      };=0A=
      if (theMatch[4] && !dateOnly) {=0A=
        transformGMTDate(RetArray,TransformToGMT,UseClientLocalTime);=0A=
      }=0A=
    }=0A=
    else=0A=
    {=0A=
      RetArray.error=3D"Wrong Date-Format";=0A=
    }=0A=
=0A=
    return (RetArray);=0A=
  }=0A=
  else=0A=
  {=0A=
    if (DateType.friendly && typeof InString=3D=3D"string")=0A=
    {=0A=
      InString =3D replaceFriendlyStuff(InString, DateType);=0A=
    }=0A=
=0A=
    wArr =3D removeWhiteS(InString.replace(/[T\/,\.\-:]/g," =
")).split(/\s+/);=0A=
=0A=
    len=3DwArr.length;=0A=
    if (len < DateType.minFields || len > DateType.maxFields)=0A=
    {=0A=
      RetArray.error=3D"Wrong Date-Format";=0A=
      return (RetArray);=0A=
    }=0A=
=0A=
    var curt=3D"";=0A=
    datef=3Dnew Array(7);=0A=
    var ftyps=3D"YMDhmst";=0A=
    var fn=3D0;=0A=
=0A=
    for (ccount=3D0;ccount<DateType.format.length;ccount++)=0A=
    {=0A=
      theChar=3DDateType.format.charAt(ccount);=0A=
      if (theChar!=3Dcurt && ftyps.indexOf(theChar)!=3D-1)=0A=
      {=0A=
        curt=3DtheChar;=0A=
        datef[curt]=3Dfn;=0A=
        fn++;=0A=
      }=0A=
    }=0A=
    //check if the date match the pattern from the fields length point =
of view (PR-1070)=0A=
    var out =3D checkDateFieldsLength4Format(DateType, wArr, datef);=0A=
    if (out.error) {=0A=
      RetArray.error =3D out.error;=0A=
      return RetArray;=0A=
    }=0A=
=0A=
    var now=3Dnew Date();=0A=
    if (datef.Y<len)=0A=
      avar=3DwArr[datef.Y];=0A=
    else=0A=
      avar=3D""+ now.getFullYear();=0A=
=0A=
    if (avar.length<=3D2)=0A=
    {=0A=
      var tyear=3DparseInt(avar);=0A=
      if (tyear<70)=0A=
        tyear=3D2000+tyear;=0A=
      else=0A=
        tyear=3D1900+tyear;=0A=
      avar=3D""+tyear;=0A=
    }=0A=
    RetArray.year=3Davar;=0A=
=0A=
    if (datef.M<len)=0A=
      avar=3DwArr[datef.M];=0A=
    else=0A=
      avar=3D"01";=0A=
    RetArray.month=3Dnorm(avar);=0A=
=0A=
    if (datef.D<len)=0A=
      avar=3DwArr[datef.D];=0A=
    else=0A=
      avar=3D"01";=0A=
    RetArray.day=3Dnorm(avar);=0A=
=0A=
    if (datef.h<len)=0A=
      if ((datef.t<len) && (wArr[datef.t].toUpperCase()=3D=3D"PM")) {=0A=
        if (Number(wArr[datef.h])!=3D12) {=0A=
          avar=3DNumber(wArr[datef.h])+12;=0A=
        }=0A=
        else {=0A=
          avar=3DwArr[datef.h];=0A=
        }=0A=
      }=0A=
      else {=0A=
        if ((datef.t<len) && (Number(wArr[datef.h])=3D=3D12)) {=0A=
          avar=3D0;=0A=
        }=0A=
        else {=0A=
          avar=3DwArr[datef.h];=0A=
        }=0A=
      }=0A=
    else=0A=
      avar=3D"00";=0A=
    RetArray.hour=3Dnorm(avar);=0A=
=0A=
    if (datef.m<len)=0A=
      avar=3DwArr[datef.m];=0A=
    else=0A=
      avar=3D"00";=0A=
    RetArray.minute=3Dnorm(avar);=0A=
=0A=
    if (datef.s<len)=0A=
      avar=3DwArr[datef.s];=0A=
    else=0A=
      avar=3D"00";=0A=
    RetArray.second=3Dnorm(avar);=0A=
    if (checkDateSense(RetArray) && !dateOnly) =
transformGMTDate(RetArray,TransformToGMT,UseClientLocalTime);=0A=
    return (RetArray);=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * Checks if a date-time value match a format from the fields length =
point of view.=0A=
 * Checks here only the year field because the others fields are checked =
by the checkDateSense() function.=0A=
 *=0A=
 * @param dateType: string: the date format=0A=
 * @param dateTimeArr: Array: store the fields of the date value {year, =
month, day, ...}=0A=
 * @param dateTimeIndex: Array (assoc): store the date fields index from =
the "dateTimeArr" array=0A=
 *          {Y: the index of the year field,=0A=
 *           M: the index of the mount field,=0A=
 *           ...: the index of the ... field}=0A=
 */=0A=
function checkDateFieldsLength4Format(dateType, dateTimeArr, =
dateTimeIndex) {=0A=
  var result =3D {error: ""};=0A=
  //check only the year because the month/day/hour/minute/seconds are =
checked in checkDateSense() function=0A=
  var field_value =3D dateTimeArr[dateTimeIndex.Y];=0A=
  if (field_value.length > dateType.date.replace(/[^Y]/g, "").length) {=0A=
    result.error =3D "Illegal Year-Value: " + field_value;=0A=
  }=0A=
  return result;=0A=
}=0A=
=0A=
function checkDateSense(DateX, Doalert)=0A=
//checks if DateX is/was/will be legal at any time of history since Year =
1 //=0A=
//Legal Range: s(0,59), m(0.59), h(0,23), D(1,), M(1,12), Y(1,) //=0A=
{=0A=
  function outsideRange(value, b1, b2) {=0A=
    return isNaN(value) || value < Math.min(b1, b2) || value > =
Math.max(b1, b2);=0A=
  }=0A=
=0A=
  var Error =3D "";=0A=
  var DaysInMonths =3D [0, 31, leapYear(DateX.year) ? 29 : 28, 31, 30, =
31, 30, 31, 31, 30, 31, 30, 31];=0A=
=0A=
  if (outsideRange(DateX.year, 1, 1e6)) {=0A=
    Error =3D "Year-Value: " + DateX.year;=0A=
  }=0A=
  else if (outsideRange(DateX.month, 1, 12)) {=0A=
    Error =3D "Month-Value: " + DateX.month;=0A=
  }=0A=
  else if (outsideRange(DateX.day, 1, DaysInMonths[DateX.month])) {=0A=
    Error =3D "Day-Value: " + DateX.day;=0A=
  }=0A=
  else if (outsideRange(DateX.hour, 0, 23)) {=0A=
    Error =3D "Hour-Value: " + DateX.hour;=0A=
  }=0A=
  else if (outsideRange(DateX.minute, 0, 59)) {=0A=
    Error =3D "Minute-Value: " + DateX.minute;=0A=
  }=0A=
  else if (outsideRange(DateX.second, 0, 59)) {=0A=
    Error =3D "Second-Value: " + DateX.second;=0A=
  }=0A=
=0A=
  if (Error) {=0A=
=0A=
    DateX.error =3D "Illegal " + Error;=0A=
    if (Doalert) {=0A=
      alert(DateX.error);=0A=
    }=0A=
    return false;=0A=
  }=0A=
  else {=0A=
=0A=
    return true;=0A=
  }=0A=
}=0A=
=0A=
function transformGMTDate(ret,TransformToGMT,UseClientLocalTime)=0A=
// if HW_UI_ConvertGMTLocalGMT is true, then:=0A=
// Transforms LocalDate->GMT if TransformToGMT is true, transforms =
GMT->LocalDate if=0A=
// false, doesn't transform at all if undefined.=0A=
{=0A=
  if ((typeof TransformToGMT !=3D "undefined") && (typeof =
HW_UI_ConvertGMTLocalGMT!=3D"undefined") && (HW_UI_ConvertGMTLocalGMT))=0A=
  {=0A=
    // if transforming to local time && we're on the server side -> use =
new function by ckoch=0A=
    if (!TransformToGMT && UseClientLocalTime && typeof request !=3D =
"undefined")=0A=
    {=0A=
      transformToLocalTime(ret);=0A=
      return;=0A=
    }=0A=
=0A=
    var HelpDate =3D new Date(ret.year, ret.month-1, ret.day, ret.hour, =
ret.minute, ret.second);=0A=
    var TOffset =3D HelpDate.getTimezoneOffset();=0A=
    if (TOffset>720) // netscape on mac ?=0A=
      TOffset=3DTOffset-1440;=0A=
=0A=
    if (UseClientLocalTime)=0A=
    {=0A=
      // Use cookie "HW_GMTOff" to get TimeOffset=0A=
      if (typeof request !=3D 'undefined') {=0A=
        if (request.field.keyvalue('Cookie')) {=0A=
          var thecookies =3D request.field.keyvalue('Cookie').values;=0A=
          for (var id in thecookies) {=0A=
            if (thecookies[id].search(/^HW_GMTOff=3D/)!=3D -1)=0A=
              TOffset =3D thecookies[id].substring(10)*60;=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
    if (TransformToGMT)=0A=
      HelpDate.setTime(HelpDate.getTime()+TOffset*60000);=0A=
    else=0A=
      HelpDate.setTime(HelpDate.getTime()-TOffset*60000);=0A=
    ret.year =3D HelpDate.getFullYear()+"";=0A=
    ret.month =3D (HelpDate.getMonth()+1);=0A=
    ret.day =3D HelpDate.getDate();=0A=
    ret.hour =3D HelpDate.getHours();=0A=
    ret.minute =3D HelpDate.getMinutes();=0A=
    ret.second =3D HelpDate.getSeconds();=0A=
  }=0A=
}=0A=
=0A=
function =
transformDate(instr,inType,outformat,TransformToGMT,UseClientLocalTime,da=
teOnly,useFriendly)=0A=
{=0A=
  if (arguments.length =3D=3D 4 && typeof TransformToGMT =3D=3D =
"object") {=0A=
    var args =3D TransformToGMT;=0A=
=0A=
    if (args.transform =3D=3D=3D "toLocal") {=0A=
      var TransformToGMT =3D false;=0A=
    }=0A=
    else if (args.transform =3D=3D=3D "toGmt") {=0A=
      var TransformToGMT =3D true;=0A=
    }=0A=
    else {=0A=
      var TransformToGMT =3D void(0);=0A=
    }=0A=
=0A=
    var UseClientLocalTime =3D typeof args.useClientLocalTime =3D=3D =
"boolean" ? args.useClientLocalTime : false;=0A=
    var dateOnly =3D typeof args.dateOnly =3D=3D "boolean" ? =
args.dateOnly : false;=0A=
    var useFriendly =3D typeof args.useFriendly =3D=3D "boolean" ? =
args.useFriendly : true;=0A=
    var sentenceContext =3D args.sentenceContext || "";=0A=
  }=0A=
  else {=0A=
    var sentenceContext =3D "";=0A=
  }=0A=
=0A=
  function _processResult(theResult, ref_hints) {=0A=
    if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.on ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.from ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.to ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.before ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.after ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.date ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.On ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.From ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.To ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.Before ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.After) {=0A=
      var the_result =3D "";=0A=
    }=0A=
    else {=0A=
      var the_result =3D theResult;=0A=
    }=0A=
=0A=
    if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.on ||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.ondate) {=0A=
      var type =3D "sentence_on";=0A=
    } else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.On =
||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.Ondate) {=0A=
      var type =3D "sentence_On";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.from =
||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.fromdate) {=0A=
      var type =3D "sentence_from";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.From =
||=0A=
        sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.Fromdate) {=0A=
      var type =3D "sentence_From";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.to ||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.todate) {=0A=
      var type =3D "sentence_to";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.To ||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.Todate) {=0A=
      var type =3D "sentence_To";=0A=
    }=0A=
    else if (sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.before ||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.beforedate) {=0A=
      var type =3D "sentence_before";=0A=
    }=0A=
    else if (sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.Before ||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.Beforedate) {=0A=
      var type =3D "sentence_Before";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.after =
||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.afterdate) {=0A=
      var type =3D "sentence_after";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.After =
||=0A=
             sentenceContext =3D=3D =
transformDate.SENTENCE_CONTEXT.Afterdate) {=0A=
      var type =3D "sentence_After";=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.date) =
{=0A=
      if (ref_hints.friendly) {=0A=
        var id =3D "sentence_" + ref_hints.friendly.replace(/\w/, =
function (m) { return m.toLowerCase(); });=0A=
        return getLibResource(id, "") || the_result;=0A=
      }=0A=
      else {=0A=
        return theResult;=0A=
      }=0A=
    }=0A=
    else if (sentenceContext =3D=3D transformDate.SENTENCE_CONTEXT.Date) =
{=0A=
      if (ref_hints.friendly) {=0A=
        var id =3D "sentence_" + ref_hints.friendly.replace(/\w/, =
function (m) { return m.toUpperCase(); });=0A=
        return getLibResource(id, "") || the_result;=0A=
      }=0A=
      else {=0A=
        return the_result;=0A=
      }=0A=
    }=0A=
    else if (sentenceContext) {=0A=
      return "??" + the_result + "??";=0A=
    }=0A=
    else {=0A=
      return the_result;=0A=
    }=0A=
=0A=
    if (ref_hints.friendly) {=0A=
      var res =3D getLibResource(type + "_" + ref_hints.friendly, "") || =
getLibResource(type, "");=0A=
    }=0A=
    else {=0A=
      var res =3D getLibResource(type, "");=0A=
    }=0A=
    if (res) {=0A=
      return res.replace(/\(\$date\)/g, the_result);=0A=
    }=0A=
    else {=0A=
      return the_result;=0A=
    }=0A=
  }=0A=
=0A=
  var ref_hints =3D {};=0A=
  var datestr =3D instr;=0A=
  if (typeof HW_API_Date !=3D "undefined" && typeof instr =3D=3D =
"string") {=0A=
    datestr =3D new HW_API_Date(instr); // "try" to parse HW_API_Date=0A=
    if (!datestr.ok) {=0A=
      datestr =3D instr;=0A=
    }=0A=
  }=0A=
  if (typeof datestr !=3D 'string' && !datestr.time) {=0A=
    return _processResult(outDate(datestr, outformat, true, ref_hints), =
ref_hints);=0A=
  }=0A=
  if (typeof HW_UI_UseLocalDate !=3D "undefined" && !HW_UI_UseLocalDate) =
{=0A=
    return _processResult(datestr, ref_hints);=0A=
  }=0A=
=0A=
  ret =3D dateConv(datestr, inType, TransformToGMT, UseClientLocalTime, =
dateOnly);=0A=
  if (ret.error) {=0A=
    return ret.error;=0A=
  }=0A=
=0A=
  if (outformat =3D=3D "jsDate") { // the outformat is a JS Date=0A=
    return _processResult(new Date(ret.year, ret.month - 1, ret.day, =
ret.hour, ret.minute, ret.second), ref_hints);=0A=
  }=0A=
  else {=0A=
    return _processResult(outDate(ret, outformat, useFriendly, =
ref_hints), ref_hints);=0A=
  }=0A=
}=0A=
transformDate.SENTENCE_CONTEXT =3D {on: {}, On: {},=0A=
                                  from: {}, From: {},=0A=
                                  to: {}, To: {},=0A=
                                  ondate: {}, Ondate: {},=0A=
                                  fromdate: {}, Fromdate: {},=0A=
                                  todate: {}, Todate: {},=0A=
                                  date: {}, Date: {},=0A=
                                  before: {}, Before: {},=0A=
                                  after: {}, After: {},=0A=
                                  beforedate: {}, Beforedate: {},=0A=
                                  afterdate: {}, Afterdate: {}};=0A=
=0A=
function checkDateInForm(theForm, elemname, doalert, allowrel, p)=0A=
{=0A=
  var p =3D p || {};=0A=
  var inputdate =3D theForm[elemname];=0A=
=0A=
  if (!inputdate) {=0A=
    return true;=0A=
  }=0A=
=0A=
  if (typeof HW_UI_UseLocalDate !=3D "undefined" && !HW_UI_UseLocalDate) =
{=0A=
    return true;=0A=
  }=0A=
=0A=
  var timeval=3Dinputdate.value;=0A=
  if (timeval.length)=0A=
  {=0A=
    if (timeval.charAt(0)=3D=3D"-" ) {=0A=
      // ERS=0A=
      if (allowrel) {=0A=
        return true; // rel date=0A=
      }=0A=
      else {=0A=
        if (doalert) {=0A=
          alert ("Error: Negative date time field!\n\nFormat is: " + =
HW_UI_Date.format);=0A=
          inputdate.focus();=0A=
        }=0A=
        return false;=0A=
      }=0A=
    }=0A=
=0A=
    var sForm =3D p.sFormat || HW_UI_Date;=0A=
    var ret=3DdateConv(timeval,sForm);=0A=
    if (ret.error)=0A=
    {=0A=
      if (doalert)=0A=
      {=0A=
        alert ("Error: "+ret.error+"\n\nFormat is: "+HW_UI_Date.format);=0A=
        inputdate.focus();=0A=
      }=0A=
      return false;=0A=
    }=0A=
  }=0A=
  return true;=0A=
}=0A=
=0A=
function convertDateInForm(theForm, elemname, p)=0A=
{=0A=
  var p =3D p || {};=0A=
  var inputdate =3D theForm[elemname];=0A=
=0A=
  if (!inputdate)=0A=
    return true;=0A=
=0A=
  if (p.Elemname)=0A=
    p.elem =3D theForm[p.Elemname];=0A=
=0A=
  if (typeof HW_UI_UseLocalDate !=3D"undefined" && !HW_UI_UseLocalDate)=0A=
    return true;=0A=
  var timeval=3Dinputdate.value;=0A=
=0A=
  var sForm =3D p.sFormat || HW_UI_Date;=0A=
  var dForm =3D p.dFormat || HWDate;=0A=
=0A=
  if (timeval.length)=0A=
  {=0A=
    if (timeval.charAt(0)=3D=3D"-")=0A=
    {=0A=
      if (p.elem) {=0A=
        p.elem.value=3Dtimeval;=0A=
      }=0A=
      else {=0A=
        inputdate.value=3Dtimeval;=0A=
      }=0A=
      return true; // rel date=0A=
    }=0A=
=0A=
    var ret=3DdateConv(timeval,sForm,p.TransformToGMT,false,p.dateOnly);=0A=
    if (ret.error)=0A=
      return false;=0A=
=0A=
    var outdateformat=3Dp.dateOnly?dForm.date:dForm.full;=0A=
    if (p.elem) {=0A=
      p.elem.value=3DoutDate(ret,outdateformat);=0A=
    }=0A=
    else {=0A=
      inputdate.value=3DoutDate(ret,outdateformat);=0A=
    }=0A=
  }=0A=
  //if empty time/date, the underlying hidden element (p.elem !) must be =
deleted, otherwise in case of=0A=
  //a search with TimeCreated=3D"something" ->Searchresult->New Search =
deleting the "something" has no effect.=0A=
  else if (p.elem) {=0A=
    p.elem.value=3D"";=0A=
  }=0A=
=0A=
  return true;=0A=
}=0A=
=0A=
// class for handling date formates=0A=
function DateFormatCollection(theDefaultFormat) {=0A=
  this.formats_ =3D {};=0A=
  this.defaultFormat_ =3D theDefaultFormat || null;=0A=
}=0A=
DateFormatCollection.prototype.addFormat =3D function (theName, =
theFormat) {=0A=
  this.formats_[theName.toLowerCase()] =3D theFormat || null;=0A=
};=0A=
DateFormatCollection.prototype.getFormat =3D function (theName) {=0A=
  return this.formats_[(theName || "").toLowerCase()] || =
this.defaultFormat_;=0A=
};=0A=
=0A=
// class for handling a date format=0A=
function DateFormat(theDefinition) {=0A=
=0A=
  this.timeFormatter_ =3D function (aString) {=0A=
    var match =3D =
aString.match(/^\s*(\d)?(\d)(?:\s*\:\s*(\d)?(\d))?(?:\s*\:\s*(\d)?(\d))?\=
s*$/i);=0A=
    if (match) { // result must look like in UsDate.format (currently =
without seconds)=0A=
      var res =3D [match[1] || "0",=0A=
                 match[2] || "0",=0A=
                 ":",=0A=
                 match[3] || "0",=0A=
                 match[4] || "0"];=0A=
      if (this.format.match(/ss/)) {=0A=
        res.push(":");=0A=
        res.push(match[5] || "0");=0A=
        res.push(match[6] || "0");=0A=
      }=0A=
      return res.join("");=0A=
    }=0A=
    else {=0A=
      return "";=0A=
    }=0A=
  };=0A=
=0A=
  this.dateTimeMerger_ =3D function (theDate, theTime) {=0A=
    return [theDate, theTime].join(this.dateTimeSeparator_);=0A=
  };=0A=
=0A=
  this.dateTimeSeparator_ =3D " ";=0A=
}=0A=
=0A=
DateFormat.prototype.setTimeFormatter =3D function (aFunction) {=0A=
  this.timeFormatter_ =3D aFunction;=0A=
};=0A=
=0A=
DateFormat.prototype.setDateTimeMerger =3D function (aFunction) {=0A=
  this.dateTimeMerger_ =3D aFunction;=0A=
};=0A=
=0A=
DateFormat.prototype.setDateTimeSeparator =3D function (aString) {=0A=
  this.dateTimeSeparator_ =3D aString;=0A=
};=0A=
=0A=
DateFormat.prototype.formatTime =3D function (aString) {=0A=
  return this.timeFormatter_.apply(this, arguments);=0A=
};=0A=
=0A=
DateFormat.prototype.mergeDateTime =3D function (theDate, theTime) {=0A=
  return this.dateTimeMerger_.apply(this, arguments);=0A=
};=0A=
=0A=
DateFormat.prototype.is12HourFormat =3D function () {=0A=
  return this.format.indexOf("tt") !=3D -1;=0A=
};=0A=
//specify format=0A=
// Y - year=0A=
// M - month=0A=
// D - day=0A=
// h - hour=0A=
// m - minute=0A=
// s - second=0A=
// ll - AM or PM=0A=
// f(...f) this part is replaced by a riendly date (Today or 13. =
September..)=0A=
// F(...F) this part is replaced by a riendly date  but no today or =
yesterday handling (13. September..)=0A=
=0A=
// Y(...Y), y(...y)=0A=
// T(...T), t(...t) used in today handling.=0A=
//      t is used when date is today=0A=
//      T is used when date is not today=0A=
//      y is used when year is this year=0A=
//      Y is used when year is other then this year=0A=
=0A=
//Date.absolute,Date.dateAbsolute friedly month names are used but no =
today, yesterday handling=0A=
=0A=
var DeDate =3D new DateFormat();=0A=
DeDate.format =3D "DD.MM.YYYY hh:mm";=0A=
DeDate.minFields =3D 3;=0A=
DeDate.maxFields =3D 6;=0A=
DeDate.full =3D "DD.MM.YYYY hh:mm";=0A=
DeDate.absolute =3D "DD.MM.YYYY hh:mm";=0A=
DeDate.minimal =3D "T(DD.MM.YYYYT)t(hh:mmt)";=0A=
DeDate.date =3D "DD.MM.YYYY";=0A=
DeDate.dateAbsolute =3D "DD.MM.YYYY";=0A=
DeDate.time =3D "hh:mm:ss";=0A=
DeDate.shortTime =3D "hh:mm";=0A=
=0A=
var DeDateFriendly =3D new DateFormat();=0A=
DeDateFriendly.format =3D "f(DD. MM YYYYf) hh:mm";=0A=
DeDateFriendly.minFields =3D 3;=0A=
DeDateFriendly.maxFields =3D 6;=0A=
DeDateFriendly.full =3D "f(DD. MM YYYYf) hh:mm";=0A=
DeDateFriendly.minimal =3D "T(f(DD. MMY( YYYYY)f)T)t(hh:mmt)";=0A=
DeDateFriendly.absolute =3D "F(DD. MM YYYYF) hh:mm";=0A=
DeDateFriendly.friendly =3D true;=0A=
DeDateFriendly.date =3D "f(DD. MM YYYYf)";=0A=
DeDateFriendly.dateAbsolute =3D "F(DD. MM YYYYF)";=0A=
DeDateFriendly.shortDate =3D "f(DD. MMf)";=0A=
DeDateFriendly.time =3D "hh:mm:ss";=0A=
DeDateFriendly.shortTime =3D "hh:mm";=0A=
=0A=
var EnDateFriendly =3D new DateFormat();=0A=
EnDateFriendly.format =3D "f(MM DD, YYYYf) hh:mm";=0A=
EnDateFriendly.minFields =3D 3;=0A=
EnDateFriendly.maxFields =3D 6;=0A=
EnDateFriendly.full =3D "f(MM DD, YYYYf) hh:mm";=0A=
EnDateFriendly.minimal =3D "T(f(MM DDY(, YYYYY)f)T)t(hh:mmt)";=0A=
EnDateFriendly.absolute =3D "F(MM DD, YYYYF) hh:mm";=0A=
EnDateFriendly.friendly =3D true;=0A=
EnDateFriendly.date =3D "f(MM DD, YYYYf)";=0A=
EnDateFriendly.dateAbsolute =3D "F(MM DD, YYYYF)";=0A=
EnDateFriendly.shortDate =3D "f(MM DDf)";=0A=
EnDateFriendly.time =3D "hh:mm:ss";=0A=
EnDateFriendly.shortTime =3D "hh:mm";=0A=
=0A=
var EnDate =3D new DateFormat();=0A=
EnDate.format =3D "DD/MM/YYYY hh:mm";=0A=
EnDate.minFields =3D 3;=0A=
EnDate.maxFields =3D 6;=0A=
EnDate.full =3D "DD/MM/YYYY hh:mm";=0A=
EnDate.absolute =3D "DD/MM/YYYY hh:mm";=0A=
EnDate.minimal =3D "T(DD/MM/YYYYT)t(hh:mmt)";=0A=
EnDate.date =3D "DD/MM/YYYY";=0A=
EnDate.dateAbsolute =3D "DD/MM/YYYY";=0A=
EnDate.time =3D "hh:mm:ss";=0A=
EnDate.shortTime =3D "hh:mm";=0A=
=0A=
var UsDate =3D new DateFormat();=0A=
UsDate.format =3D "MM/DD/YYYY hh:mm tt";=0A=
UsDate.minFields =3D 3;=0A=
UsDate.maxFields =3D 7;=0A=
UsDate.full =3D "MM/DD/YYYY hh:mm tt";=0A=
UsDate.absolute =3D "MM/DD/YYYY hh:mm tt";=0A=
UsDate.minimal =3D "T(MM/DD/YYYYT)t(hh:mm ttt)";=0A=
UsDate.date =3D "MM/DD/YYYY";=0A=
UsDate.dateAbsolute =3D "MM/DD/YYYY";=0A=
UsDate.time =3D "hh:mm:ss tt";=0A=
UsDate.shortTime =3D "hh:mm tt";=0A=
=0A=
var UsDateFriendly =3D new DateFormat();=0A=
UsDateFriendly.format =3D "f(MM DD, YYYYf) hh:mm tt";=0A=
UsDateFriendly.minFields =3D 3;=0A=
UsDateFriendly.maxFields =3D 6;=0A=
UsDateFriendly.full =3D "f(MM DD, YYYYf) hh:mm tt";=0A=
UsDateFriendly.minimal =3D "T(f(MM DDY(, YYYYY)f)T)t(hh:mm ttt)";=0A=
UsDateFriendly.absolute =3D "F(MM DD, YYYYF) hh:mm tt";=0A=
UsDateFriendly.friendly =3D true;=0A=
UsDateFriendly.date =3D "f(MM DD, YYYYf)";=0A=
UsDateFriendly.dateAbsolute =3D "F(MM DD, YYYYF)";=0A=
UsDateFriendly.shortDate =3D "f(MM DDf)";=0A=
UsDateFriendly.time =3D "hh:mm:ss tt";=0A=
UsDateFriendly.shortTime =3D "hh:mm tt";=0A=
=0A=
=0A=
var HWDate =3D new DateFormat();=0A=
HWDate.format =3D "YYYY/MM/DD hh:mm:ss";=0A=
HWDate.minFields =3D 1;=0A=
HWDate.maxFields =3D 6;=0A=
HWDate.full =3D "YYYY/MM/DD hh:mm:ss";=0A=
HWDate.absolute =3D "YYYY/MM/DD hh:mm:ss";=0A=
HWDate.minimal =3D "T(YYYY/MM/DDT)t(hh:mm:sst)";=0A=
HWDate.date =3D "YYYY/MM/DD";=0A=
HWDate.dateAbsolute =3D "YYYY/MM/DD";=0A=
HWDate.time =3D "hh:mm:ss";=0A=
HWDate.shortTime =3D "hh:mm";=0A=
=0A=
// ERS - add support for uk date format=0A=
var ERMSDate =3D new DateFormat();=0A=
ERMSDate.format =3D "YYYY-MM-DDThh:mm:ss";=0A=
ERMSDate.minFields =3D 1;=0A=
ERMSDate.maxFields =3D 6;=0A=
ERMSDate.full =3D "YYYY-MM-DDThh:mm:ss";=0A=
ERMSDate.absolute =3D "YYYY-MM-DDThh:mm:ss";=0A=
ERMSDate.minimal =3D "T(YYYY-MM-DDT)t(hh:mm:sst)";=0A=
ERMSDate.date =3D "YYYY-MM-DD";=0A=
ERMSDate.dateAbsolute =3D "YYYY-MM-DD";=0A=
ERMSDate.time =3D "hh:mm:ss";=0A=
ERMSDate.shortTime =3D "hh:mm";=0A=
=0A=
ERMSDate.setDateTimeSeparator("T");=0A=
=0A=
function usDateTimeFormatter(aString) {=0A=
=0A=
  var match =3D =
aString.match(/^\s*(\d)?(\d)(?:\s*\:\s*(\d)?(\d))?(?:\s*\:\s*(\d)?(\d))?\=
s*(am|pm)?\s*$/i);=0A=
  if (match) { // result must look like in UsDate.format (currently =
without seconds)=0A=
    return [match[1] || "0",=0A=
            match[2] || "0",=0A=
            ":",=0A=
            match[3] || "0",=0A=
            match[4] || "0",=0A=
            // ":",=0A=
            // match[5] || "0",=0A=
            // match[6] || "0",=0A=
            " ",=0A=
            (match[7] || "AM").toUpperCase()].join("");=0A=
  }=0A=
  else {=0A=
    return "";=0A=
  }=0A=
};=0A=
=0A=
UsDate.setTimeFormatter(usDateTimeFormatter);=0A=
UsDateFriendly.setTimeFormatter(usDateTimeFormatter);=0A=
=0A=
g_dates =3D new DateFormatCollection(HWDate);=0A=
g_dates.addFormat("DeDate", DeDate);=0A=
g_dates.addFormat("DeDateFriendly", DeDateFriendly);=0A=
g_dates.addFormat("EnDateFriendly", EnDateFriendly);=0A=
g_dates.addFormat("EnDate", EnDate);=0A=
g_dates.addFormat("UsDate", UsDate);=0A=
g_dates.addFormat("UsDateFriendly", UsDateFriendly);=0A=
g_dates.addFormat("HWDate", HWDate);=0A=
g_dates.addFormat("ERMSDate", ERMSDate);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.pdf;
	internal&Parameter=1364985039541e&ctx=eKS&action=forcetemplates.action&ctx=eKS

=EF=BB=BF<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" =
"http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML><HEAD><META content=3D"IE=3D8.0000" =
http-equiv=3D"X-UA-Compatible">
<TITLE>A0 ePost for Development_Management at 02/04/2013 14:11:07 - =
615654</TITLE>
<META content=3D"text/html; charset=3Dutf-8" http-equiv=3DContent-Type>
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib=
/prototype/prototype.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib=
/ojs/Object.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib=
/com/hyperwave/hw.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib=
/com/hyperwave/util/IncludeManager.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT =
type=3Dtext/javascript>hw.util.IncludeManager.static_.getInstance().setUn=
ique("515488b2-en").setPrefix("/wavemaster.internal/").setPlaceholder("vd=
", "webapp").setPlaceholder("sp", =
"/wavemaster.internal/webapp/uistyle/hwdefault");</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/cs=
lib.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.default_5_896"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x=
/com/hyperwave/util/KeyValueMap.js?cachekeY=3D515488b2-en"=20
concatid=3D"ssframesetscripts.js_12_2_296"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/standardpage/code/csframesetscripts.js?cachekeY=3D515488b2-en"=20
concatid=3D"ssframesetscripts.js_12_2_296"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (theGoid, theUrl, theUnique, theCurrentContext, =
theChildContext, useFullUrlForReload, theDocumentType) {=0A=
    gCurrentGOid =3D theGoid;=0A=
    gCurrentUrl =3D theUrl;=0A=
    gUnique =3D theUnique;=0A=
    gCurrentDocumentType =3D theDocumentType;=0A=
    top.gCurrentContext =3D theCurrentContext;=0A=
    top.gChildContext =3D theChildContext;=0A=
    gIsFrameSet =3D top.frames.length > 0;=0A=
    checkFrameSet();=0A=
    if (gIsFrameSet) {=0A=
        setHW_MainframeUrl(useFullUrlForReload ? theUrl : theGoid);=0A=
    }=0A=
}).apply(this, ["0x80010cb5_0x035dc1f3", =
"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.pdf",=
 "1364997150233", "eKS", "eKS", false, "Generic"]);=0A=
}).call(this);</SCRIPT>

<META name=3D"Assigned "=20
content=3D"On: 3/4/2013 At 11:54:34 By: AngelaBl To: =
/Documents/Users/JamesHyde">
<META name=3DAuthor content=3DJamesHy>
<META name=3DDC_BatchNumber content=3D000199828>
<META name=3DDC_DestinationGroup content=3DDevelopment_Management>
<META name=3DDC_DestinationService =
content=3DPlanning_and_Transportation>
<META name=3DDC_IsRecord content=3Dtrue>
<META name=3DDC_OCRStatus content=3DComplete>
<META name=3DDC_Status content=3DScanned>
<META name=3DDC_TagStatus content=3DRequested>
<META name=3DDescription content=3D"en:Document 2 of 2 from batch =
000199828">
<META name=3DHW_DC_InstanceOf content=3DBMBC_Document>
<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/cs=
editlinks.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.cseditlinks_1_121"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/config=
/dmc.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/menu_dc/code/menucommon.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/menu_dc/code/menu.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uistyl=
e/hwdefault/mstyle.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/menu_dc/code/openclosemenudom.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/menu_dc/code/menudom.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/menu_dc/code/keyfunctions.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.menuscripts_7_951"></SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/cs=
dialog.js?cachekeY=3D515488b2-en"=20
concatid=3D"dialogscripts.js_238_1_118"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (theWindowNamePostfixForServer) {=0A=
    top.gPostFixForServer =3D theWindowNamePostfixForServer;=0A=
}).apply(this, ["80010cb580"]);=0A=
}).call(this);</SCRIPT>

<SCRIPT>=0A=
var hwfs =3D "init";=0A=
var mstyle =3D "" || "hwblue";=0A=
var nsbform =3D false;=0A=
=0A=
var mbarst =3D typeof mbstyle !=3D "undefined" ? mbstyle : DMC;=0A=
var mitemst =3D typeof mitstyle !=3D "undefined" ? mitstyle : DMC;=0A=
=0A=
var object_tags =3D [];=0A=
addToOnload(function () {=0A=
  // in msie menus are hidden behind oject tags=0A=
  if (navigator.appVersion.indexOf("MSIE") !=3D -1)=0A=
  {=0A=
    object_tags =3D $$("object");=0A=
    if (object_tags.length)=0A=
    {=0A=
      =
hw.getFramework().getDisplayManager().addHideLayer($(document.body));=0A=
    }=0A=
  }=0A=
});=0A=
addToOnunload(function () {=0A=
  // in msie menus are hidden behind oject tags=0A=
  if (navigator.appVersion.indexOf("MSIE") !=3D -1)=0A=
  {=0A=
    if (object_tags.length)=0A=
    {=0A=
      =
hw.getFramework().getDisplayManager().remHideLayer($(document.body));=0A=
    }=0A=
  }=0A=
});=0A=
=0A=
</SCRIPT>

<SCRIPT>=0A=
var hwbar;=0A=
var hwiconbar;=0A=
function buildHWMenu(){=0A=
m1=3Dnew Menu("HWMainMenu",({relright:true, showdisabledicons:true, =
obj:"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.p=
df", frame:"top", executionframe:"HW_Mainframe", container:"top", =
inheritsizetoopener:true, cname:"hwiconbarContainerOpener", =
orientation:"top", xpos:"r", ypos:"t", menualignment:"r"}));=0A=
=0A=
  hwbar=3Dm1;=0A=
m2=3Dnew Menu("HWIconMenu",({relright:true, isiconbar:true, =
showdisabledicons:true, =
obj:"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.p=
df", frame:"top", executionframe:"HW_Mainframe", container:"top", =
containername:"hw_iconbarContainer", inheritsizetoopener:true, =
orientation:"top", xpos:"l", ypos:"t", menualignment:"l"}));=0A=
m2.add("Attributes",({key:"A", targetmult:"dialogs", target:"dialogs", =
operation:"mattrib", actmult:"dialog.modifyobjects", =
act:"dialog.editattributes", cssclass:"hw_info", selectionminimum:-1, =
selectionmaximum:1000000, opobj:true, quickTestId:"hwt_mod_EditAttr"}));=0A=
m2.add("Edit",({exec:"HTMLSave=3D'';", winstyle:"{ minWidth:'870'}", =
targetmult:"editdialogs", target:"editdialogs", operation:"eddoc", =
act:"dialog.editdoc", cssclass:"hw_edit", selectionminimum:1, =
selectionmaximum:1, opobj:true, isdisabled:true, =
quickTestId:"hwt_mod_EditDocument"}));=0A=
m2.add("Move",({winstyle:"{ height:'480', width:'640'}", =
targetmult:"dialogs", target:"dialogs", actp:"move", =
act:"dialog.choosetarget", cssclass:"hw_move", selectionminimum:1, =
selectionmaximum:1000000, op:true, isdisabled:"(false||(typeof move =
!=3D\"function\"))", quickTestId:"hw_api_move"}));=0A=
m2.add("Delete",({exec:"submitform('delete')", cssclass:"hw_delete", =
selectionminimum:1, selectionmaximum:1000000, =
quickTestId:"hw_api_remove"}));=0A=
m2.addSep();=0A=
m2.addSep();=0A=
m3=3Dnew Menu("HWPublishMenu",({showdisabledicons:true}));=0A=
m3.add("Note...",({key:"N", targetmult:"newnote", target:"newnote", =
act:"dialog.newnote", selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"hwt_pub_NewNote"}));=0A=
m3.add("Remote&nbsp;Document",({winstyle:"{ height:'460'}", =
targetmult:"dialogs", target:"dialogs", act:"dialog.newremotedoc", =
selectionminimum:-1, selectionmaximum:1000000, isdisabled:true, =
quickTestId:"hwt_pub_NewRemote"}));=0A=
m3.addSep();=0A=
m3.addSep();=0A=
m4=3Dnew Menu("HWErmsDeclRec",({showdisabledicons:true}));=0A=
m4.add("Default&nbsp;Record&nbsp;Type",({url:"/Administration/ERMS_Admini=
stration/RecordTypes/_CreateableRecordTypes_/Default_Record_Type;internal=
&action=3Djs.execute.action&Parameter=3D%23%28UIClass%3AHW_ERMS_RecordUI%=
29%28Method%3Astatic_.chooseRecordDestination%29&ctx=3DeKS", =
targetmult:"dialogs", target:"dialogs", operation:"severaldocs", =
selectionminimum:-1, selectionmaximum:1000000, op:true, submit:true}));=0A=
m4.add("E-Mail&nbsp;Record",({url:"/Administration/ERMS_Administration/Re=
cordTypes/_CreateableRecordTypes_/EMail;internal&action=3Djs.execute.acti=
on&Parameter=3D%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astatic_.cho=
oseRecordDestination%29&ctx=3DeKS", targetmult:"dialogs", =
target:"dialogs", operation:"severaldocs", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true}));=0A=
m4.add("Job_Evaluation",({url:"/Administration/ERMS_Administration/Record=
Types/_CreateableRecordTypes_/Job_Evaluation;internal&action=3Djs.execute=
.action&Parameter=3D%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astatic=
_.chooseRecordDestination%29&ctx=3DeKS", targetmult:"dialogs", =
target:"dialogs", operation:"severaldocs", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true}));=0A=
m4.add("Welfare&nbsp;Rights&nbsp;Case&nbsp;File",({url:"/Administration/E=
RMS_Administration/RecordTypes/_CreateableRecordTypes_/Welfare%20Rights%2=
0Case%20File;internal&action=3Djs.execute.action&Parameter=3D%23%28UIClas=
s%3AHW_ERMS_RecordUI%29%28Method%3Astatic_.chooseRecordDestination%29&ctx=
=3DeKS", targetmult:"dialogs", target:"dialogs", =
operation:"severaldocs", selectionminimum:-1, selectionmaximum:1000000, =
op:true, submit:true}));=0A=
m4.add("Occupational_Health_Case_File",({url:"/Administration/ERMS_Admini=
stration/RecordTypes/_CreateableRecordTypes_/Occupational_Health_Case_Fil=
e;internal&action=3Djs.execute.action&Parameter=3D%23%28UIClass%3AHW_ERMS=
_RecordUI%29%28Method%3Astatic_.chooseRecordDestination%29&ctx=3DeKS", =
targetmult:"dialogs", target:"dialogs", operation:"severaldocs", =
selectionminimum:-1, selectionmaximum:1000000, op:true, submit:true}));=0A=
m4.add("CRB&nbsp;Check",({url:"/Administration/ERMS_Administration/Record=
Types/_CreateableRecordTypes_/CRB%20Check;internal&action=3Djs.execute.ac=
tion&Parameter=3D%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astatic_.c=
hooseRecordDestination%29&ctx=3DeKS", targetmult:"dialogs", =
target:"dialogs", operation:"severaldocs", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true}));=0A=
m4.add("Birth",({url:"/Administration/ERMS_Administration/RecordTypes/_Cr=
eateableRecordTypes_/Birth;internal&action=3Djs.execute.action&Parameter=3D=
%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astatic_.chooseRecordDestin=
ation%29&ctx=3DeKS", targetmult:"dialogs", target:"dialogs", =
operation:"severaldocs", selectionminimum:-1, selectionmaximum:1000000, =
op:true, submit:true}));=0A=
m4.add("Death",({url:"/Administration/ERMS_Administration/RecordTypes/_Cr=
eateableRecordTypes_/Death;internal&action=3Djs.execute.action&Parameter=3D=
%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astatic_.chooseRecordDestin=
ation%29&ctx=3DeKS", targetmult:"dialogs", target:"dialogs", =
operation:"severaldocs", selectionminimum:-1, selectionmaximum:1000000, =
op:true, submit:true}));=0A=
m4.add("Still&nbsp;Birth",({url:"/Administration/ERMS_Administration/Reco=
rdTypes/_CreateableRecordTypes_/Still%20Birth;internal&action=3Djs.execut=
e.action&Parameter=3D%23%28UIClass%3AHW_ERMS_RecordUI%29%28Method%3Astati=
c_.chooseRecordDestination%29&ctx=3DeKS", targetmult:"dialogs", =
target:"dialogs", operation:"severaldocs", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true}));=0A=
m3.add("File&nbsp;Record",({selectionminimum:-1, =
selectionmaximum:1000000, quickTestId:"HWErmsDeclRec", child:"m4"}));=0A=
m3.addSep();=0A=
m3.add("File",({key:"F", winstyle:"{ height:'470'}", =
targetmult:"dialogs", target:"dialogs", act:"dialog.uploadfile", =
cssclass:"hw_newfile", selectionminimum:-1, selectionmaximum:1000000, =
isdisabled:true, quickTestId:"hwt_pub_NewFile"}));=0A=
m3.add("Collection",({key:"C", winstyle:"{ height:'440'}", =
targetmult:"dialogs", target:"dialogs", actp:"Collection", =
act:"dialog.newcollection", cssclass:"hw_newcoll", selectionminimum:-1, =
selectionmaximum:1000000, isdisabled:true, =
quickTestId:"hwt_pub_NewCollection"}));=0A=
m3.add("Request&nbsp;New&nbsp;Collection...",({key:"I", =
targetmult:"dialogs", target:"dialogs", act:"dialog.reqcollection", =
cssclass:"hw_reqnewcollection", selectionminimum:-1, =
selectionmaximum:1000000}));=0A=
m3.add("Publish&nbsp;Multiple&nbsp;Collections...",({key:"I", =
targetmult:"dialogs", target:"dialogs", =
act:"dialog.createMultipleCollections", selectionminimum:-1, =
selectionmaximum:1000000, isdisabled:true}));=0A=
m3.add("HTML",({key:"Y", exec:"HTMLSave=3D''", winstyle:"{ =
minWidth:'900'}", targetmult:"publishhtmldialogs", =
target:"publishhtmldialogs", act:"dialog.newhtml", selectionminimum:-1, =
selectionmaximum:1000000, isdisabled:true, =
quickTestId:"hwt_pub_NewHTML"}));=0A=
m3.add("Text",({key:"T", targetmult:"publishtextdialogs", =
target:"publishtextdialogs", act:"dialog.newtext", selectionminimum:-1, =
selectionmaximum:1000000, isdisabled:true, =
quickTestId:"hwt_pub_NewText"}));=0A=
m2.add("Publish",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"HWPublishMenu", child:"m3"}));=0A=
m2.addSep();=0A=
m5=3Dnew Menu("HWEditMenu",({showdisabledicons:true}));=0A=
m5.add("Sort&nbsp;Order...",({targetmult:"dialogs", target:"dialogs", =
act:"dialog.setsortorder", cssclass:"hw_sortorder", selectionminimum:-1, =
selectionmaximum:1000000, isdisabled:true, =
quickTestId:"hwt_mod_SortOrder"}));=0A=
m5.add("Create&nbsp;Shortcut...",({targetmult:"dialogs", =
target:"dialogs", actp:"link", act:"dialog.choosetarget", =
cssclass:"hw_createshortcut", selectionminimum:-1, =
selectionmaximum:1000000, op:true, isdisabled:"(false|| (typeof move =
!=3D\"function\"))", quickTestId:"hw_api_link"}));=0A=
m5.add("Replace",({targetmult:"dialogs", target:"dialogs", =
operation:"replace", actp:"addFileField", act:"dialog.editattributes", =
cssclass:"hw_replace", selectionminimum:1, selectionmaximum:1, =
quickTestId:"hwt_mod_replace"}));=0A=
m5.add("Duplicate",({winstyle:"{ height:'480', width:'640'}", =
targetmult:"dialogs", target:"dialogs", actp:"copy", =
act:"dialog.choosetarget", cssclass:"hw_copy", selectionminimum:1, =
selectionmaximum:1000000, op:true, isdisabled:"(false|| (typeof move =
!=3D\"function\"))", quickTestId:"hw_api_copy"}));=0A=
m5.addSep();=0A=
m5.add("Restore",({targetmult:"dialogs", target:"dialogs", =
act:"dialog.restore", cssclass:"hw_wbrestore", selectionminimum:-1, =
selectionmaximum:1000000}));=0A=
m2.add("Modify",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"HWEditMenu", child:"m5"}));=0A=
m2.addSep();=0A=
m6=3Dnew Menu("HWPropMenu",({showdisabledicons:true}));=0A=
m6.add("Open&nbsp;Documents",({exec:"openDocuments()", =
cssclass:"hw_opendocuments", selectionminimum:-1, =
selectionmaximum:1000000, quickTestId:"hwt_view_OpenDocuments"}));=0A=
m6.add("Mail&nbsp;Link...",({targetmult:"HW_DataRequestFrame", =
target:"HW_DataRequestFrame", operation:"severalObj", =
act:"send_cs_email", cssclass:"hw_maillink", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true, =
quickTestId:"hwt_email"}));=0A=
m6.add("Notes",({targetmult:"dialogs", target:"dialogs", =
operation:"vnotes", act:"dialog.notes", cssclass:"hw_notes", =
selectionminimum:-1, selectionmaximum:1000000, opobj:true, =
quickTestId:"hwt_view_Notes"}));=0A=
m2.add("View",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"HWPropMenu", child:"m6"}));=0A=
m2.addSep();=0A=
m7=3Dnew Menu("HWVermen",({showdisabledicons:true}));=0A=
m7.add("Check&nbsp;In",({key:"I", targetmult:"dialogs", =
target:"dialogs", operation:"check_in", actpmult:"multiple", =
actmult:"dialog.checkin", act:"dialog.checkin", cssclass:"hw_checkin", =
selectionminimum:1, selectionmaximum:1000000, opobj:true, =
isdisabled:"(false||nsbform)", quickTestId:"hw_api_checkIn"}));=0A=
m7.add("Check&nbsp;Out...",({key:"O", winstyle:"{ minWidth:'720'}", =
targetmult:"HW_Mainwindow", target:"dialogs", operation:"check_out", =
namemult:"%%checkout.object.form%%", act:"dialog.checkout", =
cssclass:"hw_checkout", selectionminimum:-1, selectionmaximum:1000000, =
opobj:true, isdisabled:"(true||nsbform)", =
quickTestId:"hw_api_checkOut"}));=0A=
m7.add("Version&nbsp;History...",({key:"V", winstyle:"{ =
minWidth:'720'}", targetmult:"dialogs", target:"dialogs", =
operation:"onedoc", actp:"edit", act:"dialog.versions", =
cssclass:"hw_versions", selectionminimum:1, selectionmaximum:1, =
quickTestId:"hw_api_versions"}));=0A=
m7.add("Checked&nbsp;Out&nbsp;Documents...",({winstyle:"{ =
minWidth:'720'}", targetmult:"dialogs", target:"dialogs", =
act:"dialog.listcheckedout", cssclass:"hw_checkedoutdocs", =
selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"hwt_vers_CheckedOutDocs"}));=0A=
m2.add("Versions",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"HWVermen", child:"m7", alignprevitem:1}));=0A=
m2.addSep();=0A=
m8=3Dnew Menu("elPost",({showdisabledicons:true}));=0A=
m8.add("Assign&nbsp;To...",({targetmult:"choosetarget", =
target:"choosetarget", actp:"moveassignto", act:"dialog.choosetarget", =
cssclass:"hw_assignto", selectionminimum:-1, selectionmaximum:1000000, =
op:true, opobj:true}));=0A=
m8.add("File&nbsp;ePost...",({targetmult:"choosetarget", =
target:"choosetarget", actp:"movefilepost", act:"dialog.choosetarget", =
cssclass:"hw_filepost", selectionminimum:-1, selectionmaximum:1000000, =
op:true, opobj:true}));=0A=
m8.add("Mail&nbsp;Link...",({targetmult:"HW_DataRequestFrame", =
target:"HW_DataRequestFrame", operation:"severalObj", =
act:"send_cs_email", cssclass:"hw_maillink", selectionminimum:-1, =
selectionmaximum:1000000, op:true, submit:true, =
quickTestId:"hwt_email"}));=0A=
m8.add("Open&nbsp;Documents",({exec:"openDocuments()", =
cssclass:"hw_opendocuments", selectionminimum:-1, =
selectionmaximum:1000000, quickTestId:"hwt_view_OpenDocuments"}));=0A=
m8.add("Similar&nbsp;Documents...",({winstyle:"{ minWidth:'730'}", =
targetmult:"dialogs", target:"dialogs", operation:"onedoc", =
act:"dialog.similardocs", cssclass:"hw_similardocuments", =
selectionminimum:-1, selectionmaximum:1000000, opobj:true, =
quickTestId:"hwt_view_SimDocs"}));=0A=
m8.addSep();=0A=
m8.add("ePost&nbsp;Response...",({key:"I", targetmult:"dialogs", =
target:"dialogs", actpmult:"multiple", actmult:"dialog.updatebh", =
act:"dialog.updatebh", cssclass:"hw_epostresponse", selectionminimum:-1, =
selectionmaximum:1000000, opobj:true}));=0A=
m8.add("Link&nbsp;Erica&nbsp;Post...",({targetmult:"dialogs", =
target:"dialogs", actpmult:"multiple", actmult:"dialog.ericamultpost", =
act:"dialog.ericapost", cssclass:"hw_linkerica", selectionminimum:-1, =
selectionmaximum:1000000, opobj:true}));=0A=
m2.add("ePost",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"elPost", child:"m8", alignprevitem:1}));=0A=
m2.addSep();=0A=
m9=3Dnew Menu("HWHelpMenu",({showdisabledicons:true}));=0A=
if (typeof HW_addContextHelp =3D=3D"function")=0A=
  HW_addContextHelp(m9);=0A=
m9.add("Contents...",({targetmult:"HelpWindow", target:"HelpWindow", =
act:"dialog.mainhelp.hw_bhelp", selectionminimum:-1, =
selectionmaximum:1000000}));=0A=
m2.add("Help",({selectionminimum:-1, selectionmaximum:1000000, =
quickTestId:"HWHelpMenu", child:"m9", alignprevitem:1}));=0A=
=0A=
  hwiconbar=3Dm2;=0A=
  var mstat=3Dhwbar.restorStat();=0A=
  if (mstat!=3D0){=0A=
    openMenu(-1,-1,{oname:"opener",mname:"hwbar"});=0A=
    openMenu(-1,-1,{oname:"hwiconbarContainerOpener",mname:"hwiconbar"});=0A=
    addToOnunload(function () { hwbar.destructor(); });=0A=
    addToOnunload(function () { hwiconbar.destructor(); });=0A=
  }=0A=
}=0A=
addToOnload(function (){=0A=
  if (typeof hw_menu_selection_model !=3D "undefined"){=0A=
    hw_menu_selection_model.attach(new CSMenuObserver({menu:hwbar}));=0A=
    hw_menu_selection_model.attach(new CSMenuObserver({menu:hwiconbar}));=0A=
  }=0A=
  else {=0A=
    hwbar.updateSelection(1);=0A=
    hwiconbar.updateSelection(1);=0A=
  }=0A=
},addToOnload.LAST);=0A=
  if (top.frames.length) {=0A=
    addToOnload(buildHWMenu);=0A=
  }=0A=
</SCRIPT>

<SCRIPT>=0A=
<!--=0A=
  if (top.frames.length>0) {=0A=
  top.unique=3D"1364997150233";=0A=
  top.isAlternativeCluster =3D false;=0A=
}=0A=
if (top.frames.length>0) {=0A=
  var gOC =3D top.gObjectCache;=0A=
  gOC.addObject({G:"0x80010cb5_0x035dc1f3", CTX:"eKS", =
HP:"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.pd=
f", ON:"615654_KfxPDF00001.pdf", T:"A0 ePost for Development_Management =
at 02/04/2013 14:11:07 - 615654", =
Tenc:"A0%20ePost%20for%20Development_Management%20at%2002%2F04%2F2013%201=
4%3A11%3A07%20-%20615654", A:"W", =
U:"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.pdf=
", =
OC:"opDlg('/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF0=
0001.pdf;internal&action=3Dforcetemplates.action&ctx=3DeKS','HW_Mainwindo=
w');return false;", DT:"Generic", ST:"DIZHNWX", isEditable:"true", =
IC:"/wavemaster.internal/icons/pdf.png", =
IC2:"/wavemaster.internal/icons/pdf_32.png", DCI:"BMBC_Document", =
DES:"Document 2 of 2 from batch 000199828", AU:"James%20Hyde", =
TM:"2013/04/03 10:54:28", NM:"new", S:"1.1 MB"});=0A=
  gOC.addChildren("0x80010cb5_0x035dc1f3",[],true);=0A=
if (!window.listing_container) {=0A=
  gOC.setCurrentObject("0x80010cb5_0x035dc1f3");=0A=
}=0A=
}=0A=
//--></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (treeview_on, breadcrumb_on, callback_str) {=0A=
    if (top.frames && top.frames.length > 0) {=0A=
        top.gTV =3D top.gTreeview;=0A=
        top.gBC =3D top.gBreadCrumb;=0A=
        var gObj =3D top.gTV.data_.getCurrentObject();=0A=
        if (gObj) {=0A=
            var path =3D top.gTV.searchUp(gObj.G);=0A=
            if (path.length > 0 && path[0].G =3D=3D top.gTV.getRoot()) {=0A=
                top.gTV.setNextPath(path, true);=0A=
                top.updateUpButtonState();=0A=
                if (breadcrumb_on) {=0A=
                    top.gBC.setPath(path);=0A=
                    top.gBC.render();=0A=
                } else {=0A=
                    top.gBC.clear();=0A=
                }=0A=
                top.gTV.setNextPath(null, false);=0A=
                top.setHwUITreeState(gObj);=0A=
            } else {=0A=
                top.search_up_in_progress =3D true;=0A=
                var params =3D {'GOid': gObj.G};=0A=
                if (gObj.HWV) {=0A=
                    params.version =3D gObj.HWV;=0A=
                }=0A=
                top.callServerFunction({'serverFunctionName': =
"searchUpObject", 'objectidentifier': gObj.G, 'parameters': params, =
'callback': callback_str.replace(/%GOid%/g, gObj.G)});=0A=
            }=0A=
        }=0A=
    }=0A=
}).apply(this, [true, true, "(function () {\n(function (treeview_on, =
breadcrumb_on) {\nif (top.gTV) {\nvar path =3D =
top.gTV.searchUp(\"%GOid%\");\ntop.gTV.setNextPath(path, =
true);\ntop.updateUpButtonState();\nif (treeview_on) =
{\ntop.reload_navigation();\n}\nif (breadcrumb_on) =
{\ntop.gBC.setPath(path);\ntop.gBC.render();\ntop.gTV.setNextPath(null, =
false);\n}\n}\ntop.search_up_in_progress =3D false;\n}).apply(this, =
[true, true]);\n}).call(this);"]);=0A=
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (theTreeviewState, theBreadcrumbingState, theBorderState, =
theHeaderInfo, theTreeviewInfo, theHelpInfo, theSearchInfo) {=0A=
    if (top.FrameSetMediator) {=0A=
        var fsm =3D top.FrameSetMediator.static_.getInstance();=0A=
        if (theTreeviewState) {=0A=
            fsm.setTreeviewStateTemporary(fsm.static_[theTreeviewState]);=0A=
        }=0A=
        if (theBreadcrumbingState) {=0A=
            =
fsm.setBreadcrumbingStateTemporary(fsm.static_[theBreadcrumbingState]);=0A=
        }=0A=
        if (theBorderState) {=0A=
            fsm.setMainframeBorderState(fsm.static_[theBorderState]);=0A=
        }=0A=
        if (theTreeviewInfo && top.gTreeview) {=0A=
            if (theTreeviewInfo.visibleRoot) {=0A=
                theTreeviewInfo.oldVisibleRoot =3D =
top.gTreeview.getVisibleRoot();=0A=
                =
top.gTreeview.setVisibleRoot(theTreeviewInfo.visibleRoot);=0A=
            }=0A=
            if (theTreeviewInfo.root) {=0A=
                theTreeviewInfo.oldRoot =3D top.gTreeview.getRoot();=0A=
                top.gTreeview.setRoot(theTreeviewInfo.root);=0A=
            }=0A=
        }=0A=
        addToOnload(function () {if (top.FrameSetMediator) {var =
header_info =3D {};if (theHeaderInfo.caption) {header_info.caption =3D =
theHeaderInfo.caption;}if (theHeaderInfo.title) {header_info.title =3D =
theHeaderInfo.title;}if (theHeaderInfo.tabs) {header_info.tabs =3D =
theHeaderInfo.tabs;}if (theHeaderInfo.goid && top.gObjectCache) {var obj =
=3D top.gObjectCache.getObject(theHeaderInfo.goid);if (obj) =
{header_info.infoicon =3D {'src': "/wavemaster.internal" + =
top.cs_lib_getInfoIcon(obj), 'onclick': =
top.cs_lib_getInfoIcon_onClick(obj)};}}top.FrameSetMediator.static_.getIn=
stance().setHeaderInfo(header_info);}});=0A=
        addToOnunload(function () {if (theTreeviewInfo && top.gTreeview) =
{if (theTreeviewInfo.root) =
{top.gTreeview.setRoot(theTreeviewInfo.oldRoot);}if =
(theTreeviewInfo.visibleRoot) =
{top.gTreeview.setVisibleRoot(theTreeviewInfo.oldVisibleRoot);}}});=0A=
        if (theHelpInfo && theHelpInfo.mainHelpUrl) {=0A=
            addToOnload(function () {var fw =3D hw.getFramework();var =
help_mediator =3D fw.getUIElement(fw.static_.HELPBUTTON);if =
(help_mediator) {help_mediator.setUrl(theHelpInfo.mainHelpUrl);}});=0A=
            addToOnunload(function () {var fw =3D hw.getFramework();var =
help_mediator =3D fw.getUIElement(fw.static_.HELPBUTTON);if =
(help_mediator) {help_mediator.setUrl(null);}});=0A=
        }=0A=
        if (theSearchInfo &&=0A=
            (theSearchInfo.simpleSearchUrl ||=0A=
            theSearchInfo.advancedSearchUrl)) {=0A=
            addToOnload(function () {var fw =3D hw.getFramework();var =
search_mediator =3D fw.getUIElement(fw.static_.SEARCHBUTTON);if =
(search_mediator) {if (theSearchInfo.simpleSearchUrl) =
{search_mediator.setSimpleSearchUrl(theSearchInfo.simpleSearchUrl);}if =
(theSearchInfo.advancedSearchUrl) =
{search_mediator.setAdvancedSearchUrl(theSearchInfo.advancedSearchUrl);}}=
});=0A=
            addToOnunload(function () {var fw =3D hw.getFramework();var =
search_mediator =3D fw.getUIElement(fw.static_.SEARCHBUTTON);if =
(search_mediator) {if (theSearchInfo.simpleSearchUrl) =
{search_mediator.setSimpleSearchUrl(null);}if =
(theSearchInfo.advancedSearchUrl) =
{search_mediator.setAdvancedSearchUrl(null);}}});=0A=
        }=0A=
    }=0A=
}).apply(this, ["", "", "", {title:"A0 ePost for Development_Management =
at 02/04/2013 14:11:07 - 615654", goid:"0x80010cb5_0x035dc1f3"}, {}, =
null, null]);=0A=
}).call(this);</SCRIPT>

<META name=3DGENERATOR content=3D"MSHTML 8.00.7601.18094"></HEAD>
<BODY>
<SCRIPT>=0A=
  var gToff=3Dnew Date().getTimezoneOffset()/60;=0A=
  if (gToff>12) gToff=3DgToff-24;=0A=
  setCookie('HW_GMTOff',gToff)</SCRIPT>

<SCRIPT>=0A=
if (!window.name || window.name=3D=3D""){window.name=3D"HW_Mainwindow";}=0A=
</SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (doReloadNavigation) {=0A=
    if (gIsFrameSet) {=0A=
        if (doReloadNavigation) {=0A=
            addToOnload(reload_navigation);=0A=
        }=0A=
        addToOnload(reload_userblock);=0A=
    }=0A=
}).apply(this, [true]);=0A=
}).call(this);</SCRIPT>

<SCRIPT>=0A=
function FormX(theForm) {=0A=
  if (typeof theForm =3D=3D "string") {=0A=
    this.form_ =3D document.forms[theForm];=0A=
  }=0A=
  else if (theForm.constructor =3D=3D FormX) {=0A=
    this.form_ =3D theForm.form_;=0A=
  }=0A=
  else {=0A=
    this.form_ =3D theForm;=0A=
  }=0A=
}=0A=
FormX.prototype.getElement =3D function (theName) {=0A=
  if (!this.form_[theName]) {=0A=
    $(this.form_).appendChild(new =
Element("input",{name:theName,type:"hidden"}));=0A=
  }=0A=
  return this.form_[theName];=0A=
};=0A=
FormX.prototype.getValue =3D function (theName) {=0A=
  return this.getElement(theName).value;=0A=
};=0A=
FormX.prototype.setValue =3D function (theName, theValue) {=0A=
  if (this.getElement(theName).value !=3D theValue) {=0A=
    this.getElement(theName).value =3D theValue;=0A=
  }=0A=
  return this;=0A=
}=0A=
=0A=
function getForm(theFormName) {=0A=
  return $(document.forms[theFormName]) || null;=0A=
}=0A=
=0A=
=0A=
var gCurrentUrl =3D =
"/Documents/Users/JamesHyde/_id36bc051548b00cda_/615654_KfxPDF00001.pdf";=0A=
var gCurrentGOid =3D "0x80010cb5_0x035dc1f3";=0A=
var gCurrentVersionUrl =3D "";=0A=
var gDuplicateCheckLinks =3D "3";=0A=
var gEditLocallyEnabled =3D true;=0A=
var gMoveCopyParentGOid =3D "0x80010cb5_0x035dc1f8";=0A=
var gDeleteParentUrl =3D =
"/Documents/Users/JamesHyde/_id36bc051548b00cda_";=0A=
</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/compon=
ents/standardpage/code/csmodifyscripts.js?cachekeY=3D515488b2-en"=20
concatid=3D"ssmodifyscripts.js_57_1_150"></SCRIPT>
<LINK rel=3Dstylesheet type=3Dtext/css=20
href=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/uisty=
le/hwdefault/css/annotation.css?cachekeY=3D515488b2-en"><!-- document =
-->
<FORM method=3Dpost name=3Dbodyform action=3D""><INPUT type=3Dhidden =
name=3Dnew1> <INPUT=20
type=3Dhidden name=3Dnew2> <INPUT type=3Dhidden =
name=3DPLACE_MOVECOPYOBJECTDESTINATION>=20
<INPUT value=3D0x80010cb5_0x035dc1f3 type=3Dhidden name=3Ddocname> =
</FORM>
<STYLE type=3Dtext/css>HTML {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; OVERFLOW: hidden; PADDING-TOP: 0px
}
BODY {
	PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: =
0px; OVERFLOW: hidden; PADDING-TOP: 0px
}
.fullsize {
	POSITION: absolute; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: =
0px; WIDTH: 100%; PADDING-RIGHT: 0px; HEIGHT: 100%; TOP: 0px; =
PADDING-TOP: 0px; LEFT: 0px
}
IFRAME {
	POSITION: absolute; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: =
0px; WIDTH: 100%; PADDING-RIGHT: 0px; HEIGHT: 100%; TOP: 0px; =
PADDING-TOP: 0px; LEFT: 0px
}
OBJECT {
	POSITION: absolute; PADDING-BOTTOM: 0px; MARGIN: 0px; PADDING-LEFT: =
0px; WIDTH: 100%; PADDING-RIGHT: 0px; HEIGHT: 100%; TOP: 0px; =
PADDING-TOP: 0px; LEFT: 0px
}
</STYLE>

<SCRIPT type=3Dtext/javascript>
function _start(iframe) {
  if (!hw.getFramework().getApplicationProperty("eks", =
"opendocument.documentloaded.0x80010cb5_0x035dc1f3.a49a34d623a53aa440daed=
dc47062d83")) {
    new PeriodicalExecuter(function(pe) {
        try {
          iframe.contentWindow.document.body;
          //window_debug("try: "+iframe.contentWindow.document.body);
        }
        catch (exc) {
          //window_debug("catch: ");
          hw.getFramework().setApplicationProperty("eks", =
"opendocument.documentloaded.0x80010cb5_0x035dc1f3.a49a34d623a53aa440daed=
dc47062d83", true);
          pe.stop();
        }
      }, 1);
  }
}
</SCRIPT>
<IFRAME id=3DHWHIDE1 onload=3D_start(this);=20
src=3D"http://hyperwave.barnsley.gov.uk/Documents/Users/JamesHyde/_id36bc=
051548b00cda_/615654_KfxPDF00001.pdf?hyperwave=3Daction%3Dplain.action&am=
p;cachekeY=3Da49a34d623a53aa440daeddc47062d83"=20
frameBorder=3D0></IFRAME>
<SCRIPT type=3Dtext/javascript>
var hide_layer =3D $("HWHIDE1");
addToOnload(function () {
  hw.getFramework().getDisplayManager().addHideLayer(hide_layer);
});
addToOnunload(function () {
  hw.getFramework().getDisplayManager().remHideLayer(hide_layer);
});
</SCRIPT>
<!-- /document -->
<SCRIPT>=0A=
if(typeof initializeLinkcreate =3D=3D "function" &&=0A=
   typeof selectionstart =3D=3D "function" &&=0A=
   typeof onmouseupreport =3D=3D "function" &&=0A=
   typeof reportmove =3D=3D "function")=0A=
{=0A=
  addToOnload(initializeLinkcreate);=0A=
  document.onselectstart=3Dselectionstart;=0A=
  document.onmouseup=3Donmouseupreport;=0A=
  document.onmousemove=3Dreportmove;=0A=
}=0A=
</SCRIPT>

<SCRIPT type=3Dtext/javascript=20
src=3D"http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/da=
tefunctions.js?cachekeY=3D515488b2-en"=20
concatid=3D"eks.datefunctions_1_123"></SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (theDateFormatName) {=0A=
    HW_UI_UseLocalDate =3D true;=0A=
    HW_UI_ConvertGMTLocalGMT =3D true;=0A=
    HW_UI_Date =3D g_dates.getFormat(theDateFormatName);=0A=
}).apply(this, ["HWDate"]);=0A=
}).call(this);</SCRIPT>

<SCRIPT type=3Dtext/javascript>(function () {=0A=
(function (info) {=0A=
    top.FrameSetMediator.static_.getInstance().setInfoHtml(info.html, =
top.FrameSetMediator.static_[info.type], =
top.FrameSetMediator.static_[info.alignment]);=0A=
}).apply(this, [{html:"Modified on 2013/04/03 11:54:28\n", =
type:"HEADER", alignment:"RIGHT"}]);=0A=
}).call(this);</SCRIPT>

<SCRIPT>=0A=
if (top.frames.length>0) {=0A=
  var gLW =3D getLinkWizData();=0A=
  gLW.THETYPE =3D "whole";=0A=
}=0A=
</SCRIPT>
</BODY></HTML>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=lib%2Fclientlib%2Fcom%2Fhyperwave%2Fframework%2Fhtmlres%2FFramework.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'interface_lock': new =
com.hyperwave.res.Template({ templateString_: '\x3cdiv>\x3cdiv>($#if =
$message)($html:message)&hellip;($#endif)\x3c/div>\x3c/div>'})});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("lib/clientlib/com=
/hyperwave/framework/htmlres/Framework.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=lib%2Fclientlib%2Fcom%2Fhyperwave%2Fframework%2Flangres%2FFramework.%25lang%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("lib/clientlib/com=
/hyperwave/framework/langres/Framework.%lang%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/framework/Framework.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        Framework.js=0A=
 *  Created:     2009-02-05 by sweber=0A=
 *  Description: xxx=0A=
 *=0A=
 *  $Id: Framework.js 165377 2011-08-11 10:02:46Z cgoess $=0A=
 *  $Revision: 165377 $=0A=
 * </file>=0A=
 */=0A=
 =0A=
/* <JSLINT> */=0A=
/*global Framework */=0A=
/* </JSLINT> */=0A=
 =0A=
=0A=
initPackage("com.hyperwave.framework");=0A=
// <JSClass name=3D"Framework">=0A=
=0A=
/**=0A=
 * Constructor=0A=
 */=0A=
Framework =3D com.hyperwave.framework.Framework =3D function (theWindow)=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
=0A=
  if (arguments.callee.caller !=3D =
com.hyperwave.framework.Framework.static_.getInstance &&=0A=
      arguments.callee.caller !=3D =
com.hyperwave.framework.Framework.static_.setAsRoot) {=0A=
    throw "Illegal constructor call - use =
com.hyperwave.framework.Framework.static_.getInstance()";=0A=
  }=0A=
=0A=
  this.window_ =3D theWindow;=0A=
  this.mediatorRegistry_ =3D [];=0A=
  this.displayManager_ =3D new =
com.hyperwave.framework.DisplayManager(theWindow, this);=0A=
  this.clipboard_ =3D new com.hyperwave.util.Clipboard();=0A=
  this.application_properties_ =3D {};=0A=
  this.uielements_ =3D {};=0A=
  this.frameset_mediator_ =3D null;=0A=
};=0A=
=0A=
// Inheritance call for JavaScript.=0A=
class$ =3D doInherit (com.hyperwave.framework.Framework);=0A=
=0A=
class$.static_.CONTINUE =3D true;=0A=
class$.static_.STOP =3D false;=0A=
=0A=
class$.static_.HELPBUTTON   =3D "helpbutton";=0A=
class$.static_.SEARCHBUTTON =3D "searchbutton";=0A=
class$.static_.SEARCHFORM   =3D "searchform";=0A=
class$.static_.UPBUTTON     =3D "upbutton";=0A=
class$.static_.MAINFILTER   =3D "mainfilter";=0A=
=0A=
/*=0A=
 * These are the possible blocking styles.=0A=
 * `SOFT` -> the interface is not clickable and the pointer displays the =
style `wait`=0A=
 * `DEFAULT` -> the interface is not clickable and a progress will be =
displayed=0A=
 */=0A=
class$.static_.BLOCKINGSTYLE =3D {SOFT: {toString: function () { return =
"SOFT"; }},=0A=
                                DEFAULT: {toString: function () { return =
"DEFAULT"; }}};=0A=
=0A=
class$.static_.getInstance =3D function () {=0A=
  if (this.singleton_) {=0A=
    return this.singleton_;=0A=
  }=0A=
  var a_window =3D window.top;=0A=
  =0A=
  while (typeof a_window.com =3D=3D "undefined" ||=0A=
         typeof a_window.com.hyperwave =3D=3D "undefined" ||=0A=
         typeof a_window.com.hyperwave.framework =3D=3D "undefined" ||=0A=
         typeof a_window.com.hyperwave.framework.Framework =3D=3D =
"undefined" ||=0A=
         !a_window.com.hyperwave.framework.Framework.static_.singleton_) =
{=0A=
    if (a_window.opener && !a_window.opener.closed) {=0A=
      a_window =3D a_window.opener.top;=0A=
    }=0A=
    else {=0A=
      /*=0A=
        The following part is especially for IE and in case of =
retrieving the Framework=0A=
        in an unload event. The reason is, that while unload event in =
IE, the "top" refers=0A=
        the own window and so opener can refer an undefined variable and =
opener.top=0A=
        throws an runtime error.=0A=
        Note: In "beforeunload" event the "top" refers the real "top".=0A=
      */=0A=
      var frame_element =3D null;=0A=
      try {=0A=
        frame_element =3D a_window.frameElement;=0A=
      }=0A=
      catch (exc) {=0A=
        // ignore "interface not supported"-exceptions=0A=
      }=0A=
      if (frame_element) {=0A=
        var tmp =3D a_window.frame_element.ownerDocument;=0A=
        a_window =3D (tmp.defaultView || tmp.parentWindow).top;=0A=
      }=0A=
      else {=0A=
        // fallback: make this instance the root framework=0A=
        return this.singleton_ =3D new this.class_(window);=0A=
        //throw "Unexpected Error: Could not find Framework";=0A=
      }=0A=
    }=0A=
  }=0A=
  return a_window.com.hyperwave.framework.Framework.static_.singleton_;=0A=
};=0A=
=0A=
class$.static_.getHtmlRes =3D function () {=0A=
  return =
com.hyperwave.util.IncludeManager.static_.getResource("lib/clientlib/com/=
hyperwave/framework/htmlres/Framework.xml");=0A=
};=0A=
=0A=
class$.static_.getLangRes =3D function () {=0A=
  return =
com.hyperwave.util.IncludeManager.static_.getResource("lib/clientlib/com/=
hyperwave/framework/langres/Framework.%lang%.xml");=0A=
};=0A=
=0A=
class$.actionDone =3D function (theResult, theData, theWindow) {=0A=
  var do_default_processing =3D Framework.static_.CONTINUE;=0A=
  for (var i =3D 0; i < this.mediatorRegistry_.length; i ++) {=0A=
    var result =3D =
this.mediatorRegistry_[i].onActionDone(eval(theResult), eval(theData), =
theWindow);=0A=
    if (result =3D=3D=3D Framework.static_.STOP) {=0A=
      do_default_processing =3D Framework.static_.STOP;=0A=
    }=0A=
  }=0A=
  return do_default_processing;=0A=
};=0A=
=0A=
class$.actionError =3D function (theResult, theData, theWindow) {=0A=
  var do_default_processing =3D Framework.static_.CONTINUE;=0A=
  for (var i =3D 0; i < this.mediatorRegistry_.length; i ++) {=0A=
    var result =3D =
this.mediatorRegistry_[i].onActionError(eval(theResult), eval(theData), =
theWindow);=0A=
    if (result =3D=3D=3D Framework.static_.STOP) {=0A=
      do_default_processing =3D Framework.static_.STOP;=0A=
    }=0A=
  }=0A=
  return do_default_processing;=0A=
};=0A=
=0A=
class$.addPageMediator =3D function (theMediator) {=0A=
  for (var i =3D 0; i < this.mediatorRegistry_.length; i ++) {=0A=
    if (this.mediatorRegistry_[i] =3D=3D=3D theMediator) {=0A=
      return;=0A=
    }=0A=
  }=0A=
=0A=
  this.mediatorRegistry_.push(theMediator);=0A=
};=0A=
=0A=
class$.removePageMediator =3D function (theMediator) {=0A=
  for (var i =3D this.mediatorRegistry_.length - 1; i >=3D 0; i --) {=0A=
    if (this.mediatorRegistry_[i] =3D=3D=3D theMediator) {=0A=
      this.mediatorRegistry_.splice(i, 1);=0A=
    }=0A=
  }=0A=
};=0A=
=0A=
class$.displayError =3D function (theParams, theWindow) {=0A=
  if (theParams.errorMessages && theParams.errorMessages.length>0) {=0A=
    var dialog =3D new com.hyperwave.dialogs.Message(null, =
theParams.errorMessages, 2);=0A=
  }=0A=
  else {=0A=
    var dialog =3D new com.hyperwave.dialogs.Message(null, =
theParams.errorMessage, 2);=0A=
  }=0A=
  this.displayDialog(dialog, theWindow);=0A=
  return dialog;=0A=
};=0A=
=0A=
/**=0A=
 * This method return the related DisplayManager.=0A=
 *=0A=
 * @return: com.hyperwave.framework.DisplayManager: the display manager=0A=
 */=0A=
class$.getDisplayManager =3D function () {=0A=
  return this.displayManager_;=0A=
};=0A=
=0A=
/**=0A=
 * Displays an inline dialog=0A=
 * @param theDialog: dialog js class to display=0A=
 */=0A=
class$.displayDialog =3D function (theDialog, aWindow, theParams) {=0A=
  return this.displayManager_._addDialog(theDialog, aWindow, theParams);=0A=
};=0A=
=0A=
/**=0A=
 * Close inline dialog=0A=
 * @param theDialog: the dialog class=0A=
 */=0A=
class$.closeDialog =3D function (theDialog, doDeferred) {=0A=
  // <FIXXXXXME author=3D"cgoess" date=3D"25.06.2009" descr=3D"Should be =
moved into IframeDialog-class in the next refactoring">=0A=
  // find=0A=
  var iframedialog_iframe =3D $("IframeDialog_"+theDialog.getId());=0A=
  if (iframedialog_iframe) {=0A=
    var real_close_function =3D =
this.displayManager_._remDialog.bind(this.displayManager_, theDialog, =
doDeferred);=0A=
    var close_function =3D function () {=0A=
      iframedialog_iframe.stopObserving("load", close_function);=0A=
      real_close_function.defer();=0A=
    };=0A=
    iframedialog_iframe.observe("load", close_function);=0A=
    try {=0A=
      =
iframedialog_iframe.contentWindow.location.replace("/wavemaster.internal/=
webapp/lib/empty.html");=0A=
    }=0A=
    catch (exc) {=0A=
      // generic document may throw exception=0A=
      iframedialog_iframe.src =3D =
"/wavemaster.internal/webapp/lib/empty.html";=0A=
    }=0A=
  // </FIXXXXXME>=0A=
  }=0A=
  else {=0A=
    return this.displayManager_._remDialog(theDialog, doDeferred);=0A=
  }=0A=
};=0A=
=0A=
class$.getDialogById =3D function (theId) {=0A=
  return this.displayManager_.get(theId).dialog;=0A=
};=0A=
=0A=
class$.setApplicationProperty =3D function (theApplicationId, theKey, =
theValue) {=0A=
  if (!this.application_properties_[theApplicationId]) {=0A=
    this.application_properties_[theApplicationId] =3D {};=0A=
  }=0A=
  this.application_properties_[theApplicationId][theKey] =3D theValue;=0A=
};=0A=
=0A=
class$.getApplicationProperty =3D function (theApplicationId, theKey) {=0A=
  if (this.application_properties_[theApplicationId]) {=0A=
    return this.application_properties_[theApplicationId][theKey];=0A=
  }=0A=
  return null;=0A=
};=0A=
=0A=
class$.getClipboard =3D function() {=0A=
  return this.clipboard_;=0A=
};=0A=
=0A=
/**=0A=
 * @param theParameters: object:=0A=
 * @param theParameters.baseurl: string|void: (e.g. /workflow/dashboard)=0A=
 *                               if empty, it is taken from the =
theWindow.location or form.action=0A=
 * @param theParameters.form: Element|void: (e.g. $('my_form'))=0A=
 * @param theParameters.action: string|void: (e.g. insert.action)=0A=
 * @param theParameters.method: string|void: (e.g. =
com.hyperwave.util.HW_WF_DashboardUI.static_.xyz)=0A=
 * @param theParameters.context string|void: the context (ctx) parameter =
in the url (e.g. "eKS", "HWB", ...)=0A=
 * @param theParameters.message:=0A=
 * @param theParameters.blocking: boolean|true:=0A=
 * @param theParameters.blockingStyle: =
Framework.static_.BLOCKINGSTYLE|void: defines the blocking style=0A=
 * @param theParameters.requestParameters: object|void: the request =
parameters=0A=
 * @param theParameters.requestMethod: string|void: the request method=0A=
 * @param theMediator: com.hyperwave.framework.BaseMediator: the related =
mediator, onActionError|onActionDone will be called=0A=
 * @param theWindow: window: the related window=0A=
 */=0A=
class$.ajaxRequest =3D function (theParameters, theMediator, theWindow) {=0A=
  var result =3D {};=0A=
=0A=
  if (theParameters.form) {=0A=
    var formaction =3D theParameters.form.readAttribute("action");=0A=
    var url_parts =3D =
com.hyperwave.util.Url.static_.parseUrl(formaction);=0A=
    result.action =3D url_parts.jsMethod || url_parts.action || "";=0A=
  }=0A=
  else {=0A=
=0A=
    if (theParameters.baseurl) {=0A=
      var baseurl =3D =
com.hyperwave.util.Url.static_.getBaseUrlByUrl(theParameters.baseurl);=0A=
    }=0A=
    else {=0A=
      var baseurl =3D =
com.hyperwave.util.Url.static_.getBaseUrlByWindow(theWindow);=0A=
    }=0A=
=0A=
    if (theParameters.action) {=0A=
      var url =3D baseurl + =
com.hyperwave.util.Url.static_.getUrlPostfixForAction(theParameters.actio=
n);=0A=
      result.action =3D theParameters.action;=0A=
    }=0A=
    else if (theParameters.method) {=0A=
      var url =3D baseurl + =
com.hyperwave.util.Url.static_.getUrlPostfixForMethod(null, =
theParameters.method);=0A=
      result.action =3D theParameters.method;=0A=
    }=0A=
    else {=0A=
      throw "Missing parameter action|method|form";=0A=
    }=0A=
    =0A=
    if (theParameters.context) {=0A=
      url +=3D "&ctx=3D" + theParameters.context;=0A=
    }=0A=
  }=0A=
  =0A=
  if (theParameters.event) {=0A=
    result.event =3D theParameters.event;=0A=
  }=0A=
=0A=
  if (theParameters.message) {=0A=
    var info =3D this.displayManager_.info(theParameters.message[0]);=0A=
    var unlock_function =3D (function (success) {=0A=
        if (success && theParameters.message[1]) {=0A=
          this.displayManager_.info(theParameters.message[1], 3);=0A=
        }=0A=
        info.close();=0A=
      }).bind(this);=0A=
  }=0A=
  else if (theParameters.blocking =3D=3D=3D false) {=0A=
    var unlock_function =3D function (success) { };=0A=
  }=0A=
  else {=0A=
    var lock_param =3D theParameters.blockingStyle =3D=3D =
this.static_.BLOCKINGSTYLE.SOFT ? false : true;=0A=
    this.displayManager_.lock(lock_param, theWindow);=0A=
    var unlock_function =3D (function (success) {=0A=
        this.displayManager_.unlock();=0A=
      }).bind(this);=0A=
  }=0A=
=0A=
  var ajax_params =3D {};=0A=
  ajax_params.onFailure =3D (function (theResponse) {=0A=
      unlock_function(false);=0A=
      result.ajaxResponse =3D theResponse;=0A=
      result.errorCode =3D "";=0A=
      result.errorMessage =3D theResponse.responseText;=0A=
      result.errorMessages =3D theResponse.responseJSON;=0A=
      result.form =3D theResponse.request.parameters;=0A=
      if (theMediator.onActionError(result, theResponse.responseJSON, =
theWindow) !=3D Framework.static_.STOP) {=0A=
        this.displayError(result);=0A=
      }=0A=
    }).bind(this);=0A=
  ajax_params.onSuccess =3D (function (theResponse) {=0A=
      unlock_function(true);=0A=
      result.ajaxResponse =3D theResponse;=0A=
      result.form =3D theResponse.request.parameters;=0A=
      if (theMediator.onActionDone(result, theResponse.responseJSON, =
theWindow) !=3D Framework.static_.STOP) {=0A=
        // not implemented yet -> default behaviour -> is nothing -> =
really nothing to do=0A=
      }=0A=
    }).bind(this);=0A=
  if (theParameters.requestParameters) {=0A=
    ajax_params.parameters =3D theParameters.requestParameters;=0A=
  }=0A=
  if (theParameters.requestMethod) {=0A=
    ajax_params.method =3D theParameters.requestMethod;=0A=
  }=0A=
=0A=
  if (theParameters.form) {=0A=
    theParameters.form.request(ajax_params);=0A=
  }=0A=
  else {=0A=
    new Ajax.Request(url, ajax_params);=0A=
  }=0A=
};=0A=
=0A=
class$.registerUIElement =3D function (theId, theMediator) {=0A=
  this.uielements_[theId] =3D theMediator;=0A=
};=0A=
=0A=
class$.getUIElement =3D function (theId) {=0A=
  return this.uielements_[theId];=0A=
};=0A=
=0A=
class$.setFrameSetMediator =3D function (aMediator) {=0A=
  this.frameset_mediator_ =3D aMediator;=0A=
};=0A=
=0A=
class$.getFrameSetMediator =3D function () {=0A=
  return this.frameset_mediator_;=0A=
};=0A=
=0A=
class$.static_.setAsRoot =3D function () {=0A=
  if (!this.singleton_) {=0A=
    this.singleton_ =3D new this.class_(window);=0A=
  }=0A=
  return this.singleton_;=0A=
};=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/framework/DisplayManager.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        DisplayManager.js=0A=
 *  Created:     2009-04-30 by sweber=0A=
 *  Description: ###FILE DESCRIPTION###=0A=
 *=0A=
 *  $Id: DisplayManager.js 162680 2011-04-27 09:51:28Z sweber $=0A=
 * </file>=0A=
 */=0A=
initPackage("com.hyperwave.framework");=0A=
=0A=
/**=0A=
 * ###CLASS DESCRIPTION###=0A=
 *=0A=
 * @author sweber=0A=
 */=0A=
// <JSClass Name=3D"DisplayManager">=0A=
=0A=
/**=0A=
 * The DisplayManager constructor. ###CONSTRUCTOR DESCRIPTION###=0A=
 *=0A=
 * @param ###PARAM###: ###PARAMTYPE###: ###PARAMETER DESCRIPTION###=0A=
 */=0A=
com.hyperwave.framework.DisplayManager =3D function =
DisplayManager(theWindow, theFramework)=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
=0A=
  if (theWindow !=3D theWindow.top) {=0A=
    throw "The window must be a top window";=0A=
  }=0A=
=0A=
  this.window_ =3D theWindow;=0A=
  this.framework_ =3D theFramework;=0A=
  this.dialogs_ =3D [];=0A=
  this.isLocked_ =3D false;=0A=
  this.lockQueue_ =3D [];=0A=
  this.lockElement_ =3D null;=0A=
  this.lockElement2_ =3D null;=0A=
  this.hideLayers_ =3D [];=0A=
};=0A=
class$ =3D doInherit(com.hyperwave.framework.DisplayManager);=0A=
=0A=
class$.static_.LOCK_DELAY_ =3D 0;=0A=
class$.static_.DEFAULT_HEIGHT_ =3D 240;=0A=
class$.static_.DEFAULT_WIDTH_ =3D 320;=0A=
=0A=
class$.static_.DIALOG_ORIENTATION_DOWN =3D "down";=0A=
class$.static_.DIALOG_ORIENTATION_UP   =3D "up";=0A=
=0A=
class$.static_.DIALOG_OFFSETX_RIGHT   =3D "right";=0A=
class$.static_.DIALOG_OFFSETX_LEFT    =3D "left";=0A=
class$.static_.DIALOG_OFFSETY_TOP     =3D "top";=0A=
class$.static_.DIALOG_OFFSETY_BOTTOM  =3D "bottom";=0A=
=0A=
class$._indexByDialog =3D function (aDialog) {=0A=
  var idx =3D -1;=0A=
  this.dialogs_.each(function (element, i) {=0A=
      if (element.dialog =3D=3D aDialog) {=0A=
        idx =3D i;=0A=
        throw $break;=0A=
      }=0A=
    });=0A=
  return idx;=0A=
};=0A=
=0A=
class$._indexById =3D function (anId) {=0A=
  var idx =3D -1;=0A=
  this.dialogs_.each(function (element, i) {=0A=
      if (element.dialog.getId() =3D=3D anId) {=0A=
        idx =3D i;=0A=
        throw $break;=0A=
      }=0A=
    });=0A=
  return idx;=0A=
};=0A=
=0A=
class$._addDialog =3D function (aDialog, aWindow, theParams) {=0A=
  var idx =3D this._indexByDialog(aDialog);=0A=
  if (idx !=3D -1) {=0A=
    throw "Dialog already registered";=0A=
  }=0A=
  var display_window =3D (aWindow || this.window_).top;=0A=
  var iframes_in_display =3D =
com.hyperwave.framework.DisplayManager.static_._getIframesOfWindow(displa=
y_window);=0A=
  var entry =3D {dialog: aDialog,=0A=
=0A=
               window: display_window,=0A=
=0A=
               submitForm: (function (theEvent, theDialog) {=0A=
                   theEvent.stop();=0A=
                   var def_button =3D theDialog._getDefaultButton();=0A=
                   if (def_button) {=0A=
                     entry.setFormValues();=0A=
                     =
def_button._fireEvent(com.hyperwave.dialogs.Button.static_.EVENTS.CLICK);=0A=
                     =
theDialog._fireEvent(com.hyperwave.dialogs.Dialog.static_.EVENTS.BUTTON_C=
LICK);=0A=
                   }=0A=
                 }).bindAsEventListener(this, aDialog),=0A=
=0A=
               simpleClose: (function (theEvent, theDialog) {=0A=
                   this._remDialog(theDialog);=0A=
                 }).bindAsEventListener(this, aDialog),=0A=
=0A=
               iframes: iframes_in_display=0A=
  };=0A=
  this.dialogs_.push(entry);=0A=
  this._addToDisplay(entry, theParams);=0A=
  entry.iframes.each(function (anIframe) {=0A=
      var my_close_ =3D entry.simpleClose;=0A=
      with (anIframe) {=0A=
        Event.observe(window, "beforeunload", my_close_);=0A=
      }=0A=
    });=0A=
};=0A=
=0A=
class$._remDialog =3D function (aDialog, doDeferred) {=0A=
  if (doDeferred) {=0A=
    arguments.callee.bind(this, aDialog).defer();=0A=
    return;=0A=
  }=0A=
  var idx =3D this._indexByDialog(aDialog);=0A=
  if (idx =3D=3D -1) {=0A=
    throw "Dialog not registered";=0A=
  }=0A=
=0A=
  var entry =3D this.dialogs_.splice(idx, 1)[0];=0A=
  entry.iframes.each(function (anIframe) {=0A=
      var my_close_ =3D entry.simpleClose;=0A=
      with (anIframe) {=0A=
        Event.stopObserving(window, "beforeunload", my_close_);=0A=
      }=0A=
    });=0A=
  this._removeFromDisplay(entry);=0A=
};=0A=
=0A=
class$.get =3D function (anId) {=0A=
  try {=0A=
    return this.dialogs_[this._indexById(anId)];=0A=
  }=0A=
  catch (exc) {=0A=
    return {dialog: null, window: null};=0A=
  }=0A=
};=0A=
=0A=
class$._addToDisplay =3D function (anEntry, theParams) {=0A=
  var this_params =3D theParams || {}; // variable "params" already =
defined in "anEntry.window" :-(=0A=
  =0A=
  var dialog =3D anEntry.dialog;=0A=
  with (anEntry.window) {=0A=
    focus(); // to release the focus from the clicked element (without =
have the event object)=0A=
    var body =3D $(document.body);=0A=
    anEntry.eventListenerCache_ =3D [];=0A=
  =0A=
    var outer_div_class =3D this_params.backgroundLayerClass ? =
this_params.backgroundLayerClass : "hw_framework_outer_div";=0A=
    var out =3D this.addDisplayLayer(outer_div_class);=0A=
    var outer_div =3D out.element;=0A=
    =0A=
    if (this_params.backgroundLayerHandler) {=0A=
      var handler =3D this_params.backgroundLayerHandler;=0A=
      for (var i=3D0; i<handler.length; i++) {=0A=
        out.addEventListener(handler[i].eventName, handler[i].handler);=0A=
        anEntry.eventListenerCache_.push({=0A=
          element: outer_div,=0A=
          event: handler[i].eventName,=0A=
          handler: handler[i].handler=0A=
        });=0A=
      }=0A=
    }=0A=
    else {=0A=
      var bound_onclick_handler =3D (=0A=
        function(event) {=0A=
          event.stop();=0A=
        }=0A=
      ).bindAsEventListener(this);=0A=
      outer_div.observe("click", bound_onclick_handler);=0A=
      anEntry.eventListenerCache_.push({element: outer_div, event: =
"click", handler: bound_onclick_handler});=0A=
    }=0A=
=0A=
    var offset_x =3D 0;=0A=
    var offset_y =3D 35;=0A=
=0A=
    var viewport =3D document.viewport.getDimensions();=0A=
    viewport.width -=3D offset_x;=0A=
    viewport.height -=3D offset_y;=0A=
=0A=
    var dim =3D dialog._getDimensions() || {};=0A=
    var auto_height =3D dim.x =3D=3D null;=0A=
    if (dim.x =3D=3D null) {=0A=
      dim.x =3D =
com.hyperwave.framework.DisplayManager.static_.DEFAULT_WIDTH_;=0A=
    }=0A=
    if (dim.y =3D=3D null) {=0A=
      dim.y =3D =
com.hyperwave.framework.DisplayManager.static_.DEFAULT_HEIGHT_;=0A=
    }=0A=
=0A=
    if (dim.x =3D=3D=3D dialog.static_.MAX_X) {=0A=
      dim.x =3D viewport.width;=0A=
    }=0A=
    if (dim.y =3D=3D=3D dialog.static_.MAX_Y) {=0A=
      dim.y =3D viewport.height;=0A=
    }=0A=
=0A=
    dim.x =3D Math.round(Math.min(viewport.width * 0.95, dim.x));=0A=
    dim.y =3D Math.round(Math.min(viewport.height * 0.95, dim.y));=0A=
=0A=
    /*=0A=
     * Calculate position if positioning data is given via params=0A=
     */=0A=
    var pos =3D {};=0A=
    if (this_params.position && this_params.position.element) {=0A=
      var pos_arr =3D =
this._calculateDialogPosition(this_params.position, dim, body);=0A=
      pos.x =3D pos_arr[0];=0A=
      pos.y =3D pos_arr[1];=0A=
    }=0A=
    else {=0A=
      pos.x =3D Math.max(0, Math.round((viewport.width - dim.x) / 2 + =
offset_x));=0A=
      pos.y =3D Math.max(0, Math.round((viewport.height - dim.y) / 3 + =
offset_y));=0A=
    }=0A=
=0A=
    var form =3D eval('new Element("form");');=0A=
    dialog._setForm(form);=0A=
    form.observe("submit", anEntry.submitForm);=0A=
    anEntry.eventListenerCache_.push({element: form, event: "submit", =
handler: anEntry.submitForm});=0A=
=0A=
    var styles =3D {height: Math.round(dim.y) + "px",=0A=
                  width: Math.round(dim.x) + "px",=0A=
                  left: pos.x + "px",=0A=
                  top: pos.y + "px"};=0A=
=0A=
    var name_ =3D dialog.constructor.name || "";=0A=
    if (!name_) {=0A=
      var match =3D =
dialog.constructor.toString().match(/function\s+([\$\w]+)/);=0A=
      if (match) {=0A=
        name_ =3D match[1];=0A=
      }=0A=
    }=0A=
=0A=
    var inner_div =3D eval("new Element('div');");=0A=
    inner_div.writeAttribute("name", name_);=0A=
    inner_div.writeAttribute("class", "hw_framework_inner_div");=0A=
    // maybe this style definition can be removed in later releases -> =
check inline dialogs in >=3DIE8 (standard mode)=0A=
    inner_div.setStyle("position", "absolute"); // this style is defined =
in framework.css also=0A=
    // but must be defined here too -> otherwise IE 8.0 displays a black =
canvas only=0A=
=0A=
    if (auto_height) {=0A=
      inner_div.setStyle({height: "auto",=0A=
                          minHeight: "100px",=0A=
                          width: dim.x + "px",=0A=
                          left: pos.x + "px",=0A=
                          top: pos.y + "px"});=0A=
    }=0A=
    else {=0A=
      inner_div.setStyle({height: dim.y + "px",=0A=
                          width: dim.x + "px",=0A=
                          left: pos.x + "px",=0A=
                          top: pos.y + "px"});=0A=
    }=0A=
    =0A=
    var innerHTML =3D dialog.toString().replace(/\(\$(\w+)\)/g, function =
(match, key) {=0A=
        if (dialog.references_[key]) {=0A=
          return "$dialog_references_." + key + ".value";=0A=
        }=0A=
        return match;=0A=
      });=0A=
    anEntry.window.$dialog_references_ =3D dialog.references_;=0A=
=0A=
    form.appendChild(inner_div);=0A=
    body.appendChild(form);=0A=
    inner_div.update(innerHTML);=0A=
    anEntry.setFormValues =3D function () {=0A=
      form.getElements().each(function (element) {=0A=
          dialog.setData(element.name, element.getValue());=0A=
        });=0A=
    };=0A=
    =0A=
    var default_button =3D dialog._getDefaultButton();=0A=
    dialog.getButtons().each(function (button, i) {=0A=
        button._setDialog(dialog);=0A=
        var button_element =3D $(button.getId());=0A=
        if (i =3D=3D 0 || default_button =3D=3D button) {=0A=
          try {=0A=
            button_element.focus(); // set focus to the first button or =
the default button=0A=
          }=0A=
          catch (exc) {=0A=
            // ignore=0A=
          }=0A=
        }=0A=
      =0A=
        var bound_onclick_handler =3D function () {=0A=
            anEntry.setFormValues();=0A=
            =
button._fireEvent(com.hyperwave.dialogs.Button.static_.EVENTS.CLICK);=0A=
            =
dialog._fireEvent(com.hyperwave.dialogs.Dialog.static_.EVENTS.BUTTON_CLIC=
K);=0A=
          };=0A=
        button_element.observe("click", bound_onclick_handler);=0A=
        anEntry.eventListenerCache_.push({element: button_element, =
event: "click", handler: bound_onclick_handler});=0A=
      });=0A=
=0A=
    if (form.findFirstElement()) {=0A=
      form.focusFirstElement();=0A=
    }=0A=
  }=0A=
=0A=
  anEntry.outerElem_ =3D outer_div;=0A=
  anEntry.formElem_ =3D form;=0A=
  anEntry.innerElem_ =3D inner_div;=0A=
};=0A=
=0A=
class$._removeFromDisplay =3D function (anEntry) {=0A=
  anEntry.setFormValues();=0A=
  =
anEntry.dialog._fireEvent(com.hyperwave.dialogs.Dialog.static_.EVENTS.CLO=
SE);=0A=
=0A=
  with (anEntry.window) {=0A=
    anEntry.window.$dialog_references_ =3D null;=0A=
    =0A=
    // clean up eventhandlers; the (can) cause memory leaks=0A=
    anEntry.eventListenerCache_.each(function (anEntry, i) {=0A=
      Event.stopObserving(anEntry.element, anEntry.event, =
anEntry.handler);=0A=
    });=0A=
=0A=
    anEntry.innerElem_.remove();=0A=
    anEntry.formElem_.remove();=0A=
    anEntry.outerElem_.remove();=0A=
  }=0A=
};=0A=
=0A=
class$.info =3D function (aMessage, aLifetime) {=0A=
  if (!this.infoHandler_) {=0A=
    this.infoHandler_ =3D {=0A=
    info: new Element('div', {"class": "hw_framework_infoarea"}),=0A=
    blockedCtr_: 0,=0A=
=0A=
    update: function (hint) {=0A=
        this.blockedCtr_ +=3D hint;=0A=
        if (this.blockedCtr_ =3D=3D 1 && hint =3D=3D 1) {=0A=
          this.lock();=0A=
        }=0A=
        if (this.blockedCtr_ =3D=3D 0 && hint =3D=3D -1) {=0A=
          this.unlock();=0A=
        }=0A=
      },=0A=
=0A=
    empty: function () {=0A=
        return !this.info.childNodes.length;=0A=
      },=0A=
=0A=
    append: function (aMessage, isBlocking) {=0A=
        var div =3D new Element('div', {name: isBlocking ? "blocking" : =
""});=0A=
        div.innerHTML =3D '<div><div><span>' + aMessage + =
'</span></div></div>';=0A=
        this.info.appendChild(div);=0A=
        return div;=0A=
      },=0A=
=0A=
    display: function () {=0A=
        $(document.body).appendChild(this.info);=0A=
      },=0A=
=0A=
    remove: function () {=0A=
        this.info.remove();=0A=
      },=0A=
=0A=
    lock: this.lock.bind(this, false),=0A=
    unlock: this.unlock.bind(this)=0A=
    };=0A=
  }=0A=
  var info_handler =3D this.infoHandler_;=0A=
=0A=
  if (info_handler.empty()) {=0A=
    info_handler.display();=0A=
  }=0A=
=0A=
  var wrapper =3D {=0A=
    timeout: null,=0A=
    element: info_handler.append(aMessage, !aLifetime),=0A=
    blocking: !aLifetime,=0A=
=0A=
    clearLifetime: function () {=0A=
      if (this.timeout !=3D=3D null) {=0A=
        clearTimeout(this.timeout);=0A=
        this.timeout =3D null;=0A=
      }=0A=
    },=0A=
=0A=
    applyLifetime: function (aLifetime) {=0A=
      if (aLifetime) {=0A=
        this.clearLifetime();=0A=
        this.timeout =3D this.close.bind(this).delay(aLifetime);=0A=
      }=0A=
      if (this.blocking) {=0A=
        info_handler.update(+1);=0A=
      }=0A=
    },=0A=
=0A=
    close: function (timed) {=0A=
      if (this.blocking) {=0A=
        info_handler.update(-1);=0A=
      }=0A=
      this.clearLifetime();=0A=
      this.element.remove();=0A=
      if (info_handler.empty()) {=0A=
        info_handler.remove();=0A=
      }=0A=
    }=0A=
  };=0A=
  wrapper.applyLifetime(aLifetime);=0A=
=0A=
  return {close: wrapper.close.bind(wrapper)};=0A=
};=0A=
=0A=
class$._addLock =3D function (theWindow) {=0A=
  with (theWindow || this.window_) {=0A=
    var lock =3D eval('new Element("div")');=0A=
    lock.addClassName("hw_framework_interfacelock");=0A=
    lock.addClassName("I" + Math.ceil(Math.random() * 10));=0A=
    lock.observe("click", (function (event) {=0A=
          event.stop();=0A=
        }).bindAsEventListener(this));=0A=
    $(document.body).appendChild(lock);=0A=
    =0A=
    return {unlock: function () { lock.remove(); },=0A=
            element: lock};=0A=
  }=0A=
};=0A=
=0A=
class$.addDisplayLayer =3D function (theCssClass) {=0A=
  this.hideHideLayers();=0A=
  var div_elem =3D new Element('div');=0A=
  div_elem.addClassName(theCssClass || "hw_framework_clicklayer");=0A=
  $(document.body).appendChild(div_elem);=0A=
=0A=
  return {=0A=
    remove: (function () {=0A=
        div_elem.remove();=0A=
        this.showHideLayers();=0A=
      }).bind(this),=0A=
    element: div_elem,=0A=
    addEventListener:=0A=
      function (theEvent, theListener) {=0A=
        div_elem.observe(theEvent, theListener);=0A=
      }=0A=
  };=0A=
};=0A=
=0A=
class$.lockByWindow =3D function (aWindow) {=0A=
  var unlock_function =3D (function () {=0A=
      Event.stopObserving(this.window_, "beforeunload", close_function);=0A=
      this.window_.clearInterval(interval);=0A=
      lock.unlock();=0A=
    }).bind(this);=0A=
=0A=
  var check_function =3D (function () {=0A=
      if (aWindow.closed) {=0A=
        unlock_function();=0A=
      }=0A=
    }).bind(this);=0A=
=0A=
  var close_function =3D (function () {=0A=
      if (!aWindow.closed) {=0A=
        aWindow.close();=0A=
        unlock_function();=0A=
      }=0A=
    }).bind(this);=0A=
=0A=
  var lock =3D this._addLock();=0A=
  lock.element.addClassName("disabled");=0A=
  var interval =3D this.window_.setInterval(check_function, 250);=0A=
  Event.observe(this.window_, "beforeunload", close_function);=0A=
};=0A=
=0A=
class$.lock =3D function (useProgress, theWindow) {=0A=
  if (this.isLocked_) {=0A=
    this.lockQueue_.push([useProgress, theWindow]);=0A=
    return;=0A=
    //throw "Interface already locked";=0A=
  }=0A=
  this.isLocked_ =3D true;=0A=
  this.lockElement_ =3D this._addLock();=0A=
  if (theWindow) {=0A=
    this.lockElement2_ =3D this._addLock(theWindow);=0A=
  }=0A=
=0A=
  if (useProgress =3D=3D=3D false) {=0A=
    return;=0A=
  }=0A=
=0A=
  var f_ =3D (function () {=0A=
      var res =3D new com.hyperwave.res.Resource({templateKey_: =
"interface_lock"});=0A=
      res.makeRoot();=0A=
      =
res.readAll(com.hyperwave.framework.Framework.static_.getHtmlRes());=0A=
      =
res.readAll(com.hyperwave.framework.Framework.static_.getLangRes());=0A=
      res.setRes("message", "");=0A=
      if (this.lockElement_) {=0A=
        this.lockElement_.element.innerHTML =3D res.toString();=0A=
      }=0A=
      if (this.lockElement2_) {=0A=
        this.lockElement2_.element.innerHTML =3D res.toString();=0A=
      }=0A=
  }).bind(this);=0A=
  if (com.hyperwave.framework.DisplayManager.static_.LOCK_DELAY_) {=0A=
    f_.delay(com.hyperwave.framework.DisplayManager.static_.LOCK_DELAY_);=0A=
  }=0A=
  else {=0A=
    f_();=0A=
  }=0A=
};=0A=
=0A=
class$.unlock =3D function () {=0A=
  if (!this.isLocked_) {=0A=
    throw "Interface not locked";=0A=
  }=0A=
  this.isLocked_ =3D false;=0A=
  this.lockElement_.unlock();=0A=
  this.lockElement_ =3D null;=0A=
  if (this.lockElement2_) {=0A=
    this.lockElement2_.unlock();=0A=
    this.lockElement2_ =3D null;=0A=
  }=0A=
=0A=
  if (this.lockQueue_.length) {=0A=
    this.lock.apply(this, this.lockQueue_.shift());=0A=
  }=0A=
};=0A=
=0A=
class$.static_._getIframesOfWindow =3D function (aWindow) {=0A=
  var func_ =3D arguments.callee;=0A=
  var iframes =3D [];=0A=
  if (!aWindow.$$) {=0A=
    return iframes;=0A=
  }=0A=
  iframes.push(aWindow);=0A=
  with (aWindow) {=0A=
    $$("iframe").each(function (anIframe) {=0A=
        iframes =3D iframes.concat(func_(anIframe.contentWindow));=0A=
      });=0A=
  }=0A=
  return iframes;=0A=
};=0A=
=0A=
/**=0A=
 * This function calculate the cumulative offset of a given=0A=
 * element over all iframea up to the top. This is necessary=0A=
 * to find the absolute position of an element in a subframe=0A=
 * and to place an inline dialog correctly.=0A=
 * Note: prototype must be included over the frame structure - in every=0A=
 *       containing iframe.=0A=
 *=0A=
 * @param anElement: Element: the element to find the position=0A=
 * @return: number[]: [x, y] the offsets=0A=
 */=0A=
class$.static_.getElementOffset =3D function (anElement) {=0A=
  var ret =3D [0, 0];=0A=
=0A=
  var _document =3D anElement.ownerDocument;=0A=
  var _window =3D _document.defaultView /* FF */ || =
_document.parentWindow /* IE */;=0A=
=0A=
  var offset =3D _window.$(anElement).cumulativeOffset();=0A=
  var scroll_offset =3D _window.$(anElement).cumulativeScrollOffset();=0A=
  ret[0] +=3D offset[0] - scroll_offset[0];=0A=
  ret[1] +=3D offset[1] - scroll_offset[1];=0A=
  =0A=
  if (_window.frameElement) {=0A=
    offset =3D arguments.callee.call(null, _window.frameElement);=0A=
    ret[0] +=3D offset[0];=0A=
    ret[1] +=3D offset[1];=0A=
  }=0A=
=0A=
  return ret;=0A=
};=0A=
=0A=
class$._calculateDialogPosition =3D function (thePositionInfo, =
theDialogDimensions, theWindowBody) {=0A=
  var elem =3D thePositionInfo.element;=0A=
  var elem_offset =3D this.static_.getElementOffset(elem);=0A=
  var elem_dimensions =3D elem.getDimensions();=0A=
  var dialog_dimensions =3D {width: theDialogDimensions.x, height: =
theDialogDimensions.y};=0A=
=0A=
  var posx =3D elem_offset[0];=0A=
  if (thePositionInfo.offsetx =3D=3D=3D =
this.static_.DIALOG_OFFSETX_RIGHT) {=0A=
    posx +=3D elem_dimensions.width;=0A=
  }=0A=
=0A=
  var posy =3D elem_offset[1];=0A=
  if (thePositionInfo.offsety =3D=3D=3D =
this.static_.DIALOG_OFFSETY_BOTTOM) {=0A=
    posy +=3D elem_dimensions.height;=0A=
  }=0A=
  if (thePositionInfo.orientation =3D=3D=3D =
this.static_.DIALOG_ORIENTATION_UP) {=0A=
    posy -=3D dialog_dimensions.height;=0A=
  }=0A=
=0A=
  var body_dimensions =3D Element.getDimensions(theWindowBody || =
document.body);=0A=
  =0A=
  // make sure the dialog does not move too far right/below=0A=
  posx =3D Math.min(posx, body_dimensions.width - =
dialog_dimensions.width);=0A=
  posy =3D Math.min(posy, body_dimensions.height - =
dialog_dimensions.height);=0A=
=0A=
  // make sure the position is positive=0A=
  posx =3D Math.max(posx, 0);=0A=
  posy =3D Math.max(posy, 0);=0A=
  =0A=
  return [posx, posy];=0A=
};=0A=
=0A=
class$.addHideLayer =3D function (theElement) {=0A=
  this.hideLayers_.push(theElement);=0A=
};=0A=
=0A=
class$.remHideLayer =3D function (theElement) {=0A=
  var pos;=0A=
  while ((pos =3D this.hideLayers_.indexOf(theElement)) > -1) {=0A=
    this.hideLayers_.splice(pos, 1);=0A=
  }=0A=
};=0A=
=0A=
class$.hideHideLayers =3D function () {=0A=
  this.hideLayers_.each(function (anEntry) {=0A=
      anEntry.setStyle({visibility:"hidden"});=0A=
    });=0A=
};=0A=
=0A=
class$.showHideLayers =3D function () {=0A=
  this.hideLayers_.each(function (anEntry) {=0A=
      anEntry.setStyle({visibility:"visible"});=0A=
    });=0A=
};=0A=
=0A=
/**=0A=
 * This method calculates the padding dimensions of an element.=0A=
 * The values will be returned in pixel.=0A=
 * e.g. <code>.getPaddingDimensions($(document.body)); // {x: 10, y: =
0}</code>=0A=
 *=0A=
 * @param theElement: Element: a prototype element=0A=
 * @return: object: the padding values in pixel=0A=
 * @return: object.x: the horizontal value=0A=
 * @return: object.y: the vertical value=0A=
 */=0A=
class$.getPaddingDimensions =3D function (theElement) {=0A=
=0A=
  function convert(style) {=0A=
    if (style) {=0A=
      var match =3D style.match(/^(\d+)px$/);=0A=
      if (match) {=0A=
        return match[1] - 0;=0A=
      }=0A=
    }=0A=
    return 0;=0A=
  }=0A=
=0A=
  return {x: convert(theElement.getStyle("padding-left")) + =
convert(theElement.getStyle("padding-right")),=0A=
          y: convert(theElement.getStyle("padding-top")) + =
convert(theElement.getStyle("padding-bottom"))};=0A=
};=0A=
=0A=
/**=0A=
 * This method calculates and applies the dynamic size of an element.=0A=
 * The element height will be the container height (without padding)=0A=
 * less the height of all given siblings.=0A=
 *=0A=
 * <pre>=0A=
 * +------------------------------------------+=0A=
 * |container - height: 100%                  |=0A=
 * | +--------------------------------------+ |=0A=
 * | |sibling1 - height: 100px              | |=0A=
 * | +--------------------------------------+ |=0A=
 * |                                          |=0A=
 * | +--------------------------------------+ |=0A=
 * | |sibling2 - height: 100px              | |=0A=
 * | +--------------------------------------+ |=0A=
 * |                                          |=0A=
 * | +--------------------------------------+ |=0A=
 * | |element - height: 100%-100px-100px    | |=0A=
 * | |(height must be calculated and cannot | |=0A=
 * | | be specified by css values)          | |=0A=
 * | +--------------------------------------+ |=0A=
 * |                                          |=0A=
 * +------------------------------------------+=0A=
 * </pre>=0A=
 * =0A=
 * @param theElement: Element: a prototype element=0A=
 * @param theContainer: Element|void: the parent element=0A=
 * @parent theSiblings: Element[]|void: the array of siblings=0A=
 */=0A=
class$.fitElementHeight =3D function (theElement, theContainer, =
theSiblings) {=0A=
=0A=
  var theContainer =3D theContainer || theElement.up();=0A=
=0A=
  var height =3D theContainer.getHeight() - =
this.getPaddingDimensions(theContainer).y;=0A=
=0A=
  (theSiblings || []).each(function (aSibling) {=0A=
      if (aSibling !=3D=3D theElement) {=0A=
        height -=3D aSibling.getHeight();=0A=
      }=0A=
    });=0A=
=0A=
  height =3D Math.max(0, height);=0A=
=0A=
  theElement.setStyle({height: height + "px"});=0A=
=0A=
  var diff_height =3D theElement.getHeight() - height;=0A=
  if (diff_height > 0) {=0A=
    height -=3D diff_height;=0A=
    height =3D Math.max(0, height);=0A=
    theElement.setStyle({height: height + "px"});=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * The same as <code>fitElementHeight</code> but fits the width.=0A=
 *=0A=
 * @param theElement: Element: a prototype element=0A=
 * @param theContainer: Element|void: the parent element=0A=
 * @parent theSiblings: Element[]|void: the array of siblings=0A=
 */=0A=
class$.fitElementWidth =3D function(theElement, theContainer, =
theSiblings) {=0A=
=0A=
  var theContainer =3D theContainer || theElement.up();=0A=
=0A=
  var width =3D theContainer.getWidth() - =
this.getPaddingDimensions(theContainer).x;=0A=
=0A=
  (theSiblings || []).each(function (aSibling) {=0A=
      if (aSibling !=3D=3D theElement) {=0A=
        width -=3D aSibling.getWidth();=0A=
      }=0A=
    });=0A=
=0A=
  width =3D Math.max(0, width);=0A=
=0A=
  theElement.setStyle({width: width + "px"});=0A=
=0A=
  var diff_width =3D theElement.getWidth() - width;=0A=
  if (diff_width > 0) {=0A=
    width -=3D diff_width;=0A=
    width =3D Math.max(0, width);=0A=
    theElement.setStyle({width: width + "px"});=0A=
  }=0A=
};=0A=
=0A=
/**=0A=
 * The method checks whether the given window is a dialog in a separate =
window.=0A=
 * =0A=
 * @param theWindow: window: the current window=0A=
 * @return boolean: returns <code>true</code> if the current window is a =
dialog window,=0A=
 *   otherwise <code>false</code>=0A=
 */=0A=
class$.isWindowDialog =3D function (theWindow) {=0A=
  return (this.window_ =3D=3D=3D theWindow.top.window);=0A=
};=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/framework/BaseMediator.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        BaseMediator.js=0A=
 *  Created:     2009-02-05 by sweber=0A=
 *  Description: xxx=0A=
 *=0A=
 *  $Id: BaseMediator.js 161412 2011-02-10 13:31:21Z bmarsch $=0A=
 *  $Revision: 161412 $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage("com.hyperwave.framework");=0A=
// <JSClass name=3D"com.hyperwave.framework.BaseMediator">=0A=
=0A=
/**=0A=
 * Constructor=0A=
 */=0A=
com.hyperwave.framework.BaseMediator =3D function (theWindow)=0A=
{=0A=
  if (theWindow =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
=0A=
  function checkCaller(aFunc) {=0A=
    if (aFunc =3D=3D=3D =
com.hyperwave.framework.BaseMediator.static_.getInstance) {=0A=
      return true;=0A=
    }=0A=
    else if (aFunc) {=0A=
      return checkCaller(aFunc.caller);=0A=
    }=0A=
    else {=0A=
      return false;=0A=
    }=0A=
  }=0A=
=0A=
  if (!checkCaller(arguments.callee)) {=0A=
    var msg =3D "Illegal constructor call. Use =
<classname>.static_.getInstance().";=0A=
    if (arguments.callee.caller) {=0A=
      var match =3D arguments.callee.caller.toString().match(/function =
([\w\$]*)/);=0A=
      if (match) {=0A=
        if (match[1]) {=0A=
          msg +=3D "\nClass name: " + match[1];=0A=
        }=0A=
        else {=0A=
          msg +=3D "\nCaller: " + arguments.callee.caller;=0A=
        }=0A=
      }=0A=
    }=0A=
    alert(msg);=0A=
    throw msg;=0A=
  }=0A=
=0A=
  this.window_ =3D theWindow || window;=0A=
  this.boundOnLoadHandler_ =3D this._onload.bindAsEventListener(this);=0A=
  Event.observe(this.window_, "load", this.boundOnLoadHandler_);=0A=
  this.boundOnUnloadHandler_ =3D =
this._onunload.bindAsEventListener(this);=0A=
  Event.observe(this.window_, "unload", this.boundOnUnloadHandler_);=0A=
  this.boundOnResizeHandler_ =3D =
this._onresize.bindAsEventListener(this);=0A=
  Event.observe(this.window_, "resize", this.boundOnResizeHandler_);=0A=
};=0A=
=0A=
// Inheritance call for JavaScript.=0A=
class$ =3D doInherit (com.hyperwave.framework.BaseMediator);=0A=
=0A=
class$.static_.CONTINUE =3D true;=0A=
class$.static_.STOP =3D false;=0A=
=0A=
class$.static_.LANGRES_PATH_ =3D "";=0A=
class$.static_.HTMLRES_PATH_ =3D "";=0A=
=0A=
class$.static_.LANGRES_CACHE_ =3D {};=0A=
class$.static_.HTMLRES_CACHE_ =3D {};=0A=
=0A=
class$.static_.getInstance =3D function () {=0A=
  if (this.class_ =3D=3D com.hyperwave.framework.BaseMediator) {=0A=
    throw "Illegal call. The com.hyperwave.framework.BaseMediator cannot =
be instantiated.";=0A=
  }=0A=
  return this.singleton_ || (this.singleton_ =3D new this.class_());=0A=
};=0A=
=0A=
class$.onActionDone =3D function (result, data, theWindow) {=0A=
  return com.hyperwave.framework.BaseMediator.static_.CONTINUE;=0A=
};=0A=
=0A=
class$.onActionError =3D function (result, data, theWindow) {=0A=
  return com.hyperwave.framework.BaseMediator.static_.CONTINUE;=0A=
};=0A=
=0A=
class$._onload =3D function () {=0A=
  if (this.getFramework()) {=0A=
    this.getFramework().addPageMediator(this);=0A=
  }=0A=
  this.onload();=0A=
};=0A=
=0A=
class$._onunload =3D function () {=0A=
  this.onunload();=0A=
  =0A=
  Event.stopObserving(this.window_, "load", this.boundOnLoadHandler_);=0A=
  Event.stopObserving(this.window_, "unload", =
this.boundOnUnloadHandler_);=0A=
  Event.stopObserving(this.window_, "resize", =
this.boundOnResizeHandler_);=0A=
  =0A=
  if (this.getFramework()) {=0A=
    this.getFramework().removePageMediator(this);=0A=
  }=0A=
};=0A=
=0A=
class$._onresize =3D function () {=0A=
  this.onresize();=0A=
};=0A=
=0A=
class$.onload =3D function () {=0A=
};=0A=
=0A=
class$.onunload =3D function () {=0A=
};=0A=
=0A=
class$.onresize =3D function () {=0A=
};=0A=
=0A=
class$.getFramework =3D function () {=0A=
  return hw.getFramework();=0A=
};=0A=
=0A=
class$.static_.getHTMLRes =3D function (aPath) {=0A=
  var path =3D aPath || this.HTMLRES_PATH_;=0A=
  if (!this.HTMLRES_CACHE_[path]) {=0A=
    this.HTMLRES_CACHE_[path] =3D =
com.hyperwave.util.IncludeManager.static_.getResource(path);=0A=
  }=0A=
  return this.HTMLRES_CACHE_[path];=0A=
};=0A=
=0A=
class$.static_.getLangRes =3D function (aPath) {=0A=
  var path =3D aPath || this.LANGRES_PATH_;=0A=
  if (!this.LANGRES_CACHE_[path]) {=0A=
    this.LANGRES_CACHE_[path] =3D =
com.hyperwave.util.IncludeManager.static_.getResource(path);=0A=
  }=0A=
  return this.LANGRES_CACHE_[path];=0A=
};=0A=
=0A=
class$.static_.getLangText =3D function (anId, aPath) {=0A=
  var res =3D this.getLangRes(aPath);=0A=
  if (res) {=0A=
    var txt =3D res.getRes(anId);=0A=
    if (txt) {=0A=
      return txt;=0A=
    }=0A=
  }=0A=
  return "??(" + anId+ ")";=0A=
};=0A=
=0A=
/**=0A=
 * This function create a new default resource by a given name. So you =
do not need=0A=
 * to write the code below every time if you want to get a resource from =
you UI class=0A=
 * htmlres and langres files. (similar as hw_getResource in hwlib.js)=0A=
 *=0A=
 * @param resName: string: the resource name=0A=
 * @return: com.hyperwave.res.Resource: the related resource=0A=
 */=0A=
class$.static_.getResource =3D function(resName) {=0A=
  var resource =3D new com.hyperwave.res.Resource({templateKey_: =
resName});=0A=
  resource.makeRoot();=0A=
  resource.readAll(this.getLangRes());=0A=
  resource.readAll(this.getHTMLRes());=0A=
  return resource;=0A=
}=0A=
=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/util/Clipboard.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2011=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        Clipboard.js=0A=
 *  Created:     2011-02-21 by sweber=0A=
 *=0A=
 *  $Id:$=0A=
 * </file>=0A=
 */=0A=
initPackage("com.hyperwave.util");=0A=
=0A=
// <JSClass Name=3D"com.hyperwave.util.Clipboard">=0A=
=0A=
/**=0A=
 * The Clipboard constructor.=0A=
 *=0A=
 */=0A=
com.hyperwave.util.Clipboard =3D function ()=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__")=0A=
    return;=0A=
    =0A=
  this.items_ =3D [];=0A=
=0A=
};=0A=
class$ =3D doInherit(com.hyperwave.util.Clipboard);=0A=
=0A=
class$.static_.CLIPBOARD_SIZE =3D 10;=0A=
=0A=
class$.static_.ITEM_TYPES =3D {=0A=
  XML:       "xml",=0A=
  HTML:      "html",=0A=
  TEXT:      "text",=0A=
  GOID:      "goid"=0A=
}=0A=
=0A=
class$.clear =3D function() {=0A=
	this.items_ =3D [];=0A=
}=0A=
=0A=
class$.addItem =3D function(params) {=0A=
	var item =3D {};=0A=
	/*=0A=
   * The type of data (string, xml, goid)=0A=
   */=0A=
  item.type =3D params.type || null;=0A=
  =0A=
  /*=0A=
   * The value=0A=
   */=0A=
  item.value =3D params.value || null;=0A=
  =0A=
  /*=0A=
   * The context where the item was copied from=0A=
   * e.g. "WCM"=0A=
   */=0A=
  item.context =3D params.context || null;=0A=
  =0A=
  /*=0A=
   * Some context specific data=0A=
   * e.g.=0A=
   *    this.context_ "WCM_Snippet";=0A=
   *    this.contextData_ =3D {type: "linklist"}=0A=
   *    =0A=
   *    Needs to be "cloned" because of IE's reference problems.=0A=
   *    Don't use nested object here!=0A=
   */  =0A=
  item.contextData =3D {};=0A=
  if(params.contextData) {=0A=
	  for(var key in  params.contextData) {=0A=
	  	item.contextData[key] =3D params.contextData[key];=0A=
	  }=0A=
  }=0A=
  =0A=
  this.items_.unshift(item);=0A=
  while(this.items_.length > this.static_.CLIPBOARD_SIZE) {=0A=
    this.items_.pop();=0A=
  }=0A=
};=0A=
=0A=
class$.getLastItem =3D function(context) {=0A=
  return this.getItems(context, 1)[0] || null;=0A=
};=0A=
=0A=
class$.getItems =3D function(context, quantity) {=0A=
	var re =3D [];=0A=
	for (var i=3D0; i<this.items_.length; i++) {=0A=
		if(context && this.items_[i].context !=3D context) {=0A=
			continue;=0A=
		}=0A=
		re.push(this.items_[i]);=0A=
		if(quantity && re.length >=3D quantity) {=0A=
			break;=0A=
		}=0A=
	}=0A=
	return re;=0A=
};=0A=
=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/BaseDialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Dialog.js
 *  Created:     2009-04-14 by rhoff
 *  Description: The client side part for inline dialogs.
 *
 *  $Id: BaseDialog.js 159944 2010-11-25 15:45:26Z jschipf $
 *  $Revision: 159944 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.BaseDialog">

/**
 * Constructor
 */
com.hyperwave.dialogs.BaseDialog =3D function BaseDialog() {
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  this.resKey_ =3D "BaseDialog";
  this.htmlReader_ =3D this.static_.getHtmlRes();
  this.langReader_ =3D this.static_.getLangRes();
  this.caption_ =3D null;
  this.value_ =3D null;
  this.data_ =3D [];
  this.content_ =3D null;
  this.buttons_ =3D [];
  this.defaultButtonValue_ =3D null;
  this.dimensions_ =3D {x: null, y: null};
  this.references_ =3D {};
  this.form_ =3D null;

  if (!com.hyperwave.dialogs.BaseDialog.static_.unique_) {
    com.hyperwave.dialogs.BaseDialog.static_.unique_ =3D new =
Date().getTime();
  }
  this.id_ =3D 'dialog_' + (++ =
com.hyperwave.dialogs.BaseDialog.static_.unique_);

  this.headerclass_ =3D"dialog";
};

// Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.BaseDialog);

// the following code loads the necessary resources from the server side
if (typeof document !=3D "undefined") {
  (function (path, func) {
    var language =3D document.cookie.match(/LANGUAGE=3D(\w{2})/);
    var url =3D '/hw_temporary_objects' +
      ';internal&action=3Dresreader.action' +
      '?file=3Dlib/clientlib/com/hyperwave/dialogs/' + path +
      '&func=3Dcom.hyperwave.dialogs.BaseDialog.static_.' + func +
      '&lang=3D' + (language ? language[1] : '--');

    document.writeln('<script type=3D"text/javascript" src=3D"' + url + =
'"></script>');
    return arguments.callee; // by return myself, the function can be =
executed twice with different parameters
  })("htmlres/Dialog.xml", "getHtmlRes")("langres/Dialog.%lang%.xml", =
"getLangRes");
}

class$.static_.EVENTS =3D {CLOSE: {toString: function () { return =
"CLOSE"; }},
                         BUTTON_CLICK: {toString: function () { return =
"BUTTON_CLICK"; }}};

class$.static_.MAX_X =3D {toString: function () { return "MAX_X"; }};
class$.static_.MAX_Y =3D {toString: function () { return "MAX_Y"; }};

/**
 * This method returns the unique dialog id.
 *
 * @return: string: the id
 */
class$.getId =3D function() {
  return this.id_;
};

class$._getForm =3D function () {
  return this.form_;
};

class$._setForm =3D function (theForm) {
  this.form_ =3D theForm;
};

class$.setMaxDimensions =3D function () {
  this.setDimensions(this.static_.MAX_X, this.static_.MAX_Y);
};

/**
 * This is a <b>private</b> method to get specific listeners.
 *
 * @param theEvent: EVENTS[...]: the event type
 * @return: Function[]: the listener functions
 */
class$._getListeners =3D function (theEvent) {
  if (!this.listeners_) {
    this.listeners_ =3D {};
  }
  if (!this.listeners_[theEvent]) {
    this.listeners_[theEvent] =3D [];
  }
  return this.listeners_[theEvent];
};

/**
 * This method adds a new event listener.
 *
 * @param theEvent: EVENTS[...]: the event type
 * @param theListener: Function: the listener
 */
class$.addEventListener =3D function (theEvent, theListener) {
  this._getListeners(theEvent).push(theListener);
};

/**
 * This <b>protected</b> method fires the listeners for a
 * specific event.
 *
 * @param theEvent: EVENTS[...]: the event type
 */
class$._fireEvent =3D function (theEvent) {
  var func =3D function (aListener) {
    aListener.call(this);
  };
  this._getListeners(theEvent).each(func.bind(this));
};

/**
 * This method stores formular or custom data in the dialog.
 *
 * @param theKey: string: a data key
 * @param theValue: string: data
 */
class$.setData =3D function (theKey, theValue) {
  this.data_[theKey] =3D theValue;
};

/**
 * This method returns formular data of the dialog.
 *
 * @param theKey: string: a data key
 * @return: string: data
 */
class$.getData =3D function (theKey) {
  return this.data_[theKey] || null;
};

/**
 * This is a <b>protected</b> method to store the dialog value.
 * Normally this method will be called on button click.
 * Then the button value is used as dialog value.
 *
 * @param theValue: string: the new dialog value
 */
class$._setValue =3D function (theValue) {
  this.value_ =3D theValue;
};

/**
 * This method returns the dialog value. The dialog value
 * stores the value of the button that was click before.
 *
 * @return: string|null: the dialog value (null e.g. if no button was =
clicked)
 */
class$.getValue =3D function () {
  return this.value_;
};

/**
 * This method stores the dimensions of the dialog.
 *
 * @param dimX: int: the width of the dialog in px
 * @param dimY: int: the height of the dialog in px
 */
class$.setDimensions =3D function (dimX, dimY) {
  this.dimensions_.x =3D dimX;
  this.dimensions_.y =3D dimY;
};

class$._getDimensions =3D function () {
  return {x: this.dimensions_.x,
          y: this.dimensions_.y};
};

/**
 * This method store the caption/headline of the
 * dialog.
 *
 * @param theCaption: string: the caption
 */
class$.setCaption =3D function (theCaption) {
  this.caption_ =3D theCaption;
};

/**
 * This method stores the content of the dialog.
 * The content can be any <b>valid</b> (X)HTML string.
 *
 * @param theContent: string: the html content string.
 */
class$.setContent =3D function (theContent) {
  this.content_ =3D theContent;
};

/**
 * This method stores the buttons of a dialog.
 *
 * @see: Button.js
 * @param theButtons: Button[]: the buttons
 */
class$.setButtons =3D function (theButtons) {
  this.buttons_ =3D theButtons;
};

/**
 * <fixxxme author=3D"sweber" descr=3D"wrong comment">This is a =
<b>protected</b> method that the
 * Framework can access the buttons.</fixxxme>
 *
 * @return: Button[]: the buttons
 */
class$.getButtons =3D function () {
  return this.buttons_;
};

class$.setDefaultButtonByValue =3D function (theButtonValue) {
  this.defaultButtonValue_ =3D theButtonValue;
};

class$._getDefaultButton =3D function () {
  return this._getButtonByValue(this.defaultButtonValue_);
};

class$._getButtonByValue =3D function (theButtonValue) {
  for (var i =3D 0; i < this.buttons_.length; i ++) {
    var aButton =3D this.buttons_[i];
    if (aButton._getValue() =3D=3D theButtonValue) {
      return aButton;
    }
  }
  return null;
};

class$.getResource =3D function (theName, theValues) {
  var resource =3D new com.hyperwave.res.Resource({templateKey_: =
theName});
  resource.makeRoot();
  resource.readAll(this.static_.getLangRes());
  resource.readAll(this.static_.getHtmlRes());
  for (var i in theValues) {
    resource.setRes(i, theValues[i]);
  }

  return resource;
};

class$.getButton =3D function (theValue) {
  var caption =3D =
com.hyperwave.dialogs.BaseDialog.static_.getLangRes("label_" + =
theValue);
  return new com.hyperwave.dialogs.CloseButton(theValue, caption);
};

class$.beforeToString =3D function (resource) {
  return resource;
};

class$.afterToString =3D function (string) {
  return string;
};

class$.setReference =3D function (key, value) {
  if (!key.match(/^\w+$/)) {
    throw 'Illegal key "' + key + '" for =
BaseDialog.defineVariable(<key>, <value>)';
  }
  this.references_[key] =3D {value: value};
};

/**
 * This method generates an html string that is the dialog.
 *
 * @return: string: the dialog html string
 */
class$.toString =3D function () {
  var resource =3D this.getResource(this.resKey_);
  resource.setRes("caption", this.caption_ || '');

  var buttons =3D [];
  this.buttons_.each(function (aButton) {
      buttons.push({id: aButton.getId(),
                    caption: aButton.caption_,
                    type: aButton.type_});
    });

  resource.setRes("buttons", buttons);
  resource.setRes("buttons_length", buttons.length);

  resource.setRes("content", this.content_ || "");
  return this.afterToString(this.beforeToString(resource).toString());
};


//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/Dialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Dialog.js
 *  Created:     2009-04-17 by rhoff
 *  Description: The client side part for inline dialogs.
 *
 *  $Id: Dialog.js 159933 2010-11-25 10:27:53Z cgoess $
 *  $Revision: 159933 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.Dialog">

/**
 * Constructor
 */
com.hyperwave.dialogs.Dialog =3D function Dialog()
{
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }

  com.hyperwave.dialogs.BaseDialog.apply(this, arguments);

  this.messages_ =3D [];
  this.messageType_ =3D =
com.hyperwave.dialogs.Dialog.static_.MESSAGE_TYPES.INFO;
};

//--------------------------------------------------------------------
//Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.Dialog,
                    com.hyperwave.dialogs.BaseDialog);

class$.static_.MESSAGE_TYPES =3D {INFO    : {toString: function () { =
return "INFO"; }},
                                WARNING : {toString: function () { =
return "WARNING"; }},
                                ERROR   : {toString: function () { =
return "ERROR"; }}};


/**
 * This method sets the messages_ array.
 * Any previously existing messages will be overwritten.
 *
 * @param theMessages: array: string array of messages
 */
class$.setMessages =3D function (theMessages) {
  this.messages_ =3D theMessages;
};

/**
 * This method sets a message to the messages_ array.
 * Any previously existing messages will be overwritten.
 *
 * @param theMessage: string
 */
class$.setMessage =3D function (theMessage) {
  this.messages_ =3D [theMessage];
};

/**
 * This method gets the messagesType.
 *
 * @param string: the type of the message =
(com.hyperwave.dialogs.static_.MESSAGE_TYPES)
 */
class$.setMessageType =3D function (theMessageType) {
  this.messageType_ =3D theMessageType;
};

class$.beforeToString =3D function (resource) {
  var content =3D this.getResource("content_dialog", {messages: =
this.messages_,
                                                    messages_length: =
this.messages_.length,
                                                    content: =
this.content_});
  resource.setRes("dialog_type", this.messageType_);
  resource.setRes("content", content);
  return resource;
};

//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/IframeDialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        IframeDialog.js
 *  Created:     2009-04-15 by rhoff
 *  Description: The client side part for inline iframe dialogs.
 *
 *  $Id: IframeDialog.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.IframeDialog">

/**
 * Constructor
 */
com.hyperwave.dialogs.IframeDialog =3D function IframeDialog(theParams)
{
  if (theParams =3D=3D=3D "__proto__") {
    return;
  }
  com.hyperwave.dialogs.BaseDialog.apply(this, arguments);
};
class$ =3D doInherit(com.hyperwave.dialogs.IframeDialog,
                   com.hyperwave.dialogs.BaseDialog);

class$.static_.ID_URL_KEY =3D "__dialogId__";

class$.setUrl =3D function (theUrl) {
  var url =3D theUrl;
  url +=3D url.indexOf("?") =3D=3D -1 ? "?" : "&";
  url +=3D =
encodeURIComponent(com.hyperwave.dialogs.IframeDialog.static_.ID_URL_KEY)=
 + "=3D" + encodeURIComponent(this.getId());

  this.setContent('<iframe id=3D"IframeDialog_'+this.getId()+'" =
frameborder=3D"0" src=3D"' + url + '"></iframe>');
};

class$.static_.getDialogId =3D function (theUrl) {
  var web_params =3D new com.hyperwave.util.KeyValueMap();
  web_params.addUrlParameters(theUrl);
  var dialog_id =3D web_params.getOneValue(this.ID_URL_KEY);
  return dialog_id || null;
};

//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: 7bit
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/IframePopupDialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        IframeDialog.js
 *  Created:     2009-04-15 by rhoff
 *  Description: The client side part for inline iframe dialogs.
 *
 *  $Id: IframePopupDialog.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name="com.hyperwave.dialogs.IframePopupDialog">

/**
 * Constructor
 */
com.hyperwave.dialogs.IframePopupDialog = function IframePopupDialog()
{
  if (arguments[0] === "__proto__") {
    return;
  }
  com.hyperwave.dialogs.IframeDialog.apply(this, arguments);
};

// Inheritance call for JavaScript.
class$ = doInherit(com.hyperwave.dialogs.IframePopupDialog,
                   com.hyperwave.dialogs.IframeDialog);
//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/Prompt.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Prompt.js
 *  Created:     2009-04-30 by pbaldi
 *  Description: The client side part for Prompt inline dialogs.
 *
 *  $Id: Prompt.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.Prompt">

/**
 * Constructor
 */
com.hyperwave.dialogs.Prompt =3D function Prompt(theCaption, theText, =
theValue) {
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  com.hyperwave.dialogs.BaseDialog.apply(this);

  this.setButtons([
    this.getButton(this.static_.OK),=20
    this.getButton(this.static_.CANCEL)
  ]);
  this.setDefaultButtonByValue("ok");
  this.setCaption(theCaption || '');
  this.setContent(
    this.getResource("content_prompt", {content: theText || '',
                                        name: =
this.static_.PROMPT_INPUT_FIELD_NAME,
                                        value: theValue || ''})
  );
};

//Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.Prompt,
                    com.hyperwave.dialogs.BaseDialog);

class$.static_.PROMPT_INPUT_FIELD_NAME =3D "$input";

/*=20
 * The values of the ok and cancel buttons.
 */=20
class$.static_.OK =3D "ok";
class$.static_.CANCEL =3D "cancel";

/**
 * This method returns data of the prompt input field dialog.
 *
 * @return: string: data
 */
class$.getInput =3D function () {
  return this.getData(this.static_.PROMPT_INPUT_FIELD_NAME);
};

//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/Message.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Message.js
 *  Created:     2009-05-04 by pbaldi
 *  Description: The client side part for inline message dialogs.
 *
 *  $Id: Message.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.Message">

/**
 * Constructor
 */
com.hyperwave.dialogs.Message =3D function Message(theCaption, theText, =
theType)
{
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  com.hyperwave.dialogs.BaseDialog.apply(this);

  this.dimensions_.y =3D 100;
  switch (theType) {
    case com.hyperwave.dialogs.Message.static_.TYPES.INFO:
    case 0:
      this.type_ =3D com.hyperwave.dialogs.Message.static_.TYPES.INFO;
      break;
    case com.hyperwave.dialogs.Message.static_.TYPES.WARNING:
    case 1:
      this.type_ =3D =
com.hyperwave.dialogs.Message.static_.TYPES.WARNING;
      break;
    case com.hyperwave.dialogs.Message.static_.TYPES.ERROR:
    case 2:
      this.type_ =3D com.hyperwave.dialogs.Message.static_.TYPES.ERROR;
      break;
    default:
      this.type_ =3D com.hyperwave.dialogs.Message.static_.TYPES.INFO;
  }
  this.setButtons([this.getButton("ok")]);
  this.setDefaultButtonByValue("ok");
  this.setCaption(theCaption || this.langReader_.getRes("label_" + =
this.type_));
  if (typeof theText =3D=3D "string") {
    var messages =3D [theText];
  }
  else {
    var messages =3D theText || [];
  }
  this.setContent(this.getResource("content_message", {messages: =
messages}));
};

//Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.Message,
                    com.hyperwave.dialogs.BaseDialog);


class$.static_.TYPES =3D {INFO    : {toString: function () { return =
"INFO"; }},
                        WARNING : {toString: function () { return =
"WARNING"; }},
                        ERROR   : {toString: function () { return =
"ERROR"; }}};

class$.beforeToString =3D function (resource) {
  resource.setRes("dialog_type", this.type_);
  return resource;
};

//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/Confirm.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Confirm.js
 *  Created:     2009-04-30 by pbaldi
 *  Description: The client side part for Confirm inline dialogs.
 *
 *  $Id: Confirm.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.Confirm">

/**
 * Constructor
 */
com.hyperwave.dialogs.Confirm =3D function Confirm(theCaption, theText)
{
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  com.hyperwave.dialogs.BaseDialog.apply(this);

  this.setButtons([this.getButton("yes"), this.getButton("no")]);
  this.setDefaultButtonByValue("yes");
  this.setCaption(theCaption || '');
  this.setContent(this.getResource("content_confirm", {content: theText =
|| ''}));
};

//--------------------------------------------------------------------
//Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.Confirm,
                    com.hyperwave.dialogs.BaseDialog);

/**
 * This method assigns a new caption to a button defined by it's value.
 *
 * @param theButtonValue: string: value of the button you want to change
 * @param theNewCaption: string: the new caption to be assigned to the =
button
 */
class$.setButtonCaption =3D function (theButtonValue, theNewCaption) {
  var button =3D this._getButtonByValue(theButtonValue);
  if(button !=3D=3D null) {
    button._setCaption(theNewCaption);
  }
};

/**
 * This method returns true if the user has confirmed the dialog, else =
false.
 *
 * @return: bool:
 */
class$.isConfirmed =3D function () {
  return this.getValue() =3D=3D "yes";
};

//</JSClass>
//-----------------------------------------------------------

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/UserChooserDialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        UserChooserDialog.js
 *  Created:     2009-05-28 by pbaldi
 *  Description: Displays a inline User chooser dialog.
 *
 *  $Id: UserChooserDialog.js 160588 2011-01-03 08:44:34Z sweber $
 *  $Revision: 160588 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.UserChooserDialog">

/**
 * Constructor
 */
com.hyperwave.dialogs.UserChooserDialog =3D function =
UserChooserDialog(theParams)
{
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }

  com.hyperwave.dialogs.Dialog.apply(this);

  this.setReference("dialog", this);

  this.selectionModel_ =3D null;
  this.description_ =3D "";
  this.multipleselection_ =3D true;
  this.allowUsers_ =3D 1;
  this.allowGroups_ =3D 1;
  this.allowRoles_ =3D 1;
 =20
  var cancel_button =3D this.getButton("cancel");
  =
cancel_button.setType(com.hyperwave.dialogs.Button.static_.TYPES.SECONDAR=
Y);
 =20
  var ok_button =3D new com.hyperwave.dialogs.Button("ok", "Ok");
  =
ok_button.addEventListener(com.hyperwave.dialogs.Button.static_.EVENTS.CL=
ICK,
      this.onOkClicked.bind(this));
  this.setButtons([ok_button,  cancel_button]);
//  this.setDefaultButtonByValue("ok");
};

//--------------------------------------------------------------------
//Inheritance call for JavaScript.
class$ =3D doInherit (com.hyperwave.dialogs.UserChooserDialog,
                    com.hyperwave.dialogs.Dialog);

class$.setDescription =3D function(theDescription) {
  this.description_ =3D theDescription;
};

class$.setMultipleSelection =3D function(isMultiple) {
  this.multipleselection_ =3D isMultiple;
};

class$.setAllowUser =3D function(doAllowUser) {
  if (doAllowUser)
  {
    this.alloUsers_ =3D 1;
  }
  else
  {
    this.allowUsers_ =3D 0;
  }
};

class$.setAllowGroups =3D function(doAllowGroups) {
  if (doAllowGroups)
  {
    this.allowGroups_ =3D 1;
  }
  else
  {
    this.allowGroups_ =3D 0;
  }
};

class$.setAllowRoles =3D function(doAllowRoles) {
  if (doAllowRoles)
  {
    this.allowRoles_ =3D 1;
  }
  else
  {
    this.allowRoles_ =3D 0;
  }
};

class$.getDescription =3D function() {
  return this.description_;
};

class$.beforeToString =3D function (resource) {
  this.setContent(this.getResource("content_user_chooser",
      {description: this.getDescription(),
       allow_users:this.allowUsers_,
       allow_groups:this.allowGroups_,
       allow_roles:this.allowRoles_,
       =
options_count:this.allowRoles_+this.allowGroups_+this.allowUsers_,
       =
cssFile:com.hyperwave.util.IncludeManager.static_.getInstance().getSrc("l=
ib/clientlib/com/hyperwave/css/UserChooserDialog.css")
    }));

  var content =3D this.getResource("content_dialog", {messages: =
this.messages_,
                                                    messages_length: =
this.messages_.length,
                                                    content: =
this.content_});
  resource.setRes("dialog_type", this.messageType_);
  var msg =3D =
com.hyperwave.dialogs.BaseDialog.static_.getLangRes("UserChooserOutOfOffi=
ceUsers");
  resource.setRes("UserChooserOutOfOfficeUsers",msg);
  resource.setRes("content", content);
  return resource;
};


class$.onOkClicked =3D function () {
  if (!this.selectionModel_ || this.multipleselection_ && =
this.selectionModel_.getSelection().length =3D=3D 0 ||
      !this.multipleselection_ && =
this.selectionModel_.getSelection().length !=3D 1)
  {
    var msg =3D =
com.hyperwave.dialogs.BaseDialog.static_.getLangRes("UserChooserSelectUse=
rFirst");

    $("user_dialog_error").update(msg);

  }
  else
  {
    Framework.static_.getInstance().closeDialog(this);
  }
}

/**
 * This method assigns a new caption to a button defined by it's value.
 *
 * @param theButtonValue: string: value of the button you want to change
 * @param theNewCaption: string: the new caption to be assigned to the =
button
 */
class$.setButtonCaption =3D function (theButtonValue, theNewCaption) {
  var button =3D this._getButtonByValue(theButtonValue);
  if(button !=3D=3D null) {
    button._setCaption(theNewCaption);
  }
};

/**
 * This method searches for the users which may be assigned
 */
class$.doUserSearch =3D function () {
  this.clearTheReassign();
  this.clearParticipantsList();
  var theSearchString =3D $('searchText').value;
  var fw =3D com.hyperwave.framework.Framework.static_.getInstance();
  fw.ajaxRequest({requestMethod: 'post',
                  method: "HW_WF_TaskUI.static_.searchUser",
                  baseurl: "/hw_temporary_objects",
                  requestParameters: {
                    theSearchString: theSearchString,
                    aUcheck: (this.allowUsers_ && $('Ucheck').checked) ? =
"CHECKED" : "",
                    aGcheck: (this.allowGroups_ && $('Gcheck').checked) =
? "CHECKED" : "",
                    aPcheck: (this.allowRoles_ && $('Pcheck').checked) ? =
"CHECKED" : "",
                    markOOOUsers: true
                  }
                 }, this, window);
};

class$.onSearchKeyPress =3D function(e) {
  var characterCode;

  if(e && e.which){
    characterCode =3D e.which;
  }
  else{
    characterCode =3D e.keyCode;
  }

  if(characterCode =3D=3D 13){
    this.doUserSearch();
    return false;
  }
  else{
    return true;
  }
};

/**
 * callback for ajaxRequest
 */
class$.onActionError =3D function (result, responseJSON, theWindow) {
};

/**
 * callback for ajaxRequest
 */
class$.onActionDone =3D function (result, responseJSON, theWindow) {
  var listing_items =3D this.getListingData(responseJSON.theUsers);
  if (this.selectionModel_)
  {
    this.selectionModel_.removeSelection();
  }
  this.displayListing(listing_items);
  this.initSelectionModel();
};

/**
 * This method orts the possible Participants by friendlyname
 *
 * @param listing_items: array, the items to sort
 */
class$.sortParticipants =3D function (listing_items) {
  listing_items.sort(function (a, b) {
                        if (a.ugp =3D=3D b.ugp) {
                          if (a.friendlyUserName < b.friendlyUserName) {
                             return -1;
                          }
                          if (a.friendlyUserName > b.friendlyUserName) {
                             return 1;
                          }
                        }
                        else {
                          if(a.ugp =3D=3D "g") {
                            return -1;
                          }
                          if(a.ugp =3D=3D "p") {
                            return 1;
                          }
                          if(b.ugp =3D=3D "g") {
                            return 1;
                          }
                          if(a.ugp =3D=3D "p") {
                            return -1;
                          }
                        }
                        return 0;
                    });
};


/**
 * This method retrieves the corresponding css-class for users, groups =
and roles
 *
 *  @param ugp: string, "u" for user, "g" for group, "p" for =
placeholder(role)
 *
 *  @return: string, the css-class-name
 */
class$.getListingCssClass =3D function (ugp) {
  switch(ugp) {
    case "u":
      return "user";
    case "g":
      return "group";
    case "p":
      return "role";
    default:
      return "";
  }
};

/**
 * This method prepares the retrieved users for listing
 */
class$.getListingData =3D function (theUsers) {

  if(!theUsers || theUsers.length =3D=3D=3D 0) {
    return;
  }

  var listing_items =3D [];
  for(var username in theUsers) {
    var friendlyUserName =3D theUsers[username].slice(2);
    var ugp =3D theUsers[username].slice(0, 1); // User/Group/Role
    listing_items.push({userName: username,
                        friendlyUserName: friendlyUserName,
                        cssClass: this.getListingCssClass(ugp),
                        ugp: ugp});

  }

  return listing_items;
};

/**
 * This method displays the listing
 */
class$.displayListing =3D function  (items) {
  var resource =3D this.getResource("listing_user_chooser", {});

  var item_info =3D [];
  for (var i=3D0; i<items.length; i++) {
    items[i].alternate_style =3D i%2 ? "alternate" : "";
    item_info.push(items[i]);
  }

  resource.setRes("items", item_info);
  resource.setRes("items_length", item_info.length);

  $("listing").innerHTML =3D resource.toString(true);
};

class$.initSelectionModel =3D function () {
  if(this.selectionModel_ =3D=3D=3D null) {
    var sel_mod =3D new com.hyperwave.ui.SelectionModel( $("listing"));
    sel_mod.allowMultipleSelections(this.multipleselection_);
    sel_mod.attachByCSS("hw_selectable", "hw_selection_enabled");
    sel_mod.attach({userAction: (function() {
                                  var new_participants =3D [];
                                  var selected_rows =3D =
sel_mod.getSelection();
                                  for(var i=3D0; i<selected_rows.length; =
i++) {
                                    var curr_participant =3D =
selected_rows[i].id.replace(/ListItemRow_/, "");
                                    =
new_participants.push(curr_participant);
                                  }
                                  this._getForm().theReassign.value =3D =
new_participants.join(",");
                                  if (this.multipleselection_ && =
selected_rows.length >=3D
                                      !this.multipleselection_ && =
selected_rows.length =3D=3D 1)
                                  {
                                    $("user_dialog_error").update("");
                                  }
                                }).bind(this)
                  });

    this.selectionModel_ =3D sel_mod;
   =20
  }
};

class$.clearParticipantsList =3D function () {
  $('listing').update("");
};

class$.clearTheReassign =3D function () {
  this._getForm().theReassign.value =3D "";
};

class$.showSearchOptions =3D function () {
  $("searchOptionsLink").hide();
  $("searchOptions").show();
};

//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: 7bit
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/PopupDialog.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        PopupDialog.js
 *  Created:     2010-06-01 by cgoess
 *  Description: The client side part for inline popup dialogs.
 *
 *  $Id: PopupDialog.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");

// <JSClass name="com.hyperwave.dialogs.PopupDialog">
/**
 * Constructor
 */
com.hyperwave.dialogs.PopupDialog = function PopupDialog (theEvent) {
  if (arguments[0] === "__proto__") {
    return;
  }

  com.hyperwave.dialogs.BaseDialog.apply(this, arguments);
  
  this.event_ = theEvent;
  this.caption_ = null;
  this.buttons_ = [];
};

//--------------------------------------------------------------------
//Inheritance call for JavaScript.
class$ = doInherit (com.hyperwave.dialogs.PopupDialog,
                    com.hyperwave.dialogs.BaseDialog);

/**
 * 
 */
class$.setCaption = function (theCaption) {
  throw "Setting caption for dialogs of type PopupDialog not supported.";
};

/**
 * 
 */
class$.setButtons = function (theButtons) {
  throw "Setting buttons for dialogs of type PopupDialog not supported.";
};
//</JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/Button.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        Button.js
 *  Created:     2009-04-14 by rhoff
 *  Description: The client side button for inline dialogs.
 *
 *  $Id: Button.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */
=20
/* <JSLINT> */
/*global Framework */
/* </JSLINT> */
=20

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.Button">

/**
 * Constructor
 */
com.hyperwave.dialogs.Button =3D function Button(theValue, theCaption) {
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }

  this.value_ =3D theValue;
  this.caption_ =3D typeof theCaption =3D=3D "undefined" ? theValue : =
theCaption;

  if (!com.hyperwave.dialogs.Button.static_.unique_) {
    com.hyperwave.dialogs.Button.static_.unique_ =3D new =
Date().getTime();
  }
  this.id_ =3D 'button_' + (++ =
com.hyperwave.dialogs.Button.static_.unique_);

  this.dialog_ =3D null;
  this.type_ =3D com.hyperwave.dialogs.Button.static_.TYPES.PRIMARY;

  // this is the default button listener to store the button value
  // to the dialog value when clicked -> will be executed as first =
listener
  =
this.addEventListener(com.hyperwave.dialogs.Button.static_.EVENTS.CLICK, =
function () {
      this.getDialog()._setValue(this.value_);
    });
};

class$ =3D doInherit(com.hyperwave.dialogs.Button);

class$.static_.TYPES =3D {PRIMARY: {toString: function () { return =
"PRIMARY"; }},
                        SECONDARY: {toString: function () { return =
"SECONDARY"; }}};

class$.static_.EVENTS =3D {CLICK: {toString: function () { return =
"CLICK"; }}};

class$.static_.CALLBACKS =3D {CLOSE: function () {
    Framework.static_.getInstance().closeDialog(this.getDialog());
  }};

class$.getId =3D function () {
  return this.id_;
};

class$._getValue =3D function () {
  return this.value_;
};

class$._setCaption =3D function (theCaption) {
  this.caption_ =3D typeof theCaption =3D=3D "undefined" ? this.value_ : =
theCaption;
};

class$._setDialog =3D function (theDialog) {
  this.dialog_ =3D theDialog;
};

class$.getDialog =3D function () {
  return this.dialog_;
};

class$.setType =3D function (theType) {
  this.type_ =3D theType;
};

class$._getListeners =3D function (theEvent) {
  if (!this.listeners_) {
    this.listeners_ =3D {};
  }
  if (!this.listeners_[theEvent]) {
    this.listeners_[theEvent] =3D [];
  }
  return this.listeners_[theEvent];
};

class$.addEventListener =3D function (theEvent, theListener) {
  this._getListeners(theEvent).push(theListener);
};

class$._fireEvent =3D function (theEvent) {
  var func =3D function (aListener) {
    aListener.call(this);
  };
  this._getListeners(theEvent).each(func.bind(this));
};

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/dialogs/CloseButton.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        CloseButton.js
 *  Created:     2009-04-14 by rhoff
 *  Description: The client side button for inline dialogs.
 *
 *  $Id: CloseButton.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

initPackage("com.hyperwave.dialogs");
// <JSClass name=3D"com.hyperwave.dialogs.CloseButton">

/**
 * Constructor is the constructor of a default close button.
 * This button does the same as the default button, but closes the =
dialog
 * always.
 */
com.hyperwave.dialogs.CloseButton =3D function CloseButton(theValue, =
theCaption) {
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  com.hyperwave.dialogs.Button.apply(this, arguments);
  =
this.addEventListener(com.hyperwave.dialogs.Button.static_.EVENTS.CLICK,
                        =
com.hyperwave.dialogs.Button.static_.CALLBACKS.CLOSE);
};

class$ =3D doInherit(com.hyperwave.dialogs.CloseButton,
                   com.hyperwave.dialogs.Button);

// </JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/util/Object.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        Object.js=0A=
 *  Created:     2010-04-29 by sweber=0A=
 *=0A=
 *  $Id:$=0A=
 * </file>=0A=
 */=0A=
initPackage("com.hyperwave.util");=0A=
=0A=
/**=0A=
 * This class contains some static helper methods to work=0A=
 * with javascript objects.=0A=
 *=0A=
 * @author sweber=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.util.Object">=0A=
=0A=
/**=0A=
 * The Object constructor.=0A=
 */=0A=
com.hyperwave.util.Object =3D function () {=0A=
  if (arguments[0] =3D=3D=3D "__proto__" )=0A=
    return;=0A=
};=0A=
class$ =3D doInherit(com.hyperwave.util.Object);=0A=
=0A=
/**=0A=
 * This method count the enumerable object properties.=0A=
 *=0A=
 * @param theObject: object: the object=0A=
 * @return: number: the properties count=0A=
 */=0A=
class$.static_.getLength =3D function (theObject) {=0A=
  var ctr =3D 0;=0A=
  for (var i in theObject) {=0A=
    ctr ++;=0A=
  }=0A=
  return ctr;=0A=
};=0A=
=0A=
/**=0A=
 * This method checks, whether the given object contains=0A=
 * any enumerable property.=0A=
 *=0A=
 * @param theObject: object: the object=0A=
 * @return: boolean: object has at least one property=0A=
 */=0A=
class$.static_.isEmpty =3D function (theObject) {=0A=
  for (var i in theObject) {=0A=
    return false;=0A=
  }=0A=
  return true;=0A=
};=0A=
=0A=
/**=0A=
 * The method either creates a new object with the same properties as =
the source=0A=
 * object OR copies the properties from the source object to the target =
object if=0A=
 * a target object is given (while overwriting existing target =
properties).=0A=
 * The properties will be copied by reference only, i.e. possible =
existing=0A=
 * sub-objects will not be copied but only referenced.=0A=
 * =0A=
 * @param theSourceObject: Object|void: the source object=0A=
 * @param theTargetObject: Object|void: the target object. if not =
defined a new object=0A=
 * is created.=0A=
 * @return Object: the copied object or a reference to theTargetObject=0A=
 */=0A=
class$.static_.copy =3D function (theSourceObject, theTargetObject) {=0A=
  var retobj =3D theTargetObject || {};=0A=
  for (var x in theSourceObject) {=0A=
    retobj[x] =3D theSourceObject[x];=0A=
  }=0A=
  return retobj;=0A=
};=0A=
=0A=
/**=0A=
 * The method removes all properties of the given object that have a =
value=0A=
 * that is of type "undefined". The input object will be duplicated.=0A=
 * =0A=
 * @param theObject: Object: the object of interest=0A=
 * @return Object: a reference to the original object without undefined =
values=0A=
 */=0A=
class$.static_.removeUndefined =3D function (theObject) {=0A=
  var res =3D {};=0A=
  for (var x in theObject) {=0A=
    if (typeof theObject[x] !=3D "undefined") {=0A=
      res[x] =3D theObject[x];=0A=
    }=0A=
  }=0A=
  return res;=0A=
};=0A=
=0A=
/**=0A=
 * This method removes all properties of an object with an empty value.=0A=
 * "Empty values" means the following values: void(0), undefined, NaN, =
null or "".=0A=
 *  The input object will be duplicated.=0A=
 *=0A=
 * @param theObject: Object: the object of interest=0A=
 * @return Object: the object without empty properties=0A=
 */=0A=
class$.static_.removeEmpty =3D function (theObject) {=0A=
  var res =3D {};=0A=
  for (var x in theObject) {=0A=
    if (theObject[x] || theObject[x] =3D=3D=3D 0 || theObject[x] =
=3D=3D=3D false) {=0A=
      res[x] =3D theObject[x];=0A=
    }=0A=
  }=0A=
  return res;=0A=
};=0A=
=0A=
/**=0A=
 * This method is a special version of toSource where the output is =
htmlsave=0A=
 * Especially the character < is replaced by its unicode version so that =
the=0A=
 * resulting source can be used in a html page in the value of a =
variable.=0A=
 * An example where this is usefull is, when the string "<script>" =
should be=0A=
 * used in a variable=0A=
 *=0A=
 * @param theObject: Object: the object of interest=0A=
 * @return string: the source of the object=0A=
 */=0A=
class$.static_.toSource =3D function (theObject)=0A=
{=0A=
  return theObject.toSource().replace(/</g, "\\x3c");=0A=
};=0A=
=0A=
/**=0A=
 * This method is a special version of toSource where the output is =
formatted=0A=
 * more readable.=0A=
 * NOTE: functions are only marked as function, but no source is shown=0A=
 *=0A=
 * @param theObject: Object: the object of interest=0A=
 * @param doIgnoreFunctions: boolean: set to true when functions should =
not even be marked as function=0A=
 * @return string: the source of the object=0A=
 */=0A=
class$.static_.toFormattedSource =3D function (theObject, =
doIgnoreFunctions, aLevel) {=0A=
  // redirect to special function if object type has one defined (e.g. =
HW_API_Object)=0A=
  if (theObject &&=0A=
      typeof theObject =3D=3D "object" &&=0A=
      typeof theObject.static_ =3D=3D "object" && =0A=
      typeof theObject.static_.toFormattedSource =3D=3D "function" &&=0A=
      this.toFormattedSource !=3D=3D =
theObject.static_.toFormattedSource) {=0A=
    return theObject.static_.toFormattedSource(theObject, =
doIgnoreFunctions, aLevel);=0A=
  }=0A=
  =0A=
  var arr =3D [];=0A=
  var level =3D aLevel || 0;=0A=
  =0A=
  // the padding given at the beginning of the line=0A=
  var level_padding =3D "";=0A=
  for (var i=3D0; i<level; i++) {=0A=
    level_padding +=3D "  ";=0A=
  }=0A=
  var bracket_padding =3D level_padding;=0A=
  level_padding +=3D "  ";=0A=
  =0A=
  var block_start =3D "{";=0A=
  var block_end =3D "}";=0A=
  if ( theObject instanceof Array) {=0A=
    var block_start =3D "[";=0A=
    var block_end =3D "]";=0A=
  }=0A=
  =0A=
  if (typeof theObject =3D=3D "object") {=0A=
    arr.push(bracket_padding + block_start);=0A=
    for (var item in theObject) {=0A=
      var value =3D theObject[item];=0A=
      if (typeof(value) =3D=3D 'object') {=0A=
        arr.push(level_padding + "'" + item + "'");=0A=
        arr.push(hw.util.Object.static_.toFormattedSource(value, =
doIgnoreFunctions, level+1));=0A=
      } =0A=
      else if (typeof value =3D=3D "function") {=0A=
        if (!doIgnoreFunctions) {=0A=
          arr.push(level_padding + "'" + item + "':\"function\"");=0A=
        }=0A=
      }=0A=
      else=0A=
      {=0A=
        arr.push(level_padding + "'" + item + "':\"" + value + "\"");=0A=
      }=0A=
    }=0A=
    arr.push(bracket_padding + block_end);=0A=
  }=0A=
  else if (typeof theObject =3D=3D "function") {=0A=
    =0A=
  }=0A=
  else {=0A=
    arr.push("=3D=3D=3D>"+theObject+"<=3D=3D=3D("+typeof(theObject)+")");=0A=
  }=0A=
  return arr.join('\n');=0A=
};=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/ui/SelectionModel.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:       SelectionModel.js=0A=
 *  Created:    Aug 30, 2007=0A=
 *  $Id: $=0A=
 * </file>=0A=
 */=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * An implementation of an OS like selection model, reacting on mouse =
clicks in =0A=
 * combination with CTRL and SHIFT keys. =0A=
 * <br>=0A=
 * It implements <code>com.hyperwave.ui.UIObservableIFC</code> so that =0A=
 * observers get notified whenever the selection model gets touched by =
the user. =0A=
 * <br>=0A=
 * Internal: it turned out that IE is somewhat slow when searching =
elements by =0A=
 * their CSS class name in the DOM and a lot of elements are present. =
Therefore =0A=
 * we decided to implement a caching mechanism for the currently =
selected elements=0A=
 * in the model itself. (In Firefox this would not really be necessary =
but still=0A=
 * speeds up things slightly). =0A=
 * =0A=
 * @see com.hyperwave.ui.UIObservableIFC=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.ui.SelectionModel">=0A=
defineClass ( "com.hyperwave.ui.SelectionModel",=0A=
              function ( class$ )=0A=
{=0A=
=0A=
  /**=0A=
   * Constructor.=0A=
   * @param theCanvas: Node: the DOM node to which the selection model =
should =0A=
   *   be applied. =0A=
   */=0A=
  class$.constructor =3D function( theCanvas, theId )=0A=
  {=0A=
    if ( (typeof theCanvas =3D=3D "string") && (theCanvas =3D=3D =
"__proto__" ))=0A=
      return;=0A=
      =0A=
    this.canvas_ =3D theCanvas;=0A=
    this.latestSelection_ =3D null;=0A=
    this.doubleClickEnabled_ =3D true;=0A=
    this.disabled_ =3D false;=0A=
    this.cssMarker_ =3D null;=0A=
    this.id_ =3D (theId)? theId : "selection";=0A=
    this.multipleSelectionsAllowed_ =3D true;=0A=
    // observers=0A=
    this.observers_ =3D [];=0A=
    // cache selectable elements=0A=
    this.selectable_ =3D null;=0A=
    // cache selected elements=0A=
    this.selection_ =3D [];=0A=
    // bind handler so that they are not registered more than once=0A=
    this.boundOnClickHandler_ =3D =
this.onClickHandler.bindAsEventListener ( this );=0A=
    this.boundOnDblClickHandler_ =3D =
this.onDblClickHandler.bindAsEventListener ( this );=0A=
    this.boundClearSelection_ =3D =
this.clearSelection.bindAsEventListener ( this );=0A=
  };=0A=
=0A=
  /**=0A=
   * Destructor, removes event handlers from DOM elements. =0A=
   * Does not take care about deleting the DOM elements itself.=0A=
   * Neede for memory leak "healing" in IE. =0A=
   */=0A=
  class$.destructor =3D function(){=0A=
    Event.stopObserving(this.canvas_, "click", =
this.boundOnClickHandler_);=0A=
    Event.stopObserving(this.canvas_, "dblclick", =
this.boundOnDblClickHandler_);=0A=
    Event.stopObserving(this.canvas_, "mousedown", =
this.boundClearSelection_);=0A=
    Event.stopObserving(this.canvas_, "mouseup", =
this.boundClearSelection_);=0A=
  };=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.ui.UIObservableIFC#attach=0A=
   */=0A=
  class$.attach =3D function( theObserver ) {=0A=
    this.observers_.push(theObserver);=0A=
  };=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.ui.UIObservableIFC#notify=0A=
   */=0A=
  class$.notify =3D function() {=0A=
    for(var cr=3D0;cr<this.observers_.length; ++cr){=0A=
      this.observers_[cr].userAction( this );=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   * Set whether multiple selections are allowed for this selection =
model instance=0A=
   * or not. =0A=
   * @param theFlag: boolean: multiple selections are not allowed in =
case =0A=
   *   flag is <code>false</code>. Defaults to true.=0A=
   */=0A=
  class$.allowMultipleSelections =3D function( theFlag ) {=0A=
    var flag =3D true;=0A=
    if((typeof theFlag =3D=3D "boolean") && (theFlag =3D=3D false)){=0A=
      flag =3D false;=0A=
    }=0A=
    this.multipleSelectionsAllowed_ =3D flag;    =0A=
  };=0A=
  =0A=
  /**=0A=
   * This method is needed because <code>SelectionModel</code> =
implements the=0A=
   * <code>com.hyperwave.ui.UIObservableIFC</code> and hands itself =0A=
   * over to its observers in the <code>notify</code> method. The =
observers at=0A=
   * least use method <code>getId</code> therefore we need an =
implementation of it.=0A=
   * @see com.hyperwave.ui.Element#getId=0A=
   */=0A=
  class$.getId =3D function() {=0A=
    return this.id_;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Applies the selection model to the immediate child elements of the =
given=0A=
   * canvas. Optionally the name of the CSS class for marking the =
elements as =0A=
   * selectable can be specified. Returns an instance applied to the =
given =0A=
   * canvas.=0A=
   * @param theCanvas: Node: the element to "decorate". Its children are =
then=0A=
   *   selectable by the selection model. =0A=
   * @param theCssClass: string | null: optional name of the css class =
by which =0A=
   *   selectable elements should be marked.=0A=
   * @return com.hyperwave.ui.SelectionModel: the selection model =
applied to=0A=
   *   the given canvas element.=0A=
   */=0A=
  class$.static_.makeSelectable =3D function( theCanvas, theCssClass, =
theId ) {=0A=
    var css =3D theCssClass ? theCssClass : "selectable";=0A=
    var elementArray =3D theCanvas.immediateDescendants();=0A=
    for ( var elem=3D0; elem<elementArray.length; elem++ ) {=0A=
      elementArray [ elem ].addClassName(css);      =0A=
    } =0A=
    var model =3D new com.hyperwave.ui.SelectionModel( theCanvas, theId =
);=0A=
    model.attachByCSS( css );=0A=
    // reset selectable cache=0A=
    this.selectable_ =3D null;=0A=
    return model;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Sets the DOM nodes which should be currently selected within this =
selection model.=0A=
   * @param elementArray: Node[]: the selected DOM Nodes=0A=
   */=0A=
  class$.setSelection =3D function( elementArray ) {=0A=
    this.removeSelection();=0A=
    for ( var elem=3D0; elem<elementArray.length; elem++ ) {=0A=
      this.select(elementArray[elem]);=0A=
    }    =0A=
  };=0A=
=0A=
  /**=0A=
   * Gets the DOM nodes which are currently selected within this =
selection model.=0A=
   * @return Node[]: the selected DOM Nodes=0A=
   */=0A=
  class$.getSelection =3D function() {=0A=
    return this.selection_;=0A=
  };=0A=
=0A=
  /**=0A=
   * Gets the DOM nodes which are currently selectable within this =
selection model.=0A=
   * @param force: boolean: if true the selectables need to be computed =
freshly, =0A=
   *   no cache is used then. =0A=
   * @return Node[]: the selectable DOM Nodes=0A=
   */=0A=
  class$.getSelectable =3D function( force ) {=0A=
    if(!this.selectable_ || force){=0A=
      this.selectable_ =3D this.canvas_.select( "*." + this.cssMarker_ );=0A=
    }=0A=
    return this.selectable_;=0A=
  };=0A=
=0A=
  /*=0A=
   * Method for deselecting all currently selected DOM nodes. =0A=
   */=0A=
  class$.removeSelection =3D function() {=0A=
    var elementArray =3D this.getSelection();=0A=
    for ( var elem=3D0; elem<elementArray.length; elem++ ) {=0A=
      elementArray [ elem ].removeClassName("selected");      =0A=
    } =0A=
    this.selection_ =3D [];=0A=
  };=0A=
      =0A=
  /**=0A=
   * Attaches the selection model to all elements within the given =
canvas which=0A=
   * have the given CSS class set. For simple lists the possibly easier =
approach =0A=
   * is to use <code>static_.makeSelectable</code> instead.=0A=
   * @param theClass: string: the CSS class by which the selectable =
elements are recognized=0A=
   * @param theCanvasClass: string|void: the CSS class that should be =
set on the canvas as =0A=
   *   soon as the selection model is attached.  =0A=
   * =0A=
   * @see com.hyperwave.ui.SelectionModel#static_.makeSelectable=0A=
   */=0A=
  class$.attachByCSS =3D function( theClass, theCanvasClass ) {=0A=
    this.cssMarker_ =3D theClass;=0A=
    =0A=
    if (theCanvasClass) {=0A=
      this.canvas_.addClassName(theCanvasClass);=0A=
    }=0A=
=0A=
    this.canvas_.observe (=0A=
      "click", =0A=
      this.boundOnClickHandler_=0A=
    );=0A=
=0A=
    this.canvas_.observe (=0A=
      "dblclick", =0A=
      this.boundOnDblClickHandler_=0A=
    );=0A=
=0A=
    // remove text selection for SHIFT-click, CTRL-click and META-click =
(apple)=0A=
    this.canvas_.observe (=0A=
      "mousedown", =0A=
      this.boundClearSelection_=0A=
    );=0A=
=0A=
    this.canvas_.observe (=0A=
      "mouseup", =0A=
      this.boundClearSelection_=0A=
    );=0A=
  };=0A=
  =0A=
  /**=0A=
   * The double click handler attached to the selectable DOM nodes. =0A=
   * Remembers the element that was double clicked intermediately and =
notifies =0A=
   * its observers. The observers can then use methods =
<code>isDoubleClick</code>=0A=
   * to verify whether a double click took place and =
<code>getDoubleClickElement</code>=0A=
   * to retrieve the elment that was double clicked.=0A=
   * @param event: Event: the event object (from prototype library)=0A=
   * @see com.hyperwave.ui.SelectionModel#isDoubleClick=0A=
   * @see com.hyperwave.ui.SelectionModel#getDoubleClickElement=0A=
   */=0A=
  class$.onDblClickHandler =3D function(event) {=0A=
    if(this.disabled_)=0A=
      return;=0A=
    if(this.doubleClickEnabled_) {=0A=
      var element =3D $(Event.element(event)).up('.' + this.cssMarker_);=0A=
      this.doubleClick_ =3D element;=0A=
      this.notify();=0A=
      this.doubleClick_ =3D null;=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   * Disables the selection model so that it does not react on =0A=
   * user clicks.=0A=
   * Per default the selection model is enabled.=0A=
   */=0A=
  class$.disable =3D function() {=0A=
    this.disabled_ =3D true;=0A=
  };=0A=
=0A=
  /**=0A=
   * Enables the selection model so that it reacts on user clicks.=0A=
   * Per default the selection model is enabled.=0A=
   */=0A=
  class$.enable =3D function() {=0A=
    this.disabled_ =3D false;=0A=
  };=0A=
    =0A=
  /**=0A=
   * Enables reaction of selection model on double-clicks. In case =
double-click is =0A=
   * enabled observers are also notified when the user double-clicks and =
can then =0A=
   * use method <code>isDoubleClick</code> to find out whether they have =
been notified=0A=
   * because of a double click.=0A=
   * =0A=
   * @see com.hyperwave.ui.SelectionModel#isDoubleClick=0A=
   * @see com.hyperwave.ui.SelectionModel#getDoubleClickElement=0A=
   */=0A=
  class$.enableDoubleClick =3D function() {=0A=
    this.doubleClickEnabled_ =3D true;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Disables reaction of selection model on double-clicks.=0A=
   */=0A=
  class$.disableDoubleClick =3D function() {=0A=
    this.doubleClickEnabled_ =3D false;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Method allowing observers to check whether they were notified =
because of a =0A=
   * double click. This method only returns true in case of a double =
click and only =0A=
   * during the <code>notify</code> call. Only in case double click =
reaction is =0A=
   * enabled (see <code>enableDoubleClick</code>=0A=
   * @return boolean: true if the observer was notified because of a =
double click.=0A=
   * @see com.hyperwave.ui.SelectionModel#enableDoubleClick=0A=
   */=0A=
  class$.isDoubleClick =3D function() {=0A=
    return (this.doubleClick_ !=3D null);  =0A=
  };=0A=
  =0A=
  /**=0A=
   * Method allowing observers to retrieve the element that was double =
clicked. The =0A=
   * element can only be retrieved during the <code>notify</code> call.=0A=
   * @return Node: the DOM node that got double-clicked.=0A=
   */=0A=
  class$.getDoubleClickElement =3D function() {=0A=
    return this.doubleClick_;=0A=
  };=0A=
    =0A=
  /**=0A=
   * The onclick handler attached to the selectable DOM nodes. Takes =
care about =0A=
   * attaching/detaching CSS classes accordingly (taking into account =
whether =0A=
   * CTRL or SHIFT key were additionally pressed or not). =0A=
   * @param event: Event: the event object (from prototype library) =0A=
   */=0A=
  class$.onClickHandler =3D function(event) {=0A=
    if(this.disabled_)=0A=
      return;=0A=
    var clicked_elem =3D $(Event.element(event));=0A=
    this.clearSelection(event);=0A=
    =0A=
    //  Performance improvement:=0A=
    //  Previously the prototype "up" functionality was used. As this =0A=
    //  function uses the "$" function to extend every single node on =
the =0A=
    //  way this takes far too long in case of lots of objects in the DOM=0A=
    //  (internally prototype seems to retrieve a whole bunch of nodes =
when=0A=
    //  using "up"). =0A=
    //  Therefore we search upwards from the clicked DOM element until =
we =0A=
    //  find a selectable element or reach the selection model canvas. =0A=
    //  We use the DOM property parentNode directly which increases =
performance=0A=
    //  dramatically.   =0A=
    var element;=0A=
    if(clicked_elem =3D=3D this.canvas_){=0A=
      // in case the user clicked onto the listing itself (not touching =
a =0A=
      // listing item) no reaction should take place=0A=
      element =3D null;=0A=
    }=0A=
    else if(clicked_elem.hasClassName(this.cssMarker_ )){=0A=
      element =3D clicked_elem;=0A=
    } else {=0A=
      var elem =3D clicked_elem;=0A=
      var found =3D false;=0A=
      // search upwards from the clicked element until a selectable is =
reached=0A=
      while(elem =3D $(elem.parentNode)){=0A=
        if(elem.hasClassName(this.cssMarker_ )){=0A=
          found =3D true;=0A=
          element =3D elem;=0A=
          break;=0A=
        }=0A=
        // stop searching in case the canvas was reached=0A=
        if(elem =3D=3D this.canvas_)=0A=
          break;=0A=
      }=0A=
      if(!found)=0A=
        element =3D null;=0A=
    }=0A=
=0A=
    if(!element)=0A=
      return;=0A=
    // policy in case multiple selection is allowed=0A=
    if(this.multipleSelectionsAllowed_) {=0A=
      // taken from OS:=0A=
      // CTRL Key is stronger than SHIFT Key=0A=
      // SHIFT Key policy:=0A=
      //  select all between the latest selected element and the element =0A=
      //  selected with shift (latest selected element is NOT changed),=0A=
      //  deselect all others.=0A=
      // kind of bug (but also on Windows and Linux): =0A=
      //  if an element is selected and than deselected again (by CTRL) =
it =0A=
      //  still remains the latest selected element!=0A=
      if(event.ctrlKey || event.metaKey){=0A=
        if(this.isSelected(element))=0A=
          this.deselect(element);=0A=
        else =0A=
          this.select(element);=0A=
      }=0A=
      else if(event.shiftKey){=0A=
        // modified policy:=0A=
        // working with the prototype functions getElementsByClassName,=0A=
        // Element.select or siblings needs way too much time in case =
lots =0A=
        // of selectables are present in the DOM. Therefore we use =
internal =0A=
        // DOM properties to step through the selectable elements.=0A=
        var latest =3D $(this.latestSelection_);=0A=
        this.removeSelection();=0A=
        var elem =3D $(this.latestSelection_);=0A=
        var to_select =3D [elem];=0A=
        var found =3D false;=0A=
        // search downwards first from the latest selection until the =0A=
        // currently clicked element is reached. =0A=
        while(elem =3D elem.next("*." + this.cssMarker_)){=0A=
          to_select.push(elem);=0A=
          if(elem =3D=3D element){=0A=
            found =3D true;=0A=
            break;=0A=
          }=0A=
        }=0A=
        // not found, so try to search upwards now. =0A=
        if(!found) {          =0A=
          var elem =3D this.latestSelection_;=0A=
          to_select =3D [elem];=0A=
          while(elem =3D $(elem.previousSibling)){=0A=
            if((typeof elem.hasClassName !=3D "undefined") && =
elem.hasClassName(this.cssMarker_))=0A=
              to_select.push(elem);=0A=
            if(elem =3D=3D element){=0A=
              found =3D true;=0A=
              break;=0A=
            }=0A=
          }=0A=
        }=0A=
        // select all elements between the latest selection and the =0A=
        // current selection=0A=
        if(found){=0A=
          for(var cr=3D0;cr<to_select.length;++cr){=0A=
            this.select( $(to_select[cr]) );=0A=
          }=0A=
        }=0A=
        // restore latest selection (SHIFT click does not update latest =
selection)=0A=
        this.latestSelection_ =3D latest;=0A=
      }=0A=
      else {=0A=
        this.removeSelection();=0A=
        this.select(element);     =0A=
      }=0A=
    }=0A=
    // the simple policy in case multiple selection is not allowed=0A=
    else {=0A=
      this.removeSelection();=0A=
      this.select(element);     =0A=
    }=0A=
    this.notify();=0A=
    event.stop();=0A=
  };=0A=
=0A=
  /**=0A=
   * Event handler used to remove the text selection from the browser. =
Needed because =0A=
   * using SHIFT-click or CTRL-click does not only select the elements =
of the selection =0A=
   * model but also the text in the range between the clicks. Which =
simply looks ugly. =0A=
   */=0A=
  class$.clearSelection =3D function(event) {=0A=
    if ((event.shiftKey) || (event.ctrlKey) || (event.metaKey)){=0A=
      if(typeof window.getSelection =3D=3D "function"){=0A=
        window.getSelection().removeAllRanges(); =0A=
      } else {=0A=
        document.selection.empty();=0A=
      }=0A=
    } =0A=
  };=0A=
=0A=
  /**=0A=
   * Selects the given element and remember it as the latest selection. =
Does not =0A=
   * touch already selected elements!=0A=
   * @param element: Node: the DOM node that should be selected.=0A=
   */=0A=
  class$.select =3D function( element ) {=0A=
    if(!element.hasClassName("selected")){=0A=
      element.addClassName("selected");=0A=
      this.selection_.push(element);=0A=
    }=0A=
    // if element was already selected just restore latest selection =
(SHIFT CLICK) =0A=
    this.latestSelection_ =3D element;=0A=
  };=0A=
=0A=
  /**=0A=
   * Deselects the given element. Does not =0A=
   * touch other selected elements!=0A=
   * @param element: Node: the DOM node that should be deselected.=0A=
   */=0A=
  class$.deselect =3D function( element ) {=0A=
    element.removeClassName("selected");=0A=
    for(var cr=3D0;cr<this.selection_.length;++cr){=0A=
        if(this.selection_[cr] =3D=3D element){=0A=
          this.selection_.splice(cr,1);=0A=
          break;=0A=
        }=0A=
    }=0A=
  };=0A=
    =0A=
  /**=0A=
   * Checks whether a certain DOM node is currently selected or not.=0A=
   * @param element: Node: the DOM node to check=0A=
   * @return boolean: true if the DOM node is currently selected.=0A=
   */=0A=
  class$.isSelected =3D function( element ) {=0A=
    if(element.descendantOf(this.canvas_))=0A=
      return element.hasClassName("selected");=0A=
    else =0A=
      return false;=0A=
  };   =0A=
  =0A=
  /**=0A=
   * Returns the canvas on which the selection model operates.=0A=
   * =0A=
   * @return Node: the html container on which the selection model =
operates=0A=
   */=0A=
  class$.getCanvas =3D function () {=0A=
    return this.canvas_;=0A=
  };=0A=
});=0A=
// </JSClass>
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/util/Url.js?cachekeY=515488b2-en

/*
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.
 * $Id: Url.js 124325 2007-02-22 15:31:34Z merge $
 */

initPackage ( "com.hyperwave.util" );

com.hyperwave.util.Url =3D function (args) {
  if (args =3D=3D=3D "__proto__") {
    return;
  }
};

class$ =3D doInherit(com.hyperwave.util.Url);

/**
 * This method is the comprehensive method to get an url.
 *
 * <xmp>
 *  com.hyperwave.util.Url.static_.getUrl({window: window,
 *                                         method: =
"HW_WF_Workflow.displayTask",
 *                                         parameters: {taskid: 1, type: =
'full'}});
 *
 * // returns =
"/workflow/task_lists/...;internal&action=3Djs.exec......?taskid=3D1&type=
=3Dfull"
 * //          ^^^^^^^^^^^^^^^^^^^^^^^^
 * //          window parameter        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
 * //                                  method parameter              =
^^^^^^^^^^^^^^^^^^^
 * //                                                                =
parameters
 * </xmp>
 *
 * @params theParams: object: the parameter object
 * @params theParams.url: string|void: the url source
 * @params theParams.window: window|void: the window for the url source
 *           (note: if you do not specify url or window, then the source =
url
 *                  is taken from location.href. this is normally the
 *                  window/frame url this class is included.)
 * @params theParams.action: string|void: the request action
 * @params theParams.method: string|void: the request js method
 * @params theParams.parameters: object: the request parameters
 * @return: string: the url
 */
class$.static_.getUrl =3D function (theParams) {
  var parameters =3D theParams || {};
  var url;

  if (parameters.url) {
    url =3D hw.util.Url.static_.getBaseUrlByUrl(parameters.url);
  }
  else if (parameters.window) {
    url =3D hw.util.Url.static_.getBaseUrlByWindow(parameters.window);
  }
  else {
    url =3D hw.util.Url.static_.getBaseUrlByUrl(location.href);
  }

  if (parameters.action) {
    url +=3D =
hw.util.Url.static_.getUrlPostfixForAction(parameters.action);
  }
  else if (parameters.method) {
    url +=3D hw.util.Url.static_.getUrlPostfixForMethod(null, =
parameters.method);
  }
  if (parameters.parameters) {
    return hw.util.Url.static_.appendParametersToUrl(url, =
parameters.parameters);
  }
  else {
    return url;
  }
};

/**
 * This function builds an url-postfix to call a Method of a javascript =
class with
 * optional parameters.
 * For static methods add the "static_." prefix to the methodname.
 * For packaged classes use the full qualified classname.
 *
 * <xmp>
 * var postfix1 =3D =
com.hyperwave.util.Url.static_.getUrlPostfixForMethod("HW_WF_Workflow",
 *                                                                      =
"displayTask",
 *                                                                      =
{taskid: 1,
 *                                                                       =
type: 'full'});
 * // returns ";internal&action=3Djs.exec......?taskid=3D1&type=3Dfull"
 *
 * var postfix2 =3D =
com.hyperwave.util.Url.static_.getUrlPostfixForMethod("com.hyperwave.util=
.AnyThing",
 *                                                                      =
"static_.showAttributes",
 *                                                                      =
{goid: goid});
 * // returns ";internal&action=3Djs.exec......?goid=3D..."
 *
 * // complete example
 * var method =3D "com.hyperwave.util.AnyThing.static_.showAttributes";
 * var params =3D {goid: "0x12345678_0x12345678", type: "full"};
 * var new_url =3D =
com.hyperwave.util.Url.static_.getBaseUrlByWindow(window) +
 *               =
com.hyperwave.util.Url.static_.getUrlPostfixForMethod(null, method, =
params);
 * </xmp>
 *
 * @param className: string|null: the name of the UIClass
 * @param methodName: string: the name of the method of the UIClass
 * @param parameters: object: the parameters fpr the URL
 *
 * @return: string: the url
 */
class$.static_.getUrlPostfixForMethod =3D function (className, =
methodName, parameters) {

  var url =3D ";internal";
  url+=3D "&action=3Djs.execute.action";
  url+=3D "&Parameter=3D";

  if (className =3D=3D null) {
    var classmethod_ =3D =
methodName.match(/^(.*?)\.((?:static_\.)?[\w\$]+)$/);
    if (classmethod_) {
      url+=3D =
encodeURIComponent('#(UIClass:'+classmethod_[1]+')(Method:'+classmethod_[=
2]+')');
    }
    else {
      throw "Could not parse method name";
    }
  }
  else {
    url+=3D =
encodeURIComponent('#(UIClass:'+className+')(Method:'+methodName+')');
  }
 =20
  if ((parameters || {}).context) {
    url +=3D "&ctx=3D" + parameters.context;
    delete parameters.context;
  }

  return com.hyperwave.util.Url.static_.appendParametersToUrl(url, =
parameters);
};

/**
 * This method returns an url postfix for an standard action with =
optional
 * parameters.
 *
 * <xmp>
 * var postfix =3D =
com.hyperwave.util.Url.static_.getUrlPostfixForAction("vcard", =
{username: "hwsystem"});
 * // returns ";internal&action=3Dvcard.action?username=3Dhwsystem"
 * </xmp>
 *
 * @param action: string: the action name
 * @param parameters: object|void: the option request parameters
 * @return: string: the url postfix
 */
class$.static_.getUrlPostfixForAction =3D function (action, parameters) =
{
  var url =3D ";internal&action=3D";
  url +=3D encodeURIComponent(action);
  if (!action.match(/\.action$/)) {
    url +=3D ".action";
  }
  return com.hyperwave.util.Url.static_.appendParametersToUrl(url, =
parameters);
};

/**
 * This method appends parameters to a given url.
 *
 * @param theUrl: string: the url
 * @param theParameters: object: the parameter hashmap
 * @return: string: the   url with parameters
 */
class$.static_.appendParametersToUrl =3D function (theUrl, =
theParameters) {
  var pars =3D [];
  for (var i in theParameters) {
    pars.push(encodeURIComponent(i) + "=3D" + =
encodeURIComponent(theParameters[i]));
  }

  if (pars.length) {
    return theUrl + (theUrl.indexOf("?") =3D=3D -1 ? "?" : "&") + =
pars.join("&");
  }
  else {
    return theUrl;
  }
};

/**
 * This method parse the base url from a given window.
 *
 * <xmp>
 * var url =3D =
com.hyperwave.util.Url.static_.getBaseUrlByWindow(window);
 * // if location is =
"/hw_temporary_objects;internal&action=3D...?key=3D1&value=3D3#footer"
 * // returns "/hw_temporary_objects"
 * </xmp>
 *
 * @param theWindow: window: the window to parse the url from
 * @return: string: the base url
 */
class$.static_.getBaseUrlByWindow =3D function (theWindow) {
  return =
com.hyperwave.util.Url.static_.getBaseUrlByUrl(theWindow.location.href);
};

/**
 * This method parse the base url from a given url. It truncates
 * the ;internal, query and hash parts.
 *
 * @param theUrl: string: the given url to parse
 * @return: string: the base url
 */
class$.static_.getBaseUrlByUrl =3D function (theUrl) {
  var match =3D theUrl.match(/^(.*?)[\?\;\#]/);
  if (match) {
    return match[1];
  }
  else {
    return theUrl;
  }
};

/**
 * This method parses a url ...
 *
 * @param theUrl: string: the url to parse
 * @return: object: the url parts
 * @return.baseurl: string: the base url
 * @return.action: string: the part with &action=3D...
 * @return.parameter: string: the part with &Parameter=3D...
 * @return.jsMethod: if action is js.execute... it contains the full =
qualified methodname
 * @return.jsMethodClass: just the classname
 * @return.jsMethodMethod: just the methodname (with static_ part)
 */
class$.static_.parseUrl =3D function (theUrl) {
  var ret =3D {
    baseurl: com.hyperwave.util.Url.static_.getBaseUrlByUrl(theUrl),
    action: '',
    parameter: '',
    parameters: {},
    multiParameters: {},
    jsMethod: '',
    jsMethodClass: '',
    jsMethodMethod: '',
    hash: ''
  };

  var action_ =3D theUrl.match(/\&action\=3D([^\?\&\#]+)/);
  if (action_) {
    ret.action =3D decodeURIComponent(action_[1]);
  }
  var parameter_ =3D theUrl.match(/\&Parameter\=3D([^\?\&\#]+)/);
  if (parameter_) {
    ret.parameter =3D decodeURIComponent(parameter_[1]);
  }

  if (ret.action.indexOf("js.execute") =3D=3D 0 && ret.parameter) {
    var jsmethod_ =3D =
ret.parameter.match(/\#\(UIClass\:(.*?)\)\(Method\:(.*?)\)/);
    if (jsmethod_) {
      ret.jsMethod =3D jsmethod_[1] + "." + jsmethod_[2];
      ret.jsMethodClass =3D jsmethod_[1];
      ret.jsMethodMethod =3D jsmethod_[2];
    }
  }

  var url =3D theUrl;
  var idx =3D url.indexOf("#");
  if (idx !=3D -1) {
    url =3D url.substr(0, idx);

    ret.hash =3D decodeURIComponent(url.substr(idx + 1));
  }

  var idx =3D url.indexOf("?");
  if (idx !=3D -1) {
    var query =3D url.substr(idx + 1).split("&");
    url =3D url.substr(0, idx);
   =20
    for (var i =3D 0; i < query.length; i ++) {
      var query_part =3D query[i];
      idx =3D query_part.indexOf("=3D");
      if (idx =3D=3D -1) {
        var key =3D decodeURIComponent(query_part);
        var value =3D "";
      }
      else {
        var key =3D decodeURIComponent(query_part.substr(0, idx));
        var value =3D decodeURIComponent(query_part.substr(idx + 1));
      }

      if (!ret.multiParameters[key]) {
        ret.multiParameters[key] =3D [];
      }
      ret.multiParameters[key].push(value);
      ret.parameters[key] =3D value;
    }
  }

  var idx =3D url.indexOf(";");
  if (idx !=3D -1) {
    var query =3D url.substr(idx + 1).split("&");
    url =3D url.substr(0, idx);

    for (var i =3D 0; i < query.length; i ++) {
      var query_part =3D query[i];
      if (i =3D=3D 0 && query_part =3D=3D "internal") {
        continue;
      }
      idx =3D query_part.indexOf("=3D");
      if (idx =3D=3D -1) {
        var key =3D decodeURIComponent(query_part);
        var value =3D "";
      }
      else {
        var key =3D decodeURIComponent(query_part.substr(0, idx));
        var value =3D decodeURIComponent(query_part.substr(idx + 1));
      }

      if (!ret.multiParameters[key]) {
        ret.multiParameters[key] =3D [];
      }
      ret.multiParameters[key].push(value);
      ret.parameters[key] =3D value;
    }
  }

  return ret;
};

/**
 * This returns the server and port part of an url
 * <xmp>
 * var url =3D com.hyperwave.util.Url.static_.stripServerPart(url);
 * // if url is =
"http://www.yourserver.com:80/hw_temporary_objects;internal&action=3D...?=
key=3D1&value=3D3#footer"
 * // returns =
"/hw_temporary_objects;internal&action=3D...?key=3D1&value=3D3#footer"
 * </xmp>
 *
 * @param theUrl: string: the url to strio
 * @return: string: the striped url
 */
class$.static_.stripServerPart =3D function (theUrl) {
  var serverBase =3D location.href.replace(/(https?:\/\/[^\/]*)\/.*/, =
'$1');
  serverBase=3DserverBase.replace(/([\/\^$*+?.()|{}[\]])/g, '\\$1');
  var serverReg=3Dnew RegExp(serverBase,"g");

  return theUrl.replace(serverReg, '');
};

/**
 * This function returns a title for a url;
 * In the case there is a path, the last directory or the filename ist =
returned
 * in the case there is only a host, the host is returned.
 * <xmp>
 * var title =3D com.hyperwave.util.Url.static_.getTitleFromUrl(url);
 * // if url is =
"http://www.yourserver.com:80/hw_temporary_objects;internal&action=3D...?=
key=3D1&value=3D3#footer"
 * // returns "hw_temporaryobjects"
 * // if url is "http://www.google.com"
 * // returns "http://www.google.com"
 * </xmp>
 *
 * @param theUrl: string: the url to consider
 * @return: title: the generated title
 */
class$.static_.getTitleFromUrl =3D function (theUrl) {
  var url =3D theUrl.replace(/&amp;/g, "&").replace(/&/g, "&amp;") || =
"";
  var base_url =3D com.hyperwave.util.Url.static_.getBaseUrlByUrl(url);
  var url_array =3D base_url.split("/");
  var title =3D url_array.pop().replace(/\?.*/, "") || "";
  if (!title) { // this is the case if theUrl ends with an /
    title =3D url_array.pop().replace(/\?.*/, "") || "";
  }
  return title;
};
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/frameset/code/FrameSetMediator.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        FrameSetMediator.js
 *  Created:     2009-02-05 by cgoess
 *  Description: xxx
 *
 *  $Id: FrameSetMediator.js 146481 2009-02-10 08:36:53Z sweber $
 *  $Revision: 146481 $
 * </file>
 */

/* <JSLINT> */
/*global hw */
/*global HW_Mainframe */
/*global HW_Navigationframe */
/*global setCookie */
/*global getCookie */
/* </JSLINT> */

// <JSClass name=3D"FrameSetMediator">

/**
 * Constructor
 */
function FrameSetMediator (theParams) {
  if (theParams =3D=3D=3D "__proto__") {
    return;
  }

  com.hyperwave.framework.BaseMediator.apply(this, [theParams]);

  this.infoHtmlCtr_ =3D 0;
  this.infoHtmlQueue_ =3D [];
  this.infoHtml_ =3D {HEADER_TOP: [],
                    HEADER_BOTTOM: [],

                    HEADER_LEFT: [],
                    FOOTER_LEFT: [],
                    MAIN_HEADER_LEFT: [],
                    MAIN_FOOTER_LEFT: [],

                    HEADER_CENTER: [],
                    FOOTER_CENTER: [],
                    MAIN_HEADER_CENTER: [],
                    MAIN_FOOTER_CENTER: [],

                    HEADER_RIGHT: [],
                    FOOTER_RIGHT: [],
                    MAIN_HEADER_RIGHT: [],
                    MAIN_FOOTER_RIGHT: []};
  this.lock_ =3D false;

  this.temporaryTreeviewState_ =3D [];
  this.temporaryBreadcrumbingState_ =3D [];

  this.borderStateChanged_ =3D false;

  this.mainframeUrl_ =3D null;
  this.loaded_ =3D false;
  this.fitFrameSetTimeout_ =3D null;
}
class$ =3D doInherit(FrameSetMediator, =
com.hyperwave.framework.BaseMediator);

class$.static_.ON =3D {toString: function () { return "ON"; }};
class$.static_.OFF =3D {toString: function () { return "OFF"; }};

class$.static_.LEFT =3D {toString: function () { return "LEFT"; }};
class$.static_.CENTER =3D {toString: function () { return "CENTER"; }};
class$.static_.RIGHT =3D {toString: function () { return "RIGHT"; }};
class$.static_.BOTTOM =3D {toString: function () { return "BOTTOM"; }};
class$.static_.TOP =3D {toString: function () { return "TOP"; }};

class$.static_.HEADER =3D {toString: function () { return "HEADER"; }};
class$.static_.FOOTER =3D {toString: function () { return "FOOTER"; }};
class$.static_.MAIN_HEADER =3D {toString: function () { return =
"MAIN_HEADER"; }};
class$.static_.MAIN_FOOTER =3D {toString: function () { return =
"MAIN_FOOTER"; }};

class$.static_.EMPTY_URL_ =3D =
top.com.hyperwave.util.IncludeManager.static_.getInstance().getSrc("webap=
p/lib/empty.html");
class$.static_.NAVI_URL_ =3D =
top.com.hyperwave.util.IncludeManager.static_.getInstance().getSrc("webap=
p/components/frameset/ui/naviframe_static.html");

class$.static_.LANGRES_PATH_ =3D =
"%vd%/components/frameset/langres/buildframes.%lang%.lrc";
hw.util.IncludeManager.static_.getInstance().loadResource(class$.static_.=
LANGRES_PATH_);

class$.fitFrameSet =3D function () {
  if (this.fitFrameSetTimeout_) {
    clearTimeout(this.fitFrameSetTimeout_);
  }

  this.fitFrameSetTimeout_ =3D this._fitFrameSet.bind(this).defer();
};

class$._fitFrameSet =3D function () {
  this.fitFrameSetTimeout_ =3D null;

  var menu_container =3D $("menuContainer");
  menu_container.setStyle({height: "auto"});

  var footer_height =3D $("footerContainer").getHeight();

  var body_height =3D $(document.body).getHeight();

  var treeview_container =3D $("treeviewContainer");
  var treeview_top =3D treeview_container.cumulativeOffset().top;
  treeview_container.setStyle({height: Math.max(body_height - =
treeview_top, 0) + "px"});

  var mainframe_container =3D $("mainframeContainer");
  var mainframe_top =3D mainframe_container.cumulativeOffset().top;
  var mainframe_height =3D mainframe_container.getHeight();

  var inner_mainframe_container =3D $("innerMainframeContainer");
  var inner_mainframe_height =3D inner_mainframe_container.getHeight();

  var delta =3D mainframe_height - inner_mainframe_height;
  var height =3D body_height - mainframe_top - footer_height - delta;
  inner_mainframe_container.setStyle({height: Math.max(height, 0) + =
"px"});

  menu_container.setStyle({height: menu_container.getHeight() + "px"});
};

class$.static_._getUrlFromLocation =3D function (location) {
  return location.href.replace(/.+?\/\/.+?\//, "/").replace(/#.*$/, "");
};

class$.onload =3D function () {
  if (Prototype.Browser.IE && navigator.appVersion.indexOf("MSIE 7.0") =
!=3D -1) {
    // workaround for a (invisble) scrolling body problem in IE7
    document.body.onscroll =3D function () {
      document.body.scrollTop =3D 0;
    };
  }

  this.testCoockie(this._onload2.bind(this));
};

class$._onload2 =3D function () {
  this.testOutOfOffice(this._onload3.bind(this));
};

class$._onload3 =3D function () {
  this.applyEditMode();
  this.fitFrameSet(); // that the breadcrumbing sizes can be evaluated
 =20
  if (this.static_._getUrlFromLocation(location) =3D=3D =
getCookie("HW_TopUrl2")) {
    // this covers the case when the users hits reload in browser window
    // -> the top url is the same as in onunload -> use the same url for =
main frame
    HW_Mainframe.location.replace(getCookie("HW_MainframeUrl2"));
  }
  else {
    HW_Mainframe.location.replace(this.mainframeUrl_);
   =20
    if (!HW_Mainframe.location.hash && top.location.hash) {
      HW_Mainframe.location.hash =3D top.location.hash;
    }
  }
 =20
  setCookie("HW_TopUrl2", "", new Date(0));
  setCookie("HW_MainframeUrl2", "", new Date(0));
  this.loaded_ =3D true;
};

class$.onunload =3D function () {
  if (this.loaded_) {
    setCookie("HW_TopUrl2", this.static_._getUrlFromLocation(location));
    setCookie("HW_MainframeUrl2", =
this.static_._getUrlFromLocation(HW_Mainframe.location));
  }
};

class$.onresize =3D function () {
  this.fitFrameSet();
};

class$.setTreeviewStateTemporary =3D function (state) {
  var treeview_state =3D this.temporaryTreeviewState_.pop() || =
this.getTreeviewState().state;

  if (treeview_state =3D=3D FrameSetMediator.static_.OFF) {
    state =3D FrameSetMediator.static_.OFF;
  }

  this.temporaryTreeviewState_ =3D [state, treeview_state];
};

class$.getTreeviewState =3D function () {
  var state =3D $(document.body).hasClassName("treeviewOn") ?
                this.static_.ON :
                $(document.body).hasClassName("treeviewOff") ?
                  this.static_.OFF :
                  null;
  return {isOn: function () { return =
$(document.body).hasClassName("treeviewOn"); },
          isOff: function () { return =
$(document.body).hasClassName("treeviewOff"); },
          state: state};
};

class$.setTreeviewState =3D function (state) {
  if (state =3D=3D FrameSetMediator.static_.OFF &&
      =
HW_Navigationframe.location.pathname.indexOf(this.static_.EMPTY_URL_) =
!=3D=3D 0) {
    HW_Navigationframe.location.replace(this.static_.EMPTY_URL_);

    if (!this.temporaryTreeviewState_.length) {
      top.callServerFunction({serverFunctionName: "toggleTreeview", =
callback: "",
                              parameters: {keyvalue: "no"}});
    }
  }
  else if (state =3D=3D FrameSetMediator.static_.ON &&
           =
HW_Navigationframe.location.pathname.indexOf(this.static_.NAVI_URL_) =
!=3D=3D 0) {
    HW_Navigationframe.location.replace(this.static_.NAVI_URL_);

    if (!this.temporaryTreeviewState_.length) {
      top.callServerFunction({serverFunctionName: "toggleTreeview", =
callback: "",
                              parameters: {keyvalue: "yes"}});
    }
  }

  $(document.body).removeClassName("treeviewOn");
  $(document.body).removeClassName("treeviewOff");
  $(document.body).addClassName("treeview" + =
state.toString().capitalize());
  this.fitFrameSet();
};

class$.toggleTreeviewState =3D function () {
  var state =3D this.getTreeviewState();
  if (state.isOn()) {
    this.setTreeviewState(FrameSetMediator.static_.OFF);
  } else {
    this.setTreeviewState(FrameSetMediator.static_.ON);
  }
};

class$.setBreadcrumbingStateTemporary =3D function (state) {
  var breadcrumbing_state =3D this.temporaryBreadcrumbingState_.pop() || =
this.getBreadcrumbingState().state;

  if (breadcrumbing_state =3D=3D FrameSetMediator.static_.OFF) {
    state =3D FrameSetMediator.static_.OFF;
  }

  this.temporaryBreadcrumbingState_ =3D [state, breadcrumbing_state];
};

class$.getBreadcrumbingState =3D function () {
  var state =3D $(document.body).hasClassName("breadcrumbingOn") ?
                this.static_.ON :
                $(document.body).hasClassName("breadcrumbingOff") ?
                  this.static_.OFF :
                  null;
  if (state =3D=3D=3D null) {
    throw "Unknown breadcrumbing state";
  }
  return {isOn: function () { return =
$(document.body).hasClassName("breadcrumbingOn"); },
          isOff: function () { return =
$(document.body).hasClassName("breadcrumbingOff"); },
          state: state};
};

class$.setBreadcrumbingState =3D function (state) {
  $(document.body).removeClassName("breadcrumbingOn");
  $(document.body).removeClassName("breadcrumbingOff");
  $(document.body).addClassName("breadcrumbing" + =
state.toString().capitalize());
  this.fitFrameSet();
};

class$.setMainframeBorderState =3D function (state) {
  var body =3D $(document.body);
  if (state =3D=3D this.static_.ON && body.hasClassName("noframe")) {
    body.removeClassName("noframe");
    this.fitFrameSet();
  }
  else if (state =3D=3D this.static_.OFF && =
!body.hasClassName("noframe")) {
    body.addClassName("noframe");
    this.fitFrameSet();
  }
  this.borderStateChanged_ =3D true;
};

class$.setMainframeUrl =3D function (url) {
  this.mainframeUrl_ =3D url;
};

class$.frameOnload =3D function (frame) {
  this.applyEditMode();

  if (frame.name =3D=3D "HW_Mainframe") {
   =20
    try {
      if =
(HW_Mainframe.location.pathname.indexOf(this.static_.EMPTY_URL_) !=3D=3D =
0) {
        document.title =3D HW_Mainframe.document.title.stripTags();
      }
    }
    catch (exc) {
      // in case of access denied when displaying external documents =
inline
    }
   =20
    this._updateInfoHtml();

    if (!this.borderStateChanged_) {
      this.setMainframeBorderState(this.static_.ON);
    }
    this.borderStateChanged_ =3D false;

    if (this.temporaryTreeviewState_.length) {
      this.setTreeviewState(this.temporaryTreeviewState_.shift());
    }
    if (this.temporaryTreeviewState_.length) {
      $(document.body).addClassName("notreetoggle");
    }
    else {
      $(document.body).removeClassName("notreetoggle");
    }
    if (this.temporaryBreadcrumbingState_.length) {
      =
this.setBreadcrumbingState(this.temporaryBreadcrumbingState_.shift());
    }
  }
};

class$.testCoockie =3D function (theCallback) {
  // in case the browser has cookies disabled, a alert message is =
displayed
  document.cookie =3D "cookie_test=3D1;path=3D/";
  var cookie_test =3D document.cookie.search(/cookie_test\s*=3D\s*1/) =
!=3D -1;
  document.cookie =3D "cookie_test=3D1;path=3D/;expires=3D" + new =
Date(1000).toGMTString(); // delete the cookie again
  if (!cookie_test) {
    var d =3D new hw.dialogs.Message(null, =
FrameSetMediator.static_.getLangText("ppErrAlert1"));
    d.addEventListener(d.static_.EVENTS.CLOSE, theCallback);
    this.getFramework().displayDialog(d);
  }
  else {
    theCallback();
  }
};

class$.testOutOfOffice =3D function (theCallback) {
  if (this.getFramework().getApplicationProperty("eks", =
"useroutofoffice")) {
    var d =3D new =
hw.dialogs.Confirm(FrameSetMediator.static_.getLangText("ooo_head"),
                                   =
FrameSetMediator.static_.getLangText("ooo_body"));
    d.addEventListener(d.static_.EVENTS.CLOSE, theCallback);
    d.addEventListener(d.static_.EVENTS.BUTTON_CLICK, (function (fsm) {
          if (this.getValue() =3D=3D "yes") {
            fsm.getFramework().ajaxRequest({method: =
"HW_Ebc.static_.disableOutOfOffice"}, fsm, window);
          }
        }).bind(d, this));
    this.getFramework().displayDialog(d);
  }
  else {
    theCallback();
  }
};

class$.setHeaderInfo =3D function (theParams) {
  var params =3D theParams || {};
  var reader =3D =
hw.util.IncludeManager.static_.getResource("%vd%/components/frameset/html=
res/csbuildframes.xml");

  if (hw.util.Object.static_.isEmpty(params)) {
    return;
  }

  if (params.title || params.infoicon) {
    var resource =3D new =
com.hyperwave.res.Resource({templateKey_:"header"});
    resource.makeRoot();
    resource.readAll(reader);
  	resource.setRes("title", params.title || "");
  	resource.setRes("infoicon", params.infoicon);
    this.setInfoHtml(resource.toString(),
                     this.static_.HEADER,
                     this.static_.LEFT);
  }

  if (params.tabs || params.caption) {
    var resource =3D new com.hyperwave.res.Resource({templateKey_: =
"main_header"});
    resource.makeRoot();
    resource.readAll(reader);
    resource.setRes("caption", params.caption || "");
    resource.setRes("tabs", params.tabs || []);

    for (var i =3D 0; params.tabs && i < params.tabs.length; i ++) {
      var css_class =3D "";
    	if (params.tabs[i].cssClass) {
    	  css_class +=3D params.tabs[i].cssClass;
    	}
    	if (params.tabs[i].isSelected) {
    	  css_class +=3D css_class ? " selected" : "selected";
    	}
    	params.tabs[i].cssClass =3D css_class;
    }
    this.setInfoHtml(resource.toString(),
                     this.static_.MAIN_HEADER,
                     this.static_.CENTER);
  }
};

class$.updateInfoHtml =3D function (theId, theHtmlCode) {
  if (this.infoHtmlCtr_) {
    this.infoHtmlQueue_.push([theId, theHtmlCode]);
  }
  else {
    $("info_container_" + theId).update(theHtmlCode);
  }
};

class$.setInfoHtml =3D function (theHtmlCode, theType, theAlignment) {
  this.infoHtml_[theType + "_" + theAlignment].push('<span =
id=3D"info_container_' + this.infoHtmlCtr_ + '">' +
                                                    (theHtmlCode || "") =
+ '</span>');
  return this.infoHtmlCtr_ ++;
};

class$._updateInfoHtml =3D function () {
 =20
  function _handleContainer(theContainerId, theQueue) {
    if (theQueue.length) {
      $(theContainerId).update(theQueue.join("\n"));
      $(theContainerId).show();
      theQueue.length =3D 0;
      return 1;
    }
    else {
      $(theContainerId).hide();
      return 0;
    }
  }

  function _handleContainerContainer(theContainerId, theChildCount) {
    if (theChildCount > 0) {
      $(theContainerId).show();
    }
    else {
      $(theContainerId).hide();
    }
  }

  _handleContainerContainer("mainframeHeader",
                            _handleContainer("mainframeHeaderTop", =
this.infoHtml_.HEADER_TOP) +
                            _handleContainer("mainframeHeaderLeft", =
this.infoHtml_.HEADER_LEFT) +
                            _handleContainer("mainframeHeaderCenter", =
this.infoHtml_.HEADER_CENTER) +
                            _handleContainer("mainframeHeaderRight", =
this.infoHtml_.HEADER_RIGHT) +
                            _handleContainer("mainframeHeaderBottom", =
this.infoHtml_.HEADER_BOTTOM));

  _handleContainerContainer("mainframeFooter",
                            _handleContainer("mainframeFooterLeft", =
this.infoHtml_.FOOTER_LEFT) +
                            _handleContainer("mainframeFooterCenter", =
this.infoHtml_.FOOTER_CENTER) +
                            _handleContainer("mainframeFooterRight", =
this.infoHtml_.FOOTER_RIGHT));

  _handleContainerContainer("headerContainer",
                            _handleContainer("headerContainerLeft", =
this.infoHtml_.MAIN_HEADER_LEFT) +
                            _handleContainer("headerContainerCenter", =
this.infoHtml_.MAIN_HEADER_CENTER) +
                            _handleContainer("headerContainerRight", =
this.infoHtml_.MAIN_HEADER_RIGHT));

  _handleContainerContainer("footerContainer",
                            _handleContainer("footerContainerLeft", =
this.infoHtml_.MAIN_FOOTER_LEFT) +
                            _handleContainer("footerContainerCenter", =
this.infoHtml_.MAIN_FOOTER_CENTER) +
                            _handleContainer("footerContainerRight", =
this.infoHtml_.MAIN_FOOTER_RIGHT));

  this.infoHtmlCtr_ =3D 0;
  while (this.infoHtmlQueue_.length) {
    this.updateInfoHtml.apply(this, this.infoHtmlQueue_.shift());
  }
  this.fitFrameSet();
};

class$.switchEditMode =3D function () {
  var new_edit_mode_str =3D encodeURIComponent(this.isEditMode() ? =
"EDIT_MODE:no" : "EDIT_MODE:yes");

  function _switchEditModeInUserVars(theUserVars) {
    var user_vars =3D theUserVars ? theUserVars.split(":") : [];

    var found_edit_mode =3D false;
    user_vars.each(function (aUserVar, i) {

        var a_user_var =3D decodeURIComponent(aUserVar).split(":");
        if (a_user_var[0] =3D=3D "EDIT_MODE") {
          found_edit_mode =3D true;

          user_vars[i] =3D new_edit_mode_str;
        }
      });

    if (!found_edit_mode) {
      user_vars.push(new_edit_mode_str);
    }

    return user_vars.join(":");
  }

  function _switchEditModeInCookieValue(theCookieValue) {
    var hw_session =3D theCookieValue ? theCookieValue.split(",") : [];

    var found_user_vars =3D false;
    for (var i =3D 0; i < hw_session.length; i ++) {
      var idx =3D hw_session[i].indexOf("=3D");
      var key =3D hw_session[i].substr(0, idx);
      var val =3D hw_session[i].substr(idx + 1);

      if (key =3D=3D "USERVARS") {
        found_user_vars =3D true;
        hw_session[i] =3D "USERVARS=3D" + =
_switchEditModeInUserVars(val);
      }
    }

    if (!found_user_vars) {
      hw_session.push("USERVARS=3D" + _switchEditModeInUserVars(""));
    }

    return hw_session.join(",");
  }

  var match =3D =
document.cookie.match(/(?:^|\s|\;)HyperwaveSession\=3D([^\;]+)/);
  var cookie =3D _switchEditModeInCookieValue(match ? match[1] : "");

  var expires =3D new Date();
  expires.setFullYear(expires.getFullYear() + 5);
  document.cookie =3D "HyperwaveSession=3D" + cookie + =
";path=3D/;expires=3D" + expires.toGMTString();
  // see also "reloadframe.xml"

  try {

    with (HW_Mainframe) {
      var code =3D ["<html>",
                  "<head><title>...</title>",
                  "<script>",
                  "onbeforeunload =3D function () { =
parent.parent.FrameSetMediator.static_.getInstance()._switchEditMode3(); =
};",
                  "onload =3D function () { =
parent.parent.FrameSetMediator.static_.getInstance()._switchEditMode2(); =
};",
                  "</script>",
                  "</head>",
                  "<body",
                  " =
onload=3D'parent.parent.FrameSetMediator.static_.getInstance()._switchEdi=
tMode2();'",
                  " =
onbeforeunload=3D'parent.parent.FrameSetMediator.static_.getInstance()._s=
witchEditMode3();'>...</body>",
                  "</html>"];
 =20
      var iframe =3D document.createElement("iframe");
      iframe.setAttribute("id", "switchToEditModeTester");
      iframe.setAttribute("src", 'javascript:"' + =
escapeString(code.join("\n")) + '"');
      iframe.style.position =3D "absolute";
      iframe.style.top =3D "0px";
      iframe.style.left =3D "0px";
      iframe.style.width =3D "0px";
      iframe.style.height =3D "0px";
      iframe.style.visibility =3D "hidden";
      document.body.appendChild(iframe);
    }

  }
  catch (ex) {
    this._switchEditMode2();
    this._switchEditMode3();
  }
};

class$._switchEditMode2 =3D function () {
  this.switchEditModeCancelled_ =3D false;

  if (top.isAlternativeCluster) {
    if (this.isEditMode()) {
      this.switchEditModeCancelled_ =3D true;
      HW_Mainframe.location.replace(hw.util.Url.static_.getUrl({window: =
HW_Mainframe,
                                                          action: =
"image",
                                                          parameters: =
{cachekeY: new Date().getTime()}}));
    }
    else {
      this.switchEditModeCancelled_ =3D true;
      HW_Mainframe.location.replace(hw.util.Url.static_.getUrl({window: =
HW_Mainframe,
                                                          parameters: =
{cachekeY: new Date().getTime()}}));
    }
  }
  else if (top.isHyperwaveDocument) {
    this.switchEditModeCancelled_ =3D true;
    var action =3D =
hw.util.Url.static_.parseUrl(HW_Mainframe.location.href).action;
    action =3D action =3D=3D "forcetemplates.action" || action =3D=3D =
"image.action" ? action : "";
    HW_Mainframe.location.replace(hw.util.Url.static_.getUrl({window: =
HW_Mainframe,
                                                        action: action,
                                                        parameters: =
{cachekeY: new Date().getTime()}}));
  }
  else {
    this.applyEditMode();
  }

  if (this.switchEditModeCancelled_) {
  	HW_Mainframe.focus();
    try {
      with (HW_Mainframe) {
        =
document.body.removeChild(document.getElementById("switchToEditModeTester=
"));
      }
    }
    catch (ex) {
      // ignore me
    }
  }
};

class$._switchEditMode3 =3D function () {
  this.getFramework().getDisplayManager().lock();
  this.lock_ =3D true;
  this.switchEditModeCancelled_ =3D false;
};

class$.applyEditMode =3D function () {
  if (this.isEditMode()) {
    top.editmode =3D true;
    $(document.body).addClassName("isEditMode");
    $(document.body).removeClassName("isViewMode");
  }
  else {
    top.editmode =3D false;
    $(document.body).removeClassName("isEditMode");
    $(document.body).addClassName("isViewMode");
  }

  if (this.lock_) {
    this.lock_ =3D false;
    this.getFramework().getDisplayManager().unlock();
  }
};

class$.isEditMode =3D function () {
  // get the value of hyperwave session cookie (client[...])
  var match =3D =
document.cookie.match(/(?:^|\s|\;)HyperwaveSession\=3D([^\;]*)/);
  if (match) {
    match =3D match[1];
  }
  else {
    return false;
  }

  // now get the user vars
  match =3D match.match(/(?:^|\,)USERVARS\=3D([^\,]*)/);
  if (match) {
    match =3D match[1];
  }
  else {
    return false;
  }

  var is_edit_mode =3D false;
  match.split(":").each(function (theVar) {
      var the_var =3D decodeURIComponent(theVar);
      if (the_var =3D=3D "EDIT_MODE:yes") {
        is_edit_mode =3D true;
      }
    });
  return is_edit_mode;
};

class$.getApplicationView =3D function () {
  var view =3D {
    window: HW_Mainframe
  };
 =20
  view.refresh =3D function () {
    HW_Mainframe.location.replace(HW_Mainframe.location.href);
  };
 =20
  view.replace =3D function (theUrl) {
    HW_Mainframe.location.replace(theUrl);
  };
 =20
  view.navigate =3D function (theUrl) {
    HW_Mainframe.location.href =3D theUrl;
  };
 =20
  return view;
};

class$.getCurrentObjectIdentifier =3D function () {
  return decodeURIComponent(this.getCurrentUrl().replace(/^\//, "")) || =
"/";
};

class$.getCurrentUrl =3D function () {
  var path =3D "/";
  var frameset =3D false;
  try {
    var win =3D window;
    if (top.HW_Mainframe) {
      win =3D top.HW_Mainframe;
      frameset =3D true;
    }
    path =3D win.location.pathname;

    if (frameset) {
      // in case of main frameset, try to get the url from the global =
var out of the main frame
      // normaly this fails in case of generic documents -> see above =
... get it from location.pathname
      try {
        if (win.gCurrentUrl) {
          path =3D win.gCurrentUrl;
        }
      } catch (e2) {

      }
    }
  }
  catch (e) {
    path =3D getCookie("HW_MainframeUrl") || "/";
  }

  path =3D path.match(/^(.*?)[\;\?\#].*$/) ? RegExp.$1 : path;
  return path || "/";
};

class$.getSelectedObjects =3D function () {
  var ret_arr =3D [];
  if (top.gListing) {
    ret_arr =3D top.gListing.getSelectedObjects();
  }
  if (ret_arr.length =3D=3D 0) {
    try {
      if (top.gListingMediator && typeof =
top.gListingMediator.getSelectedObjects =3D=3D "function") {
        ret_arr =3D top.gListingMediator.getSelectedObjects();
      }
    }
    catch (e) { ret_arr =3D []; }
  }
  if (ret_arr.length =3D=3D 0) {
    // check whether it is a document view
    if (HW_Mainframe &&
        HW_Mainframe.document &&
        HW_Mainframe.document.bodyform &&
        HW_Mainframe.document.bodyform.docname &&
        HW_Mainframe.document.bodyform.docname.value) {
      var goid =3D HW_Mainframe.document.bodyform.docname.value;
      if (top.gObjectCache &&
          top.gObjectCache.getObject(goid)) {
        ret_arr[ret_arr.length] =3D top.gObjectCache.getObject(goid);
      }
    }
  }
  return ret_arr;
};
// </JSClass>


------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSBreadCrumbing.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        BreadCrumbing.js=0A=
 *  Created:     2001-02-01 by akuntner=0A=
 *  Description: Definition of the CSBreadCrumbing class=0A=
 *  $Id: CSBreadCrumbing.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * A class representing a Breadcrumbing line. It basically consists of =
an array=0A=
 * (representing the path) containing objects (representing path =
entries) which hold the Goid and=0A=
 * Title of collections and methods that can be used to manipulate and =
render the Breadcrumbing line.=0A=
 * Public methods of the BreadCrumbing class:=0A=
 *   getPath ()=0A=
 *   setPath (aPath)=0A=
 *   addPathEntry (aGoid, aTitle)=0A=
 *   cutPathEntry (aPosition)=0A=
 *   render ()=0A=
 *   containerHTML (divName, imageName, classReference)=0A=
 *=0A=
 *  =3D=3D=3D=3D=3D=3D Usage =3D=3D=3D=3D=3D=3D=3D=0A=
 *=0A=
 * Preconditions: The scripts =
"wavemaster.internal/lib/base/v1.x/lang/ojs.js" and=0A=
 *   wavemaster.internal/webapp/lib/CSBreadCrumbing.js" should be =
present on the client side. In the=0A=
 *   standard Janus (HIS 6.0) user interface they're already present in =
the frame top !=0A=
 *=0A=
 * Basic Concept: =0A=
 *   On the SS: =0A=
 *     Insert an image in the HTML code (with height, width and Name =
properties) at the place the =0A=
 *     Breadcrumbing line should appear, then insert the HTML code =
returned by the call of the =0A=
 *     static method "containerHTML" (with =
"CSBreadCrumbing.static_.containerHTML(...params...)") =0A=
 *     to create an absolute DIV that overlays this image.=0A=
 *     This generally works fine with both MSIE and Netscape browsers, =
but the position of the=0A=
 *     breadcrumbing line can be changed dynamically (after it was =
already positioned) by MSIE in=0A=
 *     some cases (Portal: A dynamic track gets new (larger/smaller) =
content, all the other tracks=0A=
 *     (probably using the Breadcrumbing feature like the Advanced =
Folder Viewer Track) are=0A=
 *     repositioned...). If such a case can occur, one should slightly =
adapt the procedure described=0A=
 *     above: Put <DIV> tags around the image in case of MSIE. Only use =0A=
 *     "CSBreadCrumbing.static_.containerHTML(...params...)" as =
described above in case of Netscape.=0A=
 *     In case of MSIE don't use this method, instead give the DIV an =
id=3D"divName"+"0", where divName=0A=
 *     is the same string as provided in the "divName" parameter of the =
containerHTML(..params..) call=0A=
 *     in case of Netscape. When providing the parameter "container" in =
the instantiation of the=0A=
 *     Breadcrumbing class, also use the reference to this "normal" div =
in case of MSIE. Important:=0A=
 *     Both in Netscape and MSIE the *real* DIVs have names with some =
numbers at the end, like=0A=
 *     "BCContainer0", that's why the id of the MSIE DIV has to be =
"divName"+"0", but when specifying=0A=
 *     the name or reference to such a div, leave away the number. - It =
is handled dynamically by the=0A=
 *     class and normally you shouldn't ever notice that there are =
numbers attached (we attach numbers=0A=
 *     because in Netscape we actually create several DIVs which we =
alternatively use in order to=0A=
 *     work around a serious Netscape bug under Unix operating systems.)=0A=
 *   On the CS:=0A=
 *     Instantiate the Breadcrumbing class, specifying the target =
DIV/Layer and a callback function =0A=
 *     that should be called when user clicks on a Breadcrumbing entry. =
Then use the public methods =0A=
 *     mentioned above to change the Breadcrumbing line data structure =
(=3D"path") and call render()=0A=
 *     whenever the Breadcrumbing line should be updated.=0A=
 *=0A=
 * @author akuntner=0A=
 */=0A=
// <JSClass Name=3D"CSBreadCrumbing">=0A=
  /**=0A=
   * The CSBreadCrumbing constructor.=0A=
   *=0A=
   * @param aParam: Object: a parameter object=0A=
   * @param aParam.path: Array|void: Array of objects =
{goid:xxx,title:xxx} which represent path entries.=0A=
   * @param aParam.container: String: A string containing the reference =
to a DIV. This "container" is=0A=
   *   used to display the Breadcrumbing line in. The string should look =
like "aaa.bbb.ccc", but not like=0A=
   *   "aaa[bbb]", meaning: The path shouldn't be described using "[]", =
only with ".".=0A=
   * @param aParam.onSelectFunction: String: A string containing the =
reference to the external function=0A=
   *   that should be called if user clicks on an entry of the =
Breadcrumbing line. The external=0A=
   *   function gets three parameters: The reference to the =
Breadcrumbing instance (=3D"this"), the=0A=
   *   Position of the clicked entry in the path and the GOid of the =
clicked entry. Example of such an=0A=
   *   onSelectFunction: "function myOnSelect(theBreadInstance, =
thePosition, theGoid)=0A=
   *   { theBreadInstance.cutPath(thePosition); =
theBreadInstance.render()}=0A=
   * @param entryResource: String: The Resource (HTML code) for an =
entry, ($entry) should be used as=0A=
   *   placeholder for the entry Title in there, ($entryAbbr) for an =
abbreviated entry (using the =0A=
   *   specified maxEntryLength value to cut it off...)=0A=
   * @param separationResource: String: The Resource (HTML code) for the =
"separation" item (normally ">")=0A=
   * @param previousResource: String: The Resource (HTML code) for the =
"previous" item (could be "...")=0A=
   * @param noPreviousResource: String: The Resource (HTML code) in case =
there is no need to=0A=
   *   display a "previous" link. (Could be a grayed out version (or =
totally invisinble) of=0A=
   *   previousResource without a link)=0A=
   * @param lastEntryResource: String | void: The Resource (HTML code) =
for the last entry in the=0A=
   *   Breadcrumbing line, ($entry) should be used as placeholder for =
the entry Title in there, =0A=
   *   ($entryAbbr) for an abbreviated entry (using the specified =
maxEntryLength value to cut =0A=
   *   it off...). This normally isn't a link, whereas entryResource =
normally is.=0A=
   * @param nextResource: String | void: The Resource (HTML code) for =
the "next" item (could be "...")=0A=
   * @param noNextResource: String | void: The Resource (HTML code) in =
case there is no need to display=0A=
   *   a "next" link. (Could be a grayed out version (or totally =
invisible) of nextResource without a link)=0A=
   * @param aParam.maxEntryLength: Integer | void: The maximum length =
the title part of a path entry=0A=
   *   cannot exceed. If it does, it's abbreviated with "..." at the =
end. So if maxEntryLength_=3D=3D15,=0A=
   *   "very_long_title_there" becomes "very_long_title..."=0A=
   * @param aParam.maxEntries: Integer | void: The number of entries =
that are displayed in the=0A=
   *   Breadcrumbing line. If there are 6 entries and maxEntries=3D=3D5, =
5 entries plus a "next" link=0A=
   *   (Resource) is displayed.=0A=
   * @param aParam.entryAbbreviation: String | void: The abbreviation =
string used when entry title=0A=
   *   gets too long.=0A=
   */=0A=
  function CSBreadCrumbing (aParam)=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    var par =3D aParam || {};=0A=
=0A=
    this.path_ =3D par.path || [];=0A=
    this.container_ =3D par.container;=0A=
    this.onSelectFunction_ =3D par.onSelectFunction;=0A=
    this.entryResource_ =3D par.entryResource;=0A=
    this.separationResource_ =3D par.separationResource;=0A=
    this.previousResource_ =3D par.previousResource;=0A=
    this.noPreviousResource_ =3D par.noPreviousResource;=0A=
=0A=
    this.lastEntryResource_ =3D par.lastEntryResource || =
par.entryResource;=0A=
    this.nextResource_ =3D par.nextResource || par.previousResource;=0A=
    this.noNextResource_ =3D par.noNextResource || =
par.noPreviousResource;=0A=
    this.maxEntryLength_ =3D par.maxEntryLength || 15;=0A=
    this.maxEntries_ =3D par.maxEntries || 5;=0A=
    this.entryAbbreviation_ =3D par.entryAbbreviation || "...";=0A=
=0A=
    // Is true if the lastEntryResource is a link (contains "<A =
HREF...>")=0A=
    this.lastEntryisLink_ =3D =
this.lastEntryResource_.search(/<A\s+.*HREF.*>/i) !=3D -1;=0A=
=0A=
    // The index/position of the first entry to render=0A=
    this.firstEntryIndex_=3D0;=0A=
=0A=
    // This member is used to temporarily store the content that has to =
be written. =0A=
    this.content_ =3D "";=0A=
    // Set unique instance identifier=0A=
    this.instanceId_ =3D this.static_.instanceCounter_++;=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSBreadCrumbing);=0A=
=0A=
  // Instance counter=0A=
  class$.static_.instanceCounter_ =3D 0;=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Returns the content of the member variable path_.=0A=
   *=0A=
   * @return: Array: an array of objects {goid:xxx,title:xxx}, each =
object containing the goid and title for=0A=
   * one path entry (=3D a collection)=0A=
   */=0A=
  class$.getPath =3D function ()=0A=
  {=0A=
    return this.path_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Sets the member variable path_=0A=
   *=0A=
   * @param aPath: Array: An array of objects {goid:xxx,title:xxx}, each =
object containing the goid and=0A=
   * title for one path entry (=3D a collection)=0A=
   */=0A=
  class$.setPath =3D function (aPath)=0A=
  {=0A=
    this.path_ =3D aPath || [];=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Adds an new entry at the end of the path_=0A=
   *=0A=
   * @param aGoid: String: a regular HW Goid=0A=
   * @param aTitle: String: the title of a collection=0A=
   */=0A=
  class$.addPathEntry =3D function (aGoid, aTitle)=0A=
  {=0A=
    this.path_[this.path_.length] =3D {goid:aGoid,title:aTitle};=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Cuts off an entry at the end of the path_=0A=
   *=0A=
   * @param aPosition: Integer: the position (index) number of the entry =
in the path array.=0A=
   */=0A=
  class$.cutPathEntry =3D function (aPosition)=0A=
  {=0A=
    //bugfix PR-2233...array.slice sometimes doesn't exist/work.=0A=
    //this.path_ =3D this.path_.slice(0, aPosition+1);// throwing away =
rest of array after current position=0A=
    var hlp_arr=3D[];=0A=
    var end =3D aPosition + 1;=0A=
    for (var count=3D0; count<end; count++)=0A=
      hlp_arr[hlp_arr.length] =3D {goid:this.path_[count].goid, =
title:this.path_[count].title};=0A=
=0A=
    this.path_ =3D hlp_arr;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This is the method that is called when user clicks on a =
Breadcrumbing entry.=0A=
   *=0A=
   * @param aPosition: Integer: the position (index) of the selected =
entry in the path array=0A=
   * @param aGoid: String: a regular HW Goid, specifying the entry=0A=
   *=0A=
   */=0A=
  class$.doOnSelectEntry =3D function (aPosition, aGoid)=0A=
  {=0A=
    eval(this.onSelectFunction_+"(this, aPosition, aGoid)");=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This private method takes the title of the entry specified with =
"index" and=0A=
   * returns the (possibly abbreviated) string to display in the =
Breadcrumbing line.=0A=
   *=0A=
   * @param index: integer: The index of the entry in the path_=0A=
   * @return : string: The string to display in the Breadcrumbing line=0A=
   */=0A=
  class$._abbreviatedTitle =3D function (index)=0A=
  {=0A=
    var entry=3Dthis.path_[index].title || this.path_[index].T || =
this.path_[index].goid || this.path_[index].G;=0A=
=0A=
    if (entry.length > this.maxEntryLength_)=0A=
      return =
(entry.substring(0,this.maxEntryLength_)+this.entryAbbreviation_);=0A=
    else=0A=
      return entry;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method is called when user clicks on previous/next "..." links=0A=
   *=0A=
   * @param kind: string: Is either "previous" or "next"=0A=
   */=0A=
  class$.previousNext =3D function (kind)=0A=
  {=0A=
    if (kind=3D=3D"previous")=0A=
      this.firstEntryIndex_ =3D Math.max(0, (this.firstEntryIndex_ - =
this.maxEntries_));=0A=
    else=0A=
      this.firstEntryIndex_ =3D Math.min((this.path_.length - =
this.maxEntries_), (this.firstEntryIndex_ + this.maxEntries_));=0A=
=0A=
    this.writePathHTML();=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Writes the given content into the container.=0A=
   *=0A=
   * @return: Pointer: The reference to the links object.=0A=
   */=0A=
  class$.writeIntoContainer =3D function ()=0A=
  {=0A=
    // Test if the first part of the div reference is valid=0A=
    var steps =3D this.container_.split(".");=0A=
    var container_ref =3D eval(steps[0]);=0A=
    if (typeof container_ref =3D=3D "undefined")=0A=
      return false; // reference is not valid=0A=
    =0A=
    // now construct the div reference step by step, always checking if =
it's valid, but stop=0A=
    // one step in front of the DIV.=0A=
    for (var count=3D1; count<steps.length-1; count++)=0A=
    {=0A=
      container_ref =3D container_ref[steps[count]]; //try next step=0A=
      if (typeof container_ref =3D=3D "undefined")=0A=
        return false; // reference is not valid=0A=
    }=0A=
=0A=
    reference_to_div =3D container_ref; //keep reference to parent (in =
the DOM) of the DIV=0A=
=0A=
    // "container" looks like "top.HW_Staticframe.document.BCContainer". =
A number has to=0A=
    // be added to the divname ("BCContainer") to get the reference to =
the real DIV(s).=0A=
    var layer_number =3D 0;=0A=
    var new_div_name =3D steps[steps.length-1] + layer_number;=0A=
=0A=
    container_ref =3D container_ref.getElementById(new_div_name); //try =
full reference to DIV=0A=
    if (!container_ref)=0A=
      return false; // reference is not valid=0A=
=0A=
    =0A=
    // *** We've got all our references now, so we actually write the =
new content ***=0A=
    container_ref.innerHTML =3D this.content_;=0A=
    var links =3D container_ref.getElementsByTagName("a");=0A=
    return links;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Clears the Breadcrumbing line.=0A=
   */=0A=
  class$.clear =3D function ()=0A=
  {=0A=
    this.content_ =3D "";=0A=
    var success =3D this.writeIntoContainer();=0A=
=0A=
    if (!success) // if not successful, try again later=0A=
    {=0A=
      var this_ =3D this;=0A=
      function clearHandler()=0A=
      {=0A=
        this_.clear();      =0A=
      }=0A=
      =0A=
      var handler_name =3D "clearHandler_"+this.instanceId_;=0A=
      window[handler_name] =3D clearHandler;=0A=
      setTimeout(handler_name+"()",300);=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Displays the current path (stored in path_) in the specified =
container=0A=
   */=0A=
  class$.render =3D function ()=0A=
  {=0A=
    this.firstEntryIndex_ =3D Math.max(0, (this.path_.length - =
this.maxEntries_));=0A=
    this.writePathHTML();=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method writes the actual HTML for the Breadcrumbing line=0A=
   */=0A=
  class$.writePathHTML =3D function ()=0A=
  {=0A=
    var entry_title;=0A=
    var bread_str =3D [];=0A=
    var last_index =3D Math.min(this.path_.length, =
(this.firstEntryIndex_ + this.maxEntries_));=0A=
    var previous =3D this.firstEntryIndex_ !=3D 0;=0A=
    var next =3D last_index !=3D this.path_.length;=0A=
    var nonLinkIndex=3Dthis.path_.length-1;=0A=
=0A=
    // Adding "previous" link at beginning of Breadcrumbing line if =
necessary=0A=
    if (previous)=0A=
      bread_str[bread_str.length] =3D this.previousResource_;=0A=
    else=0A=
      bread_str[bread_str.length] =3D this.noPreviousResource_;=0A=
=0A=
    var first_entry =3D true;=0A=
=0A=
    // inserting entries (links)=0A=
    for (var counter =3D this.firstEntryIndex_; counter < last_index; =
counter++)=0A=
    {=0A=
      if (first_entry)=0A=
        first_entry =3D false;=0A=
      else  // add separator=0A=
        bread_str[bread_str.length] =3D this.separationResource_;=0A=
=0A=
      if (counter =3D=3D nonLinkIndex) // if last entry of path -> write =
normal entry (no link !)=0A=
        entry_title =3D this.lastEntryResource_;=0A=
      else // write link entry=0A=
        entry_title =3D this.entryResource_;=0A=
=0A=
      bread_str[bread_str.length] =3D =
entry_title.replace(/\(\$entryAbbr\)/g, =
this._abbreviatedTitle(counter)).replace(/\(\$entry\)/g, =
this.path_[counter].title || this.path_[counter].T || =
this.path_[counter].goid || this.path_[counter].G);=0A=
    }=0A=
=0A=
    // Adding "next" link at end of Breadcrumbing line if necessary.=0A=
    if (next)=0A=
      bread_str[bread_str.length] =3D this.nextResource_;=0A=
    else=0A=
      bread_str[bread_str.length] =3D this.noNextResource_;=0A=
    =0A=
    // Write dummy link for later finding out where our links are =
inserted=0A=
    var bread_dummy =3D "bread_dummy_" + this.instanceId_;=0A=
    bread_str[bread_str.length] =3D '<A HREF=3D"javascript:void (0);" =
type=3D"'+bread_dummy+'"></A>';=0A=
=0A=
    // storing content in instance variable=0A=
    this.content_ =3D bread_str.join("");=0A=
=0A=
    // Writing content into the container=0A=
    var this_ =3D this;=0A=
    var the_links =3D this.writeIntoContainer();=0A=
=0A=
    if (!the_links) // if not successful, try again later=0A=
    {=0A=
      function writePathHTMLHandler()=0A=
      {=0A=
        this_.writePathHTML();      =0A=
      }=0A=
      =0A=
      var handler_name =3D "writePathHTMLHandler_"+this.instanceId_;=0A=
      window[handler_name] =3D writePathHTMLHandler;=0A=
      setTimeout(handler_name+"()",300);=0A=
    }=0A=
    else // successful, now continue with onlick settings...=0A=
    {  =0A=
      // ********** Writing the ONCLICK ASSIGNMENTS **********=0A=
      for (var count=3Dthe_links.length-1; count > 0; count--) {=0A=
        if (the_links[count].type =3D=3D bread_dummy)=0A=
        {=0A=
          var link_count =3D count-1;=0A=
          break;=0A=
        }=0A=
      }=0A=
=0A=
      // Adding onclick for "next" link at end of Breadcrumbing line if =
necessary.=0A=
      if (next)=0A=
      {=0A=
        the_links[link_count].onclick =3D function () =
{this_.previousNext('next'); return false;};=0A=
        link_count--;=0A=
      }=0A=
=0A=
      // Adding onclick for the entries.=0A=
      for (var counter =3D last_index-1; counter >=3D =
this.firstEntryIndex_; counter--)=0A=
      {=0A=
        if (counter !=3D nonLinkIndex || this.lastEntryisLink_) // =
setting onclick only for link entries=0A=
        {=0A=
          eval("function onClickHandler"+counter+"() =
{this_.doOnSelectEntry("+counter+",'"+(this.path_[counter].goid || =
this.path_[counter].G)+"'); return false;}");=0A=
          the_links[link_count].onclick =3D =
eval("onClickHandler"+counter);=0A=
          link_count--;=0A=
        }=0A=
      }=0A=
=0A=
      // Adding onclick for "previous" link at beginning of =
Breadcrumbing line if necessary.=0A=
      if (previous)=0A=
      {=0A=
        the_links[link_count].onclick =3D function () =
{this_.previousNext('previous'); return false;};=0A=
      }=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This static method returns HTML code (in a string). It contains =
absolute DIV(s)=0A=
   * and by calling the static method "doPositionDiv" onload resizes and =
positions this (these)=0A=
   * DIV(s) so that it (they) exactly overlay a specified image. Since =
this HTML string also contains=0A=
   * Javascript, this static method has to be called on the SS (because =
Netscape cannot handle=0A=
   * writing JS code with document.writeln). Note: This function should =
be used in case of Netscape,=0A=
   * but not necessarily with MSIE...see general "Usage" description of =
the class for more details.=0A=
   *=0A=
   * @param divName: String: The id/name of the DIV=0A=
   * @param imageName: String: The name of the image that should be =
overlayed.=0A=
   * @param classReference: String: The reference to the BreadCrumbing =
class instance.=0A=
   * @param offset: Object | void=0A=
   * @param offset.top: Integer | void: Vertical indentation (=3D The =
number of pixels the layer=0A=
   *   should be placed lower, relative to the image position.)=0A=
   * @param offset.left: Integer | void: Horizontal indentation (=3D The =
number of pixels the layer=0A=
   *   should be placed more to the right, relative to the image =
position.)=0A=
   * @param layerQuantity: integer | void: The number of layers that =
should be used to display=0A=
   *   the Breadcrumbing line in case of Netscape. A crash can occur =
when a layer contains links and on=0A=
   *   click of one of those links the layer is rewritten in Netscape =
browsers (especially in Unix).=0A=
   *   It's even worse, Netscape layers need some "rest" after a =
link-click, that's why several layers=0A=
   *   are used. Default is 20.=0A=
   *=0A=
   * @return String: The HTML string to insert in the HTML flow (usually =
following the image...)=0A=
   */=0A=
  class$.static_.containerHTML =3D function (divName, imageName, =
classReference, offset, layerQuantity)=0A=
  {=0A=
    var the_offset =3D offset || {};=0A=
    var topoff =3D the_offset.top || 0;=0A=
    var leftoff =3D the_offset.left || 0;=0A=
    var layer_quantity =3D layerQuantity || 20;=0A=
    var div_parent;=0A=
=0A=
    // create first (and in case of MSIE only) DIV with id =3D =
divname+"0"=0A=
    retarr =3D ['<DIV ID=3D"'+divName+'0" =
STYLE=3D"visibility:visible;white-space:nowrap;position:absolute; =
z-index:3"></DIV>'];=0A=
=0A=
    div_parent =3D "document";=0A=
    var onload_func_name =3D divName + "_onload";=0A=
=0A=
    retarr[retarr.length] =3D '<SCRIPT'+'>var =
'+onload_func_name+'=3Dwindow.onload; window.onload=3Dfunction() {';=0A=
    retarr[retarr.length] =3D =
classReference+'.static_.doPositionDiv('+div_parent+', "'+divName+'", =
document.'+imageName+',';=0A=
    retarr[retarr.length] =3D topoff+','+leftoff+');';=0A=
    retarr[retarr.length] =3D 'if (typeof =
'+onload_func_name+'=3D=3D"function") =
'+onload_func_name+'();};<'+'/SCRIPT>';=0A=
    window_debug("static_.containerHTML: "+retarr.join('\n'));=0A=
    return retarr.join('\n');=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This static method resizes and positions the specified DIV(s) so =
that it (they)  exactly overlay=0A=
   * a specified image. Normally this method is only used by the static =
method "containerHTML".=0A=
   *=0A=
   * @param divParentReference: Reference: The reference to the parent =
object (in the DOM) of the DIV =0A=
   * @param divName: String: The id/name of the DIV=0A=
   * @param imageReference: Reference: The reference to the image that =
should be overlayed.=0A=
   * @param topOff: Integer: Vertical indentation (=3D The number of =
pixels the layer should be placed=0A=
   *   lower, relative to the image position.)=0A=
   * @param leftOff: Integer: Horizontal indentation (=3D The number of =
pixels the layer should be placed=0A=
   *   more to the right, relative to the image position.)=0A=
   */=0A=
  class$.static_.doPositionDiv =3D function (divParentReference, =
divName, imageReference, topOff, leftOff)=0A=
  {=0A=
    /**=0A=
     * returns the offset of a HTML element relative to the left-top, =
MSIE only.=0A=
     */=0A=
    function computeOffset(elem,kind)=0A=
    {=0A=
      var off=3Delem[kind];=0A=
      while ((elem=3Delem.offsetParent)!=3D"undefined")=0A=
      {=0A=
        if (elem.tagName=3D=3D"BODY") break;=0A=
        off+=3Delem[kind];=0A=
      }=0A=
      return off;=0A=
    }=0A=
    =0A=
    var div_reference =3D =
divParentReference.getElementById(divName+"0"); //reference to first DIV=0A=
    div_reference.style.top =3D computeOffset(imageReference, =
"offsetTop") + topOff;=0A=
    div_reference.style.left =3D computeOffset(imageReference, =
"offsetLeft") + leftOff;=0A=
    if (document.all && =
navigator.platform.toLowerCase().indexOf('mac')!=3D-1) {  // mac needs =
the height of the image=0A=
      div_reference.style.height =3D imageReference.height;=0A=
    }=0A=
  };=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSScroller.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSScroller=0A=
 *  Created:     2003-10-08 by akuntner=0A=
 *  Description: Client side class "CSScroller"=0A=
 *=0A=
 *  $Id: CSScroller.js 164655 2011-06-28 09:47:02Z sweber $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The class CSScroller offers methods to add html content into a div and=0A=
 * scroll it. The entries can always be added with the help of the =
methods addElements()=0A=
 * or addElement(), initial elements can also be added by putting span =
elements into the=0A=
 * container div. The span elements will be removed, the content of the =
spans will be=0A=
 * added as elements.=0A=
 *=0A=
 * Public methods of the CSScroller class:=0A=
 *  Static:=0A=
 *     create() - use this static method to create a new instance, don't =
use the constructor !=0A=
 *  Dynamic:=0A=
 *     scrollToStart()=0A=
 *     scrollToEnd()=0A=
 *     scrollLeft()=0A=
 *     scrollRight()=0A=
 *     scrollLeftPossible()=0A=
 *     scrollRightPossible()=0A=
 *     render()=0A=
 *     addElements()=0A=
 *     addElement()=0A=
 *     removeAllElements()=0A=
 */=0A=
// <JSClass Name=3D"CSScroller">=0A=
  /**=0A=
   * The CSScroller constructor.=0A=
   *=0A=
   * @param par: Object: A parameter object=0A=
   * @param par.window: Window reference | void: The reference to the =
window the scroller resides in.=0A=
   *   Default is the window where the CSScroller.js script file is =
included.=0A=
   * @param par.containerId: String: The id of the container <div> =
element where the scroller will live in.=0A=
   * @param par.alignment: String | void: The alignment of the scroller =
at startup. Possible values are "left" and=0A=
   *   "right", default is "right". Alignment "right" means that the =
scroller comes up in the most right position,=0A=
   *   the most right entry is fully visible.=0A=
   * @param par.minVisible: Integer | void: A value between 0 and 100. =
Default is 80. It is the percentage of an=0A=
   *   entry that has to be visible in order to be judged as "visible". =
Example: minVisible is 70%, the first/left=0A=
   *   entry is only partially displayed - only 43% of it is visible. =
Thus the a scrollLeft() call will scroll only=0A=
   *   a little bit to the left, until this entry is fully visible =
(100%). If however this entry would be 83% visible,=0A=
   *   it would be considered as "visible" and thus the scrollLeft() =
would scroll to the left until the entry before=0A=
   *   the 83% visible entry is fully visible.=0A=
   * @param par.onRenderCallback: function | void: A function which is =
called after the scoller has been rendered=0A=
   * @param par.stepSize: int | void:=0A=
   */=0A=
  function CSScroller (par)=0A=
  {=0A=
    if ( par =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    if (!par.callingFromCreate)=0A=
      throw 'Illegal CSScroller() constructor call. Use the static =
method "create()" instead.';=0A=
=0A=
    this.inline_ =3D par.inline !=3D=3D false;=0A=
    this.alignment_ =3D par.alignment || "right";=0A=
    this.minVisible_ =3D par.minVisible || 80;=0A=
    this.stepSize_ =3D par.stepSize || 1;=0A=
=0A=
    this.elements_ =3D [];=0A=
    this.firstVisibleElementIndex_ =3D 0;=0A=
    this.lastVisibleElementIndex_ =3D 0;=0A=
    this.firstPartialVisible_ =3D false;=0A=
    this.lastPartialVisible_ =3D false;=0A=
    this.currentContainerWidth_ =3D 0;=0A=
    this.onRenderCallback_ =3D par.onRenderCallback;=0A=
    =0A=
    // unique instance identifier=0A=
    this.instanceId_ =3D "CSScrollerInstance_" + =
this.static_.instanceCounter_++;=0A=
=0A=
    this._initialize(par, !par.ignoreInitialElements);=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSScroller);=0A=
=0A=
  // Static members and methods=0A=
  class$.static_.instanceCounter_ =3D 0;=0A=
  class$.static_.SCROLLER_ELEMENT_NAME =3D "SPAN";=0A=
  class$.static_.INSTANCES_CACHE =3D {};=0A=
=0A=
  /**=0A=
   * This method returns a CSScroller instance. This instance is either =
created or=0A=
   * taken out of a cache (if it has been created before).=0A=
   */=0A=
  class$.static_.create =3D function(aParam)=0A=
  {=0A=
    var par =3D aParam || {};=0A=
=0A=
    var thisWindow =3D aParam.window || window;=0A=
    var key =3D thisWindow.name + "." + aParam.containerId;=0A=
    var instance =3D CSScroller.static_.INSTANCES_CACHE[key];=0A=
    if (!instance)=0A=
    {=0A=
      // create new instance and put it into the cache=0A=
      par.callingFromCreate =3D true;=0A=
      instance =3D new CSScroller(par);=0A=
      CSScroller.static_.INSTANCES_CACHE[key] =3D instance;=0A=
    }=0A=
    else=0A=
    {=0A=
      instance._initialize(par, false);=0A=
    }=0A=
=0A=
    return instance;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.static_._setAttributes =3D function(element, attributes)=0A=
  {=0A=
    for (var attrName in attributes)=0A=
      element[attrName] =3D attributes[attrName];=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.static_._removeAllChildren =3D function(node)=0A=
  {=0A=
    var childNodes =3D node.childNodes;=0A=
    for (var i =3D childNodes.length-1; i >=3D 0; i--)=0A=
      node.removeChild(childNodes[i]);=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.static_.computeOffset =3D function(elem, kind)=0A=
  {=0A=
    var off=3Delem[kind];=0A=
=0A=
    while ((elem=3Delem.offsetParent) !=3D "undefined")=0A=
    {=0A=
      if (elem.tagName=3D=3D"BODY" || elem.tagName=3D=3D"HTML") break;=0A=
      off+=3Delem[kind];=0A=
    }=0A=
    return off;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.static_.callLater =3D function(par)=0A=
  {=0A=
    var this_ =3D par.instanceReference;=0A=
    function redirectorFunction()=0A=
    {=0A=
      this_[par.methodName]();=0A=
    }=0A=
=0A=
    var functionName =3D par.uniqueInstanceId + "_" + this.methodName;=0A=
    window[functionName] =3D redirectorFunction;=0A=
    setTimeout(functionName + "()", par.time);=0A=
  };=0A=
  //--------------------------------------------------------------------=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._initialize =3D function(par, doAddInitialElements)=0A=
  {=0A=
    // CSScroller is not yet ready=0A=
    this.isReady_ =3D false;=0A=
=0A=
    this.window_ =3D par.window || window;=0A=
    this.document_ =3D this.window_.document;=0A=
    this.currentAlignment_ =3D this.alignment_;=0A=
=0A=
    // fetch the scroll container div=0A=
    if (!par.containerId)=0A=
      throw 'Illegal create() call. The parameter "containerId" is =
missing.';=0A=
=0A=
    this.containerId_ =3D par.containerId;=0A=
    this.containerDiv_ =3D this.window_.$(par.containerId);=0A=
    if (this.containerDiv_ =3D=3D null || this.containerDiv_.nodeName =
!=3D "DIV")=0A=
      throw 'Illegal create() call. The parameter "containerId" does not =
specify a valid DIV element.';=0A=
=0A=
    //** "read in" initial scroller elements (=3D all child Html =
elements of the container div)=0A=
    if (doAddInitialElements)=0A=
    {=0A=
      var children =3D this.containerDiv_.childNodes;=0A=
      for (var i=3D0; i<children.length; i++)=0A=
      {=0A=
        var child =3D children[i];=0A=
        if (child.nodeName =3D=3D =
CSScroller.static_.SCROLLER_ELEMENT_NAME)=0A=
          this.elements_[this.elements_.length] =3D child.innerHTML;=0A=
      }=0A=
    }=0A=
=0A=
    //** insert scrolling div into document=0A=
    this.scrollerDiv_ =3D new this.window_.Element("ul");=0A=
    if (this.inline_) {=0A=
      this.scrollerDiv_.setStyle({"float": "left", overflow: "auto"});=0A=
    }=0A=
    //** add onload and onresize handler methods=0A=
    this._addEventHandler();=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._addEventHandler =3D function()=0A=
  {=0A=
    var this_ =3D this;=0A=
    this_.window_.addToOnload(function () {=0A=
      this_._handleOnload();=0A=
    });=0A=
    this_.window_.addToOnunload(function () {=0A=
      this_._handleOnunload();=0A=
    });=0A=
    this_.window_.addToOnresize(function () {=0A=
      this_._handleOnresize();=0A=
    });=0A=
  };=0A=
    =0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._reInitializeScroller =3D function()=0A=
  {=0A=
    // reposition scroller=0A=
    if (this.inline_) {=0A=
      this.scrollerDiv_.style.top =3D "0px";=0A=
      this.containerStart_ =3D 0;=0A=
      this.scrollerDiv_.style.left =3D "0px";=0A=
    }=0A=
    else {=0A=
      this.scrollerDiv_.style.top =3D =
CSScroller.static_.computeOffset(this.containerDiv_, "offsetTop")+"px";=0A=
      this.containerStart_ =3D =
CSScroller.static_.computeOffset(this.containerDiv_, "offsetLeft");=0A=
      this.scrollerDiv_.style.left =3D this.containerStart_+"px";=0A=
    }=0A=
=0A=
    // calculate new current width;=0A=
    this.currentContainerWidth_ =3D this.containerDiv_.offsetWidth;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._handleOnload =3D function()=0A=
  {=0A=
    // add the absolute div & position it=0A=
    if (this.inline_) {=0A=
      this.window_.$(this.containerId_).appendChild(this.scrollerDiv_);=0A=
    }=0A=
    else {=0A=
      this.document_.body.appendChild(this.scrollerDiv_);=0A=
    }=0A=
=0A=
    this._reInitializeScroller();=0A=
=0A=
    // CSScroller is now ready for render() calls=0A=
    this.isReady_ =3D true;=0A=
=0A=
    if (this.alignment_ =3D=3D "right")=0A=
      this.scrollToEnd();=0A=
    else=0A=
      this.scrollToStart();=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._handleOnunload =3D function()=0A=
  {=0A=
    // CSScroller is not ready=0A=
    this.isReady_ =3D false;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._handleOnresize =3D function()=0A=
  {=0A=
=0A=
    // return if container is no longer present in DOM=0A=
    if(this.window_.$(this.containerId_) =3D=3D null) {=0A=
      return;=0A=
    }=0A=
=0A=
    if (this.currentContainerWidth_ !=3D this.containerDiv_.offsetWidth)=0A=
    {=0A=
      this._reInitializeScroller();=0A=
      this.render();=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.clearContainerDiv =3D function()=0A=
  {=0A=
    try=0A=
    {=0A=
      // test if div is accessible (page containing the div is loaded) - =
if it's not, an exception is thrown=0A=
      this.scrollerDiv_.innerHTML =3D "x";=0A=
      // remove all current children (scrolling elements)=0A=
      this.scrollerDiv_.innerHTML =3D "";=0A=
    }=0A=
    catch (e)=0A=
    {=0A=
      // div not ready -> try again later=0A=
      return false;=0A=
    }=0A=
=0A=
    return true;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.isReady =3D function()=0A=
  {=0A=
    return this.isReady_;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.render =3D function()=0A=
  {=0A=
    // synchronize code & fully loaded check=0A=
    if (this.busy_ || !this.isReady_)=0A=
      return false;=0A=
    this.busy_ =3D true;=0A=
=0A=
    // clear container and at the same time check if the container div =
exists (page holding the=0A=
    // container could reload right now and the this.isReady_ parameter =
could still be "true"=0A=
    var containerReady =3D this.clearContainerDiv();=0A=
    if (!containerReady)=0A=
    {=0A=
      this.busy_ =3D false;=0A=
      return false;=0A=
    }=0A=
=0A=
    var redoRendering =3D this._doRender();=0A=
    if (redoRendering)=0A=
    {=0A=
      // there was some space left on the right side (can happen after a =
window resize) -> redo the=0A=
      // rendering, with new start parameters (have already been set in =
the previous _doRender() call)=0A=
      this.scrollerDiv_.innerHTML =3D "";=0A=
      this._doRender();=0A=
    }=0A=
=0A=
    if (this.onRenderCallback_)=0A=
      this.onRenderCallback_();=0A=
=0A=
    this.busy_ =3D false;=0A=
    return true;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._enoughWidth =3D function(currentWidth) {=0A=
    return this.inline_ || (currentWidth < this.currentContainerWidth_);=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._doRender =3D function()=0A=
  {=0A=
    var elements =3D this.elements_;=0A=
    if (elements.length > 0)=0A=
    {=0A=
      this.firstPartialVisible_ =3D false;=0A=
      this.lastPartialVisible_ =3D false;=0A=
=0A=
      // add new children=0A=
      var container =3D this.containerDiv_;=0A=
      var scrollerDiv =3D this.scrollerDiv_;=0A=
      var visibleWidth =3D this.currentContainerWidth_;=0A=
      var currentWidth =3D oldWidth =3D 0;=0A=
=0A=
      // workaround: make sure the width is measured correctly=0A=
      scrollerDiv.style.left =3D -10000;=0A=
=0A=
      if (this.currentAlignment_ =3D=3D "right")=0A=
      {=0A=
        //** scrolling from left to right (right aligned view =3D most =
right element fully visible !))=0A=
        var elemIndex =3D this.lastVisibleElementIndex_;=0A=
        while (this._enoughWidth(currentWidth) && elemIndex >=3D 0)=0A=
        {=0A=
          oldWidth =3D currentWidth;=0A=
          // insert the scrolling element=0A=
          scrollerDiv.innerHTML =3D elements[elemIndex--] + =
scrollerDiv.innerHTML;=0A=
          currentWidth =3D scrollerDiv.offsetWidth;=0A=
        }=0A=
=0A=
        if (this._enoughWidth(currentWidth) && =
this.lastVisibleElementIndex_ < elements.length)=0A=
        {=0A=
          //special case: window was resized, we have free space on the =
right side but don't use it=0A=
          // -> reset start parameters and do it again=0A=
          this.currentAlignment_ =3D "left";=0A=
          this.firstVisibleElementIndex_ =3D 0;=0A=
          return true;=0A=
        }=0A=
=0A=
        this.firstVisibleElementIndex_ =3D elemIndex + 1;=0A=
=0A=
        if (!this._enoughWidth(currentWidth))=0A=
        {=0A=
          // if "not enough" is visible of first element -> make the =
next right scroll a=0A=
          // small one ( =3D the now only partially visible element is =
then fully displayed)=0A=
          var overhang =3D currentWidth - visibleWidth;=0A=
          var elemWidth =3D currentWidth - oldWidth;=0A=
          var percentageVisible =3D (elemWidth - overhang) * 100 / =
elemWidth;=0A=
          if (percentageVisible > this.minVisible_)=0A=
            this.firstPartialVisible_ =3D true;=0A=
          else if (this.firstVisibleElementIndex_ < =
this.lastVisibleElementIndex_)=0A=
            this.firstVisibleElementIndex_++;=0A=
=0A=
          // last element should be fully visible -> add offset to =
scroller div=0A=
          scrollerDiv.style.left =3D (this.containerStart_ - =
overhang)+"px";=0A=
          if (this.inline_) {=0A=
            scrollerDiv.style.clip =3D "rect(0px " + =
(scrollerDiv.offsetWidth) + "px auto " + overhang + "px)";=0A=
          }=0A=
          else {=0A=
            scrollerDiv.style.clip =3D "rect(0px " + =
(scrollerDiv.offsetWidth) + "px " + container.offsetHeight + "px " + =
overhang + "px)";=0A=
          }=0A=
        }=0A=
        else=0A=
        {=0A=
          scrollerDiv.style.left =3D this.containerStart_+"px";=0A=
          if (this.inline_) {=0A=
            scrollerDiv.style.clip =3D "rect(0px " + visibleWidth + "px =
auto 0px)";=0A=
          }=0A=
          else {=0A=
            scrollerDiv.style.clip =3D "rect(0px " + visibleWidth + "px =
" + container.offsetHeight + "px 0px)";=0A=
          }=0A=
        }=0A=
      }=0A=
      else=0A=
      {=0A=
        //** scrolling from right to left (left aligned view =3D most =
left element fully visible !)=0A=
        var elemIndex =3D this.firstVisibleElementIndex_;=0A=
        while (this._enoughWidth(currentWidth) && elemIndex < =
elements.length)=0A=
        {=0A=
          oldWidth =3D currentWidth;=0A=
          // insert the scrolling element=0A=
          scrollerDiv.innerHTML +=3D elements[elemIndex++];=0A=
          currentWidth =3D scrollerDiv.offsetWidth;=0A=
        }=0A=
=0A=
        if (this._enoughWidth(currentWidth) && =
this.firstVisibleElementIndex_ > 0)=0A=
        {=0A=
          //special case: window was resized, we have free space on the =
right side but don't use it=0A=
          // -> reset start parameters and do it again=0A=
          this.currentAlignment_ =3D "right";=0A=
          this.lastVisibleElementIndex_ =3D elements.length - 1;=0A=
          return true;=0A=
        }=0A=
=0A=
        this.lastVisibleElementIndex_ =3D elemIndex - 1;=0A=
=0A=
        if (!this._enoughWidth(currentWidth))=0A=
        {=0A=
          // if "not enough" is visible of first element -> make the =
next left scroll a=0A=
          // small one ( =3D the now only partially visible element is =
then fully displayed)=0A=
          var overhang =3D currentWidth - visibleWidth;=0A=
          var elemWidth =3D currentWidth - oldWidth;=0A=
          var percentageVisible =3D (elemWidth - overhang) * 100 / =
elemWidth;=0A=
          if (percentageVisible > this.minVisible_)=0A=
            this.lastPartialVisible_ =3D true;=0A=
          else if (this.firstVisibleElementIndex_ < =
this.lastVisibleElementIndex_)=0A=
            this.lastVisibleElementIndex_--;=0A=
        }=0A=
=0A=
        // first element should be fully visible -> no offset for =
scroller div=0A=
        scrollerDiv.style.left =3D this.containerStart_+"px";=0A=
        if (this.inline_) {=0A=
          scrollerDiv.style.clip =3D "rect(0px " + visibleWidth + "px =
auto 0px)";=0A=
        }=0A=
        else {=0A=
          scrollerDiv.style.clip =3D "rect(0px " + visibleWidth + "px " =
+ container.offsetHeight + "px 0px)";=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
    return false;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.removeAllElements =3D function()=0A=
  {=0A=
    this.elements_ =3D [];=0A=
    this.firstVisibleElementIndex_ =3D 0;=0A=
    this.firstPartialVisible_ =3D false;=0A=
    this.lastVisibleElementIndex_ =3D 0;=0A=
    this.lastPartialVisible_ =3D false;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.addElements =3D function(elements)=0A=
  {=0A=
    for (var i=3D0; i < elements.length; i++)=0A=
      this.addElement(elements[i]);=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.addElement =3D function(element)=0A=
  {=0A=
    this.elements_[this.elements_.length] =3D element;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollLeftPossible =3D function ()=0A=
  {=0A=
    return this.firstVisibleElementIndex_ > 0 || =
this.firstPartialVisible_;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollRightPossible =3D function ()=0A=
  {=0A=
    return this.lastVisibleElementIndex_ < this.elements_.length - 1 || =
this.lastPartialVisible_;=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollLeft =3D function ()=0A=
  {=0A=
    if (this.scrollLeftPossible())=0A=
    {=0A=
      this.firstVisibleElementIndex_ =3D =
Math.max(this.firstVisibleElementIndex_ - this.stepSize_, 0);=0A=
      this.currentAlignment_ =3D "left";=0A=
      return this.render();=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollRight =3D function ()=0A=
  {=0A=
    if (this.scrollRightPossible())=0A=
    {=0A=
      this.lastVisibleElementIndex_ =3D =
Math.min(this.lastVisibleElementIndex_ + this.stepSize_, =
this.elements_.length -1);=0A=
      this.currentAlignment_ =3D "right";=0A=
      return this.render();=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollToStart =3D function()=0A=
  {=0A=
    this.firstVisibleElementIndex_ =3D 0;=0A=
    this.currentAlignment_ =3D "left";=0A=
    return this.render();=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.scrollToEnd =3D function()=0A=
  {=0A=
    this.lastVisibleElementIndex_ =3D this.elements_.length - 1;=0A=
    this.currentAlignment_ =3D "right";=0A=
    return this.render();=0A=
  };=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSBreadCrumbingX.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSBreadCrumbingX=0A=
 *  Created:     2003-10-08 by akuntner=0A=
 *  Description: Client side class "CSBreadcrumbingX"=0A=
 *=0A=
 *  $Id: CSBreadCrumbingX.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * A class representing a Breadcrumbing line.=0A=
 *=0A=
 * Public methods of the BreadCrumbing class:=0A=
 *   getPath ()=0A=
 *   setPath (aPath)=0A=
 *   clear()=0A=
 *   initialize(aParam)=0A=
 *   render ()=0A=
 *=0A=
 *  =3D=3D=3D=3D=3D=3D Usage =3D=3D=3D=3D=3D=3D=3D=0A=
 *=0A=
 * Preconditions: Depends on the scripts =
"wavemaster.internal/lib/base/v1.x/lang/ojs.js" and=0A=
 *   "wavemaster.internal/webapp/lib/CSScroller.js".=0A=
 */=0A=
// <JSClass Name=3D"CSBreadCrumbingX">=0A=
  /**=0A=
   * The CSBreadCrumbingX constructor.=0A=
   * =0A=
   * And additional parameters used for the CSScrolling instantiation, =
see file CSScroller.js for details=0A=
   * about these. Note that the parameter "containerId" is required by =
the CSScroller class.=0A=
   */=0A=
  function CSBreadCrumbingX (par)=0A=
  {=0A=
    if (par =3D=3D "__proto__")=0A=
      return;=0A=
=0A=
    this.path_ =3D [];=0A=
    this.isInitialized_ =3D false;=0A=
=0A=
    // unique instance identifier=0A=
    this.instanceId_ =3D "CSBreadCrumbingXInstance_" + =
this.static_.instanceCounter_++;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSBreadCrumbingX);=0A=
=0A=
  // Static members and methods=0A=
  class$.static_.instanceCounter_ =3D 0;=0A=
  =0A=
  /**=0A=
   * Replaces the matches of the given regExp in the given sourceText=0A=
   * with the given replaceText. This replace implementation does not =
interpret=0A=
   * "$&", "$1" etc. strings in the replaceText, whereas the standard =
javascript=0A=
   * replace does that. =0A=
   * =0A=
   * @param sourceText The text where to search & replace in=0A=
   * @param regExp The regular expression used for matching=0A=
   * @param replaceText The text to replace the matches with=0A=
   * @return The string with the replaced parts=0A=
   */=0A=
  class$.static_.replace =3D function (sourceText, regExp, replaceText)=0A=
  {=0A=
    var repText =3D replaceText.replace(/\$/g, "\uffff");=0A=
    var result =3D sourceText.replace(regExp, repText);=0A=
    return result.replace(/\uffff/g, "$");=0A=
  };=0A=
  //--------------------------------------------------------------------=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$.initialize =3D function(aParam)=0A=
  {=0A=
    var par =3D aParam || {};=0A=
=0A=
    if (!this.isInitialized_)=0A=
    {=0A=
      this._initializeOnce(par);=0A=
      this.isInitialized_ =3D true;=0A=
    }=0A=
=0A=
    this._initializeAlways(par);=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._initializeOnce =3D function(par)=0A=
  {=0A=
    this.entryResource_ =3D par.entryResource;=0A=
    // this.separationResource_ =3D par.separationResource;=0A=
    // this.previousResource_ =3D par.previousResource;=0A=
    this.lastEntryResource_ =3D par.lastEntryResource || =
par.entryResource;=0A=
    // this.nextResource_ =3D par.nextResource || par.previousResource;=0A=
    this.maxEntryLength_ =3D par.maxEntryLength || 30;=0A=
    this.entryAbbreviation_ =3D par.entryAbbreviation || "...";=0A=
    // this.previousNextOrientation_ =3D par.previousNextOrientation || =
"leftRight";=0A=
=0A=
    this.onSelectFunction_ =3D par.onSelectFunction;=0A=
    this.onSelectFunctionName_ =3D this.instanceId_ + "_onSelect";=0A=
=0A=
    // add previous link into previous resource=0A=
    // this.previousFunctionName_ =3D this.instanceId_ + =
"_previousFuncName";=0A=
    // this.previousResource_ =3D =
this.previousResource_.replace(/\$\{onclick\}/, 'onClick=3D"window.' + =
this.previousFunctionName_ + '()"');=0A=
=0A=
    // add next link into next resource=0A=
    // this.nextFunctionName_ =3D this.instanceId_ + "_nextFuncName";=0A=
    // this.nextResource_ =3D =
this.nextResource_.replace(/\$\{onclick\}/, 'onClick=3D"window.' + =
this.nextFunctionName_ + '()"');=0A=
  };=0A=
=0A=
  /**=0A=
   *=0A=
   */=0A=
  class$._initializeAlways =3D function(par)=0A=
  {=0A=
    this.window_ =3D par.window || window=0A=
    this.document_ =3D this.window_.document;=0A=
=0A=
    //** fetch breadcrumb container div=0A=
    if (!par.containerId)=0A=
      throw 'Illegal initialize() call. The parameter "containerId" is =
missing.';=0A=
    this.breadContainerDiv_ =3D =
this.document_.getElementById(par.containerId);=0A=
    if (this.breadContainerDiv_ =3D=3D null || =
this.breadContainerDiv_.nodeName !=3D "DIV")=0A=
      throw 'Illegal initialize() call. The parameter "containerId" does =
not specify a valid DIV element.';=0A=
=0A=
    // create scrollContainer code=0A=
    var scrollContainerId =3D this.instanceId_ + "_scroll";=0A=
    if (this.inline_) {=0A=
      var scrollContainerCode =3D '<div id=3D"' + scrollContainerId + '" =
style=3D"overflow:auto"></div>';=0A=
    }=0A=
    else {=0A=
      var scrollContainerCode =3D '<div id=3D"' + scrollContainerId + =
'"></div>';=0A=
    }=0A=
=0A=
    // create previous and next controls code=0A=
    // var previousId =3D this.instanceId_ + "_previous";=0A=
    // var previousCode =3D '<td id=3D"' + previousId + '" =
style=3D"white-space:noWrap">' + this.PreviousResource_ + '</td>';=0A=
    // var nextId =3D this.instanceId_ + "_next";=0A=
    // var nextCode =3D '<td id=3D"' + nextId + '" =
style=3D"white-space:noWrap">' + this.NextResource_ + '</td>';=0A=
=0A=
    // insert the code=0A=
    // var insertCode =3D '<table border=3D0 cellpadding=3D0 =
cellspacing=3D0 width=3D"100%"><tr>' + scrollContainerCode + =
"</tr></table>";=0A=
    // if (this.previousNextOrientation_ =3D=3D "allLeft")=0A=
    //   insertCode +=3D previousCode + nextCode + scrollContainerCode;=0A=
    // else if (this.previousNextOrientation_ =3D=3D "leftRight")=0A=
    //   insertCode +=3D previousCode + scrollContainerCode + nextCode;=0A=
    // else=0A=
    //   insertCode +=3D scrollContainerCode + previousCode + nextCode;=0A=
    // insertCode +=3D "</tr></table>";=0A=
    this.breadContainerDiv_.innerHTML =3D scrollContainerCode;=0A=
=0A=
    // fetch previous & next containers=0A=
    // this.previousControl_ =3D =
this.document_.getElementById(previousId);=0A=
    // this.nextControl_ =3D this.document_.getElementById(nextId);=0A=
=0A=
    //** initialize scroller=0A=
    var this_ =3D this;=0A=
    function scrollButtonsRedirector()=0A=
    {=0A=
      // this_.scrollButtons();=0A=
    }=0A=
    par.onRenderCallback =3D scrollButtonsRedirector;=0A=
    par.ignoreInitialElements =3D true; // deactivating the =
initial-elements-grabbing functionality of the scroller=0A=
    par.alignment =3D "right";=0A=
    par.containerId =3D scrollContainerId;=0A=
    this.scroller_ =3D CSScroller.static_.create(par);=0A=
=0A=
    //** set the previous & next onclick functions=0A=
    var scroller =3D this.scroller_;=0A=
    // this.window_[this.previousFunctionName_] =3D function() =
{scroller.scrollLeft(); return false;};=0A=
    // this.window_[this.nextFunctionName_] =3D function() =
{scroller.scrollRight(); return false;}=0A=
=0A=
    //** set the entry onclick function=0A=
    this.window_[this.onSelectFunctionName_] =3D function(aPosition, =
aGoid) {this_._doOnSelectEntry(aPosition, aGoid); return false;}=0A=
=0A=
    //** update the scroller data (scroller will be displayed onload by =
the CSScroller instance)=0A=
    this._updateScrollerData();=0A=
  };=0A=
=0A=
  /**=0A=
   * Returns the path entries of the breadcrumbing line.=0A=
   *=0A=
   * @return: Array: an array of objects {goid:xxx,title:xxx}, each =
object containing the goid and title for=0A=
   * one path entry (=3D a collection)=0A=
   */=0A=
  class$.getPath =3D function ()=0A=
  {=0A=
    return this.path_;=0A=
  };=0A=
=0A=
  /**=0A=
   * Sets the breadcrumbing line.=0A=
   *=0A=
   * @param aPath: Array: An array of objects {goid:xxx,title:xxx}, each =
object containing the goid and=0A=
   * title for one path entry (=3D a collection)=0A=
   */=0A=
  class$.setPath =3D function (aPath)=0A=
  {=0A=
    this.path_ =3D aPath || [];=0A=
  };=0A=
  =0A=
  /**=0A=
   * Clears the Breadcrumbing line.=0A=
   */=0A=
  class$.clear =3D function ()=0A=
  {=0A=
    this.path_ =3D [];=0A=
  };=0A=
=0A=
  /**=0A=
   * This is the method that is called when user clicks on a =
Breadcrumbing entry.=0A=
   *=0A=
   * @param aPosition: Integer: the position (index) of the selected =
entry in the path array=0A=
   * @param aGoid: String: a regular HW Goid, specifying the entry=0A=
   *=0A=
   */=0A=
  class$._doOnSelectEntry =3D function (aPosition, aGoid)=0A=
  {=0A=
    eval(this.onSelectFunction_+"(this, aPosition, aGoid)");=0A=
  };=0A=
=0A=
  /**=0A=
   * @return : string: The string to display in the Breadcrumbing line=0A=
   */=0A=
  class$._getEntryString =3D function (entryResource, index)=0A=
  {=0A=
    //** create text part of entry=0A=
    var pathEntry =3D this.path_[index];=0A=
    var text =3D pathEntry.title || pathEntry.T || pathEntry.goid || =
pathEntry.G;=0A=
=0A=
    var abbreviatedText;=0A=
    if (text.length > this.maxEntryLength_)=0A=
      abbreviatedText =3D text.substring(0, this.maxEntryLength_) + =
this.entryAbbreviation_;=0A=
    else=0A=
      abbreviatedText =3D text;=0A=
    =0A=
    var entry =3D CSBreadCrumbingX.static_.replace(entryResource, new =
RegExp("\\$\\{entryAbbr\\}", "g"), abbreviatedText);=0A=
    entry =3D CSBreadCrumbingX.static_.replace(entry, new =
RegExp("\\$\\{entry\\}", "g"), text);=0A=
=0A=
    //** add onclick =3D function call into the entry=0A=
    entry =3D entry.replace(/\$\{onclick\}/, 'onClick=3D"window.' + =
this.onSelectFunctionName_ + '(' + index + ',\'' + (pathEntry.goid || =
pathEntry.G) + '\'); return false;"');=0A=
=0A=
    entry =3D entry.replace(/\$\{url\}/, pathEntry.U || =
"javascript:void(0);");=0A=
=0A=
    return entry;=0A=
  };=0A=
=0A=
  /**=0A=
   * Updates the element data of the scroller=0A=
   */=0A=
  class$._updateScrollerData =3D function ()=0A=
  {=0A=
    var scroller =3D this.scroller_;=0A=
    scroller.removeAllElements();=0A=
    var pathLength =3D this.path_.length;=0A=
    if (pathLength > 0)=0A=
    {=0A=
      var len =3D  pathLength - 1;=0A=
      // write all entries except the last one=0A=
      for (var i=3D0; i<len; i++)=0A=
        scroller.addElement(this._getEntryString(this.entryResource_, =
i));=0A=
      // write last entry=0A=
      scroller.addElement(this._getEntryString(this.lastEntryResource_, =
len));=0A=
    }=0A=
  };=0A=
=0A=
  /**=0A=
   * previous and next buttons handling (show them or don't)=0A=
   */=0A=
  // class$.scrollButtons =3D function ()=0A=
  // {=0A=
  //   var scroller =3D this.scroller_;=0A=
  //   if (scroller.scrollLeftPossible())=0A=
  //     this.previousControl_.removeClassName("disabled");=0A=
  //   else=0A=
  //     this.previousControl_.addClassName("disabled");=0A=
  //   =0A=
  //   if (scroller.scrollRightPossible())=0A=
  //     this.nextControl_.removeClassName("disabled");=0A=
  //   else=0A=
  //     this.nextControl_.addClassName("disabled");=0A=
  // }=0A=
=0A=
  /**=0A=
   * Displays the current path (stored in path_) in the specified =
container=0A=
   */=0A=
  class$.render =3D function ()=0A=
  {=0A=
    // synchronize code & initialize check=0A=
    if (this.busy_ || !this.isInitialized_)=0A=
      return false;=0A=
    this.busy_ =3D true;=0A=
=0A=
    //** update the scroller data=0A=
    this._updateScrollerData();=0A=
=0A=
    //** display/render the scroller=0A=
    var returnValue =3D this.scroller_.scrollToEnd();=0A=
=0A=
    // synchronize code=0A=
    this.busy_ =3D false;=0A=
    return returnValue;=0A=
  };=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSObjectCache.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSObjectCache.js=0A=
 *  Created:     2001-03-05 by cgoess=0A=
 *  Description: contains the class CSObjectCache=0A=
 *=0A=
 *  $Id: CSObjectCache.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/** =0A=
 * The class will be used to cache server objects (HW_API_Object) and=0A=
 * the relation between objects (parent-child) on the client.=0A=
 * The client-side objects are mappings of the server-side objects.=0A=
 * The properties of the objects will be used to store attributes and=0A=
 * other server-side generated information. The client-side objects=0A=
 * will be generated with the help of the class SSObjectCache. The=0A=
 * mappings and update-functions are defined in=0A=
 * /webapp/components/standardpage/code/updateCSCache.js.=0A=
 * The object cache is currently used by the classes CSTreeview, =0A=
 * CSCollectionListing and CSBreadCrumbing.=0A=
 * =0A=
 * =0A=
 * @author cgoess=0A=
 */=0A=
// <JSClass Name=3D"CSObjectCache">=0A=
=0A=
  /**=0A=
   * The CSObjectCache constructor.=0A=
   *=0A=
   * @param aParam: String||void: default constructor parameter=0A=
   */=0A=
  function CSObjectCache (aParam)=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
          // the objects stored as properties of this.data_;=0A=
          // the objects will be addresses through their GOid=0A=
    this.data_ =3D {};=0A=
          // the goid of the root-object (used by searchup)=0A=
    this.root_ =3D "";=0A=
          // the goid of the current object=0A=
    this.current_ =3D "";=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSObjectCache);=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method adds a given object to the cache.=0A=
   *=0A=
   * @param anObject: Object: the object of interest=0A=
   */=0A=
  class$.addObject =3D function (anObject)=0A=
  {=0A=
    var old_object =3D this.data_[anObject.G];=0A=
    if (old_object) {=0A=
            // if the object already exists, override properties=0A=
      for (var prop in old_object) {=0A=
              // delete old properties =0A=
              // (do not delete children- and parents- information)=0A=
        if (prop!=3D"c_" && prop!=3D"p_" && prop!=3D"urls_") {=0A=
          old_object[prop] =3D "";=0A=
        }=0A=
      }=0A=
            // set new properties=0A=
      var urls =3D old_object.urls_;=0A=
      var new_url_arr =3D [];=0A=
      for (var url_count=3D0; url_count<urls.length; url_count++) {=0A=
        if (urls[url_count].U !=3D anObject.U) {=0A=
          new_url_arr.push(urls[url_count]);=0A=
        }=0A=
      }=0A=
      // FIX HWIS/PR-6460 -> Move latest URL always on the last position =
of the url_-array. =0A=
      // This way it gets used as default for navigation=0A=
      new_url_arr.push({U: anObject.U, OC: anObject.OC, CTX: =
anObject.CTX });=0A=
      old_object.urls_ =3D new_url_arr;=0A=
      // END FIX=0A=
      =0A=
      for (var prop in anObject) {=0A=
        old_object[prop] =3D anObject[prop];=0A=
      }=0A=
    }=0A=
    else {=0A=
      anObject.urls_ =3D [{U: anObject.U, OC: anObject.OC, CTX: =
anObject.CTX}];=0A=
      this.data_[anObject.G] =3D anObject;=0A=
    }=0A=
          // generate a title without HTML-tags=0A=
    if (anObject.title)=0A=
      this.data_[anObject.G].title =3D removeHTMLTags(anObject.title);=0A=
    else=0A=
      this.data_[anObject.G].title =3D removeHTMLTags(anObject.T);=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The methods removes a given object from the cache.=0A=
   *=0A=
   * @param aGOid: String: the goid of the object of interest=0A=
   * @return Boolean: indicates whether the object has been deleted=0A=
   */=0A=
  class$.deleteObject =3D function (aGOid)=0A=
  {=0A=
          // check whether the object exists=0A=
    var obj =3D this.data_[aGOid];=0A=
    if (!obj)=0A=
      return false;=0A=
=0A=
          // remove parent-child-relationship=0A=
    var parents =3D this.getParents(aGOid);=0A=
    if (parents!=3Dnull) {=0A=
=0A=
      for (var p_count=3D0; p_count<parents.length; p_count++) {=0A=
=0A=
        var p_obj =3D parents[p_count];=0A=
        if (p_obj && p_obj.c_) {=0A=
          var new_children =3D [];=0A=
          for (var c_count=3D0; c_count<p_obj.c_.length; c_count++) {=0A=
            if (aGOid !=3D p_obj.c_[c_count].G) =0A=
              new_children[new_children.length] =3D p_obj.c_[c_count];=0A=
          }=0A=
          p_obj.c_ =3D new_children;=0A=
        }=0A=
      }=0A=
    }=0A=
          // remove children=0A=
    var children =3D this.getChildren(aGOid);=0A=
    if (children !=3D null) {=0A=
=0A=
      for (var c_count=3D0; c_count<children.length; c_count++) {=0A=
=0A=
        this.deleteObject(children[c_count].G);=0A=
      }=0A=
    }=0A=
          // remove object=0A=
    this.data_[aGOid] =3D null;=0A=
    return true;=0A=
  };=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method adds a parent-child-relationship between objects.=0A=
   *=0A=
   * @param aParent: String: the goid of the parent object=0A=
   * @param theChildren: Array of String: the goids of the children-=0A=
   *   objects=0A=
   * @param doOverride: Boolean: determines whether the current children=0A=
   *   of the parent-object should be overriden or not=0A=
   * @param doMergeAndUpdate: Boolean: determines whether the current =
children=0A=
   *   of the parent-object should be merged and updated or not=0A=
   */=0A=
  class$.addChildren =3D function (aParent, theChildren, doOverride, =
doMergeAndUpdate)=0A=
  {=0A=
          // set default-value for doOverride to true=0A=
    var do_override =3D (typeof doOverride =3D=3D "undefined") ? true : =
doOverride;=0A=
    var parent =3D this.data_[aParent];=0A=
    if (do_override) {=0A=
      // remove child-parent relationship=0A=
      var old_children =3D parent.c_;=0A=
      if (old_children) {=0A=
        for (var i=3D0; i<old_children.length; i++) {=0A=
          var old_parents =3D old_children[i].p_;=0A=
          var new_parents =3D [];=0A=
          for (var j=3D0; j<old_parents.length; j++) {=0A=
          	if (old_parents[j].G !=3D parent.G) {=0A=
          	  new_parents[new_parents.length] =3D old_parents[j];=0A=
          	}=0A=
          }=0A=
          old_children[i].p_ =3D new_parents;=0A=
        }=0A=
      }=0A=
=0A=
      // remove parent-child relationship=0A=
      parent.c_ =3D [];=0A=
    }=0A=
    else {=0A=
            // initialize children-property=0A=
      if (typeof parent.c_ =3D=3D "undefined") {=0A=
        parent.c_ =3D [];=0A=
      }      =0A=
    }=0A=
=0A=
    var availableChildren =3D {};=0A=
    if (doMergeAndUpdate =3D=3D true)=0A=
    {=0A=
      for (var childCount=3D0; childCount<parent.c_.length; =
childCount++) =0A=
      {=0A=
        availableChildren[parent.c_[childCount].G] =3D true;=0A=
        for (var idx=3D0; idx<theChildren.length; idx++)=0A=
        {=0A=
          if (parent.c_[childCount].G =3D=3D theChildren[idx])=0A=
          {=0A=
            parent.c_[childCount] =3D this.data_[theChildren[idx]];=0A=
          }=0A=
        } =0A=
      }=0A=
    }=0A=
=0A=
    for (var entry=3D0; entry<theChildren.length; entry++) =0A=
    {=0A=
            // add child to children of the parent=0A=
      if (!availableChildren[theChildren[entry]])=0A=
        parent.c_[parent.c_.length] =3D this.data_[theChildren[entry]];=0A=
            // add parent to parents of the child=0A=
      if (!this.data_[theChildren[entry]].p_)=0A=
        this.data_[theChildren[entry]].p_ =3D [parent];=0A=
      else {=0A=
              // check whether the parent has already been added=0A=
        var parents =3D this.data_[theChildren[entry]].p_;=0A=
        var found =3D false;=0A=
        for (var parent_count=3D0; parent_count<parents.length; =
parent_count++) {=0A=
=0A=
          if (aParent=3D=3Dparents[parent_count].G) {=0A=
            found =3D true;=0A=
            break;=0A=
          }=0A=
        }=0A=
        if (!found)=0A=
          parents[parents.length] =3D parent;=0A=
      }=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method sets the root of the objects. The root will be used for=0A=
   * searchups.=0A=
   *=0A=
   * @param aGOid: String: the goid of the new root=0A=
   */=0A=
  class$.setRoot =3D function (aGOid)=0A=
  {=0A=
    this.root_ =3D aGOid;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the goid of the root-object.=0A=
   *=0A=
   * @return String||void: the goid of the root, in case it has been set=0A=
   */=0A=
  class$.getRoot =3D function ()=0A=
  {=0A=
    return this.root_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns a given object stored in the cache.=0A=
   *=0A=
   * @param aGOid: String: the goid of the object of interest=0A=
   * @return Object: the object as stored in the cache=0A=
   */=0A=
  class$.getObject =3D function (aGOid)=0A=
  {=0A=
    return this.data_[aGOid];=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the children of a given object.=0A=
   *=0A=
   * @param aGOid: String: the goid of the parent-object=0A=
   * @return Array of Object: the children-objects=0A=
   */=0A=
  class$.getChildren =3D function (aGOid)=0A=
  {=0A=
    if (typeof this.data_[aGOid] !=3D "undefined")=0A=
      return this.data_[aGOid].c_;=0A=
    return null;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the parents of a given object.=0A=
   *=0A=
   * @param aGOid: String: the object of interest=0A=
   * @return Array of Object: the parents as stored in the cache=0A=
   */=0A=
  class$.getParents =3D function (aGOid)=0A=
  {=0A=
    if (typeof this.data_[aGOid].p_ !=3D "undefined")=0A=
      return this.data_[aGOid].p_;=0A=
    return null;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method resets the object-cache.=0A=
   */=0A=
  class$.clear =3D function ()=0A=
  {=0A=
    this.data_=3D{};=0A=
    this.root_=3D"";=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method allows to set the current object.=0A=
   *=0A=
   * @param aGOid: String: the goid of the current object=0A=
   */=0A=
  class$.setCurrentObject =3D function (aGOid)=0A=
  {=0A=
    this.current_ =3D aGOid;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the current object, i.e. the object defined by=0A=
   * the method setCurrentObject.=0A=
   *=0A=
   * @return Object: the current object=0A=
   */=0A=
  class$.getCurrentObject =3D function ()=0A=
  {=0A=
    return this.data_[this.current_];=0A=
  };=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * removes the HTML-tags from a given String=0A=
 *=0A=
 * @param aTitle: String: the string that should be processed=0A=
 * @return String: the input-string without HTML-tags=0A=
 */=0A=
function removeHTMLTags (aTitle) {=0A=
=0A=
  if (!aTitle)=0A=
    return "";=0A=
  var ret =3D aTitle.replace(/<[^>]*>/g,"");=0A=
  return ret;=0A=
}=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSLangresServer.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSLangresServer.js=0A=
 *  Created:     2001-04-10 by cgoess=0A=
 *  Description: contains the class CSLangresServer=0A=
 *=0A=
 *  $Id: CSLangresServer.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/** =0A=
 * The class should help manage resources on the client. It allows to=0A=
 * register resource-readers and address specific entries similar=0A=
 * to the call 'lrc' or 'api.resgetx' in SSJS.=0A=
 * =0A=
 * @author cgoess=0A=
 */=0A=
// <JSClass Name=3D"CSLangresServer">=0A=
=0A=
  /**=0A=
   * The CSLangresServer constructor.=0A=
   *=0A=
   * @param aParams: String||void: default parameter=0A=
   */=0A=
  function CSLangresServer (aParam)=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
          // stores the registered resource readers=0A=
    this.readers_ =3D {};=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSLangresServer);=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method allows the request a specific entry of the registered=0A=
   * resource-files.=0A=
   *=0A=
   * @param anId: String: the id of the resource-entry=0A=
   * @param aScope: String: the scope of the resource-entry=0A=
   * @param aDefault: String: a default-value in case the entry cannot =0A=
   *   be found=0A=
   * @return String: the value of the requested resource-entry=0A=
   */=0A=
  class$.getRes =3D function (anId, aScope, aDefault)=0A=
  {=0A=
    if (this.readers_[aScope] && typeof =
this.readers_[aScope].getRes(anId) =3D=3D "string")=0A=
      return this.readers_[aScope].getRes(anId).replace(/\\n/gi,'\n');=0A=
=0A=
    return aDefault;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method allows to register resource-reader instances.=0A=
   *=0A=
   * @param aScope: String: the scope used to reference entries=0A=
   * @param aReader: com.hyperwave.res.XMLResourceReader: the resource-=0A=
   *   reader=0A=
   */=0A=
  class$.registerReader =3D function (aScope, aReader)=0A=
  {=0A=
    this.readers_[aScope] =3D aReader;=0A=
  };=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/frameset/code/SearchElement.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        SearchElement.js
 *  Created:     2009-04-21 by cgoess
 *  Description: Controller for the search element in the userblock.
 *
 *  $Id: SearchElement.js 164469 2011-06-10 08:53:36Z sweber $
 *  $Revision: 164469 $
 * </file>
 */
=20
/* <JSLINT> */
/*global setFocusToHWMainframe */
/*global getCurrPath */
/*global performAdvancedSearch */
/*global performSearch */
/*global hw */
/*global addToOnresize */
/*global Element */
/* </JSLINT> */

// <JSClass name=3D"SearchElement">

/**
 * Constructor
 */
function SearchElement () {
  if (arguments[0] =3D=3D=3D "__proto__") {
    return;
  }
  this.advancedSearchUrl_ =3D null;
  this.simpleSearchUrl_ =3D null;
  this.isV62Search_ =3D false;  // just a placeholder in case we will =
re-implement v6.2 search later
 =20
  this._init();
}
class$ =3D doInherit (SearchElement);

class$.static_.OFFSET_LEFT_ =3D 12;
class$.static_.OFFSET_TOP_ =3D -12;=20

class$.static_.getInstance =3D function () {
  return SearchElement.static_.singleton_ || =
(SearchElement.static_.singleton_ =3D new SearchElement());
};

class$._init =3D function () {
  $("search_container").observe("keypress", =
this.searchContainerListener.bindAsEventListener(this));
  addToOnresize((
    function () {=20
      if (this.getSearchContainer().visible()) {
        this.positionDialog();
      }=20
    }).bind(this)
  );
};

class$.setAdvancedSearchUrl =3D function (aUrl) {
  this.advancedSearchUrl_ =3D aUrl;
};

class$.getAdvancedSearchUrl =3D function (aUrl) {
  return this.advancedSearchUrl_;
};

class$.performAdvancedSearch =3D function (aSearchString) {
  this.setFocusToHwMainframe();  //see pr-5441   =20
  var url =3D this.getAdvancedSearchUrl();
  if (url) {
    url =3D url.replace(/\%\%currentpath\%\%/g, getCurrPath());
    url =3D url.replace(/\%\%searchstring\%\%/g, =
encodeURIComponent(aSearchString));
  }
  //bmbc mod spw 7/7/11 - comment out line below as advanced search is =
made a default
  //this.closeSearchDialog();
  //end bmbc mod
 =20
  performAdvancedSearch(aSearchString, url);
 =20
  return false; // do not follow the links
};

class$.setSimpleSearchUrl =3D function (aUrl) {
  this.simpleSearchUrl_ =3D aUrl;
};

class$.getSimpleSearchUrl =3D function (aUrl) {
  return this.simpleSearchUrl_;
};

class$.performSimpleSearch =3D function (theForm) {
  this.setFocusToHwMainframe();  //see pr-5441
  if (this.isV62Search_) {  // v6.2 search compatibility not yet =
implemented (this is just a placeholder)
    performSearch();
    return false;
  }
  var url =3D this.getSimpleSearchUrl();
  if (url) {
    url =3D url.replace(/\%\%currentpath\%\%/g, getCurrPath());
  }
  this.closeSearchDialog();
  return performSearch(theForm, url);
};

class$.getSearchContainer =3D function () {
  return $("search_container");
};

class$.searchButtonOnClick =3D function (theEvent) {
  this.displaySearchDialog();
  return false;
};

class$.displaySearchDialog =3D function () {
  var fw =3D hw.getFramework();
  this.clickLayer_ =3D fw.getDisplayManager().addDisplayLayer();
  this.clickLayer_.addEventListener("click", =
this.clickLayerListener.bindAsEventListener(this));
  this.positionDialog();
  this.getSearchContainer().show();
  $('searchstring').focus();
  $('searchstring').select();
};

class$.positionDialog =3D function () {
  var search_container =3D this.getSearchContainer();
  var search_button =3D $("searchbutton");

  var button_dimensions =3D search_button.getDimensions();
  var container_dimensions =3D search_container.getDimensions();
  var document_dimensions =3D document.viewport.getDimensions();
  var button_offset =3D search_button.cumulativeOffset();
 =20
  var position_top =3D button_offset[1] + button_dimensions.height + =
this.static_.OFFSET_TOP_;
  var position_left =3D button_offset[0] + button_dimensions.width - =
container_dimensions.width + this.static_.OFFSET_LEFT_;

  search_container.setStyle({
    left: Math.max(Math.min(position_left, (document_dimensions.width + =
5) - container_dimensions.width), 0) + "px",
    top:  Math.max(Math.min(position_top, document_dimensions.height - =
container_dimensions.height), 0)+ "px"
  });
};

class$.closeSearchDialog =3D function () {
  this.getSearchContainer().hide();
  this.clickLayer_.remove();
};

class$.clickLayerListener =3D function (theEvent) {
  this.closeSearchDialog();
};

class$.searchContainerListener =3D function (theEvent) {
  if (theEvent.keyCode =3D=3D Event.KEY_ESC) {
    this.closeSearchDialog();      =20
  }
};

class$.setFocusToHwMainframe =3D function () {
  if (typeof(top.HW_Mainframe) !=3D "undefined")
  {
    top.HW_Mainframe.focus();
  }
};
// </JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/frameset/code/MainFilterElement.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        MainFilterElement.js
 *  Created:     2009-03-31 by cgoess
 *  Description: Controller for the Filter input field provided by the =
framework
 *
 *  $Id: MainFilterElement.js 157905 2010-08-18 15:29:44Z bmarsch $
 *  $Revision: 157905 $
 * </file>
 */
=20
/* <JSLINT> */
/*global Form */
/*global PeriodicalExecuter */
/* </JSLINT> */

// <JSClass name=3D"MainFilterElement">

/**
 * Constructor
 */
function MainFilterElement (theId) {
  if (theId =3D=3D=3D "__proto__") {
    return;
  }
   =20
  this.id_ =3D (theId)? theId : "mainfilter";
  this.observers_ =3D []; =20
  this.fieldValueChecker_   =3D null;
  this.isUserAction_        =3D false;
  this.lastActionValue_     =3D "";
  this.lastUserActionValue_ =3D "";
 =20
  this.defaultLabel_            =3D "";
  this.defaultGoButtonLabel_    =3D "";
  this.defaultClearButtonLabel_ =3D "";
 =20
  this.init();
}
class$ =3D doInherit (MainFilterElement);

class$.static_.BLOCK_ID_      =3D "mainFilter";
class$.static_.FORM_ID_       =3D "mainFilterForm";
class$.static_.INPUTFIELD_ID_ =3D "mainFilterInput";
class$.static_.LABEL_ID_      =3D "mainFilterCaption";
class$.static_.GO_BUTTON_CAPTION_ID_    =3D "mainFilterGoButton";
class$.static_.CLEAR_BUTTON_CAPTION_ID_ =3D "mainFilterClearButton";

class$.setLabel =3D function (theCaption) {
  $(this.static_.LABEL_ID_).innerHTML =3D theCaption || "";
};

class$.setGoButtonLabel =3D function (theCaption) { =20
  $(this.static_.GO_BUTTON_CAPTION_ID_).innerHTML =3D theCaption || "";
};

class$.setClearButtonLabel =3D function (theCaption) { =20
  $(this.static_.CLEAR_BUTTON_CAPTION_ID_).innerHTML =3D theCaption || =
"";
};


class$.getFilterInputField =3D function () {
  return $(this.static_.INPUTFIELD_ID_);
};

class$.setValue =3D function (theValue) {
  $(this.static_.INPUTFIELD_ID_).value =3D theValue;
};

class$.getValue =3D function () {
  return $(this.static_.INPUTFIELD_ID_).getValue();
};

/**
 * Destructor, removes event handlers from DOM elements.=20
 * Does not take care about deleting the DOM elements itself.
 * Neede for memory leak "healing" in IE.=20
 */
class$.destructor =3D function() {
  $(this.static_.INPUTFIELD_ID_).stopObserving("keypress", =
this.inputFieldOnKeyPress.bind(this)); =20
  $(this.static_.GO_BUTTON_CAPTION_ID_).stopObserving("click", =
this.goButtonOnClick.bind(this));
  $(this.static_.CLEAR_BUTTON_CAPTION_ID_).stopObserving("click", =
this.clearButtonOnClick.bind(this));
  $(this.static_.FORM_ID_).stopObserving("submit", =
this.formOnSubmit.bind(this));
};

/**
 * This method is needed because <code>SelectionModel</code> implements =
the
 * <code>com.hyperwave.ui.UIObservableIFC</code> and hands itself=20
 * over to its observers in the <code>notify</code> method. The =
observers at
 * least use method <code>getId</code> therefore we need an =
implementation of it.
 * @see com.hyperwave.ui.Element#getId
 */
class$.getId =3D function() {
  return this.id_;
};

/**
 * @see com.hyperwave.ui.UIObservableIFC#attach
 */
class$.attach =3D function (theObserver) {
  this.observers_.push(theObserver);
  this.show();
};

class$.detach =3D function (theObserver) {
  var new_obs =3D [];
  for (var i=3D0; i<this.observers_.length; i++) {
  	if (this.observers_[i] !=3D=3D theObserver) {
  	  new_obs.push(this.observers_[i]);
  	}
  }
  this.observers_ =3D new_obs;
  if (this.observers_.length =3D=3D=3D 0) {
    this.hide();
    this.clear();
    this.setLabel(this.defaultLabel_);
    this.setGoButtonLabel(this.defaultGoButtonLabel_);
    this.setClearButtonLabel(this.defaultClearButtonLabel_);
  }
};

/**
 * @see com.hyperwave.ui.UIObservableIFC#notify
 */
class$.notify =3D function () {
  for(var i=3D0; i<this.observers_.length; i++){
    this.observers_[i].userAction(this);
  }
  this.lastActionValue_ =3D this.getValue();
};

class$.notifyUserAction =3D function () {
  this.isUserAction_ =3D true;
  this.notify();
  this.isUserAction_ =3D false;
  this.lastUserActionValue_ =3D this.getValue();
};

class$.show =3D function () {
  $(this.static_.BLOCK_ID_).show();
};

class$.hide =3D function () {
  $(this.static_.BLOCK_ID_).hide();
};

class$.clear =3D function () {
  $(this.static_.INPUTFIELD_ID_).clear();
};

class$.inputFieldOnKeyPress =3D function (theEvent) {
  if (theEvent.keyCode =3D=3D Event.KEY_ESC) {
    this.clearButtonOnClick(theEvent);      =20
  }
};

class$.goButtonOnClick =3D function (theEvent) {
  this.notifyUserAction();
  theEvent.stop();
};

class$.clearButtonOnClick =3D function (theEvent) {
  this.clear();
  this.notifyUserAction();
  theEvent.stop();
};

class$.formOnSubmit =3D function (theEvent) {
  this.notifyUserAction();
  theEvent.stop();
};

class$.handleFieldValueChecker =3D function (theElement, theValue) {
  if (this.fieldValueChecker_) {
    this.fieldValueChecker_.stop();
  }
  this.fieldValueChecker_ =3D new PeriodicalExecuter(
    (function () {
      this.notify();
      this.fieldValueChecker_.stop();
      $(this.static_.INPUTFIELD_ID_).focus();
    }).bind(this),=20
    0.5
  );
};

class$.init =3D function () {
  this.defaultLabel_            =3D $(this.static_.LABEL_ID_).innerHTML =
|| "";
  this.defaultGoButtonLabel_    =3D =
$(this.static_.GO_BUTTON_CAPTION_ID_).innerHTML || "";
  this.defaultClearButtonLabel_ =3D =
$(this.static_.CLEAR_BUTTON_CAPTION_ID_).innerHTML || "";
 =20
  $(this.static_.INPUTFIELD_ID_).observe("keypress", =
this.inputFieldOnKeyPress.bind(this));
  $(this.static_.GO_BUTTON_CAPTION_ID_).observe("click", =
this.goButtonOnClick.bind(this));
  $(this.static_.CLEAR_BUTTON_CAPTION_ID_).observe("click", =
this.clearButtonOnClick.bind(this));
  $(this.static_.FORM_ID_).observe("submit", =
this.formOnSubmit.bind(this));
 =20
  new Form.Element.Observer(
    this.static_.INPUTFIELD_ID_,
    0.2,
    this.handleFieldValueChecker.bind(this)
  ); =20
};

class$.isValueChanged =3D function (doCompareUserActions) {
  if (doCompareUserActions) {
    return this.getValue() !=3D this.lastUserActionValue_;
  }
  return this.getValue() !=3D this.lastActionValue_;
};

class$.isUserAction =3D function () {
  return this.isUserAction_;
};
// </JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/frameset/code/setDateCookie.js?cachekeY=515488b2-en

function getTimezoneInfo() {=0A=
  var cur_date=3Dnew Date();=0A=
  var dec_date=3Dnew Date(cur_date.getFullYear(),11,12);=0A=
  var jul_date=3Dnew Date(cur_date.getFullYear(),6,7);=0A=
  var dec_offset=3D-dec_date.getTimezoneOffset();=0A=
  var jul_offset=3D-jul_date.getTimezoneOffset();=0A=
  var cur_offset=3D-cur_date.getTimezoneOffset();=0A=
  if (dec_offset<jul_offset) {=0A=
    var hemisphere=3D"North";=0A=
    if (cur_offset=3D=3Djul_offset) {=0A=
      var DST=3D"true";=0A=
    }=0A=
    else {=0A=
      var DST=3D"false";=0A=
    }=0A=
  }=0A=
  else {=0A=
    if (dec_offset>jul_offset) {=0A=
      var hemisphere=3D"South";=0A=
      if (cur_offset=3D=3Ddec_offset) {=0A=
        var DST=3D"true";=0A=
      }=0A=
      else {=0A=
        var DST=3D"false";=0A=
      }=0A=
    }=0A=
    else {=0A=
      var hemisphere=3D"noDST";=0A=
      var DST=3D"false";=0A=
    }=0A=
  }=0A=
  var date_obj=3D{};=0A=
  date_obj.Hemisphere=3Dhemisphere;=0A=
  date_obj.DST=3DDST;=0A=
  return date_obj;=0A=
}=0A=
=0A=
function setDateCookie() {=0A=
  var date_obj=3DgetTimezoneInfo();=0A=
  setCookie('HW_Hemisphere',date_obj.Hemisphere);=0A=
  setCookie('HW_DST',date_obj.DST);=0A=
}
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/dynamic_reloading.js?cachekeY=515488b2-en

/**=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * $Id: dynamic_reloading.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 */=0A=
function arrayToCommaseparated(arr)=0A=
{=0A=
  var str=3D[];=0A=
  for (var id=3D0; id<arr.length; id++) {=0A=
		=
str[str.length]=3D'"'+arr[id].toString().replace(/\\/g,'\\\\').replace(/"=
/g,'\\"')+'"';   //");=0A=
  }=0A=
  return str.join();=0A=
}=0A=
=0A=
//HiddenFrame_isbusy: global variable that keeps the requests that have =
lined up so far, waiting for the=0A=
//hidden frame to become free...=0A=
//HiddenFrame_Queue: global variable that keeps track of the state of =
the hidden frame (busy or not...)=0A=
var HiddenFrame_isbusy=3Dfalse;=0A=
var HiddenFrame_Queue=3D[];=0A=
=0A=
function callServerMethod(p,stat)=0A=
{=0A=
  var par=3Dp||{};=0A=
  if (typeof par.methodName!=3D"string" || typeof =
par.className!=3D"string" && typeof par.objectId!=3D"string")=0A=
    return "error";=0A=
  if (par.className)=0A=
    var pars=3D["SM_"+par.className+"::"+par.methodName]; //SM=3DStatic =
Method=0A=
  else=0A=
    var pars=3D["DM_"+par.objectId+"::"+par.methodName]; //DM=3DDynamic =
Method=0A=
  return performServerCall(par,stat,pars);=0A=
}=0A=
=0A=
function callServerFunction(p,stat)=0A=
{=0A=
  var par=3Dp||{};=0A=
  if (typeof par.serverFunctionName!=3D"string"|| typeof =
par.callback!=3D"string")=0A=
    return "error";=0A=
  var pars=3D["SF_"+par.serverFunctionName]; //SF=3DServer Function=0A=
  return performServerCall(par,stat,pars);=0A=
}=0A=
=0A=
function callJSFrameworkMethod(p,stat)=0A=
{=0A=
  var par=3Dp||{};=0A=
  if (typeof par.methodName!=3D"string"|| typeof =
par.className!=3D"string")=0A=
    return "error";=0A=
  =0A=
  var pars=3D["JM_"+par.className+"::"+par.methodName]; //JM=3DJava =
Method  =0A=
  return performServerCall(par,stat,pars);=0A=
}=0A=
=0A=
function _triggerDynamicReload(theTargetWindow) {=0A=
  theTargetWindow.init(_triggerDynamicReload.theAction, =
_triggerDynamicReload.theData);=0A=
  _triggerDynamicReload.theAction =3D null;=0A=
  _triggerDynamicReload.theData =3D null;=0A=
}=0A=
_triggerDynamicReload.theAction =3D null;=0A=
_triggerDynamicReload.theData =3D null;=0A=
top.triggerDynamicReload =3D _triggerDynamicReload; // reference to top =
window=0A=
=0A=
function performServerCall(par,stat,pars)=0A=
{=0A=
  var MAX_URL_LENGTH =3D 2000; // the maximal length the url shouldn't =
exceed (MSIE cuts after ~2058 chars!)=0A=
  var state=3Dstat||"";=0A=
  if (HiddenFrame_isbusy && state!=3D"queueCall")=0A=
  {=0A=
    HiddenFrame_Queue[HiddenFrame_Queue.length]=3D{par:par, pars:pars}; =
//write request into Queue=0A=
    return "queued";=0A=
  }=0A=
=0A=
  HiddenFrame_isbusy=3Dtrue; //tell the world that hidden frame is now =
busy=0A=
  if (par.objectidentifier)=0A=
  {=0A=
    var url =3D par.objectidentifier;=0A=
    if (url.indexOf("/") !=3D 0) // objectidentifier might be given as =
"some_name" or "/some_name"...we need "/" in front=0A=
      url =3D "/" + url;=0A=
  }=0A=
  else=0A=
    var url =3D url_base; //url_base must be defined (outside !)=0A=
  url+=3D";internal&action=3DdataRequest.action";=0A=
  pars[pars.length]=3Dpar.callback;=0A=
  for (var i in par.parameters) //collect serverfunction parameters in =
array....=0A=
  {=0A=
    pars[pars.length]=3Di;=0A=
    pars[pars.length]=3Dpar.parameters[i];=0A=
  }=0A=
  =0A=
  var datafr =3D top.HW_DataRequestFrame;=0A=
  // Add data to url. Double-escape because single-or-not-escaped "&" =
cause problems on the SS side.=0A=
  // E.g. an action parameter "xx&&yy" or "escape(xx && yy)" results in =
"xx" on the SS side !=0A=
  var data_url =3D url + "&Parameter=3D" + =
encodeURIComponent(encodeURIComponent(arrayToCommaseparated(pars))); // =
adding data to url...=0A=
=0A=
  if (data_url.length < MAX_URL_LENGTH) // ...if url data isn't too =
large....=0A=
  {=0A=
    datafr.location.replace(data_url); //...then send it via URL=0A=
  }=0A=
  else // use form submit to send the data=0A=
  {=0A=
    var doc =3D datafr.document;=0A=
    doc.open();=0A=
    doc.writeln('<html>');=0A=
    doc.writeln('<body onload=3D"document.data_form.submit()">');=0A=
    if (typeof hw_htmlEscape !=3D "undefined")=0A=
    {=0A=
      doc.writeln('<form method=3D"post" name=3D"data_form" =
action=3D"'+hw_htmlEscape(url)+'">');=0A=
    }=0A=
    else=0A=
    {=0A=
      doc.writeln('<form method=3D"post" name=3D"data_form" =
action=3D"'+url+'">');=0A=
    }=0A=
    doc.writeln('<input type=3D"hidden" name=3D"call_data" =
value=3D"'+encodeURIComponent(arrayToCommaseparated(pars))+'">');=0A=
    doc.writeln('</form>');=0A=
    doc.writeln('</body>');=0A=
    doc.writeln('</html>');=0A=
    doc.close();=0A=
  }=0A=
  return "sent";=0A=
}=0A=
=0A=
//This function is called by the hidden frame. It checks if there are =
request waiting in the Queue, if so=0A=
//they get treated by calling performServerCall.=0A=
function checkHiddenFrame_Queue()=0A=
{=0A=
  if (HiddenFrame_Queue.length)=0A=
  {=0A=
    //treat first request in queue...=0A=
    =
performServerCall(HiddenFrame_Queue[0].par,"queueCall",HiddenFrame_Queue[=
0].pars);=0A=
    HiddenFrame_Queue=3DHiddenFrame_Queue.slice(1); //...then remove the =
request out of queue=0A=
  }=0A=
  else {=0A=
    HiddenFrame_isbusy=3Dfalse; //finished=0A=
    =
top.HW_DataRequestFrame.location.replace("/wavemaster.internal/webapp/lib=
/empty.html");=0A=
  }=0A=
}=0A=
=0A=
//This function is the "standard" callback function. It simply takes the =
content given in the parameter=0A=
//"content" and writes it into the DIV (MSIE) or Layer (Netscape) =
"container".=0A=
function newTrackContent_callback(content,container)=0A=
{=0A=
  var doc=3Dwindow.HW_Mainframe.document;=0A=
  var cont=3D"div"+container.replace("_","");=0A=
  var the_cont =3D doc.getElementById(cont);=0A=
  if (the_cont) { //check if target exists =0A=
    =0A=
    the_cont.innerHTML=3Dcontent;=0A=
    if (the_cont.style.overflow=3D=3D"auto" && !the_cont.style.height) { =0A=
      // overflow indiecates whether the height should stay constant=0A=
      the_cont.style.width =3D "100%";=0A=
      the_cont.style.height =3D the_cont.scrollHeight;=0A=
    }=0A=
  }=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Fcomponents%2Fframeset%2Fhtmlres%2Fcsbuildframes.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'header': new =
com.hyperwave.res.Template({ templateString_: '($#if $title)\r\n  =
\x3ch2>($#if $infoicon)($#with $infoicon)($#if $onclick)\x3ca =
href=3D\"#\" onclick=3D\"($onclick)\">($#endif)($title)($#if =
$onclick)\x3c/a>($#endif)($#endwith)($#else)($title)($#endif)\x3c/h2>\r\n=
($#endif)'}), 'main_header': new com.hyperwave.res.Template({ =
templateString_: '\x3cdiv id=3D\"tabbar\">\r\n($#if $caption)\r\n  =
\x3ch1>($caption)\x3c/h1>($#endif)\r\n  \x3cul class=3D\"tabs\">\r\n     =
($#for $tabs)\r\n     \x3cli($#if $cssClass) =
class=3D\"($cssClass)\"($#endif)>\x3ca href=3D\"($js:href)\"($#if =
$onclick) onclick=3D\"($onclick)\"($#endif) =
title=3D\"($html:iflongerthan[50]:caption)\" target=3D\"($#if =
$target)($target)($#elseif)HW_Mainframe($#endif)\">\x3cspan>($truncate[50=
]:caption)\x3c/span>\x3c/a>\x3c/li>\r\n     ($#endfor)\r\n  =
\x3c/ul>\r\n\x3c/div>'})});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/components/f=
rameset/htmlres/csbuildframes.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Fcomponents%2Fstandardpage%2Flangres%2Fmodifyalertmsgs.%25lang%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'dbDlgTxt1': 'View Attributes', =
'dbDlgTxt2': 'View Link Map', 'dbDlgTxt3': 'This function can not be =
applied.\\n\\nPossible reasons:\\n- No collection selected\\n- No write =
access\\n- Not a local collection', 'dbDlgTxt4': 'This function can not =
be applied.\\n\\nPossible reasons:\\n- No collection selected\\n- No =
configuration available for this collection\\n- Not a local collection', =
'dbDlgTxt5': 'This function can not be applied.\\n\\nPossible =
reasons:\\n- No collection selected\\n- No configuration available for =
this collection\\n- No write access\\n- Not a local collection', =
'dbDlgTxt6': 'Some of the selected objects can not be =
modified.\\n\\nPossible reasons:\\n- Not a local document\\n- No write =
access\\n- Object not checked out', 'dbDlgTxt7': 'Some of the selected =
objects can not be replaced.\\n\\nPossible reasons:\\n- Not a local =
document\\n- No write access\\n- Object not checked out \\n- Object is a =
collection', 'dbDlgTxt8': 'This function can not be =
applied.\\n\\nPossible reasons:\\n- Not under version control\\n- No =
write access\\n- Not a local document', 'dbDlgTxt9': 'You are about to =
make a physical copy.\\nThis can not be done with documents from a =
remote server.', 'dbDlgTxta': 'Some of the selected objects can not be =
checked in.\\n\\nPossible reasons:\\n- Not a local document\\n- No write =
access\\n- Object already checked in \\n- Object is a collection', =
'dbDlgTxta_single': 'The selected object can not be checked =
in.\\n\\nPossible reasons:\\n- Not a local document\\n- No write =
access\\n- Object already checked in \\n- Object is a collection', =
'dbDlgTxtd': 'Some of the selected objects can not be checked =
out.\\n\\nPossible reasons:\\n- Not a local document\\n- No write =
access\\n- Object already checked out', 'dbDlgTxtd_single': 'The =
selected object can not be checked out.\\n\\nPossible reasons:\\n- Not a =
local document\\n- No write access\\n- Object already checked out', =
'dbDlgTxte': 'The function can not be applied to any of the selected =
objects', 'dbDlgTxte_single': 'The function can not be applied to the =
selected object', 'dbDlgTxtf': 'The function can not be applied to more =
than %number% object(s)', 'dbDlgTxtg': 'Click on \"OK\" to continue with =
the remaining objects', 'dbDlgTxth': 'Please click on \"Move\" in the =
main window', 'dbDlgTxti': 'In order to use this function exactly one =
object has to be selected', 'dbDlgTxtj': 'In order to use this function =
at least one object has to be selected', 'dbDlgTxtjVars': new =
com.hyperwave.res.Template({ templateString_: 'In order to use this =
function at least one ($objectTypeCaptionSingular) has to be =
selected'}), 'dbDlgTxtk': '\\nAre you sure you want to permanently =
delete all marked documents, collections and content?', 'dbDlgTxtkVars': =
new com.hyperwave.res.Template({ templateString_: '\\nAre you sure you =
want to permanently delete all marked ($objectTypeCaptionPlural)?'}), =
'dbDlgTxtl': 'This function can not be applied.\\n\\nPossible =
reasons:\\n- No agent selected\\n- No write access\\n- Not a local =
agent', 'dbDlgTxtm': 'View Notes', 'dbDlgTxtn': 'The selected document =
can not be edited.\\n\\nPossible reasons:\\n- Not a text document\\n- No =
write access\\n- Not a local document\\n- Document is version =
controlled\\n- Document is locked by another user', 'dbDlgTxto': 'The =
selected document can not be edited.\\n\\nPossible reasons:\\n- Not an =
HTML document\\n- HTML document contains a Frame Set definition\\n- Not =
a local document\\n- Document is version controlled\\n- Document is =
locked by another user', 'dbDlgTxtp': 'This function can only be applied =
to documents.', 'dbDlgTxtq': 'One or more of the selected objects were =
found by a search.\\nAre you sure you want to delete all selected =
objects from their parent collection?', 'dbDlgTxtqVars': new =
com.hyperwave.res.Template({ templateString_: 'One or more of the =
selected ($objectTypeCaptionPlural) were found by a search.\\nAre you =
sure you want to delete all selected ($objectTypeCaptionPlural) from =
their parent collection?'}), 'dbDlgTxtr': 'One or more of the selected =
objects were found by a search.\\nAre you sure you want to move all =
selected objects from their parent collection?', 'dbDlgTxts': 'The =
selected object can not be edited.\\n\\nPossible reasons:\\n- Not a =
document\\n- No write access\\n- Not a local document\\n- Document is =
locked by another user', 'dbDlgTxtt': 'This function can only be applied =
to unlocked objects.', 'dbDlgTxtu': 'The selected document can not be =
edited.\\n\\nPossible reasons:\\n- Not an HTML or Text document\\n- Not =
a local document\\n- Document is locked by another user', =
'objectTypeCaptionPlural': 'objects', 'objectTypeCaptionSingular': =
'object', 'treeview_loading': 'Loading...', 'treeview_noobjects': 'There =
are no objects to show in this view.'});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/components/s=
tandardpage/langres/modifyalertmsgs.%lang%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Fcomponents%2Fframeset%2Flangres%2Fbuildframes.%25lang%25.lrc&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'butLbl1': 'You are at the top level =
and cannot go up another level', 'butLbl2': 'Go up to', 'ooo_body': 'You =
are currently marked as out of office.\nWould you like change this =
setting now?', 'ooo_head': 'Out of office', 'ppErrAlert1': 'Cookie =
support is necessary to browse this server.\nPlease check your security =
settings or inform your system administrator.'});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/components/f=
rameset/langres/buildframes.%lang%.lrc", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/ojs/Event.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * Event.js,v 1.12 2003/05/05 12:34:45 sraubal Exp=0A=
 */=0A=
=0A=
/**=0A=
 * This class defines a generic event object. It provides two methods =
that allow=0A=
 * querying the source and the type of the event.<p>=0A=
 * Why is the source not automatically set during event dispatching? The =
answer lies=0A=
 * in the loss of flexibility - sometimes it migth be necessary to =
separate the =0A=
 * dispatching mechanism and the object that is declared as the event =
source in an API.=0A=
 * <p>=0A=
 * Mind that You have to overwrite several methods and a field if You =
extend this =0A=
 * class: =0A=
 * Most important are the constructor (to correctyl comment the new =
properties) and the =0A=
 * private <code>_init</code> method to implement the new properties. If =
You want to =0A=
 * support the static usage, You have to overwrite the =
<code>onClassLoad</code> method, =0A=
 * the <code>getInstance</code> method and the private static field =
<code>instance_</code>.=0A=
 * (Finally You need getter methods to access the new properties - of =
course.)=0A=
 *=0A=
 * @author sraubal=0A=
 * =0A=
 * @see ojs.EventSource=0A=
 */=0A=
defineClass ( "ojs.Event",=0A=
              function ( class$ )=0A=
{=0A=
  =0A=
  /**=0A=
   * Creates a new immutable event object.<p>=0A=
   * This implementation CAN be treated as a SINGLETON (for memory usage =
reduction),=0A=
   * but when You do that, You must be aware of the fact that You =
manipulate the one =0A=
   * and only static instance (aquired this instance via the =
<code>getInstance</code>=0A=
   * method. Calling the constructor returns a new instance that has =
nothing to do =0A=
   * with the singleton object.=0A=
   * =0A=
   * @param theParams.type_: String: the name of the event type=0A=
   * @param theParams.source_: ojs.EventSource: the Object that =
propagates this event=0A=
   *=0A=
   */=0A=
  class$.constructor =3D function( theParams )=0A=
  {=0A=
    if ( theParams =3D=3D "__proto__")=0A=
      return;=0A=
  =0A=
    this._init(theParams);=0A=
  }=0A=
=0A=
  // Copy this line if You subclass this class.=0A=
  var instance_;=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Creates the singleton instance.<p>=0A=
   * "Override" this line with Your own type if You subclass this class.=0A=
   */=0A=
  class$.static_.onClassLoad =3D function( )=0A=
  {=0A=
    instance_ =3D new ojs.Event();=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the singleton instance that represents all events sharing =
this class.=0A=
   * Mind that using the singleton approach means that You always work =
with the=0A=
   * same object (problems may occur e.g. if an event handler dispatches =
another event =0A=
   * that is also represented by this singleton instance).<p>=0A=
   * "Override" this line with Your own type if You subclass this class.=0A=
   * =0A=
   * @param theParams.type_: String: the name of the event type=0A=
   * @param theParams.source_: ojs.EventSource: an Object that =
propagates this event=0A=
   * =0A=
   * @return ojs.Event: singleton instance of a simple Event=0A=
   */=0A=
  class$.static_.getInstance =3D function( theParams )=0A=
  {=0A=
    instance_._init(theParams);=0A=
  =0A=
    return instance_;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Helper method us used by the constructor and the =
<code>getInstance</code> method=0A=
   * to fill the object with the properties.<p> =0A=
   * This method has to be overwritten when a new event subclasses =
another one. It sets=0A=
   * the event specific properties that are not covered by superclasses =
and has to call=0A=
   * super_._init! See the following example:=0A=
   * <pre>=0A=
   * class$._init =3D function( theParams )=0A=
   * {=0A=
   *   class$.super_._init.call(this, theParams);=0A=
   *   =0A=
   *   this.myProperty_ =3D theParams.myProperty_;=0A=
   * }=0A=
   * </pre>=0A=
   * =0A=
   * @param theParams.type_: String: the name of the event type=0A=
   * @param theParams.source_: ojs.EventSource: an Object that =
propagates this event=0A=
   * source of this one=0A=
   */=0A=
  class$._init =3D function( theParams )=0A=
  {=0A=
    this.type_ =3D (theParams && theParams.type_) ? theParams.type_ : "";=0A=
    this.source_ =3D (theParams && theParams.source_) ? =
theParams.source_ : null;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the type of the event. (Usually this string will be defined =
by a =0A=
   * static constant in an event related class - probably in the source =
itself.)=0A=
   * =0A=
   * @return String: type of event, an empty string if no type is defined=0A=
   */=0A=
  class$.getType =3D function()=0A=
  {=0A=
    return this.type_;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the source of the event. Most oft the time this will be the =
object=0A=
   * that dispatches the event, but this is no necessity.=0A=
   * =0A=
   * @return ojs.EventSource: the source of the event=0A=
   */=0A=
  class$.getSource =3D function()=0A=
  {=0A=
    return this.source_;=0A=
  }=0A=
=0A=
} );=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/ojs/EventSource.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * EventFramework.js,v 1.1 2003/12/15 19:56:47 sraubal Exp=0A=
 */=0A=
=0A=
/**=0A=
 * This class implements the Observable pattern (though the terms "event =
source"=0A=
 * and "event listener" are used) by providing methods to add, remove =
and inform=0A=
 * listeners. The DOM specification names such an object an "event =
target" - but=0A=
 * we regard this term as misleading, so we replaced it with "event =
source".=0A=
 *=0A=
 * @author sraubal=0A=
 *=0A=
 * @see ojs.Event=0A=
 */=0A=
defineClass ( "ojs.EventSource",=0A=
              function ( class$ )=0A=
{=0A=
  var debug_;=0A=
  =0A=
  /**=0A=
   * Constructs a basic event source object.=0A=
   */=0A=
  class$.constructor =3D function( theParams )=0A=
  {=0A=
    if ( theParams =3D=3D "__proto__")=0A=
      return;=0A=
=0A=
    // array of arrays that hold all listeners for all types=0A=
    this.listener_ =3D new Array();=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Attaches a listener function as a callback for events of a specific =
type.=0A=
   * <p>=0A=
   * To redirect to the lexical scope of the object use a technique like =
the =0A=
   * following:=0A=
   * <pre>=0A=
   * class$.registerAsListener =3D function( anEventSource )=0A=
   * {=0A=
   *   var this_ =3D this;=0A=
   *   function myCallback( anEvent )=0A=
   *   {=0A=
   *     this_.doSomething( anEvent );=0A=
   *   }=0A=
   *   anEventSource.addEventListener( "myType", myCallback );=0A=
   * }=0A=
   * </pre>=0A=
   * Be aware that the usage of the <code>this</code> keyword does not =
reference=0A=
   * the native event source nor the UDA EventSource!=0A=
   *=0A=
   * Another possible use case (and very similar to the one above) might =
be the =0A=
   * registration of an object's method as the callback function:=0A=
   * <pre>=0A=
   * anEventSource.addEventListener( =0A=
   *   "myType",=0A=
   *   function myCallback( anEvent )=0A=
   *   {=0A=
   *     anObjectRef.doSomething( anEvent );=0A=
   *   }=0A=
   * );=0A=
   * </pre>=0A=
   *=0A=
   * Mind that these examples are only applicable if they are used only =
once -=0A=
   * to register for several events try something like this:=0A=
   * <pre>=0A=
   * class$.registerAsListener =3D function( anEventSource )=0A=
   * {=0A=
   *   function getCallback( anObjectRef, aType )=0A=
   *   {=0A=
   *     function redirect( anEvent )=0A=
   *     {=0A=
   *       anObjectRef["on" + aType](anEvent);=0A=
   *     }=0A=
   *     return redirect;=0A=
   *   }=0A=
   * =0A=
   *   for ( var type in this.typeArray_ )=0A=
   *     if ( this.typeArray_.hasOwnProperty(type) )=0A=
   *       anEventSource.addEventListener( type, getCallback(this, type) =
);=0A=
   * }=0A=
   * </pre>=0A=
   * =0A=
   * @param aType: String: type of event (usally defined as static =
constant)=0A=
   * @param aCallback: Function: function that is called whenever an =
event of=0A=
   * the given type appears on the node (may be an object's method)=0A=
   */=0A=
  class$.addEventListener =3D function( aType, aCallback )=0A=
  {=0A=
    if ( !this.listener_[aType] )=0A=
      this.listener_[aType] =3D new Array();=0A=
    =0A=
    var lstnr_fct =3D this.listener_[aType];=0A=
  =0A=
    for ( var i =3D 0; i < lstnr_fct.length; ++i )=0A=
      if ( lstnr_fct[i] =3D=3D aCallback )=0A=
        return;=0A=
  =0A=
    lstnr_fct[lstnr_fct.length] =3D aCallback;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Removes a callback function from the list of listeners.=0A=
   *=0A=
   * @param aType: String: type of event (see static constants)=0A=
   * @param aCallback: Function: function that is removed from the list =
of =0A=
   * callback function=0A=
   */=0A=
  class$.removeEventListener =3D function( aType, aCallback )=0A=
  {=0A=
    var lstnr_fct =3D this.listener_[aType];=0A=
    if ( !lstnr_fct )=0A=
      return;=0A=
  =0A=
    for ( var i =3D 0; i < lstnr_fct.length; ++i )=0A=
    {=0A=
      if ( lstnr_fct[i] =3D=3D aCallback )=0A=
      {=0A=
        if ( lstnr_fct.splice )=0A=
        {=0A=
          lstnr_fct.splice(i, 1);=0A=
        }=0A=
        else=0A=
        {=0A=
          //splice not supported in IE 5.0=0A=
          var start_slice =3D ( i > 0 ) ? lstnr_fct.slice(0, i) : [];=0A=
          this.listener_[aType] =3D =
start_slice.concat(lstnr_fct.slice(i+1));=0A=
        }=0A=
        break;=0A=
      }=0A=
    }=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Calls all callback functions registered for the given event with=0A=
   * the event object as the only argument.=0A=
   *=0A=
   * @param anEvent: ojs.Event: event that is send to all observers=0A=
   */=0A=
  class$.dispatchEvent =3D function( anEvent )=0A=
  {=0A=
    var lstnr_fct =3D this.listener_[anEvent.getType()];=0A=
=0A=
    if ( !debug_ && com.hyperwave && com.hyperwave.util && =
com.hyperwave.util.Debug )=0A=
      debug_ =3D =
com.hyperwave.util.Debug.static_.getDebug("com.hyperwave"); =0A=
=0A=
    if ( debug_ && debug_.isDebugEnabled() )=0A=
      debug_.debug("Dispatching event of type '" + anEvent.getType() + =
"'");=0A=
    =0A=
    if ( lstnr_fct )=0A=
      for ( var i =3D 0; i < lstnr_fct.length; ++i )=0A=
      {=0A=
        if ( debug_ )=0A=
        {=0A=
          try=0A=
          {=0A=
            if ( lstnr_fct[i] )=0A=
              lstnr_fct[i](anEvent);=0A=
          }=0A=
          catch (ex)=0A=
          {=0A=
            debug_.error("Exception in event handler: ", ex);=0A=
            throw ex;=0A=
          }=0A=
        }=0A=
        else=0A=
        {=0A=
          if ( lstnr_fct[i] )=0A=
            lstnr_fct[i](anEvent);=0A=
        }=0A=
      }=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Takes the given event and creates a new <code>ojs.Event</code> =
object with the same type =0A=
   * but this object as the source.=0A=
   *=0A=
   * @param anEvent: ojs.Event: event that defines which type of event =
should be =0A=
   * dispatched to listeners   =0A=
   */=0A=
  class$.redirectCoreEvent =3D function( anEvent )=0A=
  {=0A=
    this.dispatchEvent(new ojs.Event({ source_: this, type_: =
anEvent.getType() }));=0A=
  }=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Dispatches the given event to all its own listeners for events of =
the type (setting=0A=
   * itself as the source of the event). Afterwards it restores the =
event to its initial state.=0A=
   *=0A=
   * @param anEvent: ojs.Event: event that is dispatched to listeners =
with this object as the source   =0A=
   */=0A=
  class$.redirectEvent =3D function( anEvent )=0A=
  {=0A=
    var origSource =3D anEvent.source_;=0A=
    anEvent.source_ =3D this;=0A=
    this.dispatchEvent(anEvent);=0A=
    anEvent.source_ =3D origSource;=0A=
  }=0A=
=0A=
} );=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/ojs/Exception.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * Exception.js,v 1.9 2003/05/05 12:26:20 sraubal Exp=0A=
 */=0A=
=0A=
/**=0A=
 * Encapsulates both the description and (if available) a cause=0A=
 * for an error situation. It forms the base class for all other=0A=
 * exceptions.=0A=
 *=0A=
 * @author sraubal=0A=
 */=0A=
defineClass ( "ojs.Exception",=0A=
              function ( class$ )=0A=
{=0A=
  /**=0A=
   * Constructs simple exceptions by giving a text (mandatory) and if=0A=
   * available a cause (that is defined by another exception).=0A=
   * =0A=
   * @signature ( string aMessage )=0A=
   * @signature ( Object theParams )=0A=
   * =0A=
   * @param aMessage message text describing the exception=0A=
   * @param theParams a parameter value object for the exception's=0A=
   *   constructor=0A=
   * @param theParams.message_: string: message text describing the=0A=
   *   exception=0A=
   * @param theParams.cause_: Object: if given this parameter=0A=
   *   defines the exception that was the reason for this one=0A=
   *   (can be an <code>ojs.Exception</code>, a subclass of it or browser=0A=
   *   error object) - interesting for descriptive <code>toString</code> =
output =0A=
   */=0A=
  class$.constructor =3D function ( theParams )=0A=
  {=0A=
    if ( theParams =3D=3D "__proto__")=0A=
      return;=0A=
  =0A=
    // the message text describing the exception=0A=
    if ( (typeof theParams).toLowerCase() =3D=3D "string" )=0A=
      this.message_ =3D theParams;=0A=
    else=0A=
      this.message_ =3D theParams.message_;=0A=
      =0A=
    if ( !this.message_ )=0A=
      this.message_ =3D "(No exception message)";=0A=
    =0A=
    // nested exception, if there exists one=0A=
    this.cause_ =3D =0A=
      (theParams && theParams.cause_) ? theParams.cause_ : null;=0A=
    =0A=
    this.stackTrace_ =3D getStackTrace().slice(1);=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the message text of this exception. =0A=
   *=0A=
   * @return string: a message text describing the exception.=0A=
   */=0A=
  class$.getMessage =3D function()=0A=
  {=0A=
    return this.message_;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns the cause of this exception.=0A=
   *=0A=
   * @return Object: the nested exception that lead to this one (can be =0A=
   *   an <code>ojs.Exception</code>, a subclass of it or browser error =
object)=0A=
   *   or <code>null</code> if no cause was defined during the exception.=0A=
   */=0A=
  class$.getCause =3D function()=0A=
  {=0A=
    return this.cause_;=0A=
  }=0A=
  =0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns a string representation of this exception including all=0A=
   * causes.<p>=0A=
   * This implementation will call the <code>toString</code> method of=0A=
   * the causes recursively.=0A=
   *=0A=
   * @return string: a text describing the exception.=0A=
   */=0A=
  class$.toString =3D function()=0A=
  {=0A=
    return this.static_.getClassName() + ": " =0A=
           + this.message_ =0A=
           + (this.cause_ =0A=
              ? ", because of: " + (this.cause_.toString ? =0A=
                this.cause_.toString() : this.cause_)   =0A=
              : ".") =0A=
           + "\nStacktrace: " + this.stackTrace_.join("\n");=0A=
  }=0A=
=0A=
  //-----------------------------------------------------------=0A=
  /**=0A=
   * Returns a string representation of the given exception which can be=0A=
   * a core exception, a string or of type <code>ojs.Exception</code>.=0A=
   *=0A=
   * @return string: a text describing the exception=0A=
   */=0A=
  class$.static_.getString =3D function( anException )=0A=
  {=0A=
    if ( anException.instanceOf && anException.instanceOf(class$) )=0A=
      return anException.toString();=0A=
    else if ( anException.message )=0A=
      return anException.message;=0A=
    else=0A=
      return "" + anException;=0A=
  }=0A=
=0A=
} );=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/lang/Exception.js?cachekeY=515488b2-en

/* =0A=
 * <copyright> =0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright> =0A=
 * =0A=
 * <file> =0A=
 *  Name:        AbstractResource.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: Exception.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "lang" );=0A=
=0A=
/**=0A=
 * This exception class wraps all current resource exceptions.=0A=
 * The only purpose is to hold an array which can get a kind=0A=
 * of error stack.=0A=
 */=0A=
/**=0A=
  * The Constructor an exception creates an error array and=0A=
  * the default exceptionname.=0A=
  * @param aParam: (Object | void): if given, an initial string=0A=
  *   or error which must have a <i>string</i> representation.=0A=
  */=0A=
lang.Exception =3D function (aParam /*.....*/)=0A=
{=0A=
  if ( aParam =3D=3D "__proto__" )=0A=
    return;=0A=
=0A=
  this.errors_ =3D [];=0A=
  this.messageArray_ =3D [];=0A=
  this.cause_ =3D null;=0A=
=0A=
  if (aParam instanceof lang.Exception) {=0A=
    this.messageArray_[0] =3D "";=0A=
    // nested exception, if an exception handed over=0A=
    this.cause_ =3D aParam;=0A=
  }=0A=
  else {=0A=
    if (arguments.length > 0) {=0A=
      for (var i =3D 0; i < arguments.length; i++) {=0A=
        if (typeof arguments[i] =3D=3D "string") {=0A=
          this.messageArray_[this.messageArray_.length] =3D arguments[i];=0A=
        }=0A=
      }=0A=
    }=0A=
  }=0A=
=0A=
  // an empty exception is instantiated in the XMLResourceReader...=0A=
  if (this.messageArray_.length > 0) {=0A=
    this.message_ =3D this.messageArray_[0];=0A=
  }=0A=
  else {=0A=
    this.message_ =3D "";=0A=
  }=0A=
=0A=
  // for finding out file name and line number=0A=
  this.internalTrick_ =3D new Error( );=0A=
}=0A=
class$ =3D doInherit ( lang.Exception );=0A=
=0A=
class$.static_.NAME =3D "lang.Exception";=0A=
class$.static_.RESOURCE_FILE_NAME =3D =
"lib/base/v1.x/lang/res/exception_descriptions";=0A=
=0A=
class$.static_.EXCEPTION_FILE_INDEX =3D "Exception";=0A=
=0A=
/**=0A=
 * Add a new error to the exception object.=0A=
 * @param anError: (Object | void): an object describing the error=0A=
 *   which is put to the exception.=0A=
 */=0A=
class$.pushError =3D function ( anError )=0A=
{=0A=
  if ( anError !=3D null )=0A=
    this.errors_ [this.errors_.length] =3D anError;=0A=
}=0A=
=0A=
/**=0A=
 * Check whether or not errors have been pushed to the Exception=0A=
 * object and gives the number of errors or 0 if no errors=0A=
 * are present.=0A=
 * @return Number: 0 if no error is present or otherwise the=0A=
 *   current number of errrors.=0A=
 */=0A=
class$.errorCount =3D function ()=0A=
{=0A=
  return this.errors_.length;=0A=
}=0A=
=0A=
/**=0A=
 * Assigns a given exception as the cause of the current exception.=0A=
 * @param anException: lang.Exception: the cause of the current =
exception.=0A=
 */=0A=
class$.initCause =3D function( anException )=0A=
{=0A=
  if (anException instanceof lang.Exception){=0A=
    this.cause_ =3D anException;=0A=
  }=0A=
  else if (anException instanceof Error) {=0A=
    this.cause_ =3D anException;=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * Returns the message text of this exception. =0A=
 *=0A=
 * @return string: a message text describing the exception.=0A=
 */=0A=
class$.getMessage =3D function()=0A=
{=0A=
  return this.message_;=0A=
}=0A=
=0A=
/**=0A=
 * Returns the name of this exception. =0A=
 *=0A=
 * @return string: the name of the exception.=0A=
 */=0A=
class$.getName =3D function()=0A=
{=0A=
  return this.static_.NAME;=0A=
}=0A=
=0A=
/**=0A=
 * Returns the cause of this exception.=0A=
 *=0A=
 * @return lang.Exception: the nested exception that lead to this one =
(can be =0A=
 *   an <code>lang.Exception</code> or a subclass of it=0A=
 *   or <code>null</code> if no cause was defined during the exception.=0A=
 */=0A=
class$.getCause =3D function()=0A=
{=0A=
  return this.cause_;=0A=
}=0A=
=0A=
=0A=
/**=0A=
 * Provides the basic mechanism of creating an output=0A=
 * string from the Exception class.=0A=
 * @return String: a String containing the class type and the=0A=
 *   errors.=0A=
 */=0A=
class$.toString =3D function ()=0A=
{=0A=
  var out_array =3D [];=0A=
  for ( var index =3D 0; index < this.errors_.length; ++index ) {=0A=
    out_array [index] =3D this.errors_ [index].toString();=0A=
  }=0A=
=0A=
  var ret =3D [];=0A=
=0A=
  ret[ret.length] =3D "@" + this.static_.NAME + ": " + this.message_;=0A=
  ret[ret.length] =3D this._parseStackTrace(this.internalTrick_.stack);=0A=
=0A=
  if (out_array.length > 0) {=0A=
    ret[ret.length] =3D "\nerrors: " + out_array[0];=0A=
  }=0A=
=0A=
  for (var i =3D 1; i < out_array.length; i ++) {=0A=
    ret[ret.length] =3D " - " + out_array[i];=0A=
  }=0A=
=0A=
  if (this.cause_) {=0A=
    ret[ret.length] =3D "\nbecause of: ";=0A=
    ret[ret.length] =3D this.cause_;=0A=
    if (this.cause_ instanceof Error) {=0A=
      ret[ret.length] =3D this._parseStackTrace(this.cause_.stack);=0A=
    }=0A=
  }=0A=
=0A=
  return ret.join("\n");=0A=
}=0A=
=0A=
/**=0A=
 * Parses the stack trace.=0A=
 *=0A=
 * @return string: The parsed stack trace.=0A=
 */=0A=
class$._parseStackTrace =3D function (theStack)=0A=
{=0A=
  if (!theStack) {=0A=
    // the client side doesn't know the stack=0A=
    return "";=0A=
  }=0A=
  var ret =3D "";=0A=
  var trace =3D theStack.split("\n");=0A=
  for (var i =3D trace.length - 1; i -- > 0;) {=0A=
    var curr =3D trace[i];=0A=
    if (curr.indexOf(this.static_.EXCEPTION_FILE_INDEX) > -1) {=0A=
      break;=0A=
    }=0A=
    if (curr.indexOf("()") =3D=3D 0) {=0A=
      curr =3D curr.substr(2);=0A=
    }=0A=
    ret =3D curr.replace(/\)\@file\:/g, ")\n@file:") + (ret ? "\n" : "") =
+ ret;=0A=
  }=0A=
  return ret;=0A=
}=0A=
=0A=
/**=0A=
 * Gets the exception description.=0A=
 *=0A=
 * @param aLanguage: String: the target language.=0A=
 * @return String: The exception's description.=0A=
 */=0A=
class$.getDescription =3D function(aLanguage) {=0A=
  // get client language=0A=
  var client_language =3D aLanguage;=0A=
  if (typeof aLanguage !=3D "string") {=0A=
    client_language =3D "en";=0A=
  }=0A=
  var ex_description =3D null;=0A=
  try {=0A=
    // read resources=0A=
    var resource =3D new com.hyperwave.res.Resource({templateKey_: =
this.static_.NAME});=0A=
    resource.makeRoot();=0A=
    var text_resource_reader =3D new =
com.hyperwave.res.XMLResourceReader({=0A=
                      xmlFileName_: this.static_.RESOURCE_FILE_NAME + =
"." + client_language + ".xml"=0A=
                    });=0A=
    resource.readAll(text_resource_reader);=0A=
    for (var i =3D 0; i < this.messageArray_.length; i++) {=0A=
      var resourceKey =3D (i =3D=3D 0) ? "message" : "message_" + i;=0A=
      resource.setRes(resourceKey , this.messageArray_[i]);=0A=
    }=0A=
  =0A=
    // get message=0A=
    var ex_description =3D resource.toString();=0A=
    if (resource.error_) {=0A=
      ex_description =3D null;=0A=
      throw resource.error_; // error_ is lang.Exception=0A=
    }=0A=
  }=0A=
  catch (e) {=0A=
    if (typeof(writelnError) !=3D "undefined") {=0A=
      writelnError("Error getting exception description: " + =
e.toString());=0A=
    }=0A=
  }=0A=
  if (ex_description =3D=3D null) {=0A=
    ex_description =3D this.message_;=0A=
  }=0A=
  return ex_description;=0A=
}=0A=
=0A=
/**=0A=
 * Turns an object into a lang.Exception=0A=
 * @param anObject: Object: an arbitrary (usually caught) object=0A=
 * @return lang.Exception: the exception=0A=
 */=0A=
class$.static_.fromObject =3D function(anObject) {=0A=
  if (anObject instanceof lang.Exception) {=0A=
    return anObject;=0A=
  }=0A=
  else {=0A=
    return new lang.Exception(anObject.toString());=0A=
  }=0A=
}=0A=
=0A=
/**=0A=
 * This method returns the stack trace as string.=0A=
 * @return: string: the stack trace=0A=
 */=0A=
class$.getStackTrace =3D function () {=0A=
  var stack_ =3D this.internalTrick_.stack;=0A=
=0A=
  stack_ =3D stack_.replace(/\n\(/g, "\n<anonymous function>(");=0A=
  stack_ =3D stack_.replace(/\s+$/, "");=0A=
  stack_ =3D stack_.split("\n").reverse().join(" "); // reverse stack =
trace=0A=
  stack_ =3D stack_.replace(/\@/g, "\n@");=0A=
  stack_ =3D stack_.replace(/^\s+/, "");=0A=
//   stack_ =3D stack_.replace(/\n.*$/, ""); // remove the last line=0A=
//   stack_ =3D stack_.replace(/\n.*$/, ""); // remove the last line=0A=
  return stack_;=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/AbstractCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        AbstractCmd.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: AbstractCmd.js 161899 2011-03-07 13:39:35Z jschipf $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ForCmd" );=0A=
loadClass ( "com.hyperwave.res.IfCmd" );=0A=
loadClass ( "com.hyperwave.res.IterateCmd" );=0A=
loadClass ( "com.hyperwave.res.WithCmd" );=0A=
loadClass ( "com.hyperwave.res.DebugCmd" );=0A=
loadClass ( "com.hyperwave.res.PlaceCmd" );=0A=
loadClass ( "com.hyperwave.res.IncludeCmd" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This abstract class combines a general constructor for=0A=
 * and language constructs and a factory that creates commands=0A=
 * by means of a command name.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.AbstractCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Sets the <i>data placeholder</i> of commands. This constructor=0A=
   * assumes that the parameter object has the right properties because=0A=
   * commands should not be constructed outside this class.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.expression_: String: The name of the data=0A=
   *   placeholder for this command.=0A=
   */=0A=
  com.hyperwave.res.AbstractCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.expression_ =3D aParam.expression_;=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.AbstractCmd );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parse the command's body into the command structure. This=0A=
   * function will be called by the enclosing template's parser=0A=
   * to <i>continue</i> parsing. Note that a command must always=0A=
   * end with an end command. The parsing function returns a=0A=
   * parser state like defined in the template class.=0A=
   * @param theTemplateTail: String: the template string which=0A=
   *   follows the begin of the current command.=0A=
   * @return Object: the state object.=0A=
   * @see com.hyperwave.res.Template=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    // abstract!=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means=0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @param theEnv: com.hyperwave.res.ScopedMap: the current environment.=0A=
   * @return String: the final string after evaluation=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    // abstract!=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This factory is used to get a command classs by means of a command=0A=
   * string. Currently this factory is "wired" but it can use an=0A=
   * abstract class loading too.=0A=
   * @param aParam: Object: with the following properties=0A=
   * @param aParam.command_: String: the command string like=0A=
   *   <code>for</code>=0A=
   * @param aParam.dataPHolder_: String: the name of the command's=0A=
   *   data placeholder. This placeholder will be used to evaluate=0A=
   *   the command.=0A=
   * @return com.hyperwave.res.AbstractCmd: a command object.=0A=
   */=0A=
  class$.static_.getCommand =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D null ||=0A=
         aParam.command_ =3D=3D null )=0A=
      return null;=0A=
=0A=
    var cmd;=0A=
    switch ( aParam.command_ )=0A=
    {=0A=
    case "if":=0A=
      cmd =3D new com.hyperwave.res.IfCmd ( aParam );=0A=
      break;=0A=
    case "for":=0A=
      cmd =3D new com.hyperwave.res.ForCmd ( aParam );=0A=
      break;=0A=
    case "iterate":=0A=
      cmd =3D new com.hyperwave.res.IterateCmd ( aParam );=0A=
      break;=0A=
    case "with":=0A=
      cmd =3D new com.hyperwave.res.WithCmd ( aParam );=0A=
      break;=0A=
    case "debug":=0A=
      cmd =3D new com.hyperwave.res.DebugCmd ( aParam );=0A=
      break;=0A=
    case "place":=0A=
      cmd =3D new com.hyperwave.res.PlaceCmd ( aParam );=0A=
      break;=0A=
    case "ebc":=0A=
      cmd =3D new com.hyperwave.res.EbcCmd ( aParam );=0A=
      break;=0A=
    case "include":=0A=
      cmd =3D new com.hyperwave.res.IncludeCmd ( aParam );=0A=
      break;=0A=
    case "source":=0A=
      cmd =3D new com.hyperwave.res.SourceCmd ( aParam );=0A=
      break;=0A=
    }=0A=
    =0A=
    return cmd;=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.AbstractCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/AbstractResource.js?cachekeY=515488b2-en

/* =0A=
 * <copyright> =0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright> =0A=
 * =0A=
 * <file> =0A=
 *  Name:        AbstractResource.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: AbstractResource.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This abstract class provides the basic interface for all=0A=
 * Resource Classes. It consists of the methods =0A=
 * <code>toString</code> and <code>toSource</code>. =0A=
 * Since native JavaScript strings are used as resources (performance!)=0A=
 * AbstractResource has to provide the same interface. That is why =0A=
 * the specified method names are chosen.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.AbstractResource">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The Constructor of this class is only used for prototyping.=0A=
   */=0A=
  com.hyperwave.res.AbstractResource =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.error_ =3D null;=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.AbstractResource );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Provides a kind of <i>transport mechanism</i>=0A=
   * to transport Resource objects to the client. The output=0A=
   * of the function must always be a valid JavaScript string=0A=
   * that is executable on all supported JavaScript engines.=0A=
   * @return String: an executable JavaScript representation=0A=
   *   of a Resource object.=0A=
   */=0A=
  class$.toSource =3D function ()=0A=
  {=0A=
    // abstract !=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Provides the basic mechanism of creating an output=0A=
   * string from a Resource class.=0A=
   * @return String: a HTML portion of the user interface.=0A=
   */=0A=
  class$.toString =3D function ()=0A=
  {=0A=
    // abstract !=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.AbstractResource" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/AbstractResourceReader.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        AbstractResourceReader.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: AbstractResourceReader.js 164481 2011-06-10 13:26:41Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * An <code>AbstractResourceReader</code> defines a model for reading=0A=
 * and accessing resources and templates from the file system or the =
server. =0A=
 * These readers provide a simple map structure which can be accessed =0A=
 * directly using keys. Furthermore it can be stepped through using the =0A=
 * built-in iteration mechanism.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.AbstractResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Constructs an <code>AbstractResrouceReader</code> which only=0A=
   * prepares the intrinsic arrays and the iteration mechanism.=0A=
   */=0A=
  com.hyperwave.res.AbstractResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.keyArray_ =3D [];=0A=
    this.resArray_ =3D {};=0A=
    this.iteratorIndex_ =3D 0;=0A=
=0A=
    this.error_ =3D null;=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Sets (or overrides) a key - value pair of the internal structure.=0A=
   * @param aKey: String: the key that gets an associated value=0A=
   * @param aRes: Object: the associated object (or resource)=0A=
   */=0A=
  class$.setRes =3D function ( aKey, aRes )=0A=
  {=0A=
    this.keyArray_ [this.keyArray_.length] =3D aKey;=0A=
    this.resArray_ [aKey] =3D aRes;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Get a resource by key.=0A=
   * @param aKey: string: the key by which the resource is referenced=0A=
   * @return Object: the object referenced by this key or=0A=
   *   null if the key is not present.=0A=
   */=0A=
  class$.getRes =3D function ( aKey )=0A=
  {=0A=
    return this.resArray_ [aKey];=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  //                       Iterator Interface=0A=
  //--------------------------------------------------------------------=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Initialize the iteration process.=0A=
   */=0A=
  class$.initIteration =3D function ()=0A=
  {=0A=
    this.iteratorIndex_ =3D 0;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Check, whether or not there exists another key for the iteration.=0A=
   * @return Boolean: true if another key is there for iteration.=0A=
   */=0A=
  class$.hasNextKey =3D function ()=0A=
  {=0A=
    return ( this.iteratorIndex_ < this.keyArray_.length );=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Gets the next key if there is one. This function will return=0A=
   * null if no key is present for iteration.=0A=
   * @return String: the next key or <code>null</code> if no key=0A=
   *   is left for iteration.=0A=
   */=0A=
  class$.getNextKey =3D function ()=0A=
  {=0A=
    var curr_index =3D this.iteratorIndex_;=0A=
    if ( curr_index =3D=3D this.keyArray_.length )=0A=
      return null;=0A=
=0A=
    ++this.iteratorIndex_;=0A=
    return this.keyArray_ [curr_index];=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Shows a string representation of the reader.=0A=
   * @return String: the string representation=0A=
   */=0A=
  class$.toString =3D function ()=0A=
  {=0A=
    var out_array =3D [ "@com.hyperwave.res.AbstractResourceReader:\n"];=0A=
    =0A=
    this.initIteration ();=0A=
    while ( this.hasNextKey () )=0A=
    {=0A=
      var key =3D this.getNextKey ();=0A=
      out_array [out_array.length] =3D "  " + key + ":=3D'" + =0A=
                                     this.getRes ( key ) + "'\n";=0A=
    }=0A=
    return out_array.join ( "" );=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Returns valid JavaScript code of a fully functional client side =0A=
   * resource reader, <code>CSResourceReader</code>. Can be used to=0A=
   * transport a ResourceReader (read in on server side) to the client.=0A=
   * @return String: a CSResourceReader in its serialized form=0A=
   * @see com.hyperwave.res.CSResourceReader=0A=
   */=0A=
  class$.toSource =3D function ()=0A=
  {=0A=
    // start instantiating a CSResourceReader=0A=
    var ret_arr =3D [ "new com.hyperwave.res.CSResourceReader({" ];=0A=
    res_out =3D [];=0A=
    // step through all defined resources=0A=
    for ( var i =3D 0; i < this.keyArray_.length; ++i )=0A=
    {=0A=
      var key =3D this.keyArray_ [i];=0A=
      var res =3D this.resArray_ [key];=0A=
      =0A=
      // if resource is a template, create JS code for a template=0A=
      if ( res.isTemplate_ )=0A=
      {=0A=
        res_out.push ( "'" + key + =0A=
          "': new com.hyperwave.res.Template({ templateString_: '" + =
com.hyperwave.res.ScopedMap.static_.escapeString(res.getTemplateString())=
 + "'})" );=0A=
      }=0A=
      // otherwise simply encode and decode=0A=
      else=0A=
      {=0A=
        res_out.push ( "'" + key + "': '" + =
com.hyperwave.res.ScopedMap.static_.escapeString(res) + "'" );=0A=
      }=0A=
    }=0A=
    ret_arr.push ( res_out.join ( ", " ) );=0A=
    ret_arr.push ( "});\n" );  =0A=
    =0A=
    return ( ret_arr.join ( "" ) );=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.AbstractResourceReader.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/CSResourceReader.js?cachekeY=515488b2-en

/*=0A=
* <copyright>=0A=
* Copyright (c) Hyperwave GmbH 2010=0A=
* </copyright>=0A=
*=0A=
* <file>=0A=
* Name:    CSResourceReader.js=0A=
* Created: 2001-04-03 Mair Martin=0A=
* $Id: CSResourceReader.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
* </file>=0A=
*/=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
=0A=
//------------------------------------------------------------=0A=
/**=0A=
 * A <code>CSResourceReader</code> represents a possibility for dealing=0A=
 * with resources from a file on client side. The class is normally=0A=
 * not used explicitely by the programmer but instantiated using the=0A=
 * method <code>toSource()</code> of <code>ResourceReader</code>.=0A=
 * =0A=
 * @author Mair Martin=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.CSResourceReader">=0A=
=0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * Creates a <code>CSResourceReader</code> to have the possibility of =
a =0A=
   * resource reader also on client side. The parameter of the =
constructor =0A=
   * defines the resource array for the reader. Normally the resource =
was =0A=
   * read in on server side already and transported to client side using=0A=
   * method <code>toSource()</code> of <code>ResourceReader</code>.=0A=
   * @param aParam: String: valid JavaScript representation of a =
resource =0A=
   *                        array for the reader. (Escaped and =
unescaped).=0A=
   */=0A=
  com.hyperwave.res.CSResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    if ( aParam =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.CSResourceReader: Constructed without =
resource array" );=0A=
      return;=0A=
    }=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    this.resArray_ =3D aParam;=0A=
    this._createKeyArray();=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.CSResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
  =0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * creates the internal property <code>keyArray_</code> from the =0A=
   * given property <code>resArray_</code>=0A=
   */=0A=
  class$._createKeyArray =3D function ()=0A=
  {=0A=
    this.keyArray_ =3D new Array();=0A=
    for (var key in this.resArray_)=0A=
    {=0A=
      this.keyArray_ [this.keyArray_.length] =3D key;=0A=
    }=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//-----------------------------------------------------------------------=
-----=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/DebugCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        DebugCmd.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: DebugCmd.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This "pseudo" command writes the content of a placeholder=0A=
 * by means of the placeholder's <code>toSource</code> method.=0A=
 * It can be used like the <i>iterate</i> command but it has=0A=
 * some addititional output.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.DebugCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.DebugCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
    this.dataPHolder_ =3D com.hyperwave.res.Template.static_.parsePH ( =
this.expression_ );=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.DebugCmd, =0A=
                       com.hyperwave.res.AbstractCmd );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the rest of the <code>for</code> command. This is done=0A=
   * by finding the next <code>endfor</code>.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    //writeln ( "DDDDDEBUG: debug command" );=0A=
    var state =3D {};=0A=
    state.textTail_ =3D theTemplateTail;=0A=
    return state;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means =0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    var out_array =3D [];=0A=
    out_array [out_array.length] =3D =
"\n-------------------------------------";=0A=
    out_array [out_array.length] =3D "Debug:";=0A=
    out_array [out_array.length] =3D "  Placeholder Name: " + =
this.dataPHolder_;=0A=
    out_array [out_array.length] =3D "  Placeholder Value: >>>>";=0A=
    =0A=
    value =3D theEnv.get ( this.dataPHolder_ );=0A=
    if ( value =3D=3D null )=0A=
      out_array [out_array.length] =3D value;=0A=
    else =0A=
      out_array [out_array.length] =3D value.toSource ();=0A=
    out_array [out_array.length] =3D "<<<<\n";=0A=
    out_array [out_array.length] =3D =
"-------------------------------------\n";=0A=
    writelnError ( out_array.join ("\n") );=0A=
    return out_array.join ("\n");=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.DebugCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ForCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        ForCmd.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: ForCmd.js 162727 2011-04-29 11:23:11Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Defines the behaviour of a template's for command.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ForCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.ForCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    /**=0A=
     * Holds the parsed placeholder or null in case of invalid =
placeholder =0A=
     */=0A=
    this.parsedPHolder_ =3D  =0A=
      com.hyperwave.res.Template.static_.parsePH ( this.expression_ );=0A=
=0A=
    /**=0A=
     * Error flag is set when supplied placeholder is invalid=0A=
     */=0A=
    if ( this.parsedPHolder_ =3D=3D null ) =0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
            "com.hyperwave.res.ForCmd: Invalid placeholder '" +=0A=
            this.expression_ + "'." );=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.ForCmd, =0A=
                       com.hyperwave.res.AbstractCmd );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the rest of the <code>for</code> command. This is done=0A=
   * by finding the next <code>endfor</code>.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    this.forBodyTemplate_ =3D =0A=
      new com.hyperwave.res.Template =0A=
        ( { templateString_: theTemplateTail } );=0A=
    var state =3D =0A=
      this.forBodyTemplate_.continueParse ( theTemplateTail, { =
endfor:true, elsefor:true } );=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D "elsefor" )=0A=
    {=0A=
      this.elseBodyTemplate_ =3D=0A=
        new com.hyperwave.res.Template =0A=
          ( { templateString_: state.textTail_ } );=0A=
      state =3D =0A=
        this.elseBodyTemplate_.continueParse ( state.textTail_, { =
endfor:true } );=0A=
    }=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D null )=0A=
    {=0A=
      state.textTail_ =3D theTemplateTail;=0A=
      state.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.ForCmd: Could not find *endfor* statement." );=0A=
      return state;=0A=
    }=0A=
=0A=
    return state;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means =0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    var ScopedMap =3D com.hyperwave.res.ScopedMap;=0A=
    var array =3D theEnv.get ( this.parsedPHolder_ );=0A=
=0A=
    if ( ( array =3D=3D null ) || ( array.length =3D=3D 0 ) )=0A=
    {=0A=
      if ( this.elseBodyTemplate_ )=0A=
        return this.elseBodyTemplate_.fill ( theEnv );=0A=
      else=0A=
        return "";=0A=
    }=0A=
=0A=
    var for_map =3D {};=0A=
    var for_env =3D new ScopedMap ( theEnv, for_map );=0A=
    var out_array =3D [];=0A=
    var line_ctr =3D 0;=0A=
=0A=
    for ( var i =3D 0; i < array.length; ++i )=0A=
    {=0A=
      ++line_ctr;=0A=
      row_data =3D array [i];=0A=
      for_map.even =3D (line_ctr & 0x01) ? "" : "1";=0A=
      for_map.key =3D i;=0A=
      for_map.value =3D array [i];=0A=
      for_map.line =3D line_ctr;=0A=
      for_map.isFirst =3D (i =3D=3D 0);=0A=
      for_map.isLast =3D (i =3D=3D array.length - 1);=0A=
      var cur_env =3D new ScopedMap ( for_env, row_data );    =0A=
      out_array [out_array.length] =3D this.forBodyTemplate_.fill ( =
cur_env );=0A=
    }=0A=
    =0A=
    return out_array.join ("");=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.ForCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/IfCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        IfCmd.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: IfCmd.js 162727 2011-04-29 11:23:11Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Defines the behaviour of a template's for command.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.IfCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.IfCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
 =0A=
    /**=0A=
     * A function evaluating the parsed expression.=0A=
     */=0A=
    this.funPHolder_ =3D =0A=
      com.hyperwave.res.Template.static_.parseExpr ( this.expression_ );=0A=
=0A=
    /**=0A=
     * Error flag is set when supplied placeholder is invalid.=0A=
     */=0A=
    if ( this.funPHolder_ =3D=3D null ) =0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
            "com.hyperwave.res.IfCmd: Invalid placeholder expression '" +=0A=
            this.expression_ + "'." );=0A=
=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.IfCmd, =0A=
                       com.hyperwave.res.AbstractCmd );=0A=
                       =0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the rest of the <code>if</code> command. This is done=0A=
   * by finding the next <code>endif</code> or <code>else</code>.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    this.ifTemplate_ =3D =0A=
      new com.hyperwave.res.Template =0A=
        ( { templateString_: theTemplateTail } );=0A=
    var state =3D =0A=
      this.ifTemplate_.continueParse ( theTemplateTail, { endif:true, =
"else":true, "elseif":true } );=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( ( state.parsedEndCmd_ =3D=3D "else" ) || ( state.parsedEndCmd_ =
=3D=3D "elseif" ) )=0A=
    {=0A=
      this.elseTemplate_ =3D=0A=
        new com.hyperwave.res.Template =0A=
          ( { templateString_: state.textTail_ } );=0A=
      state =3D =0A=
        this.elseTemplate_.continueParse ( state.textTail_, { endif:true =
} );=0A=
    }=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D null )=0A=
    {=0A=
      state.textTail_ =3D theTemplateTail;=0A=
      state.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.IfCmd: Could not find *endif* statement." );=0A=
      return state;=0A=
    }=0A=
=0A=
    return state;=0A=
  };=0A=
=0A=
 //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means =0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    var condition =3D this.funPHolder_ ( theEnv );=0A=
=0A=
    if ( condition )=0A=
      return ( this.ifTemplate_.fill ( theEnv ) );=0A=
=0A=
    if ( this.elseTemplate_ )=0A=
      return ( this.elseTemplate_.fill ( theEnv ) );=0A=
=0A=
    return "";=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.IfCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/IterateCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        IterateCmd.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: IterateCmd.js 162732 2011-04-29 11:59:37Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Defines the behaviour of a template's iterate command.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.IterateCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.IterateCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    /**=0A=
     * Holds the parsed placeholder or null in case of invalid =
placeholder =0A=
     */=0A=
    this.parsedPHolder_ =3D  =0A=
      com.hyperwave.res.Template.static_.parsePH ( this.expression_ );=0A=
=0A=
    /**=0A=
     * Error flag is set when supplied placeholder is invalid=0A=
     */=0A=
    if ( this.parsedPHolder_ =3D=3D null )      =0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.IterateCmd: Invalid placeholder '" +=0A=
        this.dataPHolder_ + "'." );=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.IterateCmd, =0A=
                       com.hyperwave.res.AbstractCmd );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the rest of the <code>for</code> command. This is done=0A=
   * by finding the next <code>endfor</code>.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    this.forBodyTemplate_ =3D =0A=
      new com.hyperwave.res.Template =0A=
        ( { templateString_: theTemplateTail } );=0A=
    var state =3D =0A=
      this.forBodyTemplate_.continueParse ( theTemplateTail, { =
enditerate:true, elseiterate:true } );=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D "elseiterate" )=0A=
    {=0A=
      this.elseBodyTemplate_ =3D=0A=
        new com.hyperwave.res.Template =0A=
          ( { templateString_: state.textTail_ } );=0A=
      state =3D =0A=
        this.elseBodyTemplate_.continueParse ( state.textTail_, { =
enditerate:true } );=0A=
    }=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D null )=0A=
    {=0A=
      state.textTail_ =3D theTemplateTail;=0A=
      state.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.IterateCmd: Could not find *enditerate* =
statement." );=0A=
      return state;=0A=
    }=0A=
=0A=
    return state;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means =0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    var ScopedMap =3D com.hyperwave.res.ScopedMap;=0A=
    var array =3D theEnv.get ( this.parsedPHolder_ );=0A=
    var iterate_map =3D {};=0A=
    var iterate_env =3D new ScopedMap ( theEnv, iterate_map );=0A=
    var line_ctr =3D 0;=0A=
    var out_array =3D [];=0A=
=0A=
    if ( array =3D=3D null )=0A=
      return this.elseBodyTemplate_.fill ( theEnv );=0A=
=0A=
    for ( var i in array )=0A=
    {=0A=
      if ( i =3D=3D "key" || i =3D=3D "line" || i =3D=3D "value" || i =
=3D=3D "even" )=0A=
        continue;=0A=
      ++line_ctr;=0A=
      row_data =3D array [i];=0A=
      iterate_map.key =3D i;=0A=
      iterate_map.value =3D array [i];=0A=
      iterate_map.even =3D (line_ctr & 0x01) ? "" : "1";=0A=
      iterate_map.line =3D line_ctr;=0A=
      var for_env =3D new ScopedMap ( iterate_env, row_data );=0A=
      out_array [out_array.length] =3D this.forBodyTemplate_.fill ( =
for_env );=0A=
    }=0A=
=0A=
    if (line_ctr =3D=3D 0)=0A=
      return this.elseBodyTemplate_.fill ( theEnv );=0A=
      =0A=
    return out_array.join ("");=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.IterateCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/PlaceCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        PlaceCmd.js=0A=
 *  Created:     2007-31-05=0A=
 * </file>=0A=
 *=0A=
 * $Id: PlaceCmd.js 162732 2011-04-29 11:59:37Z cgoess $=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Defines the behaviour of a template's for command.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.PlaceCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.PlaceCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
 =0A=
    this.placeHolder_ =3D this.expression_;=0A=
=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.PlaceCmd,=0A=
                       com.hyperwave.res.AbstractCmd );=0A=
                       =0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Do not parse the rest of the <code>place</code> command.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
   =0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    var state =3D {};=0A=
    state.textTail_ =3D theTemplateTail;=0A=
    return state;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means=0A=
   * that the data placeholder is evaluated and iterated in this=0A=
   * case.=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    if (typeof(this.placeHolder_) =3D=3D "undefined" || =
this.placeHolder_ =3D=3D "")=0A=
      return "Error in place command! no placeholder passed!!!";=0A=
      =0A=
    var out_place =3D place(this.placeHolder_);=0A=
    if (typeof(out_place.error) =3D=3D "function" && out_place.error())=0A=
    {=0A=
      // error occured!!!=0A=
      out_place =3D out_place.asString();=0A=
    }=0A=
    return out_place;=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.PlaceCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/WithCmd.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        IterateCmd.js=0A=
 *  Created:     2001-03-29=0A=
 *  $Id: WithCmd.js 162732 2011-04-29 11:59:37Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Defines the behaviour of a template's with command.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.WithCmd">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Construct the for command node.=0A=
   * @see com.hyperwave.res.AbstractCmd=0A=
   */=0A=
  com.hyperwave.res.WithCmd =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractCmd;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    /**=0A=
     * Holds the parsed placeholder or null in case of invalid =
placeholder =0A=
     */=0A=
    this.parsedPHolder_ =3D  =0A=
      com.hyperwave.res.Template.static_.parsePH ( this.expression_ );=0A=
=0A=
    /**=0A=
     * Error flag is set when supplied placeholder is invalid=0A=
     */=0A=
    if ( this.parsedPHolder_ =3D=3D null ) =0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
            "com.hyperwave.res.WithCmd: Invalid placeholder '" +=0A=
            this.expression_ + "'." );=0A=
  };  =0A=
  class$ =3D doInherit ( com.hyperwave.res.WithCmd, =0A=
                       com.hyperwave.res.AbstractCmd );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the rest of the <code>with</code> command. This is done=0A=
   * by finding the next <code>endwith</code>.=0A=
   * @see com.hyperwave.res.AbstractCmd#doParse=0A=
   */=0A=
  class$.doParse =3D function ( theTemplateTail )=0A=
  {=0A=
    this.withBodyTemplate_ =3D =0A=
      new com.hyperwave.res.Template =0A=
        ( { templateString_: theTemplateTail } );=0A=
    var state =3D =0A=
      this.withBodyTemplate_.continueParse ( theTemplateTail, { =
endwith:true } );=0A=
=0A=
    if ( state.error_ )=0A=
      return state;=0A=
=0A=
    if ( state.parsedEndCmd_ =3D=3D null )=0A=
    {=0A=
      state.textTail_ =3D theTemplateTail;=0A=
      state.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.WithCmd: Could not find *endwith* statement." =
);=0A=
      return state;=0A=
    }=0A=
=0A=
    return state;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Executes the command in the given environment. This means =0A=
   * that the data placeholder is evaluated and the scope is extended=0A=
   * thus the properties can be accessed via placeholders=0A=
   *=0A=
   * @see com.hyperwave.res.AbstractCmd#execCmd=0A=
   */=0A=
  class$.execCmd =3D function ( theEnv )=0A=
  {=0A=
    var ScopedMap =3D com.hyperwave.res.ScopedMap;=0A=
    var obj_data =3D theEnv.get ( this.parsedPHolder_ );=0A=
=0A=
    if ( obj_data =3D=3D null )=0A=
    {=0A=
      return "($UNKNOWN VALUE OF:" + this.parsedPHolder_ + ")";=0A=
    }=0A=
    =0A=
    var with_env =3D new ScopedMap ( theEnv, obj_data );=0A=
=0A=
    return this.withBodyTemplate_.fill ( with_env );=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.WithCmd.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/MapStack.js?cachekeY=515488b2-en

/* =0A=
 * <copyright> =0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright> =0A=
 * =0A=
 * <file> =0A=
 *  Name:        MapStack.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: MapStack.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This class provides a <i>stack</i> of maps from string keys=0A=
 * to <code>Resource</code> objects. It must be capable of =0A=
 * constructing a new map stack by a given stack (or an empty one)=0A=
 * and a new map and must be able to search the whole stack for=0A=
 * a given key.=0A=
 * @author Simon Zwoelfer=0A=
 * @see com.hyperwave.res.AbstractResource=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.MapStack">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
    * Constructs a new MapStack by means of a given one=0A=
    * or, if none is given, an empty MapStack.=0A=
    * @param aParam: MapStack | void: this value can either=0A=
    *   be <code>null</code> or an existing stack can be=0A=
    *   used to construct a new one by copying all references=0A=
    *   of the old one. Hence the new stack will not influence=0A=
    *   the old stack but has the same conent!=0A=
    */=0A=
  com.hyperwave.res.MapStack =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    if ( aParam !=3D null && aParam.stack_ !=3D null )=0A=
      this.stack_ =3D [].concat ( aParam.stack_ );=0A=
    else=0A=
      this.stack_ =3D [];=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.MapStack );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Add a map to the stack.=0A=
   * @param aMap: Object: the map to be added=0A=
   */=0A=
  class$.pushMap =3D function ( aMap )=0A=
  {=0A=
    this.top_ =3D this.stack_ [this.stack_.length] =3D aMap;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Get a value by means of a given key, or null if the key is not=0A=
   * present in any map of the stack. The most upper key is found.=0A=
   * @param aKey: string: the key specifying the desired map item=0A=
   * @return Object: the value of the given key=0A=
   */=0A=
  class$.get =3D function ( aKey )=0A=
  {=0A=
    for ( var map_ctr =3D this.stack_.length - 1;=0A=
          map_ctr >=3D 0;=0A=
          --map_ctr )=0A=
    {=0A=
      var cur_map =3D this.stack_ [map_ctr];=0A=
      value =3D cur_map [ aKey ];=0A=
      if ( value !=3D null )=0A=
        return value;=0A=
    }=0A=
    return null;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Set a value of the map stack. This always influences the top=0A=
   * map!=0A=
   * @param aKey: String: the key which should be set=0A=
   * @param aValue: Object: the associated value=0A=
   */=0A=
  class$.put =3D function ( aKey, aValue )=0A=
  {=0A=
    if ( this.top_ )=0A=
    {=0A=
      this.top_ [aKey] =3D aValue;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.pushMap ( {} );=0A=
      this.top_ [aKey] =3D aValue;=0A=
    }=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Primitive test for the class.=0A=
   * @return String[]: an array with string errors for the class=0A=
   */=0A=
  class$.static_.test =3D function ()=0A=
  {=0A=
    var errors =3D [];=0A=
    var map1 =3D { a: "a", b: "b" };=0A=
    var map2 =3D { c: "c", a: "a2" };=0A=
    var map_s1 =3D new com.hyperwave.res.MapStack ();=0A=
    if ( map_s1.get ( "a" ) !=3D null )=0A=
      errors [errors.length] =3D "(1) Empty Stack gives values";=0A=
=0A=
    // Test Basic Map:=0A=
    map_s1.pushMap ( map1 );=0A=
    if ( map_s1.get ( "a" ) !=3D "a" ||=0A=
         map_s1.get ( "b" ) !=3D "b" ||=0A=
         map_s1.get ( "c" ) !=3D null )=0A=
      errors [errors.length] =3D "(2) Basic access does not work";=0A=
=0A=
    map_s1.put ( "c", "x" );=0A=
    if ( map_s1.get ( "a" ) !=3D "a" ||=0A=
         map_s1.get ( "b" ) !=3D "b" ||=0A=
         map_s1.get ( "c" ) !=3D "x" )=0A=
      errors [errors.length] =3D "(3) Basic access after put does not =
work";=0A=
    =0A=
    // Create new Stack by means of Stack above and put=0A=
    // overriding values in it ...=0A=
    var map_s2 =3D new com.hyperwave.res.MapStack ( map_s1 );=0A=
=0A=
    // Test the clone ...=0A=
    if ( map_s2.get ( "a" ) !=3D "a" ||=0A=
         map_s2.get ( "b" ) !=3D "b" ||=0A=
         map_s2.get ( "c" ) !=3D "x" )=0A=
      errors [errors.length] =3D "(4) Basic access after clone does not =
work";=0A=
=0A=
    // Put something ...=0A=
    map_s2.put ( "d", "d" );=0A=
    if ( map_s2.get ( "a" ) !=3D "a" ||=0A=
         map_s2.get ( "b" ) !=3D "b" ||=0A=
         map_s2.get ( "d" ) !=3D "d" ||=0A=
         map_s2.get ( "c" ) !=3D "x" )=0A=
      errors [errors.length] =3D "(4.1) Basic access after clone does =
not work";=0A=
=0A=
    map_s2.pushMap ( map2 );=0A=
    if ( map_s2.get ( "a" ) !=3D "a2" ||=0A=
         map_s2.get ( "b" ) !=3D "b" ||=0A=
         map_s2.get ( "c" !=3D "c" ) )=0A=
      errors [errors.length] =3D "(5) Overrideen access does not work";=0A=
=0A=
    map_s1.put ( "x", "s1x" );=0A=
    map_s1.put ( "y", "s1y" );=0A=
    map_s2.put ( "x", "s2x" );=0A=
    map_s2.put ( "z", "s2z" );=0A=
    if ( map_s1.get ( "z" ) !=3D null ||=0A=
         map_s2.get ( "x" ) !=3D "s2x" ||=0A=
         map_s2.get ( "z" ) !=3D "s2z" ||=0A=
         map_s2.get ( "y" ) !=3D "s1y" )=0A=
      errors [errors.length] =3D "(6) Overrideen access after put does =
not work";=0A=
    =0A=
    return errors;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Tests the class.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    var errors =3D this.test ();=0A=
    if ( errors.length =3D=3D 0 )=0A=
      writeln ( "Test of MapStack ok" );=0A=
    else=0A=
      writeln ( "Test of MapStack gives the following Errors: \n  " + =0A=
                errors.join ( "\n  " ) + "\n" );=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.MapStack.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ResourceException.js?cachekeY=515488b2-en

/* =0A=
 * <copyright> =0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright> =0A=
 * =0A=
 * <file> =0A=
 *  Name:        AbstractResource.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: ResourceException.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "lang.Exception" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This exception class wraps all current resource exceptions.=0A=
 * The only purpose is to hold an array which can get a kind=0A=
 * of error stack. =0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ResourceException">=0A=
{=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
    * Creates an exception instance for resource error handling.=0A=
    */=0A=
  com.hyperwave.res.ResourceException =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D lang.Exception;=0A=
    this.base$ ( aParam );=0A=
=0A=
    this.exceptionName_ =3D "com.hyperwave.res.ResourceException";=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.ResourceException, =
lang.Exception );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Test main routine=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    var x =3D new com.hyperwave.res.ResourceException ( "Error 1" );=0A=
    x.pushError ( "Error 2" );=0A=
    writeln ( x.toString () );=0A=
  }=0A=
=0A=
}=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.ResourceException" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/Resource.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        Resource.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: Resource.js 164512 2011-06-14 15:34:30Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResource" );=0A=
loadClass ( "com.hyperwave.res.ResourceReader" );=0A=
loadClass ( "com.hyperwave.res.ScopedMap" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Class represents a simple resource which contains a template with =0A=
 * placeholders as well as string resources. =0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.Resource">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Constructs a simple [compound] resource by means of=0A=
   * an empty template or a string template.=0A=
   * @param aParam: void | Object: contains the template's key=0A=
   * @param aParam.templateKey_: void | String:=0A=
   *   the template key.=0A=
   */=0A=
  com.hyperwave.res.Resource =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResource;=0A=
    this.base$ ( aParam );=0A=
=0A=
    if ( aParam !=3D null )=0A=
    {=0A=
      if ( aParam.templateKey_ )=0A=
        this.templateKey_ =3D aParam.templateKey_;=0A=
      if ( aParam.defaultReader_ )=0A=
        this.defaultReader_ =3D aParam.defaultReader_;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.templateKey_ =3D null;=0A=
      this.defaultReader_ =3D null;=0A=
    }=0A=
=0A=
    /**=0A=
     * The children of this resource.=0A=
     */=0A=
    this.resMap_ =3D null;=0A=
=0A=
    /**=0A=
      * The resource's default template. This template will=0A=
      * be taken if no other template can be found.=0A=
      */=0A=
    this.defaultTemplate_ =3D null;=0A=
=0A=
    /**=0A=
     * The Cache of this resource if it has already been evaluated=0A=
     */=0A=
    this.cachedString_ =3D null;=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.Resource,=0A=
                       com.hyperwave.res.AbstractResource );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Set the parent resource of the current resource. This is done=0A=
   * to <i>join</i> the (scoped) resource maps for the latter=0A=
   * placeholder evaluation.=0A=
   * @param theParentRes: com.hyperwave.res.ScopedMap: the parent=0A=
   *   resource's map.=0A=
   */=0A=
  class$._setParent =3D function ( theParentRes, theDateFormat )=0A=
  {=0A=
    if ( this.resMap_ !=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "Program Error - Resource added twice!" );=0A=
      return true;=0A=
    }=0A=
    this.resMap_ =3D new com.hyperwave.res.ScopedMap ( theParentRes );=0A=
    =0A=
    if(theDateFormat){=0A=
      this.resMap_.set("hw_uidateformat", theDateFormat);=0A=
    }=0A=
    =0A=
    this.error_ =3D null;=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Make the resource a root resource. This marks the resource as the =
root=0A=
   * of a resource tree. <B>REQUIRED:</B> call before assigning =
resources to =0A=
   * the scoped resource map (using <code>setRes()</code> or =0A=
   * <code>readAll()</code>).=0A=
   */=0A=
  class$.makeRoot =3D function (theDateFormat)=0A=
  {=0A=
    this._setParent (null, theDateFormat);=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads a resource reader's templates and strings into the =0A=
   * resource's (scoped) map. Note that the reader's values =0A=
   * override already set values!=0A=
   * @param aReader: com.hyperwave.res.AbstractResourceReader:=0A=
   *   the reader which is used to get the resources.=0A=
   */=0A=
  class$.readAll =3D function ( aReader )=0A=
  {=0A=
    if ( aReader.error_ !=3D null )=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Resource: readAll with an erroneus Reader? " =
+ =0A=
        aReader.error_ );=0A=
=0A=
    aReader.initIteration ();=0A=
    while ( aReader.hasNextKey () )=0A=
    {=0A=
      var key =3D aReader.getNextKey ();=0A=
      this.setRes ( key, aReader.getRes ( key ) );=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Tells the resource by what a certain placeholder should be replaced.=0A=
   * This function is normally used by readers and applications. Readers=0A=
   * assign language strings and templates - applications assign=0A=
   * application specific data and child resource nodes.=0A=
   * The resource or template is then assigned to the internal=0A=
   * <i>resource map</i>.=0A=
   * @param aKey: String: key of the placeholder =0A=
   * @param aRes: com.hyperwave.res.AbstractResource: =0A=
   *               replacement for the specified placeholder (can also =
be of type=0A=
   *               <CODE>com.hyperwave.res.Template</CODE>)=0A=
   */=0A=
  class$.setRes =3D function ( aKey, aRes )=0A=
  {=0A=
    // if someone is trying to assign something unknown - raise an error =
and leave=0A=
    if (typeof aRes =3D=3D "undefined") {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Resource: Method setRes was called with =
undefined value for key: " + aKey );=0A=
      return;=0A=
    }=0A=
    =0A=
    if ( typeof aRes._setParent =3D=3D 'function')=0A=
      aRes._setParent ( this.resMap_ );=0A=
=0A=
    if ( this.resMap_ =3D=3D null ) {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Resource: Resource not added or set to root!" =
);=0A=
    }=0A=
    else =0A=
      this.resMap_.set ( aKey, aRes );=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Evaluates a resource to a string. This is done in two steps:=0A=
   * Firstly, a template for the resource must be found. This is done=0A=
   * by means of the initial <code>templateKey_</code> and the resource=0A=
   * maps. If no template can be found the resource tries to=0A=
   * find the template using its <code>defaultReader_</code>.=0A=
   * The template's placeholders are replaced according to the=0A=
   * data of the scoped resource map. The resulting string is returned.=0A=
   * @param forceRebuild: Boolean: if true the string representation=0A=
   *                 is built up newly, the cached version is not used.=0A=
   * @return String: the resulting string.=0A=
   */=0A=
  class$.toString =3D function ( forceRebuild )=0A=
  {=0A=
    if ( (typeof forceRebuild !=3D "undefined") && (forceRebuild =3D=3D =
true) )=0A=
      this.cachedString_ =3D null;=0A=
    =0A=
    if ( this.cachedString_ )=0A=
      return this.cachedString_;=0A=
=0A=
    if ( this.templateKey_ =3D=3D null )=0A=
      return ( this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Resource: No templateKey was defined for =
Resource." ) ).toString();=0A=
=0A=
    if ( this.resMap_ =3D=3D null )=0A=
      return ( this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Resource: Resource not added or set to root!" =
) ).toString();=0A=
=0A=
    var template =3D this.resMap_.get ( this.templateKey_ );=0A=
    if ( template =3D=3D null )=0A=
    {=0A=
      if ( this.defaultReader_ =3D=3D null )=0A=
      {=0A=
        return ( this.error_ =3D new com.hyperwave.res.ResourceException =
(=0A=
          "com.hyperwave.res.Resource: No template reader to read =
default template. Used template key: "  + this.templateKey_ + =0A=
          ( this.error_ !=3D null ? ( "Previous (uncaught?) error: " + =
this.error_ ) : "" ) ) );=0A=
      }=0A=
      template =3D this.defaultReader_.getRes ( this.templateKey_ );=0A=
      if ( this.defaultReader_.error_ || =0A=
           template =3D=3D null || =0A=
           template.isTemplate_ =3D=3D false )=0A=
      {=0A=
        this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
          "com.hyperwave.res.Resource: No template found for key '" + =0A=
          this.templateKey_ + "'." );=0A=
        if ( this.defaultReader_.error_ )=0A=
          this.error_.pushError ( this.defaultReader_.error_ );=0A=
        return this.error_;=0A=
      }=0A=
    }=0A=
=0A=
    this.error_ =3D null;=0A=
    if (typeof template =3D=3D "string") {=0A=
      template =3D new com.hyperwave.res.Template({templateString_: =
template});=0A=
    }=0A=
    this.cachedString_ =3D template.fill ( this.resMap_ );=0A=
    return this.cachedString_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Main function to test the resource mechanism.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    gEvalCount =3D 0;=0A=
    writelnError ( "Generating Data ..." );=0A=
    var data =3D {};=0A=
    data.date_ =3D String (new Date().valueOf());=0A=
    data.buttonText_ =3D "This is the full featured Button text";=0A=
    data.logoText_ =3D "base.logotext";=0A=
    data.footerLogoText_ =3D "footer.logotext";=0A=
    data.headerLogoText_ =3D "header.logotext";=0A=
    data.table_ =3D [];=0A=
    var table1_ =3D [ =0A=
      { person: "Tarek", shoeSize: "47" },=0A=
      { person: "Martin", shoeSize: "52" },=0A=
      { person: "J&uuml;rgen", shoeSize: "530" },=0A=
      { person: "Werner", shoeSize: "205" },=0A=
      { person: "Simon", shoeSize: "22" }=0A=
      ];=0A=
    for ( var i =3D 0; i < 1; ++i )=0A=
      data.table_ =3D data.table_.concat ( table1_ );=0A=
=0A=
    writelnError ( "Making Resource Readers ..." );=0A=
    var templ_reader =3D new com.hyperwave.res.ResourceReader ( { =
lrcFileName_: "htmlres1.lrc" } );=0A=
    var lang_reader =3D new com.hyperwave.res.ResourceReader ( { =
lrcFileName_: "restable1.lrc" } );=0A=
//    if ( templ_reader.error_ )=0A=
//    {=0A=
//      writelnError ( "Error in reader: " + templ_reader.error_ );=0A=
//      return;=0A=
//    }=0A=
//    if ( lang_reader.error_ )=0A=
//    {=0A=
//      writelnError ( "Error in reader: " + lang_reader.error_ );=0A=
//      return;=0A=
//    }=0A=
=0A=
    start_tist =3D new Date().valueOf();=0A=
    writelnError ( start_tist + ": Start" );=0A=
=0A=
    var res =3D new com.hyperwave.res.Resource ( { templateKey_:"main" } =
);=0A=
    res.makeRoot ();=0A=
    res.readAll ( templ_reader );=0A=
    res.readAll ( lang_reader );=0A=
    res.setRes ( "date", data.date_ );=0A=
    res.setRes ( "ButtonText", data.buttonText_ );=0A=
    res.setRes ( "table", data.table_ );=0A=
    res.setRes ( "logoText", data.logoText_ );=0A=
=0A=
    var headerx =3D new com.hyperwave.res.Resource ( { =
templateKey_:"header" } );=0A=
    var footerx =3D new com.hyperwave.res.Resource ( { =
templateKey_:"footer" } );=0A=
    res.setRes ( "headerx", headerx );=0A=
    res.setRes ( "footerx", footerx );=0A=
=0A=
    headerx.setRes ( "logoText", data.headerLogoText_ );=0A=
    footerx.setRes ( "logoText", data.footerLogoText_ );=0A=
=0A=
    var out =3D res.toString();=0A=
    write ( out );=0A=
    writelnError ( "Evals: " + gEvalCount );=0A=
    writelnError ( "Chars: " + out.length );=0A=
=0A=
    stop_tist =3D new Date().valueOf();=0A=
    writelnError ( stop_tist + ": End of prepare: duration=3D" + =0A=
                   (stop_tist - start_tist) );=0A=
=0A=
  };=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.Resource.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ResourceManagerIFC.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * $Id: ResourceManagerIFC.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 *  Defines the interface for ResourceManager objects which have to=0A=
 * know about the path to the application resources as well as to=0A=
 * the skin specific resources (for a certain skin).=0A=
 *=0A=
 * =0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ResourceManager">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * <B>Only an interface. Do not instantiate!</B>=0A=
   */=0A=
  com.hyperwave.res.ResourceManagerIFC =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    // should not be instantiated=0A=
    throw "com.hyperave.res.ResourceManagerIFC is an interface only and =
cannot be instantiated!";=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.ResourceManagerIFC );=0A=
=0A=
=0A=
  /**=0A=
   * Returns the root path to the module specific resource directory.=0A=
   * eg. for the LNI demo module: "modules/demo/". Templates can use the =
placeholder=0A=
   * <code>($resroot)</code> to refer to the resource root of the =
currently active=0A=
   * module (specified by =
<code>ResourceManagerIFC.setActiveModule()</code>).=0A=
   * <CODE>SkinXMLResourceReaders</CODE> can have placeholders in their=0A=
   * constructor parameters (eg. <CODE>%resroot% </CODE> will be =
replaced by=0A=
   * the value returned by this method).=0A=
   * @return String: the path to the resources root directory of the =
current module=0A=
   */=0A=
  class$.getResRoot =3D function()=0A=
  {=0A=
    return "";=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the root path to the currently active module.=0A=
   * eg. for the LNI demo module: "modules/demo/".=0A=
   * Templates can use the placeholder=0A=
   * <code>($modroot)</code> to refer to the root of the currently active=0A=
   * module (specified by =
<code>ResourceManagerIFC.setActiveModule()</code>).=0A=
   * The placeholder <code>($modroot)</code> can eg. be used in =
templates for=0A=
   * including client side JavaScripts.=0A=
   * <xmp>=0A=
   * <RES name=3D"script_includes" type=3D"template">=0A=
   *   <script =
src=3D"($fileroot)($modroot)client/csjs/myfunctions.js"></script>=0A=
   * </RES>=0A=
   * </xmp>=0A=
   * @return String: the path to the module root directory=0A=
   */=0A=
  class$.getModuleRoot =3D function()=0A=
  {=0A=
    return "";=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the root path to the application specific skin resource =
directory.=0A=
   * <CODE>SkinXMLResourceReaders</CODE> can have placeholders in their=0A=
   * constructor parameters (eg. <CODE>%skinroot% </CODE> will be =
replaced by=0A=
   * the value returned by this method).=0A=
   * @return String: the path to the skin resources root directory=0A=
   */=0A=
  class$.getSkinRoot =3D function()=0A=
  {=0A=
    return "";=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the root path to the internal filesystem of the server =
("/wavemaster.internal/");.=0A=
   * <CODE>SkinXMLResourceReaders</CODE> can have placeholders in their=0A=
   * constructor parameters (eg. <CODE>%fileroot% </CODE> will be =
replaced by=0A=
   * the value returned by this method).=0A=
   * @return String: the path to the internal filesystem=0A=
   */=0A=
  class$.getFileRoot =3D function()=0A=
  {=0A=
    return "";=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the root path to an external filesystem of a different =
server.=0A=
   * This can be used if static contents like images or stylesheets are =
located=0A=
   * elsewhere (e.g. "http:/external.server.com/images/"). In general =
this method will=0A=
   * probably return the same as=0A=
   * @see ResourceManagerIFC.getFileRoot.=0A=
   * <CODE>SkinXMLResourceReaders</CODE> can have placeholders in their=0A=
   * constructor parameters (eg. <CODE>%extfileroot% </CODE> will be =
replaced by=0A=
   * the value returned by this method).=0A=
   * @return String: the path to a possibly external filesystem=0A=
   */=0A=
  class$.getExternalFileRoot =3D function()=0A=
  {=0A=
    return "";=0A=
  }=0A=
=0A=
=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ResourceManager.js?cachekeY=515488b2-en

/**=0A=
 * Copyright (c) Hyperwave GmbH 2010=0A=
 * $Id: ResourceManager.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 */=0A=
=0A=
/**=0A=
 * The LNI Implementation of the <code>ResourceManagerIFC</code>=0A=
 * to be used with <code>SkinXMLResourceReader</code> for automatic=0A=
 * includes of skin-dependent resource parts.=0A=
 * <BR>=0A=
 * Be aware that this class heavily depends on LNI specific constants=0A=
 * defined in the overall environment!=0A=
 * <BR>=0A=
 * Example usage:=0A=
 * <xmp>=0A=
 *   // get actual user=0A=
 *   var user =3D new HWUser();=0A=
 *   // get a resource manager instance=0A=
 *   var resmanager =3D ResourceManager.static_.getInstance( =
user.getSkinID() );=0A=
 *   // register the currently active module=0A=
 *   resmanager.setActiveModule( module_id );=0A=
 *   // read in the module specific resources=0A=
 *   var resreader =3D new com.hyperwave.res.SkinXMLResourceReader({=0A=
 *                       =
xmlFileName_:"%resroot%client/templates/maintemplate.xml,=0A=
 *                       manager_:manager=0A=
 *                   });=0A=
 *   ...=0A=
 * </xmp>=0A=
 * @author mmair=0A=
 * @deprecated since 2007-05-11 (use eKSResourceManager as default =
implementation)=0A=
 */=0A=
//<JSClass Name=3D"ResourceManager">=0A=
=0A=
  /**=0A=
   * Private constructor! Do not instantiate!=0A=
   * Use factory method instead.=0A=
   * @see ResourceManager#getInstance=0A=
   */=0A=
  ResourceManager =3D function( aParam )=0A=
  {=0A=
    if (aParam =3D=3D "__proto__")=0A=
      return;=0A=
=0A=
    this.skinID =3D aParam;=0A=
    this.moduleId =3D MODULES.DEFAULT;=0A=
    this.activeContext_ =3D "";=0A=
  }=0A=
  class$ =3D doInherit( ResourceManager );=0A=
=0A=
  /**=0A=
   * Registry to cache already instantiated <code>ResourceManager</code>=0A=
   * instances (there exists one singleton per skinID)=0A=
   */=0A=
class$.static_.registry =3D {};=0A=
  /**=0A=
   * Static constant specifying the delimiter of path parts.=0A=
   * Has to be added to a given skinID to have a valid path.=0A=
   */=0A=
  class$.static_.PATH_DELIMITER =3D "/";=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getResRoot=0A=
   */=0A=
  class$.getResRoot =3D function()=0A=
  {=0A=
    try {=0A=
      return APPLICATION_PATH[ this.moduleId ] + REL_PATH_TO_HTMLRES + =
REL_RESOURCE_PATH[ this.moduleId ];=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getResRoot=0A=
   */=0A=
  class$.getLangRoot =3D function()=0A=
  {=0A=
    try {=0A=
      return APPLICATION_PATH[ this.moduleId ] + REL_PATH_TO_LANGRES + =
REL_RESOURCE_PATH[ this.moduleId ];=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getModuleRoot=0A=
   */=0A=
  class$.getModuleRoot =3D function()=0A=
  {=0A=
    // is the same as resroot for LNI (but will differ normally)=0A=
    try {=0A=
      return APPLICATION_PATH[ this.moduleId ];=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getSkinRoot=0A=
   */=0A=
  class$.getSkinRoot =3D function()=0A=
  {=0A=
    try {=0A=
      return PATH_TO_SKINS + this.skinID + this.static_.PATH_DELIMITER;=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getFileRoot=0A=
   */=0A=
  class$.getFileRoot =3D function()=0A=
  {=0A=
    try {=0A=
      return PREFIX_WAVEMASTER;=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getExternalFileRoot=0A=
   */=0A=
  class$.getExternalFileRoot =3D function()=0A=
  {=0A=
    try {=0A=
      return PREFIX_REMOTE_DATA;=0A=
    }=0A=
    catch (e){=0A=
      return "";=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * Assign the currently active module to the resource manager.=0A=
   * Using this information the globally available=0A=
   * <code>APPLICATIONPATH</code> object can be used to retrieve=0A=
   * the path to the root of that module in the current=0A=
   * installation.=0A=
   * @param moduleId: String: the ID of the current active module=0A=
   */=0A=
  class$.setActiveModule =3D function( moduleId )=0A=
  {=0A=
    this.moduleId =3D moduleId;=0A=
  }=0A=
=0A=
  /**=0A=
   * Assign the currently active context to the resource manager.=0A=
   * =0A=
   * @param moduleId: String: the active context=0A=
   */=0A=
  class$.setActiveContext =3D function( theContext )=0A=
  {=0A=
    this.activeContext_ =3D theContext;=0A=
  }=0A=
=0A=
  /**=0A=
   * Get the currently active context of the resource manager.=0A=
   * =0A=
   */=0A=
  class$.getActiveContext =3D function()=0A=
  {=0A=
    return this.activeContext_;=0A=
  }=0A=
=0A=
  /**=0A=
   * Factory method to retrieve the resource manager for the=0A=
   * given skinID. Only one resource manager per skinID exists.=0A=
   * @param skinID: String: the ID of the skin to use=0A=
   * @return ResourceManager: the resource manager for the given ID=0A=
   */=0A=
  class$.static_.getInstance =3D function( skinID )=0A=
  {=0A=
    if (!this.registry[skinID])=0A=
    {=0A=
      this.registry[skinID] =3D new ResourceManager( skinID );=0A=
    }=0A=
    return this.registry[skinID];=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method return the current skin id.=0A=
   *=0A=
   * @return string: the current skin id=0A=
   */=0A=
  class$.getSkinId =3D function ()=0A=
  {=0A=
    return this.skinID;=0A=
  }=0A=
=0A=
  /* singleton for system wide resource reader */=0A=
  class$.static_._sysResReader_ =3D null;=0A=
=0A=
  /** the key (i.e. filename) to access the system wide resource reader =
*/=0A=
  class$.static_.SYS_READER_KEY =3D =
"lib/share/ResourceManager/system_texts.en.xml";=0A=
  =0A=
  //------------------------------------------------------------=0A=
  /**=0A=
   * Returns an <code>AbstractResourceReader</code> holding some=0A=
   * system wide text resources. Currently these are=0A=
   * <ul><li> ($SYS_OK): label for ok buttons </li>=0A=
   *     <li> ($SYS_CANCEL): label for cancel buttons </li>=0A=
   *     <li> ($SYS_LNI): the system name (LNI or L.N.I or whatever) =
</li>=0A=
   *     <li> ($SYS_LNI_FULL): the full system name (Learning N.I.) </li>=0A=
   * </ul>=0A=
   * <p>=0A=
   * The resource file itself can be found under=0A=
   * <code> lib/share/ResourceManager/system_texts.en.xml </code>.=0A=
   * <p>=0A=
   * For the transport to the client side the =
<code>Resources2Javascript</code>=0A=
   * functionality is used during the resource framework includes.=0A=
   * On the client side the transported registered =
<code>CSResourceReader</code>=0A=
   * is returned instead of directly using a =
<code>SkinXMLResourceReader</code>.=0A=
   * =0A=
   * @return AbstractResourceReader: a resource reader holding general=0A=
   *    system wide used resources.=0A=
   */=0A=
  class$.static_.getSystemResourceReader =3D function()=0A=
  {=0A=
    if(this._sysResReader_ =3D=3D null)=0A=
    {=0A=
      if(typeof com.hyperwave.res.SkinXMLResourceReader !=3D "undefined")=0A=
      {=0A=
        var res_mgr =3D ResourceManager.static_.getInstance(=0A=
          User.static_.getInstance().getSkinId());=0A=
        =0A=
        this._sysResReader_ =3D new =
com.hyperwave.res.SkinXMLResourceReader({=0A=
           xmlFileName_: this.SYS_READER_KEY,=0A=
           manager_: res_mgr=0A=
          });=0A=
      }=0A=
      else=0A=
      {=0A=
        this._sysResReader_ =3D =
Resources2Javascript.static_.getCSResourceReader(this.SYS_READER_KEY);=0A=
      }=0A=
    }=0A=
    return this._sysResReader_;=0A=
  }=0A=
=0A=
=0A=
//</JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ResourceReader.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        ResourceReader.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: ResourceReader.js 159001 2010-10-12 09:41:25Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
loadClass ( "com.hyperwave.res.CSResourceReader" );=0A=
loadClass ( "com.hyperwave.res.Template" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This resource reader gets the resources from so-called <i>lrc</i>=0A=
 * files from the file system and encapsulates the access to resources =0A=
 * within these files. It provides direct and iterative access to the =0A=
 * resources defined within these definitions. The files are accessed =0A=
 * by the API-calls: <code>resdef (...)</code> and <code>lrc =
(...)</code>.=0A=
 * The current supported format is:=0A=
 * <xmp>=0A=
 *  <resdefinitions>=0A=
 *  =0A=
 *  <res name=3Dindex>=0A=
 *    main:Template=0A=
 *    astring=0A=
 *    ...=0A=
 *  </res>=0A=
 *  =0A=
 *  <res name=3Dmain>=0A=
 *  <html>=0A=
 *    ...=0A=
 *  </html>=0A=
 *  </res>=0A=
 *  =0A=
 *  <res name=3Dastring>=0A=
 *  A string ...=0A=
 *  </res>=0A=
 *  =0A=
 *  </resdefinitions>=0A=
 * </xmp> =0A=
 * The <i>index</i> section has to be present and is used to access =0A=
 * the other resources.=0A=
 * Each resource has to be defined within this section (this will=0A=
 * be changed in future implementations).=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Creates a resource reader for lrc files.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.lrcFileName_: String: the filename of the lrc=0A=
   *   file. Be aware of the fact that the correctness of the=0A=
   *   filename depends on the environment. In the wavemaster environment=0A=
   *   it is relative to the wavemaster's HTML_DIR and in hwjs it =0A=
   *   is (currently) relative to $HW_HOME/wavemaster.=0A=
   */=0A=
  com.hyperwave.res.ResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.lrcFileName_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ResourceReader: Constructed without =
LRCFileName" );=0A=
      this.lrcFileName_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    this.lrcFileName_ =3D aParam.lrcFileName_;                         =0A=
    resdef ( this.lrcFileName_, this.lrcFileName_ );=0A=
    this._readLRC ();=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.ResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Name of the index node in the resource file.=0A=
   */=0A=
  class$.static_.INDEX_ID_ =3D "index";=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Regular expression to split lines in the index section.=0A=
   */=0A=
  class$.static_.INDEX_SPLIT_ =3D /[\r\n]+/;=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Regular expression to break a single line in the index section=0A=
   * into resourcename and resourcetype (if defined).=0A=
   */=0A=
  class$.static_.LINE_BREAK_ =3D /\s*([^: ]*)( *: *([^ ]*))?\s*/;=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads the Hyperwave LRC file and parses the structure. This is done=0A=
   * by means of reading the LRC <code>&lt;RES name=3D"index"&gt;</code> =
section.=0A=
   * This section defines all keys which are subsequently read into=0A=
   * the reader's internal structures.=0A=
   * @return com.hyperwave.res.ResourceException: returns null=0A=
   *   if everything went right, an exception otherwise.=0A=
   */=0A=
  class$._readLRC =3D function ()=0A=
  {=0A=
    var saved_language;=0A=
    var this_ =3D this;=0A=
    =0A=
    function saveLanguage ()=0A=
    {=0A=
      if ( typeof wavemaster !=3D "undefined" &&=0A=
           client.language !=3D "en" &&=0A=
           saved_language =3D=3D null )=0A=
      {=0A=
        // client.language is still "ge", but the lrc files have to have =
extension "de" =0A=
        if (client.language =3D=3D "ge")=0A=
          check_language =3D "de";=0A=
        else =0A=
          check_language =3D client.language;=0A=
        var cur_res_name =3D (wavemaster.htmldir + =
this_.lrcFileName_).replace ( ".lrc", "." + check_language + ".lrc"  );=0A=
        var f_cur =3D new File ( cur_res_name );=0A=
=0A=
        var des_res_name =3D (wavemaster.htmldir + =
this_.lrcFileName_).replace ( ".lrc", ".en.lrc"  );=0A=
        var f_des =3D new File ( des_res_name );=0A=
        =0A=
        if ( !f_cur.exists () && f_des.exists () )=0A=
        {=0A=
          saved_language =3D client.language;=0A=
          client.languages =3D "en";=0A=
        }=0A=
      }=0A=
    }=0A=
    =0A=
    function restoreLanguage ()=0A=
    {=0A=
      if ( typeof saved_language !=3D "undefined" )=0A=
      {=0A=
        client.languages =3D saved_language;=0A=
        saved_language =3D null;=0A=
      }=0A=
    }=0A=
      =0A=
    var index_str =3D lrc ( this.static_.INDEX_ID_, this.lrcFileName_, =
"<<null>>" );=0A=
    if ( index_str =3D=3D "<<null>>" )=0A=
    {=0A=
      saveLanguage ();=0A=
      index_str =3D lrc ( this.static_.INDEX_ID_, this.lrcFileName_, =
"<<null>>" );=0A=
    }=0A=
    =0A=
    if ( index_str =3D=3D "<<null>>" )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.ResourceReader: No 'index' section found in =
LRC file '" + =0A=
        this.lrcFileName_ + "'." );=0A=
      restoreLanguage ();=0A=
      return this.error_;=0A=
    }=0A=
    =0A=
    var line_array =3D index_str.split ( this.static_.INDEX_SPLIT_ );=0A=
    var exception =3D new com.hyperwave.res.ResourceException ();=0A=
=0A=
    for ( var line_index =3D 0; line_index < line_array.length; =
++line_index )=0A=
    {=0A=
      var line =3D line_array [line_index];=0A=
      var parts =3D this.static_.LINE_BREAK_.exec ( line );=0A=
      if ( parts =3D=3D null )=0A=
        continue;=0A=
      var key =3D parts [1];=0A=
      var value =3D parts [3];=0A=
      if ( key =3D=3D "" )=0A=
        continue;=0A=
=0A=
      var type =3D "string";=0A=
      if ( parts [3] )=0A=
        type =3D parts [3].toLowerCase ();=0A=
=0A=
      var content =3D lrc ( key, this.lrcFileName_, "<<null>>" );=0A=
      if ( content =3D=3D "<<null>>" )=0A=
        exception.pushError ( "com.hyperwave.ResourceReader: Key '" + =0A=
                              key + =0A=
                              "' of INDEX section in LRC file '" +=0A=
                              this.lrcFileName_ + "' has no content =
defined with a RES clause." );=0A=
      else if ( type =3D=3D "string" )=0A=
        this.setRes ( key, content );=0A=
      else if ( type =3D=3D "template" )=0A=
        this.setRes ( key, =0A=
                      new com.hyperwave.res.Template ( { =
templateString_: content } ) );=0A=
      else=0A=
        exception.pushError ( "com.hyperwave.res.ResourceReader: Key '" =
+ =0A=
                              key + =0A=
                              "' of INDEX section in LRC file '" +=0A=
                              this.lrcFileName_ + "' has an invalid type =
'" + =0A=
                              type + "'." );=0A=
    }=0A=
=0A=
    restoreLanguage ();=0A=
    if ( exception.errorCount () =3D=3D 0 )=0A=
      return null;=0A=
=0A=
    return this.error_ =3D exception;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Test main routine.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    var r =3D new com.hyperwave.res.ResourceReader ( { lrcFileName_: =
"htmlres1.lrc" } );=0A=
    if ( r.error_ )=0A=
      writeln ( "Error in reader: " + r.error_ );=0A=
    else=0A=
      writeln ( "Content: " + r );=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.ResourceReader.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ScopedMap.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 * =0A=
 * <file>=0A=
 *  Name:        ScopedMap.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: ScopedMap.js 166023 2011-10-11 05:48:53Z jschipf $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This class provides a <i>scope chain</i> of maps from string keys=0A=
 * to any objects. If a key is searched in the scoped map firstly=0A=
 * the top map is searched. If nothing is found the next map=0A=
 * of the chain is searched and so forth.=0A=
 * This structure simulates inheritance and overloading mechanisms=0A=
 * used in JavaScript.=0A=
 * @author Simon Zwoelfer=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ScopedMap">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
    * Constructs a new ScopedMap by means of a given one=0A=
    * or, if none is given, an empty ScopedMap.=0A=
    * @param aParam: ScopedMap | void: this value can either=0A=
    *   be <code>null</code> or an existing stack can be=0A=
    *   used to construct a new one by copying all references=0A=
    *   of the old one. Hence the new stack will not influence=0A=
    *   the old stack but has the same conent!=0A=
    * @param theTop: Object | void: a Map with already defined properties=0A=
    *   which should reside on the top of the ScopedMap=0A=
    */=0A=
  com.hyperwave.res.ScopedMap =3D function ( aParam, theTop )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    if ( !theTop )=0A=
      theTop =3D {};=0A=
    this.top_ =3D theTop;=0A=
=0A=
//  Use JavaScript internals:=0A=
//    if ( aParam !=3D null && aParam.top_ !=3D null )=0A=
//      this.top_.__proto__ =3D aParam.top_;=0A=
//=0A=
//    return;=0A=
=0A=
=0A=
    // Array implementation ...=0A=
    if ( aParam !=3D null && aParam.stack_ !=3D null )=0A=
      this.stack_ =3D [this.top_].concat ( aParam.stack_ );=0A=
    else=0A=
      this.stack_ =3D [this.top_];=0A=
=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.ScopedMap );=0A=
=0A=
  class$.static_.MODIFIER_REG_EXP =3D /^(\w+)(?:\[([\w\,]+)\])?$/;=0A=
=0A=
  class$.static_.HTML_MAP =3D {"&": "&amp;", "<": "&lt;", ">": "&gt;", =
"\"": "&quot;", "\'": "&#39;"};=0A=
  class$.static_.JS_MAP =3D {"\\": "\\\\", "\"": "\\\"", "\'": "\\\'", =
"\r": "\\r", "\n": "\\n", "<": "\\x3c"};=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Get a value by means of a given key, or null if the key is not=0A=
   * present in any map of the stack. The most upper key is found.=0A=
   * The key parameter may contain modifiers, but the returned value is =
not transformed.=0A=
   * @param aKey: String: the key which is to be searched (including =
modifiers) using the syntax:=0A=
   *    modifier1:modifier2:...:key=0A=
   * @return Object: the value of the given key or <CODE>null</CODE>=0A=
   *                 if the key was not found=0A=
   */=0A=
  class$.get =3D function ( aKey )=0A=
  {=0A=
//  Use JavaScript internals:=0A=
//    return this.top_ [aKey];=0A=
    var key =3D aKey;=0A=
    =0A=
    // parse placeholder modifiers=0A=
    if (aKey.indexOf(":") !=3D -1) {=0A=
      var key_items =3D aKey.split(":");=0A=
      key =3D key_items[key_items.length - 1];=0A=
    }=0A=
    =0A=
    for (var map_ctr =3D 0; map_ctr < this.stack_.length; ++map_ctr) {=0A=
      var cur_map =3D this.stack_ [map_ctr];=0A=
      var value =3D cur_map [ key ];=0A=
      =0A=
      // key does not exist, lookup using original key (including =
modifiers)=0A=
      if (value =3D=3D null)=0A=
        value =3D cur_map[aKey];=0A=
        =0A=
      if (value !=3D null) {=0A=
        return value;=0A=
      }=0A=
    }=0A=
    return null;=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Get a value by means of a given key, or null if the key is not=0A=
   * present in any map of the stack. The most upper key is found.=0A=
   * The key parameter may contain modifiers, which cause a set of=0A=
   * transformations to the given value, if it is a string.=0A=
   * The transformations are applied in reverse order.=0A=
   * Currently, the following modifiers are supported:=0A=
   * html:    escape string in HTML context=0A=
   * single:  escape string in single-quoted string context=0A=
   * double:  escape string in double-quoted string context=0A=
   * uri:     escape string in uri/url string context=0A=
   * @param aKey: String: the key which is to be searched (including =
modifiers) using the syntax:=0A=
   *    modifier1:modifier2:...:key=0A=
   * @return Object: the value of the given key or <CODE>null</CODE>=0A=
   *                 if the key was not found=0A=
   */=0A=
  class$.getModified =3D function ( aKey )=0A=
  {=0A=
    try {=0A=
      var modifiers =3D this.static_.getModifiers(aKey);=0A=
      var value =3D this.get(aKey);=0A=
      return this.static_.applyModifiers(modifiers, value, this);=0A=
    }=0A=
    catch (ex) {=0A=
      // FIX: HWIS/PR-6081: leave unknown placeholders the way they are=0A=
      // (xsl files may have the same syntax as resource placeholders)=0A=
      writelnError("Unknown Resource Modifier found =
(ScopedMap.getModified): " + aKey);=0A=
      return "($" + aKey + ")";=0A=
    }=0A=
  };=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Set a value of the map stack. This always influences the top=0A=
   * map!=0A=
   * @param aKey: String: the key which should be set=0A=
   * @param aValue: Object: the associated value=0A=
   */=0A=
  class$.set =3D function ( aKey, aValue )=0A=
  {=0A=
    this.top_ [aKey] =3D aValue;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Returns an array of modifiers specified by the given key=0A=
   * Currently, the following modifiers are supported:=0A=
   * html:    escape string in HTML context=0A=
   * single:  escape string in single-quoted string context=0A=
   * double:  escape string in double-quoted string context=0A=
   * uri:     escape string in uri/url string context=0A=
   * @param aKey: String: the key, also containing the modifiers=0A=
   * @return String[]: an array of modifiers, or null if no modifiers =
specified=0A=
   */=0A=
  class$.static_.getModifiers =3D function ( aKey )=0A=
  {=0A=
    // parse placeholder modifiers=0A=
    if (aKey.indexOf(":") !=3D -1) {=0A=
      var modifiers =3D new Array();=0A=
      var key_items =3D aKey.split(":");=0A=
      for (var i =3D key_items.length-2; i >=3D0; i--) {=0A=
        modifiers[i] =3D key_items[i];=0A=
        // remove optional parameters for function mapping=0A=
        var modifier_name =3D =
modifiers[i].match(com.hyperwave.res.ScopedMap.static_.MODIFIER_REG_EXP)[=
1];=0A=
        if (typeof(this.modifierRegistry[modifier_name]) !=3D "function")=0A=
        {=0A=
          throw new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ScopedMap: modifier " + modifier_name + " is =
not defined!" );=0A=
        }=0A=
      }=0A=
      return modifiers;=0A=
    }=0A=
    return null;=0A=
  };=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Applies a set of transformations to the given string value.=0A=
   * The transformations are specified by an array of string modifiers=0A=
   * and are applied in reverse order.=0A=
   * Currently, the following modifiers are supported:=0A=
   * html:    escape string in HTML context=0A=
   * single:  escape string in single-quoted string context=0A=
   * double:  escape string in double-quoted string context=0A=
   * uri:     escape string in uri/url string context=0A=
   * @param modifiers: String[]: an array of modifiers, or null if no =
modifiers specified=0A=
   * @param value: String: the string which needs to be transformed=0A=
   * @param aMap: String: the scoped map instance=0A=
   * @return String: the transformed value=0A=
   */=0A=
  class$.static_.applyModifiers =3D function ( modifiers, value , aMap)=0A=
  {=0A=
    if (modifiers =3D=3D null)=0A=
      return value;=0A=
    if (typeof(modifiers.length) !=3D "undefined" && modifiers.length > =
0) {=0A=
      var params=3D{aMap:aMap};=0A=
      for (var j =3D modifiers.length - 1; j >=3D 0; j--) {=0A=
        var the_match =3D =
modifiers[j].match(com.hyperwave.res.ScopedMap.static_.MODIFIER_REG_EXP);=0A=
=0A=
        var handler =3D this.modifierRegistry[the_match[1]];=0A=
        if (typeof(handler) =3D=3D "function" && typeof(value) =3D=3D =
"string") {=0A=
          // handle parameters passed in the modifier=0A=
          if (the_match[2])=0A=
          {=0A=
            params.args =3D the_match[2].split(",");=0A=
          }=0A=
          value =3D handler(value, params);=0A=
        }=0A=
      }=0A=
      return value;=0A=
    }=0A=
    else {=0A=
      return value;=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Primitive test for the class.=0A=
   * @return String[]: an array with string errors for the class=0A=
   */=0A=
  class$.static_.test =3D function ()=0A=
  {=0A=
    var errors =3D [];=0A=
    var map_s1 =3D new com.hyperwave.res.ScopedMap ();=0A=
    if ( map_s1.get ( "a" ) !=3D null )=0A=
      errors [errors.length] =3D "(1) Empty Stack gives values";=0A=
=0A=
    // Test Basic Map:=0A=
    map_s1.set ( "a", "a" );=0A=
    map_s1.set ( "b", "b" );=0A=
    if ( map_s1.get ( "a" ) !=3D "a" ||=0A=
         map_s1.get ( "b" ) !=3D "b" ||=0A=
         map_s1.get ( "c" ) !=3D null )=0A=
      errors [errors.length] =3D "(2) Basic access does not work";=0A=
=0A=
    map_s1.set ( "c", "x" );=0A=
    if ( map_s1.get ( "a" ) !=3D "a" ||=0A=
         map_s1.get ( "b" ) !=3D "b" ||=0A=
         map_s1.get ( "c" ) !=3D "x" )=0A=
      errors [errors.length] =3D "(3) Basic access after put does not =
work";=0A=
    =0A=
    // Create new Stack by means of Stack above and put=0A=
    // overriding values in it ...=0A=
    var map_s2 =3D new com.hyperwave.res.ScopedMap ( map_s1 );=0A=
    map_s2.set ( "c", "c" );=0A=
    map_s2.set ( "a", "a2" );=0A=
    if ( map_s2.get ( "a" ) !=3D "a2" ||=0A=
         map_s2.get ( "b" ) !=3D "b" ||=0A=
         map_s2.get ( "c" ) !=3D "c" )=0A=
      errors [errors.length] =3D "(4) Overridden access does not work";=0A=
=0A=
    map_s1.set ( "x", "s1x" );=0A=
    map_s1.set ( "y", "s1y" );=0A=
    map_s2.set ( "x", "s2x" );=0A=
    map_s2.set ( "z", "s2z" );=0A=
    if ( map_s1.get ( "z" ) !=3D null ||=0A=
         map_s2.get ( "x" ) !=3D "s2x" ||=0A=
         map_s2.get ( "z" ) !=3D "s2z" ||=0A=
         map_s2.get ( "y" ) !=3D "s1y" )=0A=
      errors [errors.length] =3D "(5) Overridden access after put does =
not work";=0A=
=0A=
    var map_s3 =3D new com.hyperwave.res.ScopedMap ( map_s2, { "x": "xx" =
} );=0A=
    if ( map_s3.get ( "xx" !=3D "xx" ) )=0A=
      errors [errors.length] =3D "(6) Overridden access after put does =
not work";=0A=
         =0A=
    return errors;=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Tests the class.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    var errors =3D this.test ();=0A=
    if ( errors.length =3D=3D 0 )=0A=
      writeln ( "Test of ScopedMap ok" );=0A=
    else=0A=
      writeln ( "Test of ScopedMap gives the following Errors: \n  " +=0A=
                errors.join ( "\n  " ) + "\n" );=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Escapes a string in an HTML context.=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeHtml =3D function (string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
=0A=
    var map =3D com.hyperwave.res.ScopedMap.static_.HTML_MAP;=0A=
    return string.replace(/[\&\<\>\"\']/g, function (match) {=0A=
        return map[match] || match;=0A=
      });=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Trims leading and trailing whitespaces from a given string.=0A=
   * @param string: String: the string to be trimmed=0A=
   * @return String: the trimmmed string=0A=
   */=0A=
  class$.static_.trim =3D function (string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    return string.trim();=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Escapes a string in a single quoted string context.=0A=
   * Additionally, splits occurences of <string> and </string> tags.=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeSingleString =3D function(string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    var outstr =3D string;=0A=
    outstr =3D outstr.replace(/\\/g, "\\\\");=0A=
    outstr =3D outstr.replace(/\n/g, "\\n");=0A=
    outstr =3D outstr.replace(/\r/g, '\\r');=0A=
    outstr =3D outstr.replace(/\t/g, '\\t');=0A=
    =0A=
    outstr =3D outstr.replace(/\'/g, "\\'");=0A=
    outstr =3D outstr.replace(/(<\/?scr)(ipt[^>]*>)/gi, "$1' + '$2");=0A=
  =0A=
    return outstr;=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Escapes a string in a double quoted string context.=0A=
   * Additionally, splits occurences of <string> and </string> tags.=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeDoubleString =3D function(string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
=0A=
    var outstr =3D string;=0A=
    outstr =3D outstr.replace(/\\/g, "\\\\");=0A=
    outstr =3D outstr.replace(/\n/g, "\\n");=0A=
    outstr =3D outstr.replace(/\r/g, '\\r');=0A=
    outstr =3D outstr.replace(/\t/g, '\\t');=0A=
=0A=
    outstr =3D outstr.replace(/\"/g, '\\"');=0A=
    outstr =3D outstr.replace(/(<\/?scr)(ipt[^>]*>)/gi, '$1" + "$2');=0A=
=0A=
    return outstr;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Similar as escapeDoubleString and escapeSingleString, but =
independent from=0A=
   * surrounding quotes.=0A=
   *=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeString =3D function(string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    =0A=
    var map =3D com.hyperwave.res.ScopedMap.static_.JS_MAP;=0A=
    return string.replace(/[\\\"\'\r\n\<]/ig, function (match) {=0A=
        return map[match] || match;=0A=
      });=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Escapes a string in a uri/url string context.=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeUriString =3D function(string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    return encodeURIComponent(string);=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Escapes a string in a uri/url string context, but the slahses.=0A=
   * This is necessary to encode object paths for usage as urls.=0A=
   * @param string: String: the string to transform=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.escapeUriPathString =3D function(string)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    return encodeURIPath(string);=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Truncates the string after a given number of characters.=0A=
   * @param string: String: the string to transform=0A=
   * @param params: Object=0A=
   * @param params.args[0]: string: the maxlenght of the string. Given =
to the modifier=0A=
   *                     in the syntax <code>  truncate[maxlenght] =
</code>=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.truncateString =3D function(string,params)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
    {=0A=
      return string;=0A=
    }=0A=
    if (!params.args)=0A=
    {=0A=
      return string;=0A=
    }=0A=
    =0A=
    var max_length=3DparseInt(params.args[0],10);=0A=
    if (string.length > max_length) {=0A=
      string =3D string.substr(0, max_length) + "\u2026";=0A=
    }=0A=
    return string;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Truncates the string after a given number of characters.=0A=
   * @param string: String: the string to transform=0A=
   * @param params: Object=0A=
   * @param params.args[0]: string: the maxlenght of the string. Given =
to the modifier=0A=
   *                     in the syntax <code>  truncate[maxlenght] =
</code>=0A=
   * @return String: the escaped string=0A=
   */=0A=
  class$.static_.longerString =3D function(string,params)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
    {=0A=
      return string;=0A=
    }=0A=
    if (!params.args)=0A=
    {=0A=
      return string;=0A=
    }=0A=
    =0A=
    var max_length=3DparseInt(params.args[0],10);=0A=
    if (string.length > max_length) {=0A=
      return string;=0A=
    }=0A=
    return "";=0A=
  };=0A=
  =0A=
    =
//--------------------------------------------------------------------=0A=
  /**=0A=
   * Transforms a given gmt date in HWDate date format in a local time =
in the set HW_UI_Date=0A=
   * datfunctions.js has to be included on the clientside to have this =
work.=0A=
   * The UI date format can be set in the function getResource().=0A=
   * Example: <code> ($date[full]:thedate))=0A=
   * @param string: String: the string to transform=0A=
   * @param params: Object=0A=
   * @param params.args[0]: string: the format thet should be used. =
Possible values=0A=
   *                          "full"*|"date"|"time"|"shortTime"=0A=
   * @param params.args[1]: string: the sentence context - possible =
values=0A=
   *                          =
""*|"on"|"to"|"from"|"ondate"|"todate"|"fromdate"=0A=
   *                          =
|"On"|"To"|"From"|"Ondate"|"Todate"|"Fromdate"=0A=
   *                          The capitalized versions return the first =
character capitalized=0A=
   *                          see datefunctions.js also=0A=
   * @return String: the transformed date=0A=
   */=0A=
  class$.static_.transformDate =3D function(string, params)=0A=
  {=0A=
    if (typeof string !=3D "string")=0A=
    {=0A=
      return string;=0A=
    }=0A=
    if (typeof HWDate =3D=3D "undefined" || typeof transformDate =3D=3D =
"undefined")=0A=
    {=0A=
      return string;=0A=
    }=0A=
    var args =3D params.args || [];=0A=
    var format =3D args[0] || "full";=0A=
    var sentence_context =3D transformDate.SENTENCE_CONTEXT[(args[1] || =
"")] || "";=0A=
   =0A=
    if (format !=3D "full" && format !=3D "absolute" &&=0A=
        format !=3D "minimal" && format !=3D "date" && =0A=
        format !=3D "dateAbsolute" && format !=3D "time" && =0A=
        format !=3D "shortTime") {=0A=
      throw new com.hyperwave.res.ResourceException (=0A=
      "com.hyperwave.res.ScopedMap: modifier date called with unknown =
format " + format +"!" );=0A=
    }=0A=
    =0A=
    var date_format =3D params.aMap.get("hw_uidateformat");=0A=
    if (date_format =3D=3D null)=0A=
    {=0A=
      if (typeof HW_UI_Date !=3D "undefined")=0A=
      {=0A=
        date_format=3DHW_UI_Date;=0A=
      }=0A=
      else=0A=
      {=0A=
        throw new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ScopedMap: modifier date used but no =
dateformat set!" );=0A=
      }=0A=
    }=0A=
    =0A=
    return transformDate(string,HWDate,date_format[format], {transform: =
"toLocal",=0A=
                                                             =
useClientLocalTime: true,=0A=
                                                             =
sentenceContext: sentence_context});=0A=
  };=0A=
  =0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Replaces a string with a resource using the string value as a key.=0A=
   * @param string: String: the string to transform=0A=
   * @param aMap: Object: the scoped map=0A=
   * @return String: the replace string=0A=
   */=0A=
  class$.static_.replaceMeta =3D function(string, params)=0A=
  {=0A=
    var aMap=3Dparams.aMap;=0A=
    var outstr =3D string;=0A=
    if (typeof string !=3D "string")=0A=
      return string;=0A=
    =0A=
    if (aMap) {=0A=
      var value =3D aMap.get(string);=0A=
      if (value !=3D null) {=0A=
        if ( value.isTemplate_ ) {=0A=
          outstr =3D value.fill(aMap);=0A=
        }=0A=
        else {=0A=
          outstr =3D aMap.getModified(string);=0A=
        }=0A=
      }=0A=
      else {=0A=
        // FIX: HWIS/PR-6081: leave unknown placeholders the way they are=0A=
        // (xsl files may have the same syntax as resource placeholders)=0A=
        writelnError("Unknown Placeholder found (ScopedMap.replaceMeta): =
" + string);=0A=
        outstr =3D "($" + string + ")";=0A=
      }=0A=
    }=0A=
    return outstr;=0A=
  };=0A=
  =0A=
  /**=0A=
   * The registry that maps placeholder modifiers to their handlers=0A=
   */=0A=
  class$.static_.modifierRegistry =3D {=0A=
          "trim"  : class$.static_.trim, // Handler for HTML modifier=0A=
          "html"  : class$.static_.escapeHtml, // Handler for HTML =
modifier=0A=
          "js"  : class$.static_.escapeString, // Handler for javascript =
string modifier=0A=
          "single": class$.static_.escapeSingleString, // Handler for =
single-quoted string modifier=0A=
          "double": class$.static_.escapeDoubleString, // Handler for =
double-quoted string modifier=0A=
          "uri": class$.static_.escapeUriString, // Handler for url/uri =
string modifier=0A=
          "uripath": class$.static_.escapeUriPathString, // Handler for =
url/uri string modifier=0A=
          "res": class$.static_.replaceMeta, // Handler for string value =
as resource key=0A=
          "date": class$.static_.transformDate, // Handler for string =
value as resource key=0A=
          "iflongerthan": class$.static_.longerString, // Handler for =
string value if longer than=0A=
          "truncate": class$.static_.truncateString // Handler for =
truncating strings=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.ScopedMap.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/ServerResourceReader.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        ResourceReader.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: ServerResourceReader.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
loadClass ( "com.hyperwave.res.CSResourceReader" );=0A=
loadClass ( "com.hyperwave.res.Template" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This resource reader gets the resources from so-called <i>lrc</i>=0A=
 * objects on server and encapsulates the access to resources within =
these=0A=
 * objects. It provides direct and iterative access to the resources=0A=
 * defined within these definitions. The files are accessed =0A=
 * by the calls: <code>api.resdef (...)</code> and <code>api.lrc =
(...)</code>.=0A=
 * The current supported format is:=0A=
 * <xmp>=0A=
 *  <resdefinitions>=0A=
 *  =0A=
 *  <res name=3Dindex>=0A=
 *    main:Template=0A=
 *    astring=0A=
 *    ...=0A=
 *  </res>=0A=
 *  =0A=
 *  <Res name=3Dmain>=0A=
 *  <html>=0A=
 *    ...=0A=
 *  </html>=0A=
 *  </res>=0A=
 *  =0A=
 *  <res name=3Dastring>=0A=
 *  A string ...=0A=
 *  </res>=0A=
 *  =0A=
 *  </resdefinitions>=0A=
 * </xmp> =0A=
 * The <i>index</i> section has to be present and is used to access =0A=
 * the other resources.=0A=
 * Each resource has to be defined within this section (this will=0A=
 * be changed in future implementations).=0A=
 *=0A=
 * The format of the lrc objects on the server has to follow some certain=0A=
 * restrictions. See also HIS Programmers Guide, chapter 1.3.4 =0A=
 * (Language Resources on the Server) for details.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.ServerResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Creates a resource reader for lrc objects from server.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.lrcServerLocation_: String: the name of the lrc =
object =0A=
   *   on the server.=0A=
   */=0A=
  com.hyperwave.res.ServerResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.lrcServerLocation_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ServerResourceReader: Constructed without =
LRCServerLocation" );=0A=
      this.lrcServerLocation_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    this.lrcServerLocation_ =3D aParam.lrcServerLocation_;   =0A=
    =0A=
    // within DC use api-call=0A=
    // within templates use server-call=0A=
    this.api_ =3D null; =0A=
    if (typeof server !=3D "undefined")=0A=
      this.api_ =3D server;=0A=
    if ( (typeof api !=3D "undefined") &&=0A=
         (typeof args !=3D "undefined") )=0A=
      this.api_ =3D api;=0A=
    if (this.api_ =3D=3D null) =0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ServerResourceReader: No API or server =
defined" );=0A=
      return;=0A=
    }=0A=
    =0A=
    // define resources=0A=
    this.api_.resdef ( { location:this.lrcServerLocation_, =
scope:this.lrcServerLocation_ } );=0A=
    this._readLRC ();=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.ServerResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Name of the index node in the resource file.=0A=
   */=0A=
  class$.static_.INDEX_ID_ =3D "index";=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Regular expression to split lines in the index section.=0A=
   */=0A=
  class$.static_.INDEX_SPLIT_ =3D /\s*[\r\n]+\s*/;=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Regular expression to break a single line in the index section=0A=
   * into resourcename and resourcetype (if defined).=0A=
   */=0A=
  class$.static_.LINE_BREAK_ =3D /\s*([^: ]*)( *: *([^ ]*))?\s*/;=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads the Hyperwave LRC object and parses the structure. This is =
done=0A=
   * by means of reading the LRC <code>&lt;RES name=3D"index"&gt;</code> =
section.=0A=
   * This section defines all keys which are subsequently read into=0A=
   * the reader's internal structures.=0A=
   * @return com.hyperwave.res.ResourceException: returns null=0A=
   *   if everything went right, an exception otherwise.=0A=
   */=0A=
  class$._readLRC =3D function ()=0A=
  {=0A=
    var index_obj =3D this.api_.lrc ( {=0A=
                      identifier:this.static_.INDEX_ID_, =0A=
                      scope:     this.lrcServerLocation_, =0A=
                      fallback:  "<<null>>",=0A=
                      language:  client.language =0A=
                    } );=0A=
    if ( index_obj.error.error() )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.ServerResourceReader: in LRC file '" + =
this.api_.toSource() + =0A=
        this.lrcServerLocation_ + "': " + =
index_obj.error[0].description("en") );=0A=
      return this.error_;=0A=
    }=0A=
    var index_str =3D index_obj.text;=0A=
    if ( index_str =3D=3D "<<null>>" )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException ( =0A=
        "com.hyperwave.res.ResourceReader: No 'INDEX' section found in =
LRC collection '" + =0A=
        this.lrcServerLocation + "'." );=0A=
      return this.error_;=0A=
    } =0A=
    =0A=
    var line_array =3D index_str.split ( this.static_.INDEX_SPLIT_ );=0A=
    var exception =3D new com.hyperwave.res.ResourceException ();=0A=
=0A=
    for ( var line_index =3D 0; line_index < line_array.length; =
++line_index )=0A=
    {=0A=
      var line =3D line_array [line_index];=0A=
      var parts =3D this.static_.LINE_BREAK_.exec ( line );=0A=
      if ( parts =3D=3D null )=0A=
        continue;=0A=
      var key =3D parts [1];=0A=
      var value =3D parts [3];=0A=
      if ( key =3D=3D "" )=0A=
        continue;=0A=
=0A=
      var type =3D "String";=0A=
      if ( parts [3] )=0A=
        type =3D parts [3];=0A=
=0A=
      var content_obj =3D this.api_.lrc ( {=0A=
                      identifier:key, =0A=
                      scope:     this.lrcServerLocation_, =0A=
                      fallback:  "<<null>>",=0A=
                      language:  client.language =0A=
                    } );=0A=
      if ( content_obj.error.error() ){ =0A=
        var content =3D "<<null>>";=0A=
      }=0A=
      else {=0A=
        var content =3D content_obj.text;=0A=
      }=0A=
      if ( content =3D=3D "<<null>>" )=0A=
        exception.pushError ( "com.hyperwave.ResourceReader: Key '" + =0A=
                              key + =0A=
                              "' of INDEX section in LRC file '" +=0A=
                              this.lrcServerLocation_ + "' has no =
content defined with a RES clause." );=0A=
      else if ( type =3D=3D "String" )=0A=
        this.setRes ( key, content );=0A=
      else if ( type =3D=3D "Template" )=0A=
        this.setRes ( key, =0A=
                      new com.hyperwave.res.Template ( { =
templateString_: content } ) );=0A=
      else=0A=
        exception.pushError ( "com.hyperwave.res.ResourceReader: Key '" =
+ =0A=
                              key + =0A=
                              "' of INDEX section in LRC file '" +=0A=
                              this.lrcServerLocation + "' has an invalid =
type '" + =0A=
                              type + "'." );=0A=
    }=0A=
=0A=
    if ( exception.errorCount () =3D=3D 0 )=0A=
      return null;=0A=
=0A=
    return this.error_ =3D exception;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Test main routine.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.ServerResourceReader.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/SkinXMLResourceReader.js?cachekeY=515488b2-en

/*=0A=
 *  Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 *  $Id: SkinXMLResourceReader.js 159001 2010-10-12 09:41:25Z cgoess $=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
loadClass ( "com.hyperwave.res.CSResourceReader" );=0A=
loadClass ( "com.hyperwave.res.Template" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This resource reader gets the resources from so-called <i>lrc</i>=0A=
 * files in XML format (.xml) and encapsulates the access to resources =
within these=0A=
 * files. It provides direct and iterative access to the resources=0A=
 * defined within these definitions. The files are accessed =0A=
 * by the calls: <code>resdefx (...)</code>, <code>resgetx (...)</code> =
and =0A=
 * <code>residx (...)</code>.=0A=
 * <P>=0A=
 * Furthermore this resource reader supports including nested resource =
files by=0A=
 * defining the paths to the resource files to include within a special =
named=0A=
 * resource definition (<code>&lt;RES name=3D"include" =
type=3D"string"&gt;</code>).=0A=
 * <P>=0A=
 * By using implementations of =
<CODE>com.hyperwave.res.ResourceManagerIFC</CODE>=0A=
 * special placeholders in the parameter path definitions will be =
automatically=0A=
 * replaced (<code>%resroot%,%fileroot%,%extfileroot%</code> and =
<code>%skinroot%</code> in addition to=0A=
 * the already existing <code>%lang%</code> placeholder).=0A=
 * <BR>=0A=
 * These placeholders will also be replaced within resources when they =
are used=0A=
 * in the traditional placeholder markup =
<code>($resroot),($skinroot),($fileroot),($extfileroot)</code>.=0A=
 * Additionally the root to the currently active module will be covered =
by using the=0A=
 * placeholder <code>($modroot)</code> (use for eg. script includes =
within templates).=0A=
 * <p>=0A=
 * The current supported format is:=0A=
 * <xmp>=0A=
 *   <?xml version=3D"1.0"?>=0A=
 *   =0A=
 *   <!DOCTYPE resdefinitions=0A=
 *       PUBLIC "-//Hyperwave//DTD Resources 1.0//EN"=0A=
 *       "http://www.hyperwave.com/dtds/xmlres_1_0.dtd"> =0A=
 *   =0A=
 *   <RESDEFINITIONS>=0A=
 *   =0A=
 *   <RES name=3D"main" type=3D"template"><![CDATA[=0A=
 *   <HTML>=0A=
 *     <HEAD>=0A=
 *       <TITLE>TestSeite</TITLE>=0A=
 *       <script =
src=3D"($fileroot)($modroot)client/csjs/myFiles.js"></script>=0A=
 *     </HEAD>=0A=
 *     <BODY BGCOLOR=3D"($bgcolor)">=0A=
 *       Dies ist ein erster Test <BR>=0A=
 *       Username: ($username)=0A=
 *       <BR><img src=3D"($fileroot)($resroot)images/share/logo.gif">=0A=
 *     </BODY>=0A=
 *   </HTML>=0A=
 *   ]]></RES>=0A=
 *   =0A=
 *   <RES name=3D"lang1" type=3D"string">=0A=
 *   This is english.=0A=
 *   </RES>=0A=
 *=0A=
 *   <!--=0A=
 *     the following section reads in all resources from the specified=0A=
 *     files by means of a com.hyperwave.res.SkinXMLResourceReader =
instance=0A=
 *     whereby the placeholders %resroot%, %fileroot%  and %skinroot% =
have to be=0A=
 *     provided by the ResourceManagerIFC implementation of the current=0A=
 *     application=0A=
 *   -->=0A=
 *   <RES name=3D"include" type=3D"string">=0A=
 *   %resroot%mod/cr/templates/maintemplate.xml=0A=
 *   %resroot%mod/cr/texts/maintexts.%lang%.xml=0A=
 *   %skinroot%mod/cr/templates/bodytemplate.xml=0A=
 *   </RES>=0A=
 *=0A=
 *   </RESDEFINITIONS>=0A=
 * </xmp> =0A=
 * An <i>index</i> section is not needed anymore.=0A=
 * <BR>=0A=
 * A small example:=0A=
 * <xmp>=0A=
 *   var manager =3D {};=0A=
 *   manager.getResRoot =3D function(){=0A=
 *     return "resourcetest/res";=0A=
 *   }=0A=
 *   manager.getSkinRoot =3D function(){=0A=
 *     return "resourcetest/skins/" + (new HWUser()).getSkinID();=0A=
 *   }=0A=
 *   manager.getFileRoot =3D function(){=0A=
 *     return "/wavemaster.internal/";=0A=
 *   }=0A=
 *   manager.getExternalFileRoot =3D function(){=0A=
 *     return "http://external.server.com/images/";=0A=
 *   }  =0A=
 *   var resreader =3D new com.hyperwave.res.SkinXMLResourceReader({=0A=
 *                       =
xmlFileName_:"%resroot%/mod/cr/templates/maintemplate.xml,=0A=
 *                       manager_:manager=0A=
 *                   });=0A=
 *   var resource =3D ....=0A=
 * </xmp>=0A=
 *=0A=
 * @see com.hyperwave.res.ResourceManagerIFC=0A=
 * @see com.hyperwave.res.ResourceReader=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.SkinXMLResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Creates a resource reader for resource files in XML format which can=0A=
   * also deal with automatic includes.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.xmlFileName_: String: the filename of the xml=0A=
   *   file. Be aware of the fact that the correctness of the=0A=
   *   filename depends on the environment. In the wavemaster environment=0A=
   *   it is relative to the wavemaster's HTML_DIR and in hwjs it =0A=
   *   is (currently) relative to $HW_HOME/wavemaster.=0A=
   * @param aParam.manager_: com.hyperwave.res.ResourceManagerIFC:=0A=
   *   a resource manager providing the paths to the root of application=0A=
   *   resources as well as to the root of skin resources for a single=0A=
   *   desired skin.=0A=
   */=0A=
  com.hyperwave.res.SkinXMLResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.xmlFileName_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.SkinXMLResourceReader: Constructed without =
XMLFileName" );=0A=
      this.xmlFileName_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    if ( aParam =3D=3D null || aParam.manager_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.SkinXMLResourceReader: Constructed without =
ResourceManagerIFC" );=0A=
      this.manager_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    this.manager_     =3D aParam.manager_;=0A=
    this.xmlFileName_ =3D this.parseFilename( aParam.xmlFileName_ );=0A=
=0A=
    // if old binaries are used xml files cannot be handled.=0A=
    if (typeof resdefx =3D=3D "undefined" ) {=0A=
      // an xml file is present but the xml readers are not defined!=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
      "com.hyperwave.res.SkinXMLResourceReader: The given resource is an =
XML file: '" + =0A=
      this.xmlFileName_ + "'. This JavaScript engine is not capable to =
handle XML files.");=0A=
      return;=0A=
    }=0A=
=0A=
    // read in xml file using new api functions=0A=
    var out =3D resdefx ({ scope: this.xmlFileName_, location: =
this.xmlFileName_ });=0A=
    if (out.error.error()) {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.SkinXMLResourceReader: Could not read in =
resource: '" + =0A=
        this.xmlFileName_ + "'. Error from server: '" +=0A=
        out.error[0].description("en") + "'" );=0A=
      return;=0A=
    }=0A=
    this._readXML ();=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.SkinXMLResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads the Hyperwave LRC file in XML format and parses the =
structure. =0A=
   * This is done by means of the new api method <code>residx</code> =
which =0A=
   * reads in the index of the resource file.=0A=
   * @return com.hyperwave.res.ResourceException: returns null=0A=
   *   if everything went right an exception otherwise.=0A=
   */=0A=
  class$._readXML =3D function ()=0A=
  {=0A=
    var exception =3D new com.hyperwave.res.ResourceException ();=0A=
=0A=
    // try to read in the index of the resource file=0A=
    var idx_obj =3D residx( {scope: this.xmlFileName_} );=0A=
    if (idx_obj.error.error()){=0A=
      exception.pushError ( "com.hyperwave.SkinXMLResourceReader: Could =
not read index of resource '" + =0A=
                            this.xmlFileName_ + =0A=
                            "'. Error message from server: '" +=0A=
                            idx_obj.error[0].description("en") + "'." ); =
       =0A=
      return this.error_ =3D exception;=0A=
    } =0A=
    =0A=
    // step through read in index and read in all resource definitions=0A=
    var res_obj;=0A=
    var key;=0A=
    var include;=0A=
    for ( var index_nr =3D 0; index_nr < idx_obj.idx.length; ++index_nr )=0A=
    {=0A=
      key =3D idx_obj.idx[index_nr];=0A=
      res_obj =3D resgetx( { scope: this.xmlFileName_ , =0A=
                           identifier: key } );=0A=
      =0A=
      if (res_obj.error.error()) {=0A=
        exception.pushError ( "com.hyperwave.SkinXMLResourceReader: Key =
'" + =0A=
                              key + =0A=
                              "' could not be read in. Error message =
from server: '" +=0A=
                              res_obj.error[0].description("en") + "'." =
);        =0A=
      }=0A=
      else {=0A=
        // treat other resources that should be included ...=0A=
        if ( key =3D=3D "include" )=0A=
        {=0A=
          include =3D res_obj;=0A=
        }=0A=
        // ... or read in the normal resources=0A=
        else {=0A=
          switch (res_obj.type)=0A=
          {=0A=
            case "template":=0A=
              // instantiate a new Template=0A=
              this.setRes ( key, =0A=
                            new com.hyperwave.res.Template ( { =
templateString_: res_obj.text } ) );=0A=
              break;=0A=
            default:=0A=
              // default is a string. =0A=
              // if old lrc files are read in using =
<code>XMLResourceReader</code> all =0A=
              // in it defined resources are treated as strings.=0A=
              this.setRes( key, res_obj.text );=0A=
          }=0A=
        }=0A=
      }=0A=
    } /* end for */=0A=
=0A=
    if (include) {=0A=
      var arr =3D include.text.split("\n");=0A=
      var temp_reader;=0A=
      for (cr=3D0;cr<arr.length;++cr) {=0A=
        temp_reader =3D new =
com.hyperwave.res.SkinXMLResourceReader({xmlFileName_:arr[cr],=0A=
                                                                   =
manager_:this.manager_});=0A=
        if (temp_reader.error_) {=0A=
          exception.pushError("com.hyperwave.SkinXMLResourceReader: =
Could not include resource'" +=0A=
                              arr[cr] +=0A=
                              "'. Error message while include: '" +=0A=
                              temp_reader.error_ + "'.");=0A=
        }=0A=
        else {=0A=
          this.readAll( temp_reader );=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
=0A=
    // assign substitutes for placeholders =
($resroot),($fileroot),($extfileroot),=0A=
    // ($modroot) and ($skinroot) as well=0A=
    this.setRes( this.static_.RESROOT_PH,  this.manager_.getResRoot() );=0A=
    this.setRes( this.static_.FILEROOT_PH, this.manager_.getFileRoot() );=0A=
    this.setRes( this.static_.EXTFILEROOT_PH, =
this.manager_.getExternalFileRoot() );=0A=
    this.setRes( this.static_.SKINROOT_PH, this.manager_.getSkinRoot() );=0A=
    this.setRes( this.static_.MODROOT_PH, this.manager_.getModuleRoot() =
);=0A=
=0A=
    if ( exception.errorCount () =3D=3D 0 )=0A=
      return null;=0A=
=0A=
    return this.error_ =3D exception;=0A=
  };=0A=
=0A=
  /**=0A=
   * definition of the placeholder for the resource root=0A=
   */=0A=
  class$.static_.RESROOT_PH =3D "resroot";=0A=
  /**=0A=
   * definition of the placeholder for the root to the desired skin=0A=
   */=0A=
  class$.static_.SKINROOT_PH =3D "skinroot";=0A=
  /**=0A=
   * definition of the placeholder for the root to the internal =
filesystem=0A=
   */=0A=
  class$.static_.FILEROOT_PH =3D "fileroot";=0A=
  /**=0A=
   * definition of the placeholder for the root to a possibly external =
filesystem=0A=
   */=0A=
  class$.static_.EXTFILEROOT_PH =3D "extfileroot";=0A=
  /**=0A=
   * definition of the placeholder for the root to the current module=0A=
   */=0A=
  class$.static_.MODROOT_PH =3D "modroot";=0A=
  /**=0A=
   * definition of the markup start of the special placeholders in file =
paths=0A=
   */=0A=
  class$.static_.MARKUP_START =3D "%";=0A=
  /**=0A=
   * definition of the markup end of the special placeholders in file =
paths=0A=
   */=0A=
  class$.static_.MARKUP_END =3D "%";=0A=
=0A=
=0A=
  /**=0A=
   * Replaces <CODE>%resroot%, %fileroot%, %extfileroot%, =
%skinroot%</CODE> in the parameter filename=0A=
   * with the strings retrieved from <CODE>ResourceManagerIFC</CODE>=0A=
   * @param filename: string: the filename handed over as part of the =
constructor=0A=
   *   parameter object.=0A=
   * @return String: the filename with certain =
<CODE>ResourceManagerIFC</CODE>=0A=
   * placeholders replaced.=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getResRoot=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getSkinRoot=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getFileRoot=0A=
   * @see com.hyperwave.res.ResourceManagerIFC#getExternalFileRoot=0A=
   */=0A=
  class$.parseFilename =3D function ( filename )=0A=
  {=0A=
    var ret;=0A=
    var resroot =3D this.static_.MARKUP_START + this.static_.RESROOT_PH =
+ this.static_.MARKUP_END;=0A=
    var skinroot =3D this.static_.MARKUP_START + =
this.static_.SKINROOT_PH + this.static_.MARKUP_END;=0A=
    var modroot =3D this.static_.MARKUP_START + this.static_.MODROOT_PH =
+ this.static_.MARKUP_END;=0A=
    var fileroot =3D this.static_.MARKUP_START + =
this.static_.FILEROOT_PH + this.static_.MARKUP_END;=0A=
    var extfileroot =3D this.static_.MARKUP_START + =
this.static_.EXTFILEROOT_PH + this.static_.MARKUP_END;=0A=
=0A=
    ret =3D filename.replace(resroot,=0A=
                           this.manager_.getResRoot() );=0A=
    ret =3D ret.     replace(skinroot,=0A=
                           this.manager_.getSkinRoot() );=0A=
    ret =3D ret.     replace(modroot,=0A=
                           this.manager_.getModuleRoot() );=0A=
    ret =3D ret.     replace(fileroot,=0A=
                           this.manager_.getFileRoot() );=0A=
    ret =3D ret.     replace(extfileroot,=0A=
                           this.manager_.getExternalFileRoot() );=0A=
    return ret;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads a resource reader's templates and strings into the =0A=
   * current resource reader's map. Note that the reader's values =0A=
   * override already set values!=0A=
   * @param aReader: com.hyperwave.res.AbstractResourceReader:=0A=
   *   the reader which is used to get the resources.=0A=
   */=0A=
  class$.readAll =3D function ( aReader )=0A=
  {=0A=
    if ( aReader.error_ !=3D null )=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.SkinXMLResourceReader: readAll with an =
erroneus Reader? " + =0A=
        aReader.error_ );=0A=
=0A=
    aReader.initIteration ();=0A=
    while ( aReader.hasNextKey () )=0A=
    {=0A=
      var key =3D aReader.getNextKey ();=0A=
      this.setRes ( key, aReader.getRes ( key ) );=0A=
    }=0A=
  };=0A=
=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/Template.js?cachekeY=515488b2-en

/* =0A=
 * <copyright> =0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright> =0A=
 * =0A=
 * <file> =0A=
 *  Name:        Resource.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: Template.js 162732 2011-04-29 11:59:37Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.ResourceException" );=0A=
loadClass ( "com.hyperwave.res.AbstractCmd" );=0A=
=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * Templates are strings containing placeholders and simple commands.=0A=
 * They can be evaluated when they have an environment or map of=0A=
 * placeholdernames to resources, by recursively replacing all =
placeholders=0A=
 * by the string/template representation of the resources. The whole=0A=
 * mechanism consists of a <code>parser</code> and a <code>fill</code>=0A=
 * mechanism.=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.Template">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Constructs a template and initializes the parsing=0A=
   * structure.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.templateString_: String: the template=0A=
   */=0A=
  com.hyperwave.res.Template =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.templateString_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Template: tried to construct a template " +=0A=
        "without a string." );=0A=
      this.templateString_ =3D null;=0A=
    }=0A=
    else=0A=
    {=0A=
      this.error_ =3D null;=0A=
      /**=0A=
       * Member holding the current template, line comments are removed =
from it!=0A=
       */=0A=
      this.templateString_ =3D =
aParam.templateString_.replace(/##.*(([\n\r]|[\n])|$)/g,"");=0A=
    }=0A=
=0A=
    /**=0A=
     * The members for parsing ...=0A=
     */=0A=
    this.parsedSnips_ =3D [];=0A=
    this.parsedPHolders_ =3D [];=0A=
    this.parsedCmds_ =3D {};=0A=
    this.parsed_ =3D false;=0A=
    this.isTemplate_ =3D true;=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.Template );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Gets the current resource template. It is <code>null</code>=0A=
   * if no template has already been assigned (which is in=0A=
   * fact a programming error).=0A=
   * @return String: the template=0A=
   */=0A=
  class$.getTemplateString =3D function ()=0A=
  {=0A=
    return this.templateString_; =0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Sets the template string of the template.=0A=
   * @param aTemplate: string: a string containing the new template.=0A=
   */=0A=
  class$.setTemplate =3D function ( aTemplate )=0A=
  {=0A=
    this.templateString_ =3D aTemplate;=0A=
  };=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Static Regular expression for Template parsing.=0A=
   * Note: Executing the regular expression gives a special array.=0A=
   * Try the string "($xyz) ($#for $control) ($endfor)" =0A=
   * for the possible results.=0A=
   */=0A=
  class$.static_.placeholderRegExp =3D =0A=
    /\(\$(((\#)([^\)\s\$\"]*)\s*([\$|\"]?([^\)]*))?)|([^\)\s]*))\s*\)/;=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Static regexps for expression parsing. The actual regexp is divided=0A=
   * into several subexpressions that are assembled as needed. =0A=
   */=0A=
  class$.static_.expressionRegExps_ =3D {=0A=
                                        // regexp to check for =
placeholder with leading '$' =0A=
                                        s_expr: =
'(\\$(([a-zA-Z0-9_]*:)*([a-zA-Z0-9_]*))|\\"([^\\"]*)\\"|\\d+|TRUE|FALSE)'=
,=0A=
                                        // regexp to match a single =
placeholder and strip trailing spaces=0A=
                                        ph    : =
'^\\$(([a-zA-Z0-9_]*:)*([a-zA-Z0-9_]*))\\s*$',=0A=
                                        // regexp to check for operators =
- AND/OR must gbe enclosed by spaces!=0A=
                                        op    : =
'((\\s*!=3D\\s*|\\s*=3D=3D\\s*|\\s*>=3D\\s*|\\s*<=3D\\s*|\\s*<\\s*|\\s*>\=
\s*)|(\\s+AND\\s|\\s+OR\\s+))',=0A=
                                        // regexp to check for boolean =
operators=0A=
                                        boolop: '(AND|OR)'=0A=
                                      };=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * A static counter for commands which are replaced by "pseudo" =
identifiers =0A=
   */=0A=
  class$.static_.resIdCounter_ =3D 0;=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This is a static class method that checks whether the supplied =
string is a =0A=
   * single placeholder or not. In the first case the function returns =0A=
   * the placeholder, in the second case null.=0A=
   * return String: the parsed placeholder or <CODE>null</CODE>=0A=
   */=0A=
  class$.static_.parsePH =3D function ( thePH )=0A=
  {      =0A=
    // Create the regexp out of static object data=0A=
    var ph_reg =3D new RegExp( this.expressionRegExps_.ph );=0A=
    var parsed_ph =3D ph_reg.exec( thePH );=0A=
    =0A=
    if ( parsed_ph =3D=3D null ) =0A=
      return null;=0A=
    =0A=
    return parsed_ph[1];=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method is used for commands that can be supplied with command =
placeholders=0A=
   * as well as more complex expressions (involving AND, NOT, OR, !=3D, =
...).=0A=
   * The method checks whether the supplied string is a single command =0A=
   * placeholder or a command expression. In the first case it returns =0A=
   * the placeholder. In the second case it returns a function that must =0A=
   * be supplied with the actual environment and then computes a boolean =
value=0A=
   * representing the value of the expression.=0A=
   * @param thePHExpr: String: the command placeholder (expression) to =
parse.=0A=
   * @return Function: a function computing the value of the given =
expression within=0A=
   *                   the actual environment or <null> if nothing found=0A=
   */=0A=
  class$.static_.parseExpr =3D function ( thePHExpr )=0A=
  {=0A=
    //get the expressions regexps from static object=0A=
    var ph_const_exp =3D this.expressionRegExps_.s_expr;=0A=
    var op_exp =3D this.expressionRegExps_.op;=0A=
    var boolop_exp =3D this.expressionRegExps_.boolop;=0A=
=0A=
    // the assembled regexp to parse expressions - every expression that =
can =0A=
    // be matched by this regexp is a valid expression.=0A=
    var expr_reg =3D new RegExp("(^" + ph_const_exp + "(" + op_exp + =
ph_const_exp + ")*)", "i");=0A=
    =0A=
    // strip trailing spaces from the input string=0A=
    thePHExpr =3D thePHExpr.replace(/\s*$/,"");=0A=
    =0A=
    var parsed_ph =3D expr_reg.exec( thePHExpr );=0A=
          =0A=
    if ( (parsed_ph =3D=3D null) || (parsed_ph[0] !=3D thePHExpr) ) =0A=
      return null;=0A=
=0A=
    // a single placeholder was supplied=0A=
    if ( parsed_ph.length =3D=3D 4 ) {      =0A=
      var fun =3D "return theEnv.getModified('" + parsed_ph[3] + "')";=0A=
      return new Function ("theEnv", fun);=0A=
    }=0A=
 =0A=
    // Replacing placeholders with corresponding environment access=0A=
    var eval_expr =3D =
thePHExpr.replace(/\$(([a-zA-Z0-9_]*:)*([a-zA-Z0-9_]*))/g,"theEnv.getModi=
fied('$1')");=0A=
=0A=
    // Translating boolean operators to JS     =0A=
    eval_expr =3D eval_expr.replace(/\sOR\s/ig," || =
").replace(/\sAND\s/ig," && ");=0A=
    // In JS booelean literals MUST be written in lower case=0A=
    eval_expr =3D =
eval_expr.replace(/TRUE/g,"true").replace(/FALSE/g,"false");=0A=
    =0A=
    =0A=
    var eval_fun =3D "return " + eval_expr;=0A=
    =0A=
    return new Function ("theEnv", eval_fun);=0A=
  };=0A=
=0A=
//--------------------------------------------------------------------=0A=
  /**=0A=
   * Parses the template into the internal parse structure that consists=0A=
   * of template snips (containing no placeholders), placeholders and=0A=
   * a set of commands. Command bodies are parsed recursively. =0A=
   * @param theText: string: the template's text=0A=
   * @param theEndCmdSet: Object: a JavaScript object containing=0A=
   *   keys which specify commands that should stop parsing=0A=
   * @return object: consists of the following properties=0A=
   * <BR><CODE>object.error_ [com.hyperwave.res.Exception | =
void]</CODE>: =0A=
   *   an Exeption describing an error or void if all went ok.=0A=
   * <BR><CODE>object.textTail_ [String | void]</CODE>: the rest of the=0A=
   *   template if the parsing process has been ended or null=0A=
   *   if no characters were left.=0A=
   * <BR><CODE>object.endCmd_ [String | void]</CODE>: the End Command if =0A=
   *   there was an end command given and found.=0A=
   */=0A=
  class$.continueParse =3D function ( theTemplate, theEndCmdSet )=0A=
  {=0A=
    this.parsed_ =3D true;=0A=
    var text_tail;=0A=
    var state =3D {};=0A=
    var regexp =3D this.static_.placeholderRegExp;=0A=
=0A=
    for ( ;; )=0A=
    {=0A=
      var exec_out =3D regexp.exec ( theTemplate );=0A=
=0A=
      if ( exec_out =3D=3D null )=0A=
      {=0A=
        this.parsedSnips_ [this.parsedSnips_.length] =3D =0A=
          theTemplate;=0A=
        state.textTail_ =3D null;=0A=
        break;=0A=
      }=0A=
 =0A=
      // Check JavaScript Engine Problems:=0A=
      if ( exec_out[0].length =3D=3D 0 )=0A=
      {=0A=
        ++err_count;=0A=
        reg_exp.compile ();=0A=
        if ( err_count =3D=3D 5 )=0A=
        {=0A=
          state.error_ =3D new com.hyperwave.res.ResourceException (=0A=
            "com.hyperwave.res.Template: Internal Parser Error" );=0A=
          state.textTail_ =3D theTemplate;=0A=
          return state;=0A=
        }=0A=
      }=0A=
 =0A=
      var placeholder_string =3D exec_out[0];=0A=
=0A=
      this.parsedSnips_ [this.parsedSnips_.length] =3D =0A=
        theTemplate.substring ( 0, exec_out.index );=0A=
      text_tail =3D theTemplate.substring ( exec_out.index + =
placeholder_string.length );=0A=
=0A=
      if ( exec_out [3] =3D=3D "#" )       // Command ... ?=0A=
      {=0A=
        var command =3D exec_out [4].toLowerCase ();=0A=
=0A=
        if ( theEndCmdSet && theEndCmdSet [ command ] )=0A=
        {=0A=
          state.parsedEndCmd_ =3D command;=0A=
          state.textTail_ =3D text_tail;=0A=
          break;=0A=
        };=0A=
         =0A=
        var command_expr =3D exec_out[5];=0A=
=0A=
        var cmd_node =3D =0A=
          com.hyperwave.res.AbstractCmd.static_.getCommand (=0A=
            { command_: command,=0A=
              expression_: command_expr } );=0A=
 =0A=
        if ( cmd_node =3D=3D null )=0A=
        {=0A=
          state.error_ =3D new com.hyperwave.res.ResourceException (=0A=
            "com.hyperwave.res.Template: Unsupported Template Command '" =
+=0A=
            exec_out [4] + "'." );=0A=
          state.textTail_ =3D text_tail;=0A=
          break;=0A=
        }=0A=
        =0A=
        if ( cmd_node.error_ )=0A=
        {=0A=
          state.error_ =3D cmd_node.error_;=0A=
          state.textTail_ =3D text_tail;=0A=
          break;=0A=
        }=0A=
=0A=
        var ctr =3D ++this.static_.resIdCounter_;=0A=
        var res_id =3D "_intcmd" + ctr + "_";=0A=
        this.parsedPHolders_ [this.parsedPHolders_.length] =3D res_id;=0A=
        =0A=
        this.parsedCmds_ [res_id] =3D cmd_node;=0A=
        new_state =3D cmd_node.doParse ( text_tail );=0A=
        if ( new_state.error_ )=0A=
          return new_state;=0A=
        =0A=
        text_tail =3D new_state.textTail_;=0A=
      }=0A=
      else                             // Simple Placeholder!=0A=
        this.parsedPHolders_ [this.parsedPHolders_.length] =3D exec_out =
[7];=0A=
=0A=
      theTemplate =3D text_tail;=0A=
    } /* for */=0A=
=0A=
    return state;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Invokes the parser. Sets and returns the object's internal error =0A=
   * condition.=0A=
   * @return com.hyperwave.res.ResourceException: an=0A=
   *   Exception type if an error occured otherwise null=0A=
   */=0A=
  class$.doParse =3D function ()=0A=
  {=0A=
    if ( this.parsed_ )=0A=
      return this.error_;=0A=
    =0A=
    if ( this.templateString_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.Template: cannot parse an empty template." );=0A=
    }=0A=
    else=0A=
    {=0A=
      var state =3D this.continueParse ( this.templateString_ );=0A=
      if ( state.error_ )=0A=
        this.error_ =3D state.error_;=0A=
    }=0A=
    return this.error_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Fills a template with the resources of a given scoped map.=0A=
   * @param theEnv: com.hyperwave.res.ScopedMap: the current environment=0A=
   *   that includes all placeholder references to Resources and =
Templates.=0A=
   * @return String: the string representation.=0A=
   */=0A=
  class$.fill =3D function ( theEnv )=0A=
  {=0A=
    var ScopedMap =3D com.hyperwave.res.ScopedMap;=0A=
    if ( !this.parsed_ )=0A=
    {=0A=
      this.doParse ();=0A=
      if ( this.error_ )=0A=
        return ( this.error_.toString () );=0A=
    }=0A=
=0A=
    var out_array =3D [];=0A=
    for ( var snip_ind =3D 0; snip_ind < this.parsedSnips_.length; =
++snip_ind )=0A=
    {=0A=
      out_array [out_array.length] =3D this.parsedSnips_ [snip_ind];=0A=
      if ( snip_ind < this.parsedPHolders_.length )=0A=
      {=0A=
        var pholder =3D this.parsedPHolders_ [snip_ind];=0A=
        if (pholder =3D=3D "ui_language")=0A=
        {=0A=
          if (typeof client !=3D "undefined")=0A=
          {=0A=
            var value =3D client.language;=0A=
          }=0A=
          else if (typeof document !=3D "undefined")=0A=
          {=0A=
            var value =3D document.cookie.match(/LANGUAGE=3D(\w{2})/);=0A=
          }=0A=
          else=0A=
          {=0A=
            value =3D "en";=0A=
          }=0A=
        }=0A=
        else=0A=
        {  =0A=
          var value =3D theEnv.get ( pholder );=0A=
        }=0A=
        try {=0A=
          var modifiers =3D ScopedMap.static_.getModifiers(pholder);=0A=
        }=0A=
        catch (ex) {=0A=
          var modifiers =3D null;=0A=
          // FIX: HWIS/PR-6081: leave unknown placeholders the way they =
are=0A=
          // (xsl files may have the same syntax as resource =
placeholders)=0A=
          if(typeof writelnError !=3D "undefined")=0A=
            writelnError("Unknown Resource Modifier found =
(Template.fill): " + this.parsedPHolders_ [snip_ind]);=0A=
          value =3D "($" + this.parsedPHolders_ [snip_ind] + ")";=0A=
        }=0A=
        if ( value =3D=3D null )=0A=
        {=0A=
          value =3D this.parsedCmds_ [pholder];=0A=
          if ( value =3D=3D null ) {=0A=
            // FIX: HWIS/PR-6081: leave unknown placeholders the way =
they are=0A=
            // (xsl files may have the same syntax as resource =
placeholders)=0A=
            if(typeof writelnError !=3D "undefined")=0A=
              writelnError("Unknown Placeholder found (Template.fill): " =
+ this.parsedPHolders_ [snip_ind]);=0A=
            out_array [out_array.length] =3D "($" + this.parsedPHolders_ =
[snip_ind] + ")";=0A=
          }=0A=
          else=0A=
            out_array [out_array.length] =3D =
ScopedMap.static_.applyModifiers(modifiers, value.execCmd ( theEnv ), =
theEnv);=0A=
        }=0A=
        else=0A=
          if ( value.isTemplate_ )=0A=
            out_array [out_array.length] =3D =
ScopedMap.static_.applyModifiers(modifiers, value.fill ( theEnv ), =
theEnv);=0A=
          else=0A=
            out_array [out_array.length] =3D =
ScopedMap.static_.applyModifiers(modifiers, value.toString(), theEnv);=0A=
      }=0A=
    }=0A=
=0A=
    return ( out_array.join ( "" ) );=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Returns the template's string representation (not processed).=0A=
   */=0A=
  class$.toString =3D function () =0A=
  {=0A=
    return "@com.hyperwave.Template: templateString_=3D'" + =
this.templateString_ + "'";=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/XMLResourceReader.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        ResourceReader.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: XMLResourceReader.js 164480 2011-06-10 13:23:56Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
loadClass ( "com.hyperwave.res.CSResourceReader" );=0A=
loadClass ( "com.hyperwave.res.Template" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This resource reader gets the resources from so-called <i>lrc</i>=0A=
 * files in XML format (.xml) and encapsulates the access to resources =
within these=0A=
 * files. It provides direct and iterative access to the resources=0A=
 * defined within these definitions. The files are accessed =0A=
 * by the calls: <code>resdefx (...)</code>, <code>resgetx (...)</code> =
and =0A=
 * <code>residx (...)</code>.=0A=
 * The current supported format is:=0A=
 * <xmp>=0A=
 *   <?xml version=3D"1.0"?>=0A=
 *   =0A=
 *   <!DOCTYPE resdefinitions=0A=
 *       PUBLIC "-//Hyperwave//DTD Resources 1.0//EN"=0A=
 *       "http://www.hyperwave.com/dtds/xmlres_1_0.dtd"> =0A=
 *   =0A=
 *   <RESDEFINITIONS>=0A=
 *   =0A=
 *   <RES name=3D"main" type=3D"template"><![CDATA[=0A=
 *   <HTML>=0A=
 *     <HEAD>=0A=
 *       <TITLE>TestSeite</TITLE>=0A=
 *     </HEAD>=0A=
 *     <BODY BGCOLOR=3D"($bgcolor)">=0A=
 *       Dies ist ein erster Test <BR>=0A=
 *       Username: ($username)=0A=
 *     </BODY>=0A=
 *   </HTML>=0A=
 *   ]]></RES>=0A=
 *   =0A=
 *   <RES name=3D"lang1" type=3D"string">=0A=
 *   This is english.=0A=
 *   </RES>=0A=
 *   =0A=
 *   </RESDEFINITIONS>=0A=
 * </xmp> =0A=
 * An <i>index</i> section is not needed anymore.=0A=
 * @see com.hyperwave.res.ResourceReader=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.XMLResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Creates a resource reader for resource files in XML format.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.xmlFileName_: String: the filename of the xml=0A=
   *   file. Be aware of the fact that the correctness of the=0A=
   *   filename depends on the environment. In the wavemaster environment=0A=
   *   it is relative to the wavemaster's HTML_DIR and in hwjs it =0A=
   *   is (currently) relative to $HW_HOME/wavemaster.=0A=
   */=0A=
  com.hyperwave.res.XMLResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.xmlFileName_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.XMLResourceReader: Constructed without =
XMLFileName" );=0A=
      this.xmlFileName_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    this.xmlFileName_ =3D aParam.xmlFileName_;     =0A=
=0A=
    // if old binaries are used xml files cannot be handled.=0A=
    if (typeof resdefx =3D=3D "undefined" ) {=0A=
      // an xml file is present but the xml readers are not defined!=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
      "com.hyperwave.res.XMLResourceReader: The given resource is an XML =
file: '" + =0A=
      this.xmlFileName_ + "'. This JavaScript engine is not capable to =
handle XML files.");=0A=
      return;=0A=
    }=0A=
=0A=
    // read in xml file using new api functions=0A=
    var out =3D resdefx ({ scope: this.xmlFileName_, location: =
this.xmlFileName_ });=0A=
    if (out.error.error()) {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.XMLResourceReader: Could not read in =
resource: '" + =0A=
        this.xmlFileName_ + "'. Error from server: '" +=0A=
        out.error[0].description("en") + "'" );=0A=
      return;=0A=
    }=0A=
    this._readXML ();=0A=
  };=0A=
  class$ =3D doInherit ( com.hyperwave.res.XMLResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads the Hyperwave LRC file in XML format and parses the =
structure. =0A=
   * This is done by means of the new api method <code>residx</code> =
which =0A=
   * reads in the index of the resource file.=0A=
   * @return com.hyperwave.res.ResourceException: returns null=0A=
   *   if everything went right an exception otherwise.=0A=
   */=0A=
  class$._readXML =3D function ()=0A=
  {=0A=
    var exception =3D new com.hyperwave.res.ResourceException ();=0A=
=0A=
    // try to read in the index of the resource file=0A=
    var idx_obj =3D residx( {scope: this.xmlFileName_} );=0A=
    if (idx_obj.error.error()){=0A=
      exception.pushError ( "com.hyperwave.XMLResourceReader: Could not =
read index of resource '" + =0A=
                            this.xmlFileName_ + =0A=
                            "'. Error message from server: '" +=0A=
                            idx_obj.error[0].description("en") + "'." ); =
       =0A=
      return this.error_ =3D exception;=0A=
    } =0A=
    =0A=
    // step through read in index and read in all resource definitions=0A=
    var res_obj;=0A=
    var key;=0A=
    for ( var index_nr =3D 0; index_nr < idx_obj.idx.length; ++index_nr )=0A=
    {=0A=
      key =3D idx_obj.idx[index_nr];=0A=
      res_obj =3D resgetx( { scope: this.xmlFileName_ , =0A=
                           identifier: key } );=0A=
      =0A=
      if (res_obj.error.error()) {=0A=
        exception.pushError ( "com.hyperwave.XMLResourceReader: Key '" + =0A=
                              key + =0A=
                              "' could not be read in. Error message =
from server: '" +=0A=
                              res_obj.error[0].description("en") + "'." =
);        =0A=
      }=0A=
      else {=0A=
        switch (res_obj.type)=0A=
        {=0A=
          case "template":=0A=
            // instantiate a new Template=0A=
            this.setRes ( key, =0A=
                          new com.hyperwave.res.Template ( { =
templateString_: res_obj.text } ) );=0A=
            break;=0A=
          default:=0A=
            // default is a string. =0A=
            // if old lrc files are read in using =
<code>XMLResourceReader</code> all =0A=
            // in it defined resources are treated as strings.=0A=
            this.setRes( key, res_obj.text );=0A=
        }=0A=
      }=0A=
    } /* end for */=0A=
    =0A=
    if ( exception.errorCount () =3D=3D 0 )=0A=
      return null;=0A=
=0A=
    return this.error_ =3D exception;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Test main routine.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
    var r =3D new com.hyperwave.res.ResourceReader ( { lrcFileName_: =
"htmlres1.lrc" } );=0A=
    if ( r.error_ )=0A=
      writeln ( "Error in reader: " + r.error_ );=0A=
    else=0A=
      writeln ( "Content: " + r );=0A=
  };=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.XMLResourceReader.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/com/hyperwave/res/XMLServerResourceReader.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        XMLServerResourceReader.js=0A=
 *  Created:     2001-01-14=0A=
 *  $Id: XMLServerResourceReader.js 157905 2010-08-18 15:29:44Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
initPackage ( "com.hyperwave.res" );=0A=
loadClass ( "com.hyperwave.res.AbstractResourceReader" );=0A=
loadClass ( "com.hyperwave.res.CSResourceReader" );=0A=
loadClass ( "com.hyperwave.res.Template" );=0A=
=0A=
//----------------------------------------------------------------------=0A=
/**=0A=
 * This resource reader gets the resources from resource objects on =
server =0A=
 * in XML format and encapsulates the access to resources within these=0A=
 * objects. It provides direct and iterative access to the resources=0A=
 * defined within these definitions. The files are accessed =0A=
 * by the calls: <code>api.resdef (...)</code> and <code>api.lrc =
(...)</code>.=0A=
 * The current supported format is:=0A=
 * <xmp>=0A=
 *   <?xml version=3D"1.0"?>=0A=
 *   =0A=
 *   <!DOCTYPE resdefinitions=0A=
 *       PUBLIC "-//Hyperwave//DTD Resources 1.0//EN"=0A=
 *       "http://www.hyperwave.com/dtds/xmlres_1_0.dtd"> =0A=
 *   =0A=
 *   <RESDEFINITIONS>=0A=
 *   =0A=
 *   <RES name=3D"main" type=3D"template"><![CDATA[=0A=
 *   <HTML>=0A=
 *     <HEAD>=0A=
 *       <TITLE>TestSeite</TITLE>=0A=
 *     </HEAD>=0A=
 *     <BODY BGCOLOR=3D"($bgcolor)">=0A=
 *       Dies ist ein erster Test <BR>=0A=
 *       Username: ($username)=0A=
 *     </BODY>=0A=
 *   </HTML>=0A=
 *   ]]></RES>=0A=
 *   =0A=
 *   <RES name=3D"lang1" type=3D"string">=0A=
 *   This is english.=0A=
 *   </RES>=0A=
 *   =0A=
 *   </RESDEFINITIONS>=0A=
 * </xmp> =0A=
 * An <i>index</i> section is not needed anymore.=0A=
 * @see com.hyperwave.res.ResourceReader=0A=
 */=0A=
// <JSClass Name=3D"com.hyperwave.res.XMLServerResourceReader">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Creates a resource reader for resource files on server in XML =
format.=0A=
   * @param aParam: Object:=0A=
   * @param aParam.lrcServerLocation_: String: the location of the lrc =
on server=0A=
   */=0A=
  com.hyperwave.res.XMLServerResourceReader =3D function ( aParam )=0A=
  {=0A=
    if ( aParam =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.base$ =3D com.hyperwave.res.AbstractResourceReader;=0A=
    this.base$ ( aParam );=0A=
    delete this.base$;=0A=
=0A=
    if ( aParam =3D=3D null || aParam.lrcServerLocation_ =3D=3D null )=0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.XMLServerResourceReader: Constructed without =
LRCServerLocation" );=0A=
      this.lrcServerLocation_ =3D null;=0A=
      return;=0A=
    }=0A=
=0A=
    this.lrcServerLocation_ =3D aParam.lrcServerLocation_;   =0A=
    =0A=
    // within DC use api-call=0A=
    // within templates use server-call=0A=
    this.api_ =3D null; =0A=
    if (typeof server !=3D "undefined")=0A=
      this.api_ =3D server;=0A=
    if ( (typeof api !=3D "undefined") &&=0A=
         (typeof args !=3D "undefined") )=0A=
      this.api_ =3D api;=0A=
    if (this.api_ =3D=3D null) =0A=
    {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.ServerResourceReader: No API or server =
defined" );=0A=
      return;=0A=
    }=0A=
    =0A=
    // if old binaries are used xml files cannot be handled.=0A=
    if (typeof resdefx =3D=3D "undefined" ) {=0A=
      // an xml file is present but the xml readers are not defined!=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
      "com.hyperwave.res.XMLServerResourceReader: The given resource is =
an XML file: '" + =0A=
      this.lrcServerLocation_ + "'. This JavaScript engine is not =
capable to handle XML files.");=0A=
      return;=0A=
    }=0A=
=0A=
    // read in xml file using new api functions=0A=
    var out =3D this.api_.resdefx ({ scope: this.lrcServerLocation_, =
location: this.lrcServerLocation_ });=0A=
    if (out.error.error()) {=0A=
      this.error_ =3D new com.hyperwave.res.ResourceException (=0A=
        "com.hyperwave.res.XMLResourceReader: Could not read in =
resource: '" + =0A=
        this.lrcServerLocation_ + "'. Error from server: '" +=0A=
        out.error[0].description("en") + "'" );=0A=
      return;=0A=
    }=0A=
    this._readXML ();=0A=
  }=0A=
  class$ =3D doInherit ( com.hyperwave.res.XMLServerResourceReader,=0A=
                       com.hyperwave.res.AbstractResourceReader );=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Reads the Hyperwave LRC object in XML format from server and parses =
the structure. =0A=
   * This is done by means of the new api method <code>residx</code> =
which =0A=
   * reads in the index of the resource file.=0A=
   * @return com.hyperwave.res.ResourceException: returns null=0A=
   *   if everything went right an exception otherwise.=0A=
   */=0A=
  class$._readXML =3D function ()=0A=
  {=0A=
    var exception =3D new com.hyperwave.res.ResourceException ();=0A=
=0A=
    // try to read in the index of the resource file=0A=
    var idx_obj =3D this.api_.residx( {scope: this.lrcServerLocation_} );=0A=
    if (idx_obj.error.error()){=0A=
      exception.pushError ( "com.hyperwave.XMLServerResourceReader: =
Could not read index of resource '" + =0A=
                            this.lrcServerLocation_ + =0A=
                            "'. Error message from server: '" +=0A=
                            idx_obj.error[0].description("en") + "'." ); =
       =0A=
      return this.error_ =3D exception;=0A=
    } =0A=
    =0A=
    // step through read in index and read in all resource definitions=0A=
    var res_obj;=0A=
    var key;=0A=
    for ( var index_nr =3D 0; index_nr < idx_obj.idx.length; ++index_nr )=0A=
    {=0A=
      key =3D idx_obj.idx[index_nr];=0A=
      res_obj =3D this.api_.resgetx( { scope: this.lrcServerLocation_ , =0A=
                           identifier: key } );=0A=
      =0A=
      if (res_obj.error.error()) {=0A=
        exception.pushError ( "com.hyperwave.XMLServerResourceReader: =
Key '" + =0A=
                              key + =0A=
                              "' could not be read in. Error message =
from server: '" +=0A=
                              res_obj.error[0].description("en") + "'." =
);        =0A=
      }=0A=
      else {=0A=
        switch (res_obj.type)=0A=
        {=0A=
          case "template":=0A=
            // instantiate a new Template=0A=
            this.setRes ( key, =0A=
                          new com.hyperwave.res.Template ( { =
templateString_: res_obj.text } ) );=0A=
            break;=0A=
          default:=0A=
            // default is a string. =0A=
            // if old lrc files are read in using =
<code>XMLResourceReader</code> all =0A=
            // in it defined resources are treated as strings.=0A=
            this.setRes( key, res_obj.text );=0A=
        }=0A=
      }=0A=
    } /* end for */=0A=
    =0A=
    if ( exception.errorCount () =3D=3D 0 )=0A=
      return null;=0A=
=0A=
    return this.error_ =3D exception;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Test main routine.=0A=
   */=0A=
  class$.static_.main =3D function ()=0A=
  {=0A=
  }=0A=
=0A=
// </JSClass>=0A=
//----------------------------------------------------------------------=0A=
=0A=
/* End of "com.hyperwave.res.XMLServerResourceReader.js" */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/com/hyperwave/util/WebParameters.js?cachekeY=515488b2-en

/*=0A=
 * Copyright (c) Hyperwave GmbH 2010. All rights reserved.=0A=
 * $Id: WebParameters.js 162833 2011-05-05 11:05:55Z sweber $=0A=
 */=0A=
=0A=
 /* =0A=
  * FIXXME: 2004-10-28 (cdaller)=0A=
  * the parsing of the web parameters will not work with web parameter=0A=
  * objects as values of the web parameters!!! Hopefully, these methods=0A=
  * are not used! The getParameterString does work with the encapsulated=0A=
  * web parameter objects.=0A=
  */=0A=
=0A=
/**=0A=
 * Represents an abstract form of key |=3D&gt; array maps that mostly=0A=
 * represent either URL parameters or parameters that should be=0A=
 * encoded into a URL or HTML form. It serves mostly as a convenience =
class=0A=
 * that helps to get rid of the problem that URL parameters can have=0A=
 * multiple values for on key but won't usually use this feature. So=0A=
 * we will use this classes' method to get rid of nasty accessors like=0A=
 * <code>if (params[key]) value =3D=3D params[key][0]</code>.</p>=0A=
 *=0A=
 * <p>This class might be useful for all parameter modifications on=0A=
 * the client side that will finally result in a URL. One can use=0A=
 * this class to create right parameter strings for URLs that=0A=
 * are RFC-2396 conform.=0A=
 *=0A=
 * @author simon.zwoelfer=0A=
 */=0A=
 =0A=
defineClass ( "com.hyperwave.util.WebParameters", function (class$)=0A=
{=0A=
  /**=0A=
   * Default constructor for a new WebParameters instance.=0A=
   *=0A=
   * <p>This implementation will initialize internal structures hence=0A=
   * it has to be called by subclass constructors.</p>=0A=
   * =0A=
   * @param keyValuesMap: Object | void: a map that has the following =
structure:=0A=
   *   <ul>=0A=
   *     <li><code>key</code>: the name of the parameter (as =
string)</li> =0A=
   *     <li><code>value</code>: a list of values (as linear array of =
objects)</li>=0A=
   *   </ul> =0A=
   */=0A=
  class$.constructor =3D function ( keyValuesMap )=0A=
  {=0A=
    if ( keyValuesMap =3D=3D "__proto__" )=0A=
      return;=0A=
    =0A=
    /** Private holder for the key-values */=0A=
    this.map_ =3D keyValuesMap || new Object();=0A=
=0A=
    /** Indicator for sorted conversions */=0A=
    this.valueSort_ =3D false;=0A=
  }=0A=
	=0A=
  /**=0A=
   * Solves some problems that occur with bad firewalls. The problem is=0A=
   * that too much is escaped sometimes. Hence one has to convert=0A=
   * escaped &quot;&amp;&quot;" characters (%26) back to their=0A=
   * original value to split key value pairs later on.=0A=
   *=0A=
   * <p>Note: This implementation is somewhat questionable because=0A=
   * there might occur some problems with it:=0A=
   * <ul>=0A=
   *   <li>There exist firewalls that decode URLs and URL=0A=
   *     parameters=0A=
   *   <li>There exist firewalls that ENCODE URLs and URL=0A=
   *     parameters=0A=
   *   <li>It depends on the assumption that question mark=0A=
   *     characters are not allowed within the path or=0A=
   *     host information.=0A=
   * </ul>=0A=
   * @param aParametersString: string: the parameters part of a URL=0A=
   * @return string: the converted parameters part of the URL=0A=
   */=0A=
  class$._solveFirewallProblem =3D function ( aParametersString )=0A=
  {=0A=
    var converted_par_str =3D "";=0A=
    var split =3D aParametersString.split("=3D");=0A=
=0A=
    if (split.length > 0)=0A=
    {=0A=
      converted_par_str +=3D split[0] + "=3D";=0A=
      for (var k=3D0; k<split.length; k++)=0A=
      {=0A=
        var and_position =3D split[k].lastIndexOf("%26");=0A=
        if (and_position !=3D -1)=0A=
        {=0A=
          var prev_value =3D split[k].substring(0,and_position);=0A=
          var next_key   =3D split[k].substr(and_position+3);=0A=
          converted_par_str +=3D prev_value + "&" +  next_key + "=3D";=0A=
        }=0A=
      }=0A=
      converted_par_str +=3D split[split.length-1];=0A=
    }=0A=
=0A=
    return converted_par_str;=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns only the parameter part of a URL as a string.=0A=
   *=0A=
   * <p>This implementation extracts the parameter part of the URL by=0A=
   * means of the first occurrence of a parameter separator. A=0A=
   * separator might be a question mark "?" or an escaped question=0A=
   * mark "%3F". From the point of view of RFC 2396 this is not=0A=
   * considered a problem because (a) question marks are reserved=0A=
   * characters and (b) escaped question marks will normally not be=0A=
   * present within the path information (because the Windows=0A=
   * file-system does not allow question marks within Filenames). If=0A=
   * this is the case a special handling of key-value pairs has to be=0A=
   * done.=0A=
   *=0A=
   * @param  anUrl: string: the URL to be analyzed.=0A=
   * @return string: the parameter string of the URL=0A=
   */=0A=
  class$._getParameterStringFromUrl =3D function (anUrl)=0A=
  {=0A=
    var par_str =3D "";=0A=
=0A=
    var found_position_of_questionmark =3D anUrl.indexOf("?");=0A=
    var found_position_of_escaped_qmark =3D anUrl.indexOf ("%3F");=0A=
=0A=
    if (found_position_of_questionmark !=3D -1)=0A=
      par_str =3D anUrl.substr(found_position_of_questionmark + 1);=0A=
    else if (found_position_of_escaped_qmark !=3D -1)=0A=
    {=0A=
      par_str =3D anUrl.substr(found_position_of_unescaped_semicolon + =
3);=0A=
      par_str =3D this._solveFirewallProblem(par_str);=0A=
    }=0A=
=0A=
    return par_str;=0A=
  }=0A=
=0A=
  /**=0A=
   * Merges the elements of another web parameters object into this one.=0A=
   * <p>=0A=
   * This implementations "clones" the key value(s) pairs of the operand=0A=
   * and merges all these pairs to the parameters. Note that there =0A=
   * is no checking of uniqueness (as usual). Another fact is that the=0A=
   * values will not be cloned - the value references will be the same=0A=
   * as in the parameter map.=0A=
   *=0A=
   * @param webParameters: WebParameters: a web parameters object whose=0A=
   *   elements are merged into this one (after they have been cloned).=0A=
   */=0A=
  class$.merge =3D function ( webParameters )=0A=
  {=0A=
    if ( typeof webParameters =3D=3D "undefined" || webParameters =3D=3D =
null )=0A=
      return;=0A=
=0A=
//    var clone =3D webParameters.clone();=0A=
    var clone =3D webParameters;=0A=
    for ( var key in clone.map_ )=0A=
    {=0A=
      if ( this.map_ [key] )=0A=
      {=0A=
        var arr =3D clone.map_ [key];=0A=
        var out_arr =3D this.map_ [key];=0A=
        for ( var i =3D 0; i < arr.length; ++i )=0A=
          out_arr.push ( arr [i] );=0A=
      }=0A=
      else=0A=
        this.map_ [key] =3D clone.map_ [key];=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * Adds a key value pair to the map. Note that all other=0A=
   * values remain in the map and are not changed. Regardless=0A=
   * to the existence of a same value the given value will=0A=
   * simply be added to the array of values for this key.=0A=
   *=0A=
   * @param aKey: String: contains the name which should map=0A=
   *   at least to the given value.=0A=
   * @param aValue: Object: is the value which should be=0A=
   *   added to the key's values.=0A=
   */=0A=
  class$.addKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    if ( typeof aValue =3D=3D "undefined" )=0A=
      return;=0A=
=0A=
    if (this.map_[aKey])=0A=
      this.map_[aKey][this.map_[aKey].length] =3D aValue;=0A=
    else=0A=
      this.map_[aKey] =3D ([ aValue ]);=0A=
  }=0A=
=0A=
  /**=0A=
   * Deletes a key and its associated values from the map.=0A=
   * @param aKey: string: the key that should be deleted.=0A=
   */=0A=
  class$.deleteKey =3D function (aKey)=0A=
  {=0A=
    if (this.map_[aKey])=0A=
      delete this.map_[aKey];=0A=
  }=0A=
=0A=
  /**=0A=
   * Assures that the map contains exactly one key (with the name=0A=
   * aKey) with one corresponding value. Note that previous values=0A=
   * will simply be discarded.=0A=
   *=0A=
   * @param aKey: string: contains the name which should have=0A=
   *   the given value.=0A=
   * @param aValue: Object: defines the value.=0A=
   */=0A=
  class$.setKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    if ( typeof aValue =3D=3D "undefined" )=0A=
      return;=0A=
=0A=
    this.map_[aKey] =3D ([ aValue ]);=0A=
  }=0A=
=0A=
  /**=0A=
   * Splits an arbitrary <i>parameter string</i> into its keys and=0A=
   * values and adds them to the map.=0A=
   *=0A=
   * <p>This implementation uses the @see #addUrlParameters method as a=0A=
   * helper.=0A=
   *=0A=
   * @param theParams: string: the Parameters in String representation=0A=
   * @see #addUrlParameters=0A=
   */=0A=
  class$.addParameterString =3D function ( theParams )=0A=
  {=0A=
    if (theParams)=0A=
    {=0A=
      var my_key_values_array =3D theParams.split("&");=0A=
      for (var i=3D0; i<my_key_values_array.length; i++)=0A=
      {=0A=
        var key_value_pair =3D my_key_values_array [i].split("=3D");=0A=
        if (key_value_pair.length !=3D 2)=0A=
          continue;=0A=
  =0A=
        var temp_key =3D unescape(key_value_pair[0].replace (/\+/g, ' =
'));=0A=
        if ( testUtf8 ( temp_key ) )=0A=
          temp_key =3D decodeUtf8 ( temp_key );=0A=
  =0A=
        var temp_value =3D unescape(key_value_pair[1].replace (/\+/g, ' =
'));=0A=
        if ( testUtf8 ( temp_value ) )=0A=
          temp_value =3D decodeUtf8 ( temp_value );=0A=
  =0A=
        this.addKeyValue(temp_key, temp_value );=0A=
      }=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * Fetches all available parameters from the given URL string and=0A=
   * adds them to the key-values. The parameters are extracted from=0A=
   * the URL with the following algorithm:=0A=
   * <ul>=0A=
   * <li>Detect the parameter string:=0A=
   *  <ul>=0A=
   *  <li>If there is a question mark, take the string after the=0A=
   *    question mark and process the parameters.=0A=
   *  <li>Otherwise: if there is an escaped question mark (which is in=0A=
   *    fact the string "%3F" then take the characters which follow this=0A=
   *    string. In this case take care of escaped "=3D" and "&" =
characters=0A=
   *    too.=0A=
   *  </ul>=0A=
   * <li>Extract the parameters by splitting the whole string by its=0A=
   *   "&" characters. Subsequently use the first "=3D" character within=0A=
   *   the resulting string fragments as end for the key string and=0A=
   *   beginning for the value string. The general form of parameter=0A=
   *   strings is then:=0A=
   *   <pre>=0A=
   *    key1=3Dvalue11&key1=3Dvalue12&key...=0A=
   *   </pre>=0A=
   * </ul>=0A=
   *=0A=
   * <p>This implementation will add key-values regardless to existing=0A=
   * key-values.</p>=0A=
   *=0A=
   * @param theUrl: string: the URL containing the parameters.=0A=
   *   which should be added.=0A=
   * @examplecall=0A=
   *   // Client Example: get URL of window, add=0A=
   *   //   a parameter and make a link ...=0A=
   *   var my_par =3D new com.hyperwave.util.WebParameters ();=0A=
   *   my_par.addUrlParameters ( window.location.href );=0A=
   *   my_par.addKeyValue ( "key10", "value10" );=0A=
   *   document.writeln ( "<a href=3D'" +=0A=
   *                      window.loaction.pathname + ";" +=0A=
   *                      my_par.getParameterString () );=0A=
   */=0A=
  class$.addUrlParameters =3D function ( theUrl )=0A=
  {=0A=
    this.addParameterString(this._getParameterStringFromUrl(theUrl));=0A=
  }=0A=
=0A=
  /**=0A=
   * Checks if a given key exists which has at least the=0A=
   * desired value. Note that the "desired value" will be matched by=0A=
   * the JavaScript equality.=0A=
   *=0A=
   * @param aKey: string: contains the name of the parameter=0A=
   * @param aValue: Object: contains the desired value=0A=
   * @return boolean: true, if the key aKey exists and one of=0A=
   *   its values is equal to aValue. Otherwise false will be=0A=
   *   returned.=0A=
   */=0A=
  class$.containsKeyValue =3D function (aKey, aValue)=0A=
  {=0A=
    var values =3D this.map_[aKey];=0A=
    if ( !values )=0A=
      return false;=0A=
=0A=
    for (var i=3D0; i<values.length; i++)=0A=
    {=0A=
      if (values[i] =3D=3D aValue)=0A=
        return true;=0A=
    }=0A=
    return false;=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns an array of strings containing all keys with at=0A=
   * least one value. (This array is often called <i>the map's domain=0A=
   * set</i>.)=0A=
   *=0A=
   * @return String[]: an array of strings containing the keys=0A=
   *   which have at least one value.=0A=
   * @examplecall=0A=
   *   URL: http://www.server.com/module?p1=3D1&p1=3D2&p2=3D5&p3=3D10=0A=
   *=0A=
   *   var my_params =3D new com.hyperwave.util.WebParameters();=0A=
   *   my_params.addUrlParameters ( location.href );=0A=
   *   var my_keys =3D my_params.getKeys();=0A=
   *=0A=
   *   Result: my_keys =3D ["p1", "p2", "p3"]=0A=
   **/=0A=
  class$.getKeys =3D function ()=0A=
  {=0A=
    var ret =3D new Array();=0A=
    for (var x in this.map_)=0A=
      if ( this.map_.hasOwnProperty ( x ) )=0A=
        ret[ret.length] =3D x;=0A=
=0A=
    return ret;=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the number of keys with at least one value.=0A=
   *=0A=
   * @return int: number of keys.=0A=
   */=0A=
  class$.getNumberOfKeys =3D function ()=0A=
  {=0A=
    var ret =3D 0;=0A=
    for (var x in this.map_)=0A=
      if ( this.map_.hasOwnProperty ( x ) )=0A=
        ++ret;=0A=
=0A=
    return ret;=0A=
  }=0A=
=0A=
  /**=0A=
   * Checks if a given key with at least one value is present.=0A=
   *=0A=
   * @param aKey: string: the key to be checked.=0A=
   * @return boolean: true, if <i>aKey</i> has at least one=0A=
   *   value within the map.=0A=
   */=0A=
  class$.containsKey =3D function (aKey)=0A=
  {=0A=
    return (this.map_[aKey] ? true : false);=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns the number of values of a given key.=0A=
   *=0A=
   * @param aKey: string: the key.=0A=
   * @return int: representing the number of values to that key.=0A=
   *   If the key is not present in the map the value 0 will=0A=
   *   returned.=0A=
   */=0A=
  class$.getNumberOfValues =3D function (aKey)=0A=
  {=0A=
    if (this.map_[aKey])=0A=
      return this.map_[aKey].length;=0A=
    return 0;=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns all values of a given key.=0A=
   *=0A=
   * @param  aKey: string: the key.=0A=
   * @return String[]: an array of strings containing all values=0A=
   *   of the given key or <code>null</code> if the key is not=0A=
   *   present in the map.=0A=
   *   Note that the returned array can contain multiple=0A=
   *   entries with the same value.=0A=
   * @examplecall=0A=
   *   var url =3D =
"http://www.server.com/module;p1=3D1&p1=3D2&p2=3D5&p3=3D10";=0A=
   *   var my_params =3D new com.hyperwave.util.WebParameters();=0A=
   *   my_params.addUrlParameters ( url );=0A=
   *   my_values =3D my_params.getAllValues("p1");=0A=
   *=0A=
   *   Result: my_values =3D ["1", "2"]=0A=
   */=0A=
  class$.getAllValues =3D function (aKey)=0A=
  {=0A=
    return this.map_[aKey];=0A=
  }=0A=
=0A=
  /**=0A=
   * If a key has exactly one value it will be returned, if there=0A=
   * are more than one values only one value will be selected in a=0A=
   * nondeterministic way.=0A=
   *=0A=
   * @param aKey: string: the key.=0A=
   * @return Object: will be <code>null</code> if the key is not=0A=
   *   present within the map or one of the objects (strings)=0A=
   *   referenced by the key.=0A=
   */=0A=
  class$.getOneValue =3D function (aKey)=0A=
  {=0A=
    if (this.map_[aKey] && this.map_[aKey].length > 0)=0A=
      return this.map_[aKey][0];=0A=
=0A=
    return null;=0A=
  }=0A=
=0A=
  /**=0A=
   * Clones a WebParameters at the level of keys. This means, that=0A=
   * a new WebParameters will be returned with new keys BUT=0A=
   * references to the values. If the values are strings=0A=
   * or only key-manipulations are done this is sufficient.</p>=0A=
   *=0A=
   * This implementations will use the constructor to create=0A=
   * a new object.=0A=
   *=0A=
   * @param windowScope: Object | void: the brwoser window reference =
that points=0A=
   *   to the frame/window where the clone should be created (default is =
<code>window</code>)=0A=
   * @param theExclList: String[]: array of string keys which=0A=
   *   should not be contained in the resulting map.=0A=
   * @return com.hyperwave.util.WebParameters: a new WebParameters=0A=
   *   containing all keys and their corresponding values but the keys=0A=
   *   in the exclusion list=0A=
   */=0A=
  class$.clone =3D function (windowScope, theExclList)=0A=
  {=0A=
    var windowScope =3D windowScope || window;=0A=
=0A=
    var theClone =3D =
windowScope.newInstanceOf(windowScope.com.hyperwave.util.WebParameters);=0A=
    var look_up =3D {};=0A=
    if (theExclList) {=0A=
      for ( var i =3D 0; i < theExclList.length; ++i )=0A=
        look_up [theExclList [i]] =3D true;=0A=
    }=0A=
    var key_array =3D this.getKeys ();=0A=
=0A=
    for ( var i =3D 0; i < key_array.length; ++i )=0A=
    {=0A=
      var key =3D key_array [i];=0A=
      if ( look_up [key] )=0A=
        continue;=0A=
=0A=
      var values =3D this.getAllValues (key);=0A=
      for ( var j =3D 0; j < values.length; ++j )=0A=
        theClone.addKeyValue ( class$.static_.clone(key, windowScope), =
class$.static_.clone(values [j], windowScope) );=0A=
    }=0A=
    return theClone;=0A=
  }=0A=
=0A=
  /**=0A=
   * Returns a WebParameter object with flat keys - this =0A=
   * means that recursive webparameters will be put into=0A=
   * one final map that contains "recursive" keys.=0A=
   * =0A=
   * @return com.hyperwave.util.WebParameters: the final =0A=
   *   parameter object.=0A=
   */=0A=
  class$._getFlatWebParameters =3D function (keyPrefix, out)=0A=
  {=0A=
    if ( typeof out =3D=3D "undefined" )=0A=
      out =3D new com.hyperwave.util.WebParameters();=0A=
    if ( typeof keyPrefix =3D=3D "undefined" )=0A=
      keyPrefix =3D "";=0A=
      =0A=
    for ( var key in this.map_ )=0A=
    {=0A=
      if ( !this.map_.hasOwnProperty ( key ) )=0A=
        continue;=0A=
      var values =3D this.map_ [key];=0A=
      for ( var j =3D 0; j < values.length; ++j )=0A=
      {=0A=
        if ( (values[j] =3D=3D null) || (typeof values[j] =3D=3D =
"undefined" ))=0A=
          continue;=0A=
        if ( values[j].instanceOf &&  =
values[j].instanceOf("com.hyperwave.util.WebParameters") )=0A=
        {=0A=
          values[j]._getFlatWebParameters ( keyPrefix + "-wp-" + key + =
".", out );=0A=
        }=0A=
        else=0A=
        {=0A=
          out.addKeyValue ( keyPrefix + key, values [j] );=0A=
        }=0A=
      }=0A=
    }=0A=
    return out;=0A=
  }=0A=
  =0A=
  /**=0A=
   * Create a parameter-string which is unique for this=0A=
   * set of parameters (sorted by keys and values). This=0A=
   * string can be appended to an URL for transmitting ...=0A=
   * Note: This function is the inverse function of=0A=
   *   addParameterString.=0A=
   * <p>Note: Keys without a value are not added to the string.=0A=
   *=0A=
   * @return string: the key-value pairs for an URL=0A=
   * @examplecall=0A=
   *   // Client Example: get URL of window, add=0A=
   *   //   a parameter and make a link ...=0A=
   *   var my_par =3D new com.hyperwave.util.WebParameters ();=0A=
   *=0A=
   *   my_par.addUrlParameters ( "key2=3D2&key2=3D1&key1=3D2" );=0A=
   *   writeln ( my_par.getParameterString () )=0A=
   *   // would give: "key1=3D2&key2=3D1&key2=3D2" !=0A=
   */=0A=
  class$.getParameterString =3D function (keyPrefix)=0A=
  {=0A=
    if ( typeof keyPrefix =3D=3D "undefined" )=0A=
      keyPrefix =3D "";=0A=
    var out_arr =3D [];=0A=
    var key_array =3D this.getKeys ();=0A=
    key_array.sort ();=0A=
=0A=
    for ( var i =3D 0; i < key_array.length; ++i )=0A=
    {=0A=
      var key =3D key_array [i];=0A=
      if ( !this.map_.hasOwnProperty ( key ) )=0A=
        continue;=0A=
      var values =3D this.map_ [key];=0A=
      if (this.valueSort_)=0A=
        values.sort ();=0A=
      for ( var j =3D 0; j < values.length; ++j )=0A=
      {=0A=
        if ( (values[j] =3D=3D null) || (typeof values[j] =3D=3D =
"undefined" ))=0A=
          continue;=0A=
        if ( values[j].instanceOf &&  =
values[j].instanceOf("com.hyperwave.util.WebParameters") )=0A=
        {=0A=
          // add child web parameters in a recursive way:=0A=
          var child_param_string =3D =
values[j].getParameterString(keyPrefix + "-wp-" + key + ".");=0A=
          out_arr [out_arr.length] =3D child_param_string;=0A=
        }=0A=
        else=0A=
        {=0A=
          out_arr [out_arr.length] =3D encodeURIComponent (keyPrefix + =
key) + "=3D"=0A=
            + encodeURIComponent (values[j]);=0A=
        }=0A=
      }=0A=
    }=0A=
    return out_arr.join ( "&" );=0A=
  }=0A=
  =0A=
  /**=0A=
   * Returns a key string that can be used as a key that holds the =
information about key and=0A=
   * subkey. This string can be used on the server side to reconstruct a =
web parameters object=0A=
   * as the value mapped to the given key.=0A=
   * =0A=
   * @param key: String: The key under which the web parameters object =
can be retrieved.=0A=
   * @param subKey: String: The key that retrieves an element from the =
web parameters object=0A=
   *   addressed by key.=0A=
   */=0A=
  class$.static_.getSubKeyString =3D function (key, subKey)=0A=
  {=0A=
    return "-wp-" + key + "." + subKey;=0A=
  }=0A=
  =0A=
=0A=
  /**=0A=
   * Returns a list of all key-values.=0A=
   * @return string: containing the status of the map.=0A=
   */=0A=
  class$.toString =3D function ()=0A=
  {=0A=
    var out_arr =3D [ "@" + this.static_.getClassName() + ":" ];=0A=
=0A=
    for ( var key in this.map_ )=0A=
    {=0A=
      if ( !this.map_.hasOwnProperty ( key ) )=0A=
        continue;=0A=
      var values =3D this.map_ [key];=0A=
      out_arr [out_arr.length] =3D=0A=
        "'" + key + "' =3D> [" +=0A=
        values.join ( "," ) + "]";=0A=
    }=0A=
    return out_arr.join ( "\n" );=0A=
  }=0A=
=0A=
  /**=0A=
   * After calling this method all values of a given key are inserted=0A=
   * in sorted order when creating the parameter string=0A=
   * (getParameterString()).=0A=
   *=0A=
   * <p>This is also the default behavior to make a comparision of=0A=
   * maps possible on the level of strings.</p>=0A=
   */=0A=
  class$.enableSort =3D function ()=0A=
  {=0A=
    this.valueSort_ =3D true;=0A=
  }=0A=
=0A=
  /**=0A=
   * After calling this method all values of a given key are inserted=0A=
   * in the order they appear when creating the parameter string=0A=
   * (getParameterString()). This is NOT the default behaviour=0A=
   * (default: insert in sorted order).=0A=
   */=0A=
  class$.disableSort =3D function ()=0A=
  {=0A=
    this.valueSort_ =3D false;=0A=
  }=0A=
});=0A=
=0A=
/* End of WebParameters.js */=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/csview_lib.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        csview_lib.js=0A=
 *  Created:     2001-05-04 by cgoess=0A=
 *  Description: The file contains various functions used by the=0A=
 *               client side treeview and listing.=0A=
 *=0A=
 *  $Id: csview_lib.js 159440 2010-10-29 10:26:06Z bmarsch $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function returns the URL of the corresponding icon.=0A=
 *=0A=
 * @param anObj: Object: the client-side representation of a server=0A=
 *   object=0A=
 * @param inpath: Boolean: indicates whether the object is in the path=0A=
 *   to the current object=0A=
 * @param showLargeIcons: Boolean: if <code>true</code> large icons will=0A=
 *   be returned, otherwise their smaller counterparts=0A=
 * @return String: the url of the icon=0A=
 */=0A=
function cs_lib_getIcon (anObj, inpath, showLargeIcons)=0A=
{=0A=
  if (showLargeIcons) {=0A=
    if (inpath && anObj.IC2) {=0A=
      if (anObj.IC2.indexOf('/icons/collection_32.png')!=3D-1) {=0A=
        return '/wavemaster.internal/icons/coll_open.gif';=0A=
      }=0A=
    }=0A=
    return anObj.IC2 || "/wavemaster.internal/icons/unknown_32.png";=0A=
  }=0A=
  else {=0A=
    if (inpath && anObj.IC) {=0A=
      if (anObj.IC.indexOf('/icons/collection.png')!=3D-1) {=0A=
        return '/wavemaster.internal/icons/coll_open.gif';=0A=
      }=0A=
    }=0A=
    return anObj.IC || "/wavemaster.internal/icons/unknown.png";=0A=
  }=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function returns the URL of the corresponding info-icon (view=0A=
 * attributes).=0A=
 *=0A=
 * @param anObj: Object: the client-side representation of a server=0A=
 *   object=0A=
 * @return String: the url of the info icon=0A=
 */=0A=
function cs_lib_getInfoIcon (anObj) {=0A=
=0A=
  if (anObj.HWAT=3D=3D"Configuration")=0A=
    return "/icons/inforedc2.gif";=0A=
=0A=
  if (anObj.HWC && anObj.HWC!=3D"undefined")=0A=
    return "/icons/infoblackc2.gif";=0A=
=0A=
  return "/icons/info.png";=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function returns the JavaScript code that will be executed when=0A=
 * the info-icon will be clicked on. The code opens the attributes-=0A=
 * dialog.=0A=
 *=0A=
 * @param anObj: Object: the client-side representation of a server=0A=
 *   object=0A=
 * @return String: the JavaScript code=0A=
 */=0A=
function cs_lib_getInfoIcon_onClick (anObj) {=0A=
  var act =3D "";=0A=
  if (anObj.HWV && anObj.HWV!=3D"experimental" && anObj.SC) {=0A=
    act +=3D "&Version=3D"+anObj.HWV;=0A=
  }=0A=
  if (top.editmode && (anObj.A=3D=3D"W" || =
((anObj.ST||"").indexOf("O")>=3D0)) && anObj.CT!=3D"ServColl" && =
(anObj.isEditable =3D=3D "true"))=0A=
    act +=3D "&action=3Ddialog.editattributes.action";=0A=
  else=0A=
    act +=3D "&action=3Ddialog.attributes.action";=0A=
=0A=
  if (anObj.UID) {=0A=
    act +=3D "&Parameter=3Du"+window_escape(anObj.UID);=0A=
  }=0A=
  else {=0A=
=0A=
    if (anObj.GID) {=0A=
      act +=3D "&Parameter=3Dg"+window_escape(anObj.GID);=0A=
    }=0A=
  }=0A=
   =0A=
  if ( anObj.CTX )=0A=
  {=0A=
    act +=3D "&ctx=3D" + anObj.CTX;=0A=
  }=0A=
  =0A=
  var url =3D anObj.U;=0A=
  var idx =3D url.indexOf(";internal");=0A=
  if (idx>0)=0A=
    url =3D url.substring(0,idx);=0A=
  var idx =3D url.indexOf("?");=0A=
  if (idx>0)=0A=
    url =3D url.substring(0,idx);=0A=
  =0A=
  return 'opDlg(\''+url+';internal'+act+'\',\'dialogs\');return false;';=0A=
}=0A=
=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function returns the JavaScript code that will be executed when=0A=
 * the mouse moves over a link to an object. The code sets the=0A=
 * statusbar to the current url for Netscape browsers.=0A=
 *=0A=
 * @param anObj: Object: the client-side representation of a server=0A=
 *   object=0A=
 * @return String: the JavaScript code=0A=
 */=0A=
function cs_lib_getOnMouseOver (anObj)=0A=
{=0A=
  return "return false;";=0A=
}=0A=
=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function sets the statusbar to a specific value.=0A=
 *=0A=
 * @param aText: String: the text that should be displayed=0A=
 * @return Boolean: return value=0A=
 */=0A=
function cs_lib_setStatus (aText)=0A=
{=0A=
  window.status =3D decodeURIComponent(aText);=0A=
  return true;=0A=
}=0A=
=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function generates the URL to the given object.=0A=
 *=0A=
 * @param anObj: Object: the client-side representation of the server=0A=
 *   object=0A=
 * @return String: the url to the object=0A=
 */=0A=
function cs_lib_getHref (anObj)=0A=
{=0A=
  // <FIXXXXXME date=3D"2003-03-12" author=3D"hschwarz">=0A=
  // url =3D anObj.U + ";internal&ctx=3D"+gCurrentContext???=0A=
  // </FIXXXXXME>=0A=
  var url =3D anObj.U;=0A=
  var lstr =3D (!anObj.DF ? (url || "/"+anObj.G) : "/"+anObj.G);=0A=
  return lstr;=0A=
}=0A=
=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function will be called when clicking on a link to an object.=0A=
 * It updates the treeview-status, constructs the url of the object=0A=
 * and performs a redirect.=0A=
 *=0A=
 * @param aGOid: String: the GOid of the object of interest=0A=
 * @param aPath: String|Array of Object|void: the path to the object=0A=
 *   of interest=0A=
 * @param anEvent: Event: the corresponding event=0A=
 * @param theParams: object: additional parameters=0A=
 * @return Boolean: the return value (false)=0A=
 */=0A=
function cs_lib_ld (aGOid, aPath, anEvent, theParams) {=0A=
  var the_params =3D theParams || {};=0A=
  var navigation_update =3D !the_params.listingContainer;=0A=
=0A=
  if (typeof aPath =3D=3D "undefined") {=0A=
=0A=
    aPath =3D top.gTreeview.getCurrentNode();=0A=
  }=0A=
  if (typeof aPath =3D=3D "string")=0A=
    var path =3D top.gTreeview.getPathFromNode(aPath);=0A=
  else=0A=
    var path =3D aPath;=0A=
=0A=
  var obj =3D gObjectCache.getObject(aGOid);=0A=
  if (obj =3D=3D null)=0A=
    return false;=0A=
=0A=
  // FR9.2 treeview presentation attriute=0A=
  //if comes from client side navigation check the document Type=0A=
  if (navigation_update) {=0A=
    setHwUITreeState(obj, true);=0A=
  }=0A=
=0A=
  if (obj.DT =3D=3D "Remote" && obj.RURL) {=0A=
    var winsytle =3D=0A=
    {=0A=
        location:"yes",=0A=
        status:"yes",=0A=
        toolbar:"yes",=0A=
        menubar:"yes",=0A=
        resizable:"yes",=0A=
        scrollbars:"yes"=0A=
    }=0A=
    if (obj.HWWS)=0A=
    {=0A=
      eval("winsytle =3D"+obj.HWWS);=0A=
    }=0A=
=0A=
    if (top.gRemoteDocumentsInNewWindow) {=0A=
      opDlg(obj.RURL, "RemoteDocument"+new Date().getTime(),winsytle);=0A=
    }=0A=
    else if (obj.HWTA) {=0A=
      opDlg(obj.RURL, obj.HWTA,winsytle);=0A=
    }=0A=
    else if (obj.HWPL) {=0A=
      opDlg(obj.RURL, "_top");=0A=
    }=0A=
    else {=0A=
      // control one-level-up button (see PR-5726)=0A=
      path[path.length] =3D obj;=0A=
      if (navigation_update) {=0A=
        top.gTreeview.setNextPath(path, true);=0A=
        top.updateUpButtonState();=0A=
      }=0A=
=0A=
      // open remote url in mainframe=0A=
      opDlg(obj.RURL, "HW_Mainwindow");=0A=
    }=0A=
    return false;=0A=
  }=0A=
=0A=
  top.isAlternativeCluster =3D (obj.CT=3D=3D"AlternativeCluster");=0A=
  // fix for HWIS/PR-4239=0A=
  if (obj.DT!=3D"collection" && path.length>0 && =
path[path.length-1].DT!=3D"collection") {=0A=
=0A=
    // there cannot be two documents in the path, replace last document =
with new one=0A=
    path[path.length-1] =3D obj;=0A=
  }=0A=
  else {=0A=
    path[path.length] =3D obj;=0A=
  }=0A=
  if (navigation_update) {=0A=
    if (obj.HWTA) {=0A=
      // when opening the link in it's own window the current node of =
the window should not be changed=0A=
      top.gTreeview.setNextPath(path, false);=0A=
    } else {=0A=
      top.gTreeview.setNextPath(path, true);=0A=
    }=0A=
  }=0A=
=0A=
  var hierarchical_name =3D top.gTreeview.getHierarchicalName(path);=0A=
=0A=
  // use the last registered url as default (has the best chance to be =
the correct one)=0A=
  var url_obj =3D obj.urls_[obj.urls_.length-1];=0A=
  =0A=
  if (hierarchical_name) {=0A=
=0A=
    if (obj.urls_.length>1) {=0A=
      // find the correct url/onclick pair=0A=
      // choose the url that corresponds to the hierarchical name=0A=
      for (var i=3D0; i<obj.urls_.length; i++) {=0A=
        if (obj.urls_[i].U.indexOf(hierarchical_name)=3D=3D0) {=0A=
          if (obj.urls_[i].U.length>hierarchical_name.length) {=0A=
            var next_char =3D =
obj.urls_[i].U.charAt(hierarchical_name.length);=0A=
            if (next_char=3D=3D";" || next_char=3D=3D"#" || =
next_char=3D=3D"?")=0A=
            {// we have an url, that matches except for the url =
parameters, try to find a better match=0A=
              url_obj=3Dobj.urls_[i];=0A=
              continue;=0A=
            }=0A=
            if (next_char!=3D";" && next_char!=3D"#" && next_char!=3D"?")=0A=
            {=0A=
              continue;  // it is not the one we are looking for=0A=
            }=0A=
          }=0A=
          url_obj =3D obj.urls_[i];=0A=
        }=0A=
      }=0A=
    }=0A=
  }=0A=
  =0A=
  var url=3D"";=0A=
  if (!obj.DF && url_obj.U) {=0A=
    url =3D url_obj.U;=0A=
  }=0A=
  if (!url)=0A=
    url =3D "/"+obj.G;=0A=
  =0A=
  if (obj.CT =3D=3D "AlternativeCluster") {=0A=
    // Alternative Clusters require different urls in view- and editmode=0A=
    // (imgage.action needs to be appended in editmode)=0A=
    if (top.editmode) {=0A=
      if (url.indexOf(";internal&action=3Dimage.action")=3D=3D-1) {=0A=
        url +=3D ";internal&action=3Dimage.action";=0A=
      }=0A=
    }=0A=
    else {=0A=
      if (url.indexOf(";internal&action=3Dimage.action")!=3D-1) {=0A=
        url =3D url.substring(0, =
url.indexOf(";internal&action=3Dimage.action"));=0A=
      }=0A=
    }=0A=
  }=0A=
=0A=
  if (obj.HWPL=3D=3D"yes" || obj.UPU) {=0A=
    // for hw_plain-objects leave url as is=0A=
    var newurl =3D url;=0A=
  }=0A=
  else {=0A=
    var unique =3D "";=0A=
    if (typeof top.HW_treeview_unique =3D=3D "object") {=0A=
      var clearCacheCookie=3DgetCookie("clearUniqueCache");=0A=
      if (clearCacheCookie=3D=3D"1") {=0A=
        top.HW_treeview_unique=3D{};=0A=
        setCookie("clearUniqueCache","0");=0A=
      }=0A=
      unique =3D top.HW_treeview_unique[params.G];=0A=
      if (typeof unique =3D=3D "undefined") {=0A=
        top.HW_treeview_unique[params.G]=3Dtop.unique;=0A=
        unique =3D top.unique;=0A=
      }=0A=
      if (top.editmode) {=0A=
        unique +=3D 'e';=0A=
      }=0A=
    }=0A=
    =0A=
    var separator =3D ";internal&";=0A=
    if ( url.search(/;internal&/i)!=3D-1 || url.search(/\?/i)!=3D-1 )=0A=
      separator =3D "&";=0A=
    =0A=
    var url_addon =3D "";=0A=
    if (obj.DT !=3D "collection" && =
url.search(/(\/[^;\/\?]+\.([^;\/\?]+))$/gi)!=3D-1) {=0A=
      url_addon =3D RegExp.$1;=0A=
      var file_extension =3D RegExp.$2;=0A=
    }=0A=
  =0A=
    var newurl =3D url;=0A=
    if (unique) {=0A=
      newurl +=3D separator+"Parameter=3D"+unique;=0A=
      separator =3D "&";=0A=
    }=0A=
    =0A=
    if ( url_obj.CTX ) {=0A=
      newurl +=3D separator + "ctx=3D" + url_obj.CTX;=0A=
      separator =3D "&";=0A=
    }=0A=
   =0A=
    if (url_addon && !top.gFileExtensionExclusionList[file_extension]) {=0A=
      newurl +=3D separator+url_addon;=0A=
    }=0A=
=0A=
  }=0A=
  =0A=
  if (url_obj.OC && !(top.editmode && obj.DF)) {=0A=
    var tonclick =3D url_obj.OC;=0A=
    if (tonclick.lastIndexOf("return ")!=3D-1)=0A=
      tonclick =3D tonclick.substring(0,tonclick.lastIndexOf("return "));=0A=
    =0A=
    if (tonclick.indexOf(";internal")>0)=0A=
    {=0A=
      if ( url_obj.CTX ) {=0A=
        tonclick =3D tonclick.replace(/;internal/,";internal&ctx=3D" + =
url_obj.CTX );=0A=
      }=0A=
      =0A=
      if ( tonclick.indexOf("Parameter") < 0 && (unique) )=0A=
        tonclick =3D =
tonclick.replace(/;internal/,";internal&Parameter=3D" + unique );=0A=
    }=0A=
    else=0A=
    {=0A=
      tonclick =3D tonclick.replace( url , newurl );=0A=
    }=0A=
    eval(tonclick);=0A=
  }=0A=
  else {=0A=
    if (obj.HWPL !=3D "yes")=0A=
    {=0A=
      if (top.frames.HW_Subframe && =
top.frames.HW_Subframe.frames["HW_Mainframe"])=0A=
        =
top.frames.HW_Subframe.frames.HW_Mainframe.location.href=3Dnewurl;=0A=
      else {=0A=
        =0A=
        if (the_params.listingContainer =3D=3D "object") {=0A=
          opDlg(newurl, "HW_Mainwindow");=0A=
        }=0A=
        else {=0A=
          top.location.href=3Dnewurl;=0A=
        }=0A=
      }=0A=
    }=0A=
    else=0A=
      top.location.href=3Dnewurl;=0A=
  }=0A=
=0A=
  if ( anEvent ) {=0A=
    anEvent.cancelBubble =3D true;=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * FR9.2 treeview presentation attriute=0A=
 *=0A=
 * The function change the state of the tree view concerning to the=0A=
 * attribute value HideTreeView.=0A=
 * If this flag (TV on client sinde cache object) is set to "yes",=0A=
 * the tree view is hidden. Otherwise the tree view should be on.=0A=
 * If the tree view is hidden manually by clicking the "X" icon=0A=
 * the state of attribute value should be ignored.=0A=
 *=0A=
 * This function is called on client side by navigating with the tree=0A=
 * view or collection listing. The function is also called from=0A=
 * server side by generating the content in the content frame.=0A=
 * If the document type is an Image or Generic (the content can be=0A=
 * displayed in a new window or in a special plugin) the function is=0A=
 * called from client side. In all other cases the function would be=0A=
 * called from server side.=0A=
 *=0A=
 * @param string: obj: the current cs object=0A=
 * @param boolean: checkDT: the document type of the object should be=0A=
 *                          considered=0A=
 */=0A=
function setHwUITreeState(obj,checkDT)=0A=
{=0A=
  if (checkDT)=0A=
  {=0A=
    switch (obj.DT)=0A=
    {=0A=
      case "Image":=0A=
      case "Generic":=0A=
      case "Remote":=0A=
        break;=0A=
      default:=0A=
        // call the function from server side while building content =
frame=0A=
        return false;=0A=
    }=0A=
  }=0A=
  if (obj.TV =3D=3D "no")=0A=
  {=0A=
    if (FrameSetMediator.static_.getInstance().getTreeviewState().isOn())=0A=
    {=0A=
      top.tv_hw_ui =3D true;=0A=
      =
FrameSetMediator.static_.getInstance().setTreeviewState(FrameSetMediator.=
static_.OFF);=0A=
    }=0A=
  }=0A=
  else=0A=
  {=0A=
=0A=
    if ( top.tv_hw_ui && =
!FrameSetMediator.static_.getInstance().getTreeviewState().isOn())=0A=
    {=0A=
      top.tv_hw_ui =3D false;=0A=
      =
FrameSetMediator.static_.getInstance().setTreeviewState(FrameSetMediator.=
static_.ON);=0A=
    }=0A=
  }=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSCollectionListing.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSCollectionListing.js=0A=
 *  Created:     2001-03-14 by cgoess=0A=
 *  Description: contains the client-side collection listing=0A=
 *=0A=
 *  $Id: CSCollectionListing.js 162695 2011-04-27 15:03:09Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The class provides the methods to display a collection listing,=0A=
 * whereas the data for the objects will be requested from the client-=0A=
 * side object cache.=0A=
 * There are two xml-resources associated to this class. They are=0A=
 * located in ./htmlres/listing.xml and ./langres/listing_text.xml=0A=
 *=0A=
 * @author cgoess=0A=
 */=0A=
// <JSClass Name=3D"CSCollectionListing">=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The constructor of the class.=0A=
   *=0A=
   * @param theData: CSObjectCache: the object cache to request=0A=
   *    information=0A=
   * @param anOutput: String: the output-frame/layer/div=0A=
   * @param theParams: Object||void: other seldom used parameters=0A=
   * @param theParams.eCS: Boolean: indicates whether eCS-icons should=0A=
   *   be displayed=0A=
   * @param theParams.friendlyname: Boolean: indicates whether the=0A=
   *   friendlyname should be used instead of user-ids=0A=
   * @param theParams.show_system_objects: Boolean: indicates whether=0A=
   *   system objects should be displayed in the listing=0A=
   */=0A=
  function CSCollectionListing (theData, anOutput, theParams)=0A=
  {=0A=
    if ( theData =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
          // an instance of CSObjectCache=0A=
    this.data_ =3D theData;=0A=
          // the output-frame/layer=0A=
    this.output_ =3D anOutput;=0A=
          // store parameters=0A=
    this.params_ =3D theParams || {};=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSCollectionListing);=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method sets the placeholder for the collection-listing resource=0A=
   * reader and writes the resulting HTML into the configured =
frame/layer.=0A=
   *=0A=
   * @param anObj: Object: the parent of the objects that should be=0A=
   *   displayed in the listing=0A=
   * @param theColumns: Array: the definition of the colums of the=0A=
   *   listing=0A=
   * @param showHeader: Boolean: true, if the current object should=0A=
   *   be displayed as a header (default: true)=0A=
   * @param warningMessage: string: the warning message that will be =
displayed in the listing=0A=
   * @param outputWindow: Window|void: the optional output window -> =
necessary if the listing=0A=
   *   should be displayed in a foreign frame=0A=
   * @param showLargeIcons: Boolean: if <code>true</code> large icons =
will=0A=
   *   be displayed in the listing, otherwise their smaller counterparts=0A=
   */=0A=
  class$.draw =3D function (anObj, theColumns, showHeader, =
warningMessage, outputWindow, showLargeIcons)=0A=
  {=0A=
    if (typeof anObj =3D=3D "string")=0A=
    var anObj =3D this.data_.getObject(anObj);  // get object from cache=0A=
    if (!anObj)=0A=
      return;=0A=
=0A=
    //eval('var columns =3D ' + columnsString);=0A=
    var columns =3D theColumns;=0A=
=0A=
    var show_header =3D ( typeof showHeader =3D=3D "undefined" ) ? true =
: showHeader;=0A=
    var show_largeIcons =3D typeof showLargeIcons =3D=3D "boolean" ? =
showLargeIcons : false;=0A=
    =0A=
    var data =3D this._getListingResource(anObj, columns, =
show_largeIcons); // extract necessary information=0A=
=0A=
    var lines =3D [];=0A=
    var header_lines =3D [];=0A=
    for ( var cnt=3D0; cnt < columns.length; cnt++ )=0A=
    {=0A=
      // get the name of the attribute=0A=
      var shortcut =3D columns[cnt].Shortcut;=0A=
=0A=
      if (shortcut=3D=3D"ECS" && !this.params_.eCS)=0A=
        continue;=0A=
=0A=
      // choose the right resource.=0A=
      if (columns[cnt].Sortable)=0A=
        var template_name =3D "header_sort";=0A=
      else=0A=
        var template_name =3D "header";=0A=
=0A=
      var header_res =3D new com.hyperwave.res.Resource( =
{templateKey_:template_name} );=0A=
      header_res.makeRoot();=0A=
            // assign all templates from server (text and HTML)=0A=
      header_res.readAll( top.cslisting_reader );=0A=
      header_res.readAll( top.cslisting_texts );=0A=
=0A=
      // replace the generic placeholder "VAR_NAME" by "($1)" for the =
first attribute, ($2) for the second, etc.=0A=
=0A=
      header_res.setRes( "_if", "$#if" );=0A=
      header_res.setRes( "_endif", "($#endif)" );=0A=
      header_res.setRes( "_else", "($#else)" );=0A=
=0A=
      // eCS=0A=
      if (columns[cnt].Shortcut=3D=3D"ECS" && this.params_.eCS) {=0A=
        header_res.setRes( "header_x", '&nbsp;' );=0A=
      }=0A=
      else {=0A=
        header_res.setRes( "header_x", columns[cnt].Caption || '' );=0A=
      }=0A=
      // eCS=0A=
      header_res.setRes( "sort_x", "$sort_"+shortcut+"" );=0A=
      header_res.setRes( "sort_isx", "$sort_is"+shortcut+"" );=0A=
      header_res.setRes( "sort_down", "$sort_down" );=0A=
      header_res.setRes( "x_width", columns[cnt].Width || "0" );=0A=
      header_res.setRes( "x_align", columns[cnt].Align || "left" );=0A=
      header_res.setRes( "x_nowrap", ((columns[cnt].Nowrap =3D=3D =
false)? "" : "nowrap" ));=0A=
=0A=
      // add it to the resulting line.=0A=
      header_lines[header_lines.length] =3D header_res.toString();=0A=
=0A=
      // choose the right resource.=0A=
      if (columns[cnt].Type=3D=3D"Marker") {=0A=
        var template_name =3D "entry_marker";=0A=
      }=0A=
      else if (columns[cnt].Shortcut=3D=3D"ECS" && this.params_.eCS) {=0A=
        var template_name =3D "entry_ecs";=0A=
      }=0A=
      else if (columns[cnt].Shortcut=3D=3D"VM") {=0A=
        var template_name =3D "entry_vc";=0A=
      }=0A=
      else {=0A=
        if (columns[cnt].HRef)=0A=
          var template_name =3D "entry_href";=0A=
        else=0A=
          var template_name =3D "entry";=0A=
      }=0A=
      =0A=
      var entry_res =3D new com.hyperwave.res.Resource( =
{templateKey_:template_name} );=0A=
        entry_res.makeRoot();=0A=
              // assign all templates from server (text and HTML)=0A=
        entry_res.readAll( top.cslisting_reader );=0A=
        entry_res.readAll( top.cslisting_texts );=0A=
  =0A=
        // replace the generic placeholder "VAR_NAME" by "($1)" for the =
first attribute, ($2) for the second, etc.=0A=
  =0A=
        entry_res.setRes( "_if", "$#if" );=0A=
        entry_res.setRes( "_endif", "($#endif)" );=0A=
        entry_res.setRes( "_else", "($#else)" );=0A=
      entry_res.setRes( "x", "$"+shortcut+"" );=0A=
      entry_res.setRes( "x_width", columns[cnt].Width || "0" );=0A=
      entry_res.setRes( "x_align", columns[cnt].Align || "left" );=0A=
      entry_res.setRes( "x_nowrap", ((columns[cnt].Nowrap =3D=3D false)? =
"" : "nowrap" ));=0A=
      entry_res.setRes( "x_href", "$"+shortcut+"_href" );=0A=
      entry_res.setRes( "x_onclick", "$"+shortcut+"_onclick" );=0A=
      entry_res.setRes( "x_class", columns[cnt].Class || =
"collattributes" );=0A=
      if (columns[cnt].Shortcut=3D=3D"ECS" && this.params_.eCS) {=0A=
        entry_res.setRes( "x_uid", "$"+shortcut+"_uid" );=0A=
        entry_res.setRes( "x_state", "$"+shortcut+"_state" );=0A=
      }=0A=
      if (columns[cnt].Shortcut=3D=3D"VM") {=0A=
        entry_res.setRes( "x_class", "$"+shortcut+"_class");=0A=
      }=0A=
      if (columns[cnt].Type=3D=3D"Marker") {=0A=
        entry_res.setRes( "x_display", "$"+shortcut+"_display");=0A=
        entry_res.setRes( "x_class", "$"+shortcut+"_class");=0A=
        entry_res.setRes( "x_title", "$"+shortcut+"_title");=0A=
      }=0A=
=0A=
      // add it to the resulting line.=0A=
      lines[lines.length] =3D entry_res.toString();=0A=
=0A=
      //for sorting=0A=
      if (columns[cnt].Sortable)=0A=
      {=0A=
        top.cslisting_res.setRes("sort_" + shortcut, data["sort_" + =
shortcut]);=0A=
        top.cslisting_res.setRes("sort_is" + shortcut, data["sort_is" + =
shortcut]);=0A=
      }=0A=
    }=0A=
=0A=
    var header_template =3D new =
com.hyperwave.res.Template({templateString_:header_lines.join('')});=0A=
    var template =3D new =
com.hyperwave.res.Template({templateString_:lines.join('')});=0A=
=0A=
    var i=3D0;=0A=
    top.cslisting_res.setRes("header_dynamic", header_template);=0A=
    top.cslisting_res.setRes("collectionentry", template);=0A=
    //display the warning message if it exist=0A=
    top.cslisting_res.setRes("DisplayWarningMessage", warningMessage ? =
true : false);=0A=
    top.cslisting_res.setRes("WarningMessage", warningMessage ? =
warningMessage : "");=0A=
=0A=
    top.cslisting_res.setRes("showHeader", show_header);=0A=
    var checkboxes_to_display =3D false;=0A=
    var objmenu_to_display =3D false;=0A=
    for(var i=3D0; i<data.entries.length; i++) {=0A=
    	if (data.entries[i].checkbox) {=0A=
    	  checkboxes_to_display =3D true;=0A=
    	}=0A=
    	if (data.entries[i].menu) {=0A=
    	  objmenu_to_display =3D true;=0A=
    	}=0A=
    	if (checkboxes_to_display && objmenu_to_display) {=0A=
    	  break;=0A=
    	}=0A=
    }=0A=
    =0A=
    top.cslisting_res.setRes("showCheckboxColumn", =
checkboxes_to_display);=0A=
    // show objectmenu column if checkbox column is not displayed to get=0A=
    // some spacing on the left of the listing=0A=
    top.cslisting_res.setRes("showObjMenuColumn", !checkboxes_to_display =
|| objmenu_to_display);=0A=
    top.cslisting_res.setRes("sort_type", data.sort_type);=0A=
    top.cslisting_res.setRes("sort_title", data.sort_title);=0A=
    top.cslisting_res.setRes("sort_istype", data.sort_istype);=0A=
    top.cslisting_res.setRes("sort_istitle", data.sort_istitle);=0A=
    top.cslisting_res.setRes("sort_down", data.sort_down);=0A=
    top.cslisting_res.setRes("editmode", data.editmode);=0A=
    top.cslisting_res.setRes("obj_title", data.obj_title);=0A=
    top.cslisting_res.setRes("obj_infoicon_src", data.obj_infoicon_src);=0A=
    top.cslisting_res.setRes("obj_infoicon_onclick", =
data.obj_infoicon_onclick);=0A=
    top.cslisting_res.setRes("obj_icon", data.obj_icon);=0A=
    top.cslisting_res.setRes("empty", data.empty);=0A=
    top.cslisting_res.setRes("entries", data.entries);=0A=
=0A=
    var doc;=0A=
    try {=0A=
      doc =3D eval(this.output_+".document");=0A=
    }=0A=
    catch (ignore_me) {=0A=
      return;=0A=
    }=0A=
    if (typeof doc =3D=3D "undefined") {=0A=
      return;=0A=
    }=0A=
=0A=
    if (outputWindow && outputWindow.document !=3D doc) {=0A=
      // will not be rendered into the mainframe -> no checkboxes=0A=
      doc =3D outputWindow.document;=0A=
      top.cslisting_res.setRes("showCheckboxColumn", false);=0A=
      top.cslisting_res.setRes("showObjMenuColumn", true);=0A=
    }=0A=
    // write html into page=0A=
    doc.writeln(top.cslisting_res.toString(true));=0A=
    this.attachEventHandlers(doc);=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method gathers the information needed by the resource reader.=0A=
   *=0A=
   * @param anObj: Object: the parent of the objects that should be=0A=
   *   displayed in the listing=0A=
   * @param showLargeIcons: Boolean: if <code>true</code> large icons =
will=0A=
   *   be displayed in the listing, otherwise their smaller counterparts=0A=
   * @return Object: the extracted data stored in its properties=0A=
   */=0A=
  class$._getListingResource =3D function (anObj, columns, =
showLargeIcons)=0A=
  {=0A=
    var data =3D {};=0A=
    data.editmode =3D (top.editmode) ? "true" : "";=0A=
    var show_largeIcons =3D typeof showLargeIcons =3D=3D "boolean" ? =
showLargeIcons : false;=0A=
=0A=
          // collect data about the sortorder=0A=
    if (typeof top.sortorder !=3D "string") {=0A=
      top.sortorder =3D getCookie("cl_sortorder") || "asctitle";=0A=
      setCookie("cl_sortorder", "", new Date(1000)); // delete the =
cookie again=0A=
    }=0A=
    var type =3D top.cl_getSortType(top.sortorder);=0A=
    data.sort_istype   =3D (type=3D=3D"type") ? "true" : "";=0A=
    data.sort_istitle  =3D (type=3D=3D"title") ? "true" : "";=0A=
    for (var i=3D0; i<columns.length; i++){=0A=
      var shortcut =3D columns[i].Shortcut;=0A=
      eval('data.sort_is'+shortcut+' =3D (type=3D=3D"' + shortcut + '") =
? "true" : "";');=0A=
    }=0A=
    var nosortorder =3D (!anObj.SO);=0A=
    data.sort_down =3D (top.cl_getMulti(top.sortorder)=3D=3D-1) ? "true" =
: "";=0A=
    if (nosortorder) {=0A=
=0A=
      if (!data.sort_istype)=0A=
        data.sort_type =3D "asctype";=0A=
      else {=0A=
        if (data.sort_down)=0A=
          data.sort_type =3D "asctype";=0A=
        else=0A=
          data.sort_type =3D "desctype";=0A=
      }=0A=
      if (!data.sort_istitle)=0A=
        data.sort_title =3D "asctitle";=0A=
      else {=0A=
        if (data.sort_down)=0A=
          data.sort_title =3D "asctitle";=0A=
        else=0A=
          data.sort_title =3D "desctitle";=0A=
      }=0A=
      for (var i=3D0; i<columns.length; i++){=0A=
        var shortcut =3D columns[i].Shortcut;=0A=
        if (!data['sort_is' + shortcut])=0A=
          data['sort_' + shortcut] =3D =
top.cl_getSortRef(columns[i],"asc");=0A=
      else {=0A=
        if (data.sort_down)=0A=
            data['sort_' + shortcut] =3D =
top.cl_getSortRef(columns[i],"asc");=0A=
        else=0A=
            data['sort_' + shortcut] =3D =
top.cl_getSortRef(columns[i],"desc");=0A=
        }=0A=
      }=0A=
    }=0A=
    else {=0A=
      // prevent displaying the "sort_down" or "sort_up" icons in case =
of a=0A=
      // predefined sort order.=0A=
      data.sort_istype   =3D "";=0A=
      data.sort_istitle  =3D "";=0A=
      for (var i=3D0; i<columns.length; i++){=0A=
        var shortcut =3D columns[i].Shortcut;=0A=
        data['sort_is'+shortcut] =3D "";=0A=
      }=0A=
=0A=
      data.sort_type   =3D "";=0A=
      data.sort_title  =3D "";=0A=
      for (var i=3D0; i<columns.length; i++){=0A=
        var shortcut =3D columns[i].Shortcut;=0A=
        data['sort_' + shortcut] =3D "";=0A=
      }=0A=
    }=0A=
=0A=
          // collect data for current object=0A=
    data.obj_title =3D anObj.T;=0A=
    data.obj_url =3D anObj.U;=0A=
    data.obj_infoicon_src =3D cs_lib_getInfoIcon(anObj);=0A=
    data.obj_infoicon_onclick =3D cs_lib_getInfoIcon_onClick(anObj);=0A=
    data.obj_icon =3D cs_lib_getIcon(anObj, true, show_largeIcons);=0A=
=0A=
          // collect data of children object=0A=
    data.entries =3D [];=0A=
    var children =3D this.data_.getChildren(anObj.G);=0A=
    if (this.hasVisibleEntries(children)) {=0A=
=0A=
      data.empty =3D "";=0A=
            // sort the listing according to the chosen sortorder=0A=
      var nosortorder =3D (!anObj.SO);=0A=
      if (nosortorder)=0A=
        children.sort(top.cl_getSortFunction(top.sortorder));=0A=
=0A=
            // used by drop-down menu=0A=
      var openercount =3D 0;=0A=
=0A=
      for (var kid=3D0; kid<children.length; kid++) {=0A=
=0A=
        var tobj =3D children[kid];=0A=
        if (this.isVisible(tobj))=0A=
        {=0A=
          var temp_obj =3D {};=0A=
=0A=
                // Agent objects will be marked as such=0A=
          if (tobj.SC)=0A=
            temp_obj.agentitem =3D true;=0A=
          else=0A=
            temp_obj.agentitem =3D false;=0A=
=0A=
          if (cl_isGOid(tobj.G)) { // check if it is an external document=0A=
=0A=
                  // checkbox=0A=
            temp_obj.checkbox =3D top.cl_getCheckbox(tobj);=0A=
            temp_obj.GOid =3D tobj.G;=0A=
                  // context menu=0A=
            temp_obj.menu =3D "";=0A=
            if (tobj.DT!=3D 'collection' && tobj.DT !=3D 'Remote' && =
tobj.DT !=3D 'RegistryEntry' && (!tobj.UID) && (!tobj.GID) &&  tobj.DT =
!=3D 'CGI' && tobj.DT !=3D 'Schedule') {=0A=
              if (typeof top.objmenuname !=3D "undefined") {=0A=
                temp_obj.menu =3D top.cl_getIconWithMenu({=0A=
                  ma: "l",=0A=
                  xp: "l",=0A=
                  imgsrc: =
"/wavemaster.internal/icons/contextmenu_button.png",=0A=
                  openername: top.objmenuname+"_"+openercount,=0A=
                  menuname: top.objmenuname,=0A=
                  obj: tobj.G,=0A=
                  attrobj: tobj=0A=
                });=0A=
                openercount++;=0A=
              }=0A=
            }=0A=
            else {=0A=
              if (typeof top.default_context_menuname !=3D "undefined") {=0A=
                temp_obj.menu =3D top.cl_getIconWithMenu({=0A=
                  ma: "l",=0A=
                  xp: "l",=0A=
                  imgsrc: =
"/wavemaster.internal/icons/contextmenu_button.png",=0A=
                  openername: =
top.default_context_menuname+"_"+openercount,=0A=
                  menuname: top.default_context_menuname,=0A=
                  obj: tobj.G,=0A=
                  attrobj: tobj=0A=
                });=0A=
                openercount++;=0A=
              }=0A=
            }=0A=
=0A=
            temp_obj.infoicon_onclick =3D =
cs_lib_getInfoIcon_onClick(tobj);=0A=
            temp_obj.infoicon_src =3D cs_lib_getInfoIcon(tobj);=0A=
          }=0A=
          else {=0A=
                  // must be an external document=0A=
            temp_obj.checkbox =3D "";=0A=
            temp_obj.menu =3D "";=0A=
            temp_obj.infoicon_onclick =3D "";=0A=
            temp_obj.infoicon_src =3D "";=0A=
          }=0A=
          temp_obj.href =3D cs_lib_getHref(tobj);=0A=
=0A=
                // display info-dialog for groups and registry entries=0A=
          if (tobj.GID || tobj.DT=3D=3D"RegistryEntry") {=0A=
            temp_obj.onclick =3D cs_lib_getInfoIcon_onClick(tobj);=0A=
          }=0A=
          else {=0A=
            var add_params =3D '{listingContainer: =
window.listing_container}';=0A=
            temp_obj.onclick =3D "return top.cs_lib_ld('"+tobj.G+"', =
void(0), event, " + add_params + ");";=0A=
          }=0A=
          temp_obj.onmouseover =3D cs_lib_getOnMouseOver(tobj);=0A=
          temp_obj.icon =3D cs_lib_getIcon(tobj, false, show_largeIcons);=0A=
          temp_obj.title =3D tobj.UID || tobj.GID || tobj.T;=0A=
          if (tobj.NM)=0A=
            temp_obj.update =3D tobj.NM;=0A=
          else=0A=
            temp_obj.update =3D "";=0A=
            =0A=
          if (tobj.VM)=0A=
            temp_obj.version =3D tobj.VM;=0A=
          else=0A=
            temp_obj.version =3D "";=0A=
            =0A=
            =0A=
            =0A=
          temp_obj.description =3D (tobj.DES) ? tobj.DES : "";=0A=
=0A=
          //dynamic attributes=0A=
=0A=
          for (var i=3D0; i<columns.length; i++){=0A=
            var shortcut =3D columns[i].Shortcut;=0A=
            var type =3D columns[i].Type;=0A=
            if (type =3D=3D 'HW_API_Date' && tobj[shortcut]){=0A=
             if (columns[i].DateView && (columns[i].DateView=3D=3D"date" =
|| columns[i].DateView=3D=3D"reldate"))=0A=
                temp_obj[shortcut] =3D =
transformDate(tobj[shortcut],HWDate,HW_UI_Date.date,false,false,true);=0A=
              else=0A=
                temp_obj[shortcut] =3D =
transformDate(tobj[shortcut],HWDate,HW_UI_Date.full,false,false,false);=0A=
            }=0A=
            else {=0A=
              temp_obj[shortcut] =3D decodeURIComponent(tobj[shortcut] =
|| '');=0A=
            }=0A=
            temp_obj[shortcut + '_href'] =3D (columns[i].HRef || =
'').replace(/\(\$url\)/,tobj.U||"").replace(/\(\$value\)/,encodeURICompon=
ent(tobj[shortcut]||""));=0A=
            temp_obj[shortcut + '_onclick'] =3D (columns[i].OnClick || =
'').replace(/\(\$url\)/,tobj.U||"").replace(/\(\$value\)/,encodeURICompon=
ent(tobj[shortcut]||""));=0A=
            =0A=
            if (type =3D=3D "Marker") {=0A=
              temp_obj[shortcut + "_display"] =3D tobj[shortcut] =3D=3D =
"true";=0A=
              temp_obj[shortcut + "_class"]   =3D columns[i].Class;=0A=
              temp_obj[shortcut + "_title"]   =3D columns[i].Title || "";=0A=
            }=0A=
=0A=
            if (shortcut =3D=3D 'VM') {=0A=
              if (this.displayEditable() && tobj.HWV=3D=3D"experimental" =
&& tobj.ST.indexOf("H")!=3D-1) {=0A=
                temp_obj[shortcut] =3D =
top.cslisting_texts.getRes("checkin");=0A=
                temp_obj[shortcut + '_class'] =3D "button";=0A=
                temp_obj[shortcut + '_href'] =3D "#";=0A=
                temp_obj[shortcut + '_onclick'] =3D =
'opDlg(\'/'+tobj.G+';internal&action=3Ddialog.checkin.action\',\'dialogs\=
');return false;';=0A=
              }=0A=
              else {=0A=
                temp_obj[shortcut + '_href'] =3D "#";=0A=
                temp_obj[shortcut + '_onclick'] =3D 'opDlg(\'/' + tobj.G =
+=0A=
                                                  =
';internal&action=3Ddialog.versions.action' +=0A=
                                                  =
(this.displayEditable() ? '&Parameter=3Dedit' : '') +=0A=
                                                  =
'\',\'dialogs\');return false;';=0A=
              }=0A=
            }=0A=
            //special cases=0A=
            if (shortcut =3D=3D 'AU'){=0A=
//                if (this.params_.friendlyname) {=0A=
//                        // if friendlyname is on start email-client =
when clicking on username=0A=
//                  if (tobj.EM) {=0A=
//                    temp_obj[shortcut + '_href'] =3D 'mailto:'+tobj.EM;=0A=
//                    temp_obj[shortcut + '_onclick'] =3D 'return true;';=0A=
//                  }=0A=
//                  else {=0A=
//                    temp_obj[shortcut + '_href'] =3D '';=0A=
//                  }=0A=
//                }=0A=
//                else {=0A=
//                        // if friendlyname is off display buisnesscard =
when clicking on the user-id=0A=
              // changed behaviour -> always display link to =
businesscard now=0A=
                temp_obj[shortcut + '_href'] =3D "#";=0A=
                // FIX HWF/ PR-1097=0A=
                if (typeof(tobj.ebcUser)!=3D"undefined" && =
tobj.ebcUser!=3D"")=0A=
                {=0A=
                  var bc_params =3D new com.hyperwave.util.KeyValueMap();=0A=
                  bc_params.setKeyValue("uid",tobj.ebcUser);=0A=
                  var bc_url =3D "/" =
+tobj.G+";internal&action=3Ddialog.ebc.action";=0A=
                  bc_url =3D bc_url + "&Parameter=3D" + =
encodeURIComponent(bc_params.getParameterString());=0A=
                  temp_obj[shortcut + '_onclick'] =3D =
'opDlg(\''+bc_url+'\',\'dialogs\');return false;';=0A=
                }else=0A=
                temp_obj[shortcut + '_onclick'] =3D =
'opDlg(\'/'+tobj.G+';internal&action=3Ddialog.ebc.action\',\'dialogs\');r=
eturn false;';=0A=
//                }=0A=
            }=0A=
=0A=
            // eCS-handling=0A=
            if (shortcut =3D=3D 'ECS' && this.params_.eCS) {=0A=
=0A=
              if (tobj.ECS) {=0A=
=0A=
                var ecs =3D decodeURIComponent(tobj.ECS);=0A=
                var state =3D ecs.substring(0, ecs.indexOf('^'));=0A=
                var uid =3D ecs.substring(ecs.indexOf('^')+1);=0A=
=0A=
                temp_obj[shortcut + '_uid'] =3D encodeURIComponent(uid);=0A=
                temp_obj[shortcut + '_state'] =3D state;=0A=
              }=0A=
              else {=0A=
                temp_obj[shortcut + '_uid'] =3D "";=0A=
                temp_obj[shortcut + '_state'] =3D "";=0A=
              }=0A=
            }=0A=
          }//end for loop=0A=
          temp_obj.row_style =3D (data.entries.length % 2) ? "" : =
"alternate";=0A=
          data.entries[data.entries.length] =3D temp_obj;=0A=
        }=0A=
      }=0A=
    }=0A=
    else=0A=
      data.empty =3D "true";=0A=
=0A=
    return data;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method returns whether we are in edit mode and not=0A=
   * in an embeded listing.=0A=
   *=0A=
   * @return Boolean: display as in view mode=0A=
   */=0A=
  class$.displayEditable =3D function ()=0A=
  {=0A=
    return top.editmode && !window.listing_container;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks whether there are entries that will be displayed=0A=
   * in the listing.=0A=
   *=0A=
   * @param anObjArray: Array of Object: the entries of the listing=0A=
   * @return Boolean: indicates whether there are visible entries=0A=
   */=0A=
  class$.hasVisibleEntries =3D function (anObjArray)=0A=
  {=0A=
    if (anObjArray !=3D null)=0A=
    {=0A=
      for (var obj in anObjArray)=0A=
      {=0A=
        if (this.isVisible(anObjArray[obj]))=0A=
          return true;=0A=
      }=0A=
    }=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method controls the checkboxes of the entries and returns the=0A=
   * the selected objects.=0A=
   *=0A=
   * @return Array of Object: the objects whose checkbox has been=0A=
   *   selected=0A=
   */=0A=
  class$.getSelectedObjects =3D function ()=0A=
  {=0A=
    var ret_arr =3D [];=0A=
    var hlp, doc;=0A=
=0A=
    hlp =3D eval(this.output_);=0A=
=0A=
    if (typeof hlp =3D=3D "undefined" || typeof hlp.document =3D=3D =
"undefined")=0A=
      return ret_arr;=0A=
    doc =3D hlp.document;=0A=
=0A=
    var body_form =3D doc.bodyform;=0A=
    if (typeof body_form =3D=3D "undefined")=0A=
      return ret_arr;=0A=
=0A=
    for (var entry=3D0; entry<body_form.elements.length; entry++) {=0A=
=0A=
      var elem =3D body_form.elements[entry];=0A=
      if (elem.name.substring(0,8)=3D=3D"initname" && =
elem.checked=3D=3Dtrue) {=0A=
=0A=
        if (typeof top.gObjectCache !=3D "undefined") {=0A=
                // elem.value stores the GOid of the object=0A=
          if (this.data_.getObject(elem.value))=0A=
            ret_arr[ret_arr.length] =3D this.data_.getObject(elem.value);=0A=
        }=0A=
      }=0A=
    }=0A=
    return ret_arr;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks whether an object will be displayed in the=0A=
   * listing.=0A=
   *=0A=
   * @param anObj: Object: the object of interest=0A=
   * @return Boolean: indicates whether the object will be displayed in=0A=
   *   the listing=0A=
   */=0A=
  class$.isVisible =3D function (anObj)=0A=
  {=0A=
    if (typeof anObj !=3D "object")=0A=
      return false;=0A=
=0A=
    if (anObj.ADD && anObj.ADD.indexOf("skiplisting")!=3D-1)=0A=
      return false;=0A=
=0A=
          // display objects found by Queries in any case=0A=
          // (SC is short for Score)=0A=
    if (typeof anObj.SC !=3D "undefined")=0A=
      return true;=0A=
=0A=
    if =
((anObj.PH=3D=3D"SystemObject"||anObj.PH=3D=3D"ApplicationObject") && =
!this.params_.show_system_objects)=0A=
      return false;=0A=
=0A=
    if (top.editmode)=0A=
      return true;=0A=
=0A=
    if ((anObj.PH =3D=3D "Hidden") ||=0A=
      (anObj.PH =3D=3D "CollectionHead") ||=0A=
      (anObj.PH =3D=3D "FullCollectionHead"))=0A=
      return false;=0A=
=0A=
    return true;=0A=
  };=0A=
  =0A=
  class$.static_.getGOidByElement =3D function (theElement) {=0A=
    var tr_tag =3D theElement.up("tr");=0A=
    if (!tr_tag.id || tr_tag.id.indexOf("listing_")!=3D0) {=0A=
      tr_tag =3D tr_tag.up("tr");  // agent listing=0A=
    }=0A=
    if (tr_tag.id && tr_tag.id.indexOf("listing_")=3D=3D0) {=0A=
      return tr_tag.id.substring("listing_".length);=0A=
    }=0A=
    return "";=0A=
  };=0A=
  =0A=
  class$.attachEventHandlers =3D function (theDocument) {=0A=
    var workflow_mediator =3D =
hw.getFramework().getApplicationProperty("eks.workflow", =
"WorkflowMediator");=0A=
    if (workflow_mediator) {=0A=
      var win =3D theDocument.defaultView || theDocument.parentWindow;=0A=
      with (win) {=0A=
        var elems =3D $("listing").select(".hw_status_locked");=0A=
        for (var i=3D0; i<elems.length; i++) {=0A=
          var goid =3D =
CSCollectionListing.static_.getGOidByElement(elems[i]);=0A=
          if (goid) {=0A=
            workflow_mediator.attachIsInWorkflowEventHandlers(elems[i], =
goid);=0A=
          }=0A=
        }=0A=
      }=0A=
    }=0A=
  };=0A=
// </JSClass>=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * extracts the current sort type=0A=
 *=0A=
 * @param sortorder: String: the sortorder as stored in top.sortorder=0A=
 * @return String: the sort-type=0A=
 */=0A=
function cl_getSortType (sortorder)=0A=
{=0A=
  if (typeof sortorder =3D=3D "string"){=0A=
    sortorder =3D sortorder.replace(/^asc/,"").replace(/^desc/,"");=0A=
    sortorder =3D sortorder.replace(/num$/,"").replace(/str$/,"");=0A=
    return sortorder;=0A=
  }=0A=
  return "";=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * determines whether the current sortorder is ascending or descending=0A=
 *=0A=
 * @param sortorder: String: the sortorder as stored in top.sortorder=0A=
 * @return Number: ascending sortorder .... 1=0A=
 *                 descending sortorder ...-1=0A=
 *                 no sortorder ........... 0=0A=
 */=0A=
function cl_getMulti (sortorder)=0A=
{=0A=
  if (typeof sortorder !=3D "string")=0A=
    return 0;=0A=
=0A=
  if (sortorder.indexOf("asc") =3D=3D 0) return 1;=0A=
  if (sortorder.indexOf("desc") =3D=3D 0) return -1;=0A=
  return 0;=0A=
}=0A=
=0A=
function cl_sortForNum (sortorder)=0A=
{=0A=
  if (typeof sortorder !=3D "string")=0A=
    return false;=0A=
=0A=
  if (sortorder.lastIndexOf("num") =3D=3D (sortorder.length - =
"num".length))=0A=
    return true;=0A=
=0A=
  return false;=0A=
}=0A=
=0A=
function cl_getSortRef( anItem, anOrder )=0A=
{=0A=
  var item =3D anItem || {};=0A=
=0A=
  var order =3D anOrder || "asc";=0A=
  var shortcut =3D item.Shortcut ||"";=0A=
  var type =3D item.Type || "string";=0A=
=0A=
  if (type=3D=3D"integer" || type=3D=3D"float")=0A=
    var ttype =3D "num";=0A=
  else=0A=
    var ttype =3D "str";=0A=
=0A=
  return order + shortcut + ttype;=0A=
}=0A=
=0A=
// returns the sort-function according to the current sortorder=0A=
function cl_getSortFunction (sortorder)=0A=
{=0A=
  var stype =3D cl_getSortType(sortorder);=0A=
  var multi =3D cl_getMulti(sortorder);=0A=
  var sort_num =3D cl_sortForNum(sortorder);=0A=
=0A=
  var func;=0A=
  if (stype =3D=3D "type") {=0A=
    if (multi =3D=3D 1)=0A=
      return so_type_asc;=0A=
    else=0A=
      return so_type_desc;=0A=
  }=0A=
  if (stype =3D=3D "title") {=0A=
    if (multi =3D=3D 1)=0A=
      return so_title_asc;=0A=
    else=0A=
      return so_title_desc;=0A=
  }=0A=
  else if (sort_num=3D=3Dtrue)=0A=
  {=0A=
    eval ('func =3D function (a, b)\n\=0A=
      {\n\=0A=
        var iscoll =3D so_isCollection(a,b);\n\=0A=
        if (iscoll !=3D 0)\n\=0A=
          return iscoll;\n\=0A=
      \n\=0A=
        var ret =3D =
so_comp_number(Number(a.'+stype+'),Number(b.'+stype+'));\n\=0A=
        if (ret !=3D 0)\n\=0A=
          return ret*(' + multi + ');\n\=0A=
      \n\=0A=
        return (so_title(a, b)*(' + multi + '));\n\=0A=
      };');=0A=
  }=0A=
  else{ //other columns=0A=
    eval ('func =3D function (a, b)\n\=0A=
      {\n\=0A=
        var iscoll =3D so_isCollection(a,b);\n\=0A=
        if (iscoll !=3D 0)\n\=0A=
          return iscoll;\n\=0A=
      \n\=0A=
        var ret =3D =
so_comp(decodeURIComponent(a.'+stype+').toLowerCase(),decodeURIComponent(=
b.'+stype+').toLowerCase());\n\=0A=
        if (ret !=3D 0)\n\=0A=
          return ret*(' + multi + ');\n\=0A=
      \n\=0A=
        return (so_title(a, b)*(' + multi + '));\n\=0A=
      };');=0A=
  }=0A=
  return func;=0A=
}=0A=
=0A=
// sortorder-functions: used to perform sorting of the listing on cs.=0A=
=0A=
// collections are ranked above other objects in the listing=0A=
// compares whether on of the objects is of documenttype collection=0A=
function so_isCollection (a, b)=0A=
{=0A=
  if ((cl_getTypeIndex(a) =3D=3D 1) && (cl_getTypeIndex(b) !=3D 1))=0A=
    return -1;=0A=
  if ((cl_getTypeIndex(b) =3D=3D 1) && (cl_getTypeIndex(a) !=3D 1))=0A=
    return 1;=0A=
  return 0;=0A=
}=0A=
=0A=
// compares value a to value b=0A=
function so_comp (a, b)=0A=
{=0A=
  var aa=3DintStrKeyLevel1(a);=0A=
  var bb=3DintStrKeyLevel1(b);=0A=
  if (aa > bb)=0A=
    return 1;=0A=
  if (bb > aa)=0A=
    return -1;=0A=
=0A=
  aa=3DintStrKeyLevel2(a);=0A=
  bb=3DintStrKeyLevel2(b);=0A=
  if (aa > bb)=0A=
    return 1;=0A=
  if (bb > aa)=0A=
    return -1;=0A=
=0A=
  return 0;=0A=
}=0A=
=0A=
// compares two number values=0A=
function so_comp_number (a, b)=0A=
{=0A=
  if (a > b)=0A=
    return 1;=0A=
  if (b > a)=0A=
    return -1;=0A=
=0A=
  return 0;=0A=
}=0A=
=0A=
=0A=
=0A=
// compares the title of a and b=0A=
function so_title (a, b)=0A=
{=0A=
  var mya =3D a.T.toLowerCase();=0A=
  var myb =3D b.T.toLowerCase();=0A=
=0A=
  return so_comp(mya, myb);=0A=
}=0A=
=0A=
// compares the title of a and b in ascending order=0A=
function so_title_asc (a, b)=0A=
{=0A=
  var iscoll =3D so_isCollection(a,b);=0A=
  if (iscoll !=3D 0)=0A=
    return iscoll;=0A=
=0A=
  return so_title(a,b);=0A=
}=0A=
=0A=
// compares the title of a and b in descending order=0A=
function so_title_desc (a, b)=0A=
{=0A=
  var iscoll =3D so_isCollection(a,b);=0A=
  if (iscoll !=3D 0)=0A=
    return iscoll;=0A=
=0A=
  return so_title(a,b)*(-1);=0A=
}=0A=
=0A=
// this array defines the sortorder for type-sorting=0A=
var so_DOCTYPES =3D {'collection':1, 'Collection':1,=0A=
                   'text':10, 'Text':10,=0A=
                   'image':12, 'Image':12,=0A=
                   'film':14, 'Film':14,=0A=
                   'audio':16, 'Audio':16,=0A=
                   'scene':18, 'Scene':18,=0A=
                   'postscript':20, 'PostScript':20,=0A=
                   'generic':22, 'Generic':22,=0A=
                   'annotation':24, 'Annotation':24,=0A=
                   'remote':26, 'Remote':26};=0A=
=0A=
// defines the the sortorder for objects of type collection=0A=
var so_COLLTYPES =3D {'Collection':1,=0A=
                    'Cluster':3,=0A=
                    'Sequence':1,=0A=
                    'MultiCluster':3,=0A=
                    'AlternativeCluster':3};=0A=
=0A=
// defines the sortorder for objects of type collection that=0A=
// are not used like regular collections=0A=
var so_SPECIALTYPES =3D {'DForum':1,=0A=
                       'DCCollection':1,=0A=
                       'DCCollection-forceshow':1,=0A=
                       'HW_WF_WorkflowDefinitionVersionContainer':6,=0A=
                       'DCObject': 5};=0A=
=0A=
// returns an index that makes a type-comparison possible=0A=
function cl_getTypeIndex (a)=0A=
{=0A=
  if (typeof so_DOCTYPES[a.DT] !=3D "undefined")=0A=
  {=0A=
    if (so_DOCTYPES[a.DT] =3D=3D 1)=0A=
    {=0A=
      // treatment of specialities first place=0A=
      // (used to treat certain DCs (collections) as non-collections in =
listing)=0A=
      if (typeof a.DCI !=3D "undefined")=0A=
        if (typeof so_SPECIALTYPES[a.DCI] !=3D "undefined")=0A=
          return so_SPECIALTYPES[a.DCI];=0A=
      =0A=
      if (a.DCO =3D=3D "yes")=0A=
        return so_SPECIALTYPES['DCObject'];=0A=
      if (a.DCFS =3D=3D "true")=0A=
        return so_SPECIALTYPES['DCCollection-forceshow'];=0A=
      if (typeof a.DCI !=3D "undefined")=0A=
        return so_SPECIALTYPES['DCCollection'];=0A=
=0A=
      if (a.DF =3D=3D "yes")=0A=
        return so_SPECIALTYPES['DForum'];=0A=
=0A=
      if (a.CT && typeof so_COLLTYPES[a.CT] !=3D "undefined")=0A=
        return so_COLLTYPES[a.CT];=0A=
    }=0A=
    return so_DOCTYPES[a.DT] || 100;=0A=
  }=0A=
  return 30;=0A=
}=0A=
=0A=
// compares the types of objects a and b in ascending order=0A=
function so_type_asc (a, b)=0A=
{=0A=
  var ret =3D so_comp_number(cl_getTypeIndex(a),cl_getTypeIndex(b));=0A=
  if (ret !=3D 0)=0A=
    return ret;=0A=
=0A=
  if (a.IC>b.IC)=0A=
    return 1;=0A=
=0A=
  if (a.IC<b.IC)=0A=
    return -1;=0A=
=0A=
  return (so_title(a, b));=0A=
}=0A=
=0A=
// compares the types of objects a and b in descending order=0A=
function so_type_desc (a, b)=0A=
{=0A=
  var ret =3D so_comp_number(cl_getTypeIndex(a),cl_getTypeIndex(b));=0A=
  if (ret !=3D 0)=0A=
    return ret*(-1);=0A=
=0A=
  if (a.IC>b.IC)=0A=
    return -1;=0A=
=0A=
  if (a.IC<b.IC)=0A=
    return 1;=0A=
=0A=
  return (so_title(a, b));=0A=
}=0A=
=0A=
// performs the sorting when clicking on the table header bar=0A=
function cl_sort (order)=0A=
{=0A=
  if (typeof order =3D=3D "string")=0A=
  {=0A=
    if (top.frames.HW_Subframe && =
top.frames.HW_Subframe.frames.HW_Mainframe) {=0A=
      top.sortorder =3D order;=0A=
      var the_frame =3D top.frames.HW_Subframe.frames.HW_Mainframe;=0A=
      the_frame.location.replace(the_frame.location.pathname + =
the_frame.location.search);=0A=
    }=0A=
    else {=0A=
      // in this case, not the default frameset is built (maybe HW_PLAIN =
is set)=0A=
      // store the sort order in a cookie before rebuild the page=0A=
      setCookie("cl_sortorder", order, null);=0A=
      location.replace(location.href);=0A=
    }=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
// returns the HTML for the checkbox and the hidden fields=0A=
// for the edit-mode=0A=
function cl_getCheckbox (obj)=0A=
{=0A=
  var ret =3D "";=0A=
  ret +=3D '<input type=3D"checkbox" name=3D"initname'+obj.ST+'" =
value=3D"'+obj.G+'" id=3D"checkbox_'+obj.G+'" />';=0A=
  ret +=3D '<input type=3D"hidden" name=3D"HWTITLE' + obj.G + '" =
value=3D"' + obj.Tenc + '" />';=0A=
  return ret;=0A=
}=0A=
=0A=
// writes the HTML for the link to the drop-down menu=0A=
// on the leftmost column in view-mode=0A=
function cl_getIconWithMenu (params)=0A=
{=0A=
  var p =3D params || {};=0A=
  p.ma=3Dp.ma||"r";=0A=
  p.yp=3Dp.yp||"b";=0A=
  p.xp=3Dp.xp||"r";=0A=
  p.obj=3Dp.obj||"";=0A=
  p.oname=3Dp.openername||p.menuname;=0A=
  var ret =3D [];=0A=
=0A=
  ret [ret.length] =3D '<SPAN ID=3D"'+p.oname+'">';=0A=
  var open_menu =3D[];=0A=
  open_menu[open_menu.length]=3D "openMenu(-1,-1,{obj:'";=0A=
  open_menu[open_menu.length]=3Dp.obj;=0A=
  open_menu[open_menu.length]=3D"',attrobj:{title:'";=0A=
  open_menu[open_menu.length]=3Dp.attrobj.Tenc;=0A=
  open_menu[open_menu.length]=3D"',url:'";=0A=
  open_menu[open_menu.length]=3Dp.attrobj.U;=0A=
  open_menu[open_menu.length]=3D"',goid:'";=0A=
  open_menu[open_menu.length]=3Dp.attrobj.G;=0A=
  open_menu[open_menu.length]=3D"',status:'";=0A=
  open_menu[open_menu.length]=3Dp.attrobj.ST;=0A=
  open_menu[open_menu.length]=3D"'},mname:'";=0A=
  open_menu[open_menu.length]=3Dp.menuname;=0A=
  open_menu[open_menu.length]=3D"',oname:'";=0A=
  open_menu[open_menu.length]=3Dp.oname;=0A=
  open_menu[open_menu.length]=3D"',yp:'b',xp:'";=0A=
  open_menu[open_menu.length]=3Dp.xp;=0A=
  open_menu[open_menu.length]=3D"',ma:'";=0A=
  open_menu[open_menu.length]=3Dp.ma;=0A=
  open_menu[open_menu.length]=3D"',h:false, event: =
self.event||arguments[0], element: this})";=0A=
  open_menu_string=3Dopen_menu.join("");=0A=
  ret [ret.length]=3D "<A BORDER=3D'0' HREF=3D'#' onClick=3D\"";=0A=
  ret [ret.length]=3Dopen_menu_string;=0A=
  ret [ret.length]=3D";return false;\" onKeyPress=3D\"";=0A=
  ret [ret.length]=3Dopen_menu_string;=0A=
  ret [ret.length]=3D"\">\n";=0A=
  ret [ret.length]=3D '<img';=0A=
  ret [ret.length]=3D ' src=3D"';=0A=
  ret [ret.length]=3Dp.imgsrc;=0A=
  ret [ret.length]=3D'"></a>';=0A=
  ret [ret.length]=3D '</SPAN>';=0A=
=0A=
  return ret.join("");=0A=
}=0A=
=0A=
// checks whether the given string is a GOid=0A=
function cl_isGOid (aString) {=0A=
  if (typeof aString=3D=3D"undefined")=0A=
    return false;=0A=
  return (aString.search(/^0x........_0x........$/)!=3D-1);=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Flib%2Fhtmlres%2Flisting.%25style%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'entry': new =
com.hyperwave.res.Template({ templateString_: '    =
\x3ctd>(($x))\x3c/td>'}), 'entry_ecs': new com.hyperwave.res.Template({ =
templateString_: '    \x3ctd =
class=3D\"ListingImage\">(($_if)($x_uid))\x3ca href=3D\"#\" =
onclick=3D\"opDlg(\'/;internal&action=3Ddialog.ecs_new_session.action&use=
rs=3D(($x_uid))\');return false;\">\x3cimg =
src=3D\"/wavemaster.internal/webapp/uistyle/icons/ecs_(($x_state)).gif\" =
width=3D\"16\" height=3D\"16\" border=3D\"0\">\x3c/a>($_else)\x3cimg =
src=3D\"/wavemaster.internal/webapp/uistyle/icons/empty.gif\" =
width=3D\"16\" height=3D\"16\" border=3D\"0\">($_endif)\x3c/td>'}), =
'entry_href': new com.hyperwave.res.Template({ templateString_: '    =
\x3ctd>(($_if) ($x_href))\x3ca href=3D\"(($x_href))\" =
onclick=3D\"(($x_onclick))\">(($x))\x3c/a>($_else)(($x))($_endif)\x3c/td>=
'}), 'entry_marker': new com.hyperwave.res.Template({ templateString_: ' =
   \x3ctd>\n    (($_if) ($x_display))\n       \x3ca href=3D\"#\" =
onclick=3D\"return false;\" class=3D\"(($x_class))\" =
title=3D\"(($x_title))\">\x3cspan>\x3cspan>(($x))\x3c/span>\x3c/span>\x3c=
/a>\n    ($_endif)\n    \x3c/td>'}), 'entry_static': new =
com.hyperwave.res.Template({ templateString_: '  \x3c!-- Listing Data =
Checkbox -->\n   ($#if $showCheckboxColumn)\n	   ($#if $checkbox)\n	     =
 \x3ctd class=3D\"checkbox\">($checkbox)\x3c/td>\n     ($#else)\n        =
\x3ctd>\x3c/td>\n	   ($#endif)\n   ($#endif)	   \n   ($#if =
$showObjMenuColumn)\n	   ($#if $menu)\n	      \x3ctd>($menu)\x3c/td>\n   =
  ($#else)\n        \x3ctd>\x3c/td>\n	   ($#endif)\n   ($#endif)\n  =
\x3c!-- Listing Data Icon -->    \n      \x3ctd class=3D\"icon\">\n      =
   \x3ca href=3D\"($href)\" onclick=3D\"($onclick)\" =
target=3D\"HW_Mainframe\">\n         \x3cimg src=3D\"($icon)\">\n        =
 \x3c/a>\n      \x3c/td>\n  \x3c!-- Listing Data Titel -->\n      \x3ctd =
colspan=3D2 class=3D\"main($#if $agentitem) agentitem($#endif)\">\n      =
  \x3ca href=3D\"($href)\" onclick=3D\"($onclick)\" =
onmouseover=3D\"return top.window_setStatus(this.href);\" =
target=3D\"HW_Mainframe\">($title)\x3c/a>\n  \x3c!-- Listing Data Update =
-->\n        ($#if $update)\n           \x3cspan =
class=3D\"status\">\x3cspan>($update)\x3c/span>\x3c/span>\n        =
($#endif)\n        ($#if $description)\x3cdiv =
class=3D\"description\">($description)\x3c/div>($#endif)\n      =
\x3c/td>'}), 'entry_vc': new com.hyperwave.res.Template({ =
templateString_: '    (($_if) ($x_class))\n    \x3ctd =
class=3D\"(($x_class))\">\x3ca href=3D\"(($x_href))\" =
onclick=3D\"(($x_onclick))\">\x3cspan>(($x))\x3c/span>\x3c/a>\x3c/td>\n  =
  ($_else)\n		\x3ctd>\x3ca href=3D\"(($x_href))\" =
onclick=3D\"(($x_onclick))\">(($x))\x3c/a>\x3c/td>\n		($_endif)'}), =
'header': new com.hyperwave.res.Template({ templateString_: '    =
\x3cth>($header_x)\x3c/th> '}), 'header_sort': new =
com.hyperwave.res.Template({ templateString_: '    \x3cth (($_if) =
($sort_x)) class=3D\"sortable\" =
onclick=3D\"top.cl_sort(\'(($sort_x))\'); return false;\"($_endif)>\n    =
  ($header_x)                  \n      (($_if) ($sort_isx))\n         =
(($_if) ($sort_down))\n            \x3cimg =
src=3D\"/wavemaster.internal/webapp/uistyle/icons/sortdown.png\">\n      =
   ($_else)\n            \x3cimg =
SRC=3D\"/wavemaster.internal/webapp/uistyle/icons/sortup.png\">\n        =
 ($_endif)\n      ($_endif)         \n    \x3c/th> '}), 'header_static': =
new com.hyperwave.res.Template({ templateString_: '    \x3c!-- Listing =
Header Menu/Checkbox -->\n    ($#if $showCheckboxColumn)\n    \x3cth =
class=3D\"checkbox\">&nbsp;\x3c/th>\n    ($#endif)\n    ($#if =
$showObjMenuColumn)\n    \x3cth>&nbsp;\x3c/th>\n    ($#endif)\n    =
\x3c!-- Listing Header Type -->\n    \x3cth($#if $sort_type) =
class=3D\"sortable\" onclick=3D\"top.cl_sort(\'($sort_type)\'); return =
false;\"($#endif)>  \n      ($header_type)                  \n      =
($#if $sort_istype)\n         ($#if $sort_down)\n            \x3cimg =
SRC=3D\"/wavemaster.internal/webapp/uistyle/icons/sortdown.png\">\n      =
   ($#else)\n            \x3cimg =
src=3D\"/wavemaster.internal/webapp/uistyle/icons/sortup.png\">\n        =
 ($#endif)\n      ($#endif)\n    \x3c/th> \n    \x3c!-- Listing Header =
Title -->      \n    \x3cth colspan=3D\"2\" ($#if $sort_title) =
class=3D\"sortable\" onclick=3D\"top.cl_sort(\'($sort_title)\'); return =
false;\"($#endif)>\n    ($header_title)                  \n    ($#if =
$sort_istitle)\n       ($#if $sort_down)\n          \x3cimg =
src=3D\"/wavemaster.internal/webapp/uistyle/icons/sortdown.png\">\n      =
 ($#else)\n          \x3cimg =
SRC=3D\"/wavemaster.internal/webapp/uistyle/icons/sortup.png\">\n       =
($#endif)\n    ($#endif)         \n    \x3c/th> '}), 'main': new =
com.hyperwave.res.Template({ templateString_: '($#if =
$showHeader=3D=3D\"true\")\n\x3cdiv id=3D\"pageheader\">\n  =
\x3ch1>($obj_title)\x3c/h1>\n\x3c/div>\n($#endif)\n\n	($#if =
$DisplayWarningMessage)\n	\x3cdiv class=3D\"WarningSection\">\n	   =
\x3cspan class=3D\"Warning\">\n	      ($WarningMessage)\n	   =
\x3c/span>\n	\x3c/div>\n	($#endif)\n\n  \x3cform name=3D\"bodyform\" =
method=3D\"post\" action=3D\"\" target=3D\"\">\n    \x3cinput =
type=3D\"hidden\" name=3D\"new1\" value=3D\"\">\n    \x3cinput =
type=3D\"hidden\" name=3D\"new2\" value=3D\"\">\n    \x3cinput =
type=3D\"hidden\" name=3D\"PLACE_MOVECOPYOBJECTDESTINATION\" =
value=3D\"\">\n\n	  \x3ctable id=3D\"listing\"($#if $empty) =
class=3D\"empty\"($#endif)>\n\n		($#if $empty)\n      \x3ctr>\n         =
\x3ctd colspan=3D\"8\">\x3cspan>($emptystr)\x3c/span>\x3c/td>\n      =
\x3c/tr>\n		($#else)\n		  \x3ctr>\n		  \x3c!-- HEADER -->  \n		    =
($header_static)($header_dynamic)\n		  \x3c/tr>\n\n		  \x3c!-- display =
an info if collection is empty ...-->\n      \x3c!-- step through list =
of children -->\n		   ($#for $entries)\n		      \x3ctr =
class=3D\"hw_selectable ($row_style)\" =
id=3D\"listing_($GOid)\">($entry_static)($collectionentry)\x3c/tr>\n		   =
($#endfor)\n		($#endif)\n\n\n    \x3c/table>\n  \x3c/form>'})});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/lib/htmlres/=
listing.%style%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Flib%2Flangres%2Flisting_text.%25lang%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'checkin': 'Check In', 'emptystr': =
'Collection is empty.', 'header_modified': 'Modified', 'header_owner': =
'Owner', 'header_size': 'Size', 'header_title': 'Title', 'header_type': =
'Type', 'header_version': 'Version'});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/lib/langres/=
listing_text.%lang%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSTreeview.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSTreeview.js=0A=
 *  Created:     2001-03-13 by cgoess=0A=
 *  Description: contains the class CSTreeview=0A=
 *=0A=
 *  $Id: CSTreeview.js 164658 2011-06-28 12:29:05Z jschipf $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The class provides the means to display a treeview. It uses the=0A=
 * data stored in an instance of CSObjectCache to gather the=0A=
 * information to construct the necessary html. The look of the entries=0A=
 * of the treeview are defined in webapp/lib/htmlres/treeview.xml.=0A=
 * =0A=
 * @author cgoess=0A=
 */=0A=
// <JSClass Name=3D"CSTreeview">=0A=
=0A=
  /**=0A=
   * The CSTreeview constructor.=0A=
   *=0A=
   * @param aData: CSObjectCache: a reference to the object-cache=0A=
   *   that should be visualized by the treeview.=0A=
   * @param theParams: Object: a JavaScript object holding the following=0A=
   *   properties=0A=
   * @param theParams.variable_name: String: variable name of the =
instance=0A=
   * @param theParams.output_frame: String: code to access the document =
of=0A=
   *   the frame that should display the treeview=0A=
   * @param theParams.indent: Number|void: number of pixels used to =
indent=0A=
   *   each level of the treeview=0A=
   * @param theParams.server_function_name: String: the server-side =
function=0A=
   *   that should be called to update the treeview after clicking on the=0A=
   *   '+'-sign=0A=
   * @param theParams.frame_reload_function: String: code that should be=0A=
   *   executed to redraw the treeview=0A=
   * @param theParams.onclick: String: function called after click on =
treeview=0A=
   *   entry=0A=
   * @param theParams.root: the goid of the root-object for the treeview=0A=
   * @param theParams.navigation_id: String|void: id used for server =
requests=0A=
   * @param theParams.multiple_open: Boolean|void: activates =
multiple-open mode=0A=
   * @param theParams.no_hiliting: Boolean|void: if set no object will be=0A=
   *   hilited=0A=
   * @param theParams.show_system_objects: Boolean|void: if set system =
objects=0A=
   *   will be displayed (PresentationHints=3D=3DSystemObject)=0A=
   */=0A=
  function CSTreeview (aData, theParams)=0A=
  {=0A=
    if ( aData =3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    var params =3D theParams || {};=0A=
          // stores the reference to the CSObjectCache=0A=
    this.data_ =3D aData || null;=0A=
          // stores the variable-name of the instance=0A=
    this.name_ =3D params.variable_name;=0A=
          // stores the output-frame/div=0A=
    this.output_ =3D params.output_frame;=0A=
          // stores the indent-parameter=0A=
    this.indent_ =3D params.indent || 20;=0A=
          // stores the update-function=0A=
    this.server_function_name_ =3D params.server_function_name;=0A=
          // stores the reload-function=0A=
    this.frame_reload_function_ =3D params.frame_reload_function || "";=0A=
          // stores the onlick-function=0A=
    this.onclick_ =3D params.onclick;=0A=
          // stores the root of the treeview=0A=
    this.root_ =3D params.root;=0A=
          // stores the first node that is displayed. nodes above this=0A=
          // entry are hidden.=0A=
    this.visible_root_ =3D null;=0A=
          // stores the id used for navigation=0A=
    this.navigation_id_ =3D params.navigation_id || "/";=0A=
          // stores the multiple_open parameter=0A=
    this.multiple_open_ =3D (params.multiple_open=3D=3Dtrue) || false;=0A=
          // stores the no_hiliting parameter=0A=
    this.no_hiliting_ =3D (params.no_hiliting=3D=3Dtrue) || false;=0A=
          // stores the show_system_objects parameter=0A=
    this.show_system_objects_ =3D (params.show_system_objects=3D=3Dtrue) =
|| false;=0A=
          // stores the functions that have been register=0A=
          // with the method registerView()=0A=
    this.display_functions_ =3D [];=0A=
          // stores the status of the treeview, i.e. which=0A=
          // objects are or have been visible=0A=
    this.status_ =3D [];=0A=
          // stores the path that should be displayed as open=0A=
          // when the treeview will be redrawn=0A=
    this.next_path_ =3D null;=0A=
          // stores the path to the next active node.=0A=
          // the active node is the last node that has been selected=0A=
          // by navigating the tree=0A=
          // the nodes will be stored in this.status_=0A=
          // example: active_node_ =3D "0_1_1" can be found in=0A=
          // this.status_[0].c_[1].c_[1]=0A=
    this.active_node_ =3D "";=0A=
          // stores the path to the current object (displayed in =
mainframe)=0A=
          // the format is the same as for active_node_=0A=
    this.current_node_ =3D "";=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSTreeview);=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method searches for a path from the given object to the root=0A=
   * of the tree.=0A=
   *=0A=
   * @param aGOid: String: goid of object=0A=
   * @return Array of Object: path from root to object=0A=
   */=0A=
  class$.searchUp =3D function (aGOid)=0A=
  {=0A=
    var root =3D this.getRoot();=0A=
    var obj  =3D this.data_.getObject(aGOid);=0A=
    if (!obj)=0A=
      return [];=0A=
=0A=
    var aPath =3D this.getCurrentPath();=0A=
    var next_path =3D this.getNextPath();=0A=
=0A=
    if (next_path !=3D null) {=0A=
      // the next-path has already been set --> no need for searchup=0A=
      this.setNextPath(null, false);=0A=
      // cut off all objects which are after the current object=0A=
      // (may happen after a click on an object that is not displayed in =
the mainframe (e.g. DiscussionGroup))=0A=
      var found =3D false;=0A=
      for (var i=3Dnext_path.length-1; i>=3D0; i--) {=0A=
        if (next_path[i].G =3D=3D aGOid) {=0A=
          next_path =3D next_path.slice(0,i+1);=0A=
          found =3D true;=0A=
          break;=0A=
        }=0A=
      }=0A=
      // if the object is in the path return, otherwise a searchup is =
required=0A=
      if (found)=0A=
        return next_path;=0A=
    }=0A=
=0A=
          // check whether current object is already root=0A=
    if (aGOid =3D=3D root ||=0A=
      (obj.HWAT=3D=3D"Configuration" && obj.HWC && obj.HWC.replace(/ =
/,'_')=3D=3Droot))=0A=
      return [this.data_.getObject(root)];=0A=
=0A=
    // use the top-url as a hint=0A=
    if (top.request_objectpath) {=0A=
      var top_url =3D top.request_objectpath;=0A=
    }=0A=
    else {=0A=
      var top_url =3D tv_cutURL(top.location.pathname);=0A=
    }=0A=
    var bestfit =3D decodeURIComponent(top_url).toLowerCase();=0A=
    var parent_path =3D bestfit.split('/');=0A=
    if (typeof parent_path.pop !=3D "function") {  // MSIE 5.0 does not =
know pop()=0A=
      parent_path.length =3D Math.max(parent_path.length-1,0);=0A=
    }=0A=
    else {=0A=
      parent_path.pop();=0A=
    }=0A=
    bestfit =3D parent_path.join('/');=0A=
=0A=
          // perform searchup=0A=
    var nottried =3D [];=0A=
    var try_index =3D 0;=0A=
    var path =3D [obj];=0A=
    var found =3D false;=0A=
=0A=
    do {=0A=
      =0A=
      var parents =3D this.data_.getParents(obj.G);=0A=
      if (parents!=3Dnull) {=0A=
=0A=
        var temp_parents =3D [];=0A=
        for (var p_count=3D0; p_count<parents.length; p_count++) {=0A=
                // in case of a configuration the child-parent-relation =
may be corrupted=0A=
                // -> check whether obj is also child of parent=0A=
          if (obj.HWAT=3D=3D"Configuration") {=0A=
            if (tv_isContainedIn(obj.G, parents[p_count].c_)=3D=3D-1) =
continue;=0A=
          }=0A=
                // if parent is already in path use other parent=0A=
          if (tv_isContainedIn(parents[p_count].G, path)!=3D-1) continue;=0A=
          temp_parents[temp_parents.length] =3D parents[p_count];=0A=
        }=0A=
        if (temp_parents.length=3D=3D0) return [];=0A=
        parents =3D temp_parents;=0A=
        var temp_next =3D "";=0A=
        var highest_index =3D -1;=0A=
        for (var p_entry=3D0; p_entry<parents.length; p_entry++) {=0A=
=0A=
          // try to get the parent that fits the given URL=0A=
          if (bestfit) {=0A=
            var parent_url =3D =
decodeURIComponent(tv_cutURL(parents[p_entry].U)).toLowerCase();=0A=
            if (parent_url =3D=3D bestfit) {=0A=
              temp_next =3D parents[p_entry];=0A=
              if (typeof parent_path.pop !=3D "function") {  // MSIE 5.0 =
does not know pop()=0A=
                parent_path.length =3D Math.max(parent_path.length-1,0);=0A=
              }=0A=
              else {=0A=
                parent_path.pop();=0A=
              }=0A=
              bestfit =3D parent_path.join('/');=0A=
              break;=0A=
            }=0A=
          }=0A=
=0A=
          // try to find a path that contains the current path=0A=
          var search =3D tv_isContainedIn(parents[p_entry].G, aPath);=0A=
          if ((search!=3D-1) && (search>highest_index)) {=0A=
            =0A=
            temp_next =3D parents[p_entry];=0A=
            highest_index =3D search;=0A=
          }=0A=
        }=0A=
=0A=
        if (typeof temp_next!=3D"string")=0A=
          obj =3D temp_next;=0A=
        else {=0A=
          obj =3D parents[0];=0A=
          bestfit =3D "";  // no bestfit found=0A=
        }=0A=
=0A=
              // check whether the current object is already root=0A=
        if (obj.G=3D=3Droot ||=0A=
          (obj.HWAT=3D=3D"Configuration" && obj.HWC && obj.HWC.replace(/ =
/,'_')=3D=3Droot)) {=0A=
            =0A=
          path[path.length] =3D obj;=0A=
          found =3D true;=0A=
        }=0A=
        else {=0A=
                // store other parents=0A=
          for (var p_entry=3D0; p_entry<parents.length; p_entry++) {=0A=
=0A=
            if (parents[p_entry].G!=3Dobj.G)=0A=
              nottried[nottried.length] =3D {object: parents[p_entry], =
path: path.concat([parents[p_entry]])};=0A=
          }=0A=
          path[path.length] =3D obj;=0A=
        }=0A=
      }=0A=
      else {=0A=
              // try next stored parent=0A=
        if (nottried.length>0) {=0A=
          =0A=
          var next_object =3D nottried[try_index];=0A=
          try_index++;=0A=
          obj =3D next_object.object;=0A=
          path =3D next_object.path;=0A=
          bestfit =3D "";  // best fitting path will be found =
immediately or not at all=0A=
        }=0A=
        else=0A=
          obj =3D null;=0A=
      }=0A=
    } while (!found && obj!=3Dnull);=0A=
=0A=
    path =3D path.reverse();=0A=
    return path;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method constructs an array that holds a path from the current=0A=
   * object as defined in the object-cache to the root of the tree.=0A=
   *=0A=
   * @return Array of Object: path from current object to the root of=0A=
   *   the tree=0A=
   */=0A=
  class$.getCurrentPath =3D function ()=0A=
  {=0A=
    return this.getPathFromNode(this.getCurrentNode());=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method sets a path that should be displayed by the treeview.=0A=
   * The effect can be seen after the next 'draw'-call of the treeview.=0A=
   *=0A=
   * @param aPath: Array of Object: path that should be displayed=0A=
   */=0A=
  class$.setNextPath =3D function (aPath, doSetCurrent)=0A=
  {=0A=
    var aPath =3D aPath || null;=0A=
    this.next_path_ =3D aPath;=0A=
    if (aPath!=3Dnull && aPath.length>0) {=0A=
=0A=
      var node =3D this.addPath(aPath);=0A=
      this.setActiveNode(node);=0A=
      if (doSetCurrent)=0A=
        this.setCurrentNode(node);=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the latest path set be using the method=0A=
   * setNextPath.=0A=
   *=0A=
   * @return Array of Object|null: path that should be displayed next=0A=
   */=0A=
  class$.getNextPath =3D function ()=0A=
  {=0A=
    return this.next_path_ || null;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method creates the resource object for a particular entry=0A=
   * in the treeview.=0A=
   *=0A=
   * @param anObj: Object: object of interest=0A=
   * @param aState: Object: the sub-state for the given object=0A=
   * @param isOpen: Boolean: indicated whether the object has children=0A=
   *   that should be displayed=0A=
   * @param anIndent: Number: an integer that defines the level in the=0A=
   *   tree of this particular object=0A=
   * @param aNodeId: String: the id used to find the particular object=0A=
   *   in the status object; necessary because of multiple parents and=0A=
   *   loops=0A=
   * @param aParentNode: String: the id of the parent used to find the=0A=
   *   parent object in the status object; necessary because of multiple=0A=
   *   parents and loops=0A=
   * @param aHierarchy: currently unused=0A=
   * @return Object: the object needed to fill the resource file=0A=
   */=0A=
  class$._createResource =3D function (anObj, aState, isOpen, anIndent, =
aNodeId, aParentNode, aHierarchy)=0A=
  {=0A=
    var temp_obj =3D {};=0A=
    if (anIndent=3D=3D0) {=0A=
      temp_obj.indent =3D 0;=0A=
    }=0A=
    else {=0A=
      temp_obj.indent =3D anIndent*this.indent_;=0A=
    }=0A=
=0A=
    temp_obj.indentplus5 =3D temp_obj.indent + 5;=0A=
    temp_obj.indentplus20 =3D temp_obj.indent + 20;=0A=
=0A=
          // check whether a display-function has been defined for this =
object=0A=
    var html =3D "";=0A=
    for (var func_count=3D0; func_count<this.display_functions_.length; =
func_count++) {=0A=
      =0A=
      var display =3D this.display_functions_[func_count];=0A=
      if (display[0](anObj)) {=0A=
          =0A=
        html =3D display[1](anObj);=0A=
        temp_obj.customhtml =3D html;=0A=
        return temp_obj;=0A=
      }=0A=
    }=0A=
    temp_obj.customhtml =3D "";=0A=
=0A=
    temp_obj.hideExpandCollapseIcon =3D (anObj.HECI)? "true" : "false";=0A=
    if (this.isNavigateable(anObj)) {=0A=
=0A=
      if (isOpen) {=0A=
        temp_obj.navigate =3D "return =
"+this.getName()+".minus('"+aNodeId+"', self.event || arguments[0]);";=0A=
      }=0A=
      else {=0A=
        temp_obj.navigate =3D "return =
"+this.getName()+".plus('"+anObj.G+"','"+aParentNode+"', self.event || =
arguments[0],'"+anObj.CTX+"');";=0A=
      }=0A=
    }=0A=
    else {=0A=
      =0A=
      temp_obj.navigate =3D "";=0A=
    }=0A=
    temp_obj.uistylepath =3D top.gUIStylePath;=0A=
    temp_obj.href =3D top.cs_lib_getHref(anObj);=0A=
    temp_obj.onclick =3D 'return =
'+this.onclick_+'(\''+anObj.G+'\',\''+aParentNode+'\', =
self.event||arguments[0])';=0A=
    temp_obj.onmouseover =3D top.cs_lib_getOnMouseOver(anObj);=0A=
=0A=
    temp_obj.inpath =3D (isOpen ? "true" : "");=0A=
    if (this.doDisplayIcon(anObj)) {=0A=
      temp_obj.doDisplayIcon =3D "true";=0A=
    }=0A=
    temp_obj.icon =3D top.cs_lib_getIcon(anObj, isOpen);=0A=
    temp_obj.title =3D anObj.T || "";=0A=
    // use title without HTML for alt-text of icon=0A=
    temp_obj.alt_title =3D anObj.title || "";=0A=
    // escape double quotes: PR-4683=0A=
    temp_obj.alt_title =3D temp_obj.alt_title.replace(/\"/g,"&quot;");=0A=
=0A=
    // FolderViewer support=0A=
    if (typeof this.openFolder =3D=3D 'function') {=0A=
      temp_obj.infoicon_src =3D cs_lib_getInfoIcon(anObj);=0A=
      temp_obj.infoicon_onclick =3D 'top.' + =
cs_lib_getInfoIcon_onClick(anObj);=0A=
    }=0A=
=0A=
    temp_obj.level =3D anIndent;=0A=
          // add hiliting-information=0A=
    temp_obj.emph =3D "";=0A=
    if (!this.no_hiliting_) {=0A=
=0A=
      var path =3D this.getCurrentNode();=0A=
      if (path=3D=3DaNodeId.substring(0, path.length)) {=0A=
        temp_obj.is_cur_child =3D true;=0A=
      }=0A=
      else=0A=
        temp_obj.is_cur_child =3D false;=0A=
=0A=
      if (aNodeId=3D=3Dpath.substring(0, aNodeId.length) &&=0A=
          (path.charAt(aNodeId.length)=3D=3D'_' || =
path.charAt(aNodeId.length)=3D=3D'')) {=0A=
        =0A=
        var emph =3D this.isLastVisible(anObj, aState, true, =
path.substring(aNodeId.length+1));=0A=
        temp_obj.emph =3D (emph) ? "true" : "";=0A=
      }=0A=
    }=0A=
          // add information whether an anchor should be added=0A=
    if (isOpen) {=0A=
      var path =3D this.getActiveNode();=0A=
      if (aNodeId =3D=3D path) {=0A=
        temp_obj.anchor =3D "true";=0A=
      }=0A=
      else {=0A=
        if (aNodeId=3D=3Dpath.substring(0, aNodeId.length) &&=0A=
            (path.charAt(aNodeId.length)=3D=3D'_' || =
path.charAt(aNodeId.length)=3D=3D'')) {=0A=
=0A=
          var anchor =3D this.isLastVisible(anObj, aState, isOpen, =
path.substring(aNodeId.length+1));=0A=
          temp_obj.anchor =3D (anchor) ? "true" : "";=0A=
        }=0A=
        else {=0A=
          temp_obj.anchor =3D "";=0A=
        }=0A=
      }=0A=
    }=0A=
    else=0A=
      temp_obj.anchor =3D "";=0A=
    return temp_obj;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method constructs the HTML for the treeview an writes it into=0A=
   * the predefined frame.=0A=
   */=0A=
  class$.draw =3D function ()=0A=
  {=0A=
    this.setNextPath(null, false);=0A=
    var state =3D this.getStatus();=0A=
=0A=
    var tree_data =3D {};=0A=
    tree_data.entries =3D this._getTreeResource(state);=0A=
    if (typeof top.cstreeview_res !=3D "undefined") {=0A=
=0A=
      var target =3D eval(this.output_);=0A=
      if (typeof target =3D=3D "object") {=0A=
        =0A=
        var tree_doc =3D target.document;=0A=
        if (tree_data.entries.length>0) {=0A=
=0A=
          top.cstreeview_res.setRes("entries", tree_data.entries);=0A=
          tree_doc.writeln(top.cstreeview_res.toString(true));=0A=
          with (target) {=0A=
            var selected =3D $$(".selected");=0A=
            if (selected.length > 0) {=0A=
              var html_element =3D $(tree_doc.body).up()=0A=
              var right =3D html_element.scrollWidth - 1; // -1 is to =
correct a problem with ie7=0A=
              =0A=
              selected[0].setStyle({width: right+"px"});=0A=
            }=0A=
          }=0A=
        }=0A=
        else {=0A=
          if (top.gLangresServer) {=0A=
            tree_doc.writeln('<DIV =
class=3D"AttrValue">'+top.gLangresServer.getRes("treeview_noobjects","std=
p","There are no objects to show in this view.")+'</DIV>');=0A=
          }=0A=
          else {=0A=
            tree_doc.writeln("There are no objects to show in this =
view.");=0A=
          }=0A=
        }=0A=
      }=0A=
      else=0A=
        alert("The specified frame "+this.output_+" cannot be found!");=0A=
    }=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method constructs the object that is needed by the resource=0A=
   * reader to construct the html of the treeview.=0A=
   *=0A=
   * @param anObj: Object: the object of interest=0A=
   * @param aState: Object: the state of the treeview that should be=0A=
   *   constructed=0A=
   * @param anIndex: Number: the current position in the data structure=0A=
   * @param aNodeId: String: the ide of the node=0A=
   * @param aParentNode: String: the id of the parent node=0A=
   * @param aHierarchy: String: currently unused!=0A=
   * @param anIndentLevel: String: the indentation level for the=0A=
   *   current object in the tree=0A=
   * @return Array of Object: the object needed to fill the resource file=0A=
   */=0A=
  class$._getTreeResource =3D function (aState)=0A=
  {=0A=
    var this_ =3D this;=0A=
    function _getTreeResource_recursive (anObj, aState, anIndex, =
aNodeId, aParentNode, aHierarchy, anIndentLevel) {=0A=
=0A=
      var entry_arr =3D [];=0A=
      if (this_.isVisible(anObj, true)) {=0A=
                =0A=
        var next_indentlevel =3D anIndentLevel;=0A=
        if (anIndex=3D=3D0 && !anObj.SP && =
anObj.G.indexOf('0x00000002')=3D=3D11) { // special handling for =
rootcollection=0A=
          entry_arr[entry_arr.length] =3D this_._createResource(anObj, =
aState, true, -1, aNodeId, aParentNode, aHierarchy);=0A=
        }=0A=
        else {=0A=
          entry_arr[entry_arr.length] =3D this_._createResource(anObj, =
aState, true, anIndentLevel, aNodeId, aParentNode, aHierarchy);=0A=
          next_indentlevel++;=0A=
        }=0A=
=0A=
        if (anObj.DCFS!=3D"true" || anObj.DCDC=3D=3D"true") {  // do not =
display children of a document class with force show unless =
UIDisplayChildren has been set=0A=
=0A=
          var children =3D this_.data_.getChildren(anObj.G);=0A=
          if (children !=3D null) {=0A=
            =0A=
            var next_ids =3D (aState && aState.c_ && aState.c_.length>0) =
? aState.c_ : [];=0A=
            var active_node =3D this_.getActiveNode();=0A=
            var active_nodes =3D active_node.split('_');=0A=
            =0A=
            if (typeof active_nodes[anIndex+1] !=3D "undefined")=0A=
              var next_single_index =3D Number(active_nodes[anIndex+1]);=0A=
            else=0A=
              var next_single_index =3D -1;=0A=
=0A=
            var help_hierarchy =3D =
(aHierarchy.lastIndexOf('/')=3D=3DaHierarchy.length-1) ? aHierarchy : =
aHierarchy+'/';=0A=
            for (var kid=3D0; kid<children.length; kid++) {=0A=
              =0A=
              var tobj =3D children[kid];=0A=
              var index =3D tv_isContainedIn(tobj.G,next_ids);=0A=
              var next_hierarchy =3D help_hierarchy+tobj.ON;=0A=
=0A=
              if (index!=3D-1 && !next_ids[index].u && =
(this_.multiple_open_ || index=3D=3Dnext_single_index)) {=0A=
              =0A=
                entry_arr =3D =
entry_arr.concat(_getTreeResource_recursive(tobj, next_ids[index], =
anIndex+1, aNodeId+'_'+index, aNodeId, next_hierarchy, =
next_indentlevel));=0A=
              }=0A=
              else {=0A=
                if (this_.isVisible(tobj)) {=0A=
                  =0A=
                  entry_arr[entry_arr.length] =3D =
this_._createResource(tobj, aState, false, next_indentlevel, =
aNodeId+'_'+index, aNodeId, next_hierarchy);=0A=
                }=0A=
              }=0A=
            }=0A=
          }=0A=
        }=0A=
      }=0A=
      return entry_arr;=0A=
    }=0A=
=0A=
    var entry_arr =3D [];=0A=
    if (aState.length=3D=3D0) {=0A=
            // only one root for the tree possible=0A=
      var root =3D this.getRoot();=0A=
      if (root !=3D "") {=0A=
        var root_obj =3D this.data_.getObject(root);=0A=
        entry_arr =3D [this._createResource(root_obj, aState, false, 0, =
"", root_obj.HP || "")];=0A=
      }=0A=
    }=0A=
    else {=0A=
            // several roots for the tree are possible=0A=
            // get index from active node=0A=
      var active_nodes =3D (this.getActiveNode() || "0").split('_');=0A=
      var active_nodes_index =3D 0;=0A=
      var active_node_id =3D active_nodes[0];=0A=
      var state_entry =3D aState[Number(active_nodes[0])];=0A=
      =0A=
      if (this.getVisibleRoot()) {=0A=
        var out =3D this.evaluateVisibleRootSetting(aState, =
active_nodes);=0A=
        if (out) {=0A=
          state_entry =3D out.state_entry;=0A=
          active_node_id =3D out.node_id;=0A=
          active_nodes_index =3D out.node_index;=0A=
        }=0A=
      }=0A=
=0A=
      var tobj =3D this.data_.getObject(state_entry.G);=0A=
      if (!state_entry.u) {=0A=
        entry_arr =3D entry_arr.concat(_getTreeResource_recursive(tobj, =
state_entry, active_nodes_index, active_node_id, "", tobj.HP || "", 0));=0A=
      }=0A=
      else {=0A=
        entry_arr =3D entry_arr.concat([this._createResource(tobj, =
state_entry, false, active_nodes_index, active_node_id, "", tobj.HP || =
"")]);=0A=
      }=0A=
    }=0A=
    return entry_arr;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the predefined variable name of the particular=0A=
   * instance. It should allow to call methods of itself in onclick-=0A=
   * functions.=0A=
   *=0A=
   * @return String: the variable name of the instance=0A=
   */=0A=
  class$.getName =3D function ()=0A=
  {=0A=
    return this.name_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the predefined url that should be used when=0A=
   * requesting objects from the server (necessary when navigating using=0A=
   * the '+'-sign).=0A=
   *=0A=
   * @return String: the url that should be used for server requests=0A=
   */=0A=
  class$.getNavigationId =3D function ()=0A=
  {=0A=
    return this.navigation_id_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks wether there are any visible objects in the=0A=
   * given path.=0A=
   *=0A=
   * @param anObj: Object: object of interest=0A=
   * @param aState: Object: the substate for this object=0A=
   * @param isOpen: Boolean: indicates whether there are childrens that=0A=
   *   should be displayed=0A=
   * @param aPath: String: the path in aState that should be displayed=0A=
   * @return Boolean: indicates whether there are other visible objects=0A=
   *   in the given path=0A=
   */=0A=
  class$.isLastVisible =3D function (anObj, aState, isOpen, aPath)=0A=
  {=0A=
    if (typeof(anObj)=3D=3D"object" && isOpen)=0A=
    {=0A=
      if (anObj.DCFS=3D=3D"true" && anObj.DCDC!=3D"true") {=0A=
        return true;=0A=
      }=0A=
=0A=
      var state =3D aState;=0A=
      while (typeof state =3D=3D "object") {=0A=
=0A=
        if (typeof state.c_ =3D=3D "object") {=0A=
          var objs =3D this.getPathFromNode(aPath, state.c_);=0A=
          if (objs =3D=3D null) {=0A=
            return false;=0A=
          }=0A=
=0A=
          for (var count=3D0; count<objs.length; count++) {=0A=
          =0A=
            var tobj =3D this.data_.getObject(objs[count].G);=0A=
            if (this.isVisible(tobj, true)) {=0A=
              return false;=0A=
            }=0A=
          }=0A=
          state =3D state.c_;=0A=
        }=0A=
        else=0A=
          state =3D "";=0A=
      }=0A=
      return true;=0A=
    }=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks whether the given object will be displayed in the=0A=
   * treeview.=0A=
   *=0A=
   * @param anObj: Object: object of interest=0A=
   * @param isOpen: Boolean: indicates whether the current obeject is=0A=
   *   part of the path to the current object (hidden objects will be=0A=
   *   display in this case)=0A=
   * @return Boolean: indicates wether the given object is visible in=0A=
   *   the treeview=0A=
   */=0A=
  class$.isVisible =3D function (anObj, isOpen)=0A=
  {=0A=
    for (var func_count=3D0; func_count<this.display_functions_.length; =
func_count++) {=0A=
=0A=
      if (this.display_functions_[func_count][0](anObj))=0A=
        return true;=0A=
    }=0A=
=0A=
    if (!anObj || !anObj.G)=0A=
      return false;=0A=
=0A=
    if (anObj.ADD && anObj.ADD.indexOf('skiptree')!=3D-1)=0A=
      return false;=0A=
=0A=
    if (anObj.DT !=3D "collection")=0A=
      return false;=0A=
  =0A=
    if (!top.editmode && ((anObj.PH=3D=3D"Hidden" && !isOpen) || =
(anObj.PH=3D=3D"CollectionHead") || =
(anObj.PH=3D=3D"FullCollectionHead")))=0A=
      return false;=0A=
=0A=
    if =
((anObj.PH=3D=3D"SystemObject"||anObj.PH=3D=3D"ApplicationObject") && =
!this.show_system_objects_)=0A=
      return false;=0A=
  =0A=
          // check if object is a dc and of type object -> no children=0A=
    if (typeof anObj.DCI!=3D"undefined" && anObj.DCO=3D=3D"yes")=0A=
      return false;=0A=
  =0A=
          // by default display collections of every CollectionType =
except=0A=
          // Cluster, AlternativeCluster, MultiCluster=0A=
    if (!top.editmode && ((anObj.CT =3D=3D "Cluster") || (anObj.CT =
=3D=3D "AlternativeCluster") || (anObj.CT =3D=3D "MultiCluster")))=0A=
      return false;=0A=
=0A=
    return true;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks wether the given objects are equal. In case of=0A=
   * a configuration object special handling is necessary.=0A=
   *=0A=
   * @param anObjA: Object: object of interest=0A=
   * @param anObjB: Object: second object of interest=0A=
   * @return Boolean: indicates whether the objects are equal=0A=
   */=0A=
  class$.isEqual =3D function (anObjA, anObjB)=0A=
  {=0A=
    if ((typeof anObjA!=3D"object") || (typeof anObjB!=3D"object")) =
return false;=0A=
=0A=
    if (anObjA.G=3D=3DanObjB.G) return true;=0A=
=0A=
    if (anObjA.HWAT=3D=3D"Configuration" &&=0A=
      typeof(anObjA.HWC)=3D=3D"string" && =
anObjB.G=3D=3DanObjA.HWC.replace(" ","_"))=0A=
      return true;=0A=
=0A=
    if (anObjB.HWAT=3D=3D"Configuration" &&=0A=
      typeof(anObjB.HWC)=3D=3D"string" && =
anObjA.G=3D=3DanObjB.HWC.replace(" ","_"))=0A=
      return true;=0A=
=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method checks whether the given object should be navigateable,=0A=
   * i.e. whether the '+'-sign has a functionality attached to.=0A=
   *=0A=
   * @param anObj: Object: object of interest=0A=
   * @return Boolean: indicates the object can be opened=0A=
   */=0A=
  class$.isNavigateable =3D function (anObj)=0A=
  {=0A=
    if (typeof anObj !=3D "object")=0A=
      return false;=0A=
=0A=
    if (anObj.PT =3D=3D "yes")=0A=
      return false;=0A=
=0A=
    if (!top.editmode && (anObj.DF =3D=3D "yes"))=0A=
      return false;=0A=
=0A=
    if (!top.editmode && anObj.CT &&=0A=
      (anObj.CT !=3D "Collection") && (anObj.CT !=3D "Sequence") &&=0A=
      (anObj.CT !=3D "ServColl") && (anObj.CT !=3D "Derived") &&=0A=
      (anObj.CT !=3D "Registry") && (anObj.CT !=3D "RegistryCategory") &&=0A=
      (anObj.CT !=3D "Directory"))=0A=
      return false;=0A=
=0A=
    if ((typeof anObj.DCI !=3D "undefined") && (anObj.DCFS =3D=3D =
"true") && (anObj.DCDC !=3D "true"))=0A=
      return false;=0A=
=0A=
    if (anObj.CT=3D=3D"ServColl" && (anObj.HWPS=3D=3D"DISABLED" || =
anObj.HWSS=3D=3D"DOWN" || anObj.HWSS=3D=3D"FORCED_DOWN" ))=0A=
      return false;=0A=
=0A=
    return true;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The mehtod adds a given path to the status of the treeview. In case=0A=
   * of a multiple-open-tree this means another path will be displayed=0A=
   * after the following 'draw'-call. When using a single open path the=0A=
   * defined path overrides the last path.=0A=
   *=0A=
   * @param aPath: Array of Object: that path that should be added=0A=
   * @return String: the id of the last node of the path=0A=
   */=0A=
  class$.addPath =3D function (aPath)=0A=
  {=0A=
    var subpath =3D this.getStatus();=0A=
    var ret_node =3D "";=0A=
    for (var count=3D0; count<aPath.length; count++) {=0A=
      =0A=
      var s_count =3D 0;=0A=
      while (s_count<subpath.length && =
subpath[s_count].G!=3DaPath[count].G) {=0A=
        s_count++;=0A=
      }=0A=
      if (s_count<subpath.length) {=0A=
        subpath[s_count].u =3D false;=0A=
        subpath =3D subpath[s_count].c_;=0A=
      }=0A=
      else {=0A=
        subpath[s_count] =3D {G: aPath[count].G, c_: []};=0A=
        subpath =3D subpath[s_count].c_;=0A=
      }=0A=
      if (ret_node =3D=3D "")=0A=
        ret_node +=3D s_count;=0A=
      else=0A=
        ret_node +=3D '_'+s_count;=0A=
    }=0A=
    return ret_node;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method closes a path of the treeview. The next 'draw'-call will=0A=
   * display a treeview that views no children after the given path.=0A=
   *=0A=
   * @param aPath: Array of Object: the path after which the display=0A=
   *   of children should be stopped=0A=
   * @return Boolean: indicates whether the given path could be found=0A=
   *   and cut=0A=
   */=0A=
  class$.cutPath =3D function (aPath)=0A=
  {=0A=
    var subpath =3D this.getStatus();=0A=
    for (var p_count=3D0; p_count<aPath.length; p_count++) {=0A=
      =0A=
      var s_count =3D 0;=0A=
      while (s_count<subpath.length && =
subpath[s_count].G!=3DaPath[p_count].G) {=0A=
=0A=
        s_count++;=0A=
      }=0A=
      if (s_count<subpath.length) {=0A=
=0A=
        if (p_count!=3DaPath.length-1)=0A=
          subpath =3D subpath[s_count].c_;=0A=
        else // u indicates that the children will not be displayed=0A=
          subpath[s_count].u =3D true;=0A=
      }=0A=
      else=0A=
        return false;=0A=
    }=0A=
    return true;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the status object of the treeview.=0A=
   *=0A=
   * @return Array of Object: the status objects=0A=
   */=0A=
  class$.getStatus =3D function ()=0A=
  {=0A=
    return this.status_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method resets the members that store information about the=0A=
   * status of the treeview (e.g. open collections)=0A=
   */=0A=
  class$.clearStatus =3D function ()=0A=
  {=0A=
    this.status_ =3D [];=0A=
    this.setCurrentNode("");=0A=
  };=0A=
=0A=
=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method constructs a path from the given node id.=0A=
   *=0A=
   * @param anId: String: the id of the node of interest=0A=
   * @param aStatus:  Array of Object|void: sub-status that should be=0A=
   *   used to construct path; uses status of tree if not defined=0A=
   * @return Array of Object|void: sub-status object of interest; uses=0A=
   */=0A=
  class$.getPathFromNode =3D function (anId, aStatus)=0A=
  {=0A=
    if (typeof anId =3D=3D "undefined" || anId=3D=3D"") {=0A=
      return [];=0A=
    }=0A=
=0A=
    if (typeof aStatus !=3D "object")=0A=
      var status =3D this.getStatus();=0A=
    else=0A=
      var status =3D aStatus;=0A=
=0A=
    var node_path =3D anId.split('_');=0A=
    var path =3D [];=0A=
    for (var node_count=3D0; node_count<node_path.length; node_count++) {=0A=
=0A=
      var index =3D new Number(node_path[node_count]);=0A=
      if (typeof status[index] !=3D "object")=0A=
        return null;=0A=
=0A=
      path[path.length] =3D this.data_.getObject(status[index].G);=0A=
      status =3D status[index].c_;=0A=
    }=0A=
    return path;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method sets the id of the last active node. This is=0A=
   * needed to place the anchor for scrolling.=0A=
   *=0A=
   * @param aNode: String: the id of the last active node=0A=
   */=0A=
  class$.setActiveNode =3D function (aNode)=0A=
  {=0A=
    this.active_node_ =3D aNode;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the id of the last active node. This is=0A=
   * needed to place the anchor for scrolling.=0A=
   *=0A=
   * @return String: the id of the last active node=0A=
   */=0A=
  class$.getActiveNode =3D function ()=0A=
  {=0A=
    return this.active_node_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method sets the id of the node of the current object as defined=0A=
   * in objectcache. This is needed to emphasize the correct object.=0A=
   *=0A=
   * @param aNode: String: the id of the node of the current object=0A=
   */=0A=
  class$.setCurrentNode =3D function (aNode)=0A=
  {=0A=
    this.current_node_ =3D aNode;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the id of the node of the current object as=0A=
   * defined in objectcache. This is needed to emphasize the correct=0A=
   * object.=0A=
   *=0A=
   * @return String: the id of the node of the current object=0A=
   */=0A=
  class$.getCurrentNode =3D function ()=0A=
  {=0A=
    return this.current_node_;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method will be associated to the '-' sign of the treeview. It=0A=
   * results in a reload of the frame where the corresponding collection=0A=
   * will be closed.=0A=
   *=0A=
   * @param aNodeId: String: the id of the particular node=0A=
   * @param anEvent: Event: the corresponding event=0A=
   * @return Boolean: returns false to prevent the activation of the=0A=
   *   corresponding link=0A=
   */=0A=
  class$.minus =3D function (aNodeId, anEvent)=0A=
  {=0A=
    var path =3D this.getPathFromNode(aNodeId);=0A=
    this.cutPath(path);=0A=
    if (path.length>0) {=0A=
      this.setNextPath(path.slice(0,path.length-1), false);=0A=
    }=0A=
    eval(this.frame_reload_function_);=0A=
    if ( anEvent )=0A=
      anEvent.cancelBubble =3D true;=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method will be associated to the '+' sign of the treeview. It=0A=
   * results in a reload of the frame where the corresponding collection=0A=
   * will be opened.=0A=
   *=0A=
   * @param aGOid: String: goid of the collection that should be opened=0A=
   * @param aContext: String: context in which the collection should be =
opened.=0A=
   * @param aParentNode: String: id of the parent node=0A=
   * @param anEvent: Event: the corresponding event=0A=
   * @return Boolean: returns false to prevent the activation of the=0A=
   *   corresponding link=0A=
   */=0A=
  class$.plus =3D function (aGOid, aParentNode, anEvent, aContext)=0A=
  {=0A=
    the_context =3D (typeof aContext !=3D "undefined") ? aContext : "";=0A=
    var path =3D this.getPathFromNode(aParentNode);=0A=
    path[path.length] =3D this.data_.getObject(aGOid);=0A=
    this.setNextPath(path, false);=0A=
    =0A=
    var stored =3D (this.data_.getChildren(aGOid)!=3Dnull);=0A=
    if (!stored)=0A=
    {=0A=
      // get children of object=0A=
      if (typeof this.server_function_name_ =3D=3D "string") {=0A=
        top.callServerFunction({serverFunctionName: =
this.server_function_name_,=0A=
                                objectidentifier: this.getNavigationId(),=0A=
                                parameters: {GOid: aGOid,=0A=
                                             context: the_context },=0A=
                                callback: this.frame_reload_function_});=0A=
      }=0A=
    }=0A=
    else {=0A=
      eval(this.frame_reload_function_);=0A=
    }=0A=
    if ( anEvent ) {=0A=
      anEvent.cancelBubble =3D true;=0A=
    }=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method allows to register functions that provide the html for=0A=
   * an entry of the treeview by themselves.=0A=
   *=0A=
   * @param aDecision: Function: a function that returns a Boolean value=0A=
   *   that indicates whether the html provided by the second function=0A=
   *   should be used for this object or the standard resource-html.=0A=
   * @param aHTML: Function: a function that returns the html for the=0A=
   *   given object.=0A=
   */=0A=
  class$.registerView =3D function (aDecision, aHTML)=0A=
  {=0A=
    if (typeof aDecision =3D=3D "function" && typeof aHTML =3D=3D =
"function") {=0A=
=0A=
      this.display_functions_[this.display_functions_.length] =3D =
[aDecision, aHTML];=0A=
      return true;=0A=
    }=0A=
    return false;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method returns the goid that has been set with the method=0A=
   * setRoot.=0A=
   *=0A=
   * @return String: the goid of the root-object=0A=
   */=0A=
  class$.getRoot =3D function ()=0A=
  {=0A=
    return this.root_ || this.data_.getRoot();=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method set the goid of the root-object.=0A=
   *=0A=
   * @param aGOid: String: the goid of the root-object=0A=
   */=0A=
  class$.setRoot =3D function (aGOid)=0A=
  {=0A=
    this.root_ =3D aGOid;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * The method defines whether the icon of a given object is displayed=0A=
   * in the treeview. It is mapped onto the property doDisplayIcon in=0A=
   * the resource ./htmlres/treeview.xml.=0A=
   *=0A=
   * @param anObj: Object: the object of interest=0A=
   * @return Boolean: defines whether the icon is displayed=0A=
   */=0A=
  class$.doDisplayIcon =3D function (anObj)=0A=
  {=0A=
    if (!anObj.IC || anObj.IC.indexOf('/icons/collection.png')!=3D-1)=0A=
      return false;=0A=
    return true;=0A=
  };=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * ###METHOD DESCRIPTION###=0A=
   *=0A=
   * @param aPath: Array of Object: ###PARAMETER DESCRIPTION###=0A=
   * @return String: ###PARAMETER DESCRIPTION###=0A=
   */=0A=
  class$.getHierarchicalName =3D function (aPath)=0A=
  {=0A=
    var ret_str =3D aPath[0].HP;=0A=
    if (typeof ret_str =3D=3D "undefined") {=0A=
      return "";=0A=
    }=0A=
    if (ret_str.lastIndexOf('/')!=3Dret_str.length-1)=0A=
      ret_str+=3D'/';=0A=
=0A=
    var object_names =3D [];=0A=
    for (var path_count=3D1; path_count<aPath.length; path_count++) {=0A=
=0A=
      object_names[object_names.length] =3D aPath[path_count].ON;=0A=
    }=0A=
    ret_str +=3D object_names.join('/');=0A=
    return ret_str;=0A=
  };=0A=
  =0A=
  /**=0A=
   * This function opens any object in treeview without navigating to =
specified object.=0A=
   * This function does the same as navigating with plus icon to =
specified object.=0A=
   * =0A=
   * @param goid: string: the goid=0A=
   * @param content: string: the context=0A=
   */=0A=
  class$.expandObject =3D function (goid, context) {=0A=
    var this_ =3D this;=0A=
    var fname =3D "callbackFunction" + new Date().valueOf();=0A=
    top[fname] =3D function () {=0A=
      var current_node =3D this_.getCurrentNode();=0A=
      var path =3D this_.searchUp(goid);=0A=
      this_.setNextPath(path, false);=0A=
      top.reload_navigation();=0A=
      this_.setNextPath(null, false);=0A=
      top[fname] =3D void(0);=0A=
    };=0A=
    =0A=
    top.callServerFunction({serverFunctionName: =
"write_updateCSObjectCache",=0A=
                            objectidentifier: this.getNavigationId(),=0A=
                            parameters: {GOid: goid,=0A=
                                         searchUp: true,=0A=
                                         context: context || ""},=0A=
                            callback: "top." + fname + "()"});=0A=
  };=0A=
  =0A=
  /**=0A=
   * Setter method for the visible root member.=0A=
   * =0A=
   * The visible root allows to limit the scope of the treeview to a sub =
tree without limiting the=0A=
   * data that is available in the treeview. This is important when the =
breadcrumbing should display the whole=0A=
   * path up to the root object (bad design). If only =
<code>setRoot</code> would be used the breadcrumbing=0A=
   * would display the same limited path.=0A=
   * =0A=
   * @params theRoot: string: the visible root. must be a GOid as =
provided by the function <code>getGOid()</code>=0A=
   */=0A=
  class$.setVisibleRoot =3D function (theRoot) {=0A=
    this.visible_root_ =3D theRoot;=0A=
  };=0A=
  =0A=
  /**=0A=
   * Getter method for the visible root member.=0A=
   * =0A=
   * @return String: the previously registered visible root or =
<code>null</code> if no root=0A=
   *   has been registered=0A=
   */=0A=
  class$.getVisibleRoot =3D function () {=0A=
    return this.visible_root_;=0A=
  };=0A=
=0A=
  /**=0A=
   * The method limits the state objects to the sub-tree that should be =
displayed=0A=
   * in the treeview.=0A=
   * =0A=
   * @param aState: object[]: the treeview state=0A=
   * @theActiveNodes: string[]: the path to the active nodes in the =
state object=0A=
   * @return object: the return object holding the scoped state variables=0A=
   */=0A=
  class$.evaluateVisibleRootSetting =3D function (aState, =
theActiveNodes) {=0A=
    var state =3D aState;=0A=
    var active_nodes =3D theActiveNodes;=0A=
    var node_ids =3D [];=0A=
    for (var i=3D0; i<active_nodes.length; i++) {=0A=
      var index =3D Number(active_nodes[i]);=0A=
      node_ids.push(active_nodes[i]);=0A=
      if (state[index].G =3D=3D this.getVisibleRoot()) {=0A=
        return {=0A=
          state_entry: state[index],=0A=
          node_index: i,=0A=
          node_id: node_ids.join('_')=0A=
        };=0A=
      }=0A=
      state =3D state[index].c_;=0A=
    }=0A=
    return null;=0A=
  };=0A=
// </JSClass>=0A=
=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function checks whether an object with the given goid is=0A=
 * contained in the given array.=0A=
 *=0A=
 *=0A=
 * @param aGOid: String: goid of the object of interest=0A=
 * @param anArray: Array of Object: the array of objects to search in=0A=
 * @return Number: the position of the object in the array, returns -1=0A=
 *   if anEntry cannot be found in the array=0A=
 */=0A=
function tv_isContainedIn (aGOid, anArray) {=0A=
  =0A=
  if (typeof aGOid =3D=3D "string" && typeof anArray =3D=3D "object") {=0A=
=0A=
    for (var count=3D0; count<anArray.length; count++) {=0A=
      =0A=
      if (aGOid=3D=3DanArray[count].G) {=0A=
        return count;=0A=
      }=0A=
    }=0A=
  }=0A=
  return -1;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The function removes any 'addons' from the URL. The remaining part=0A=
 * should be the hierarchical name or the alias name of the requested=0A=
 * object.=0A=
 *=0A=
 * @param aURL: String: a URL=0A=
 * @return String: the hierarchical name or alias name of the=0A=
 *   requested object=0A=
 */=0A=
function tv_cutURL (aURL)=0A=
{=0A=
  var url =3D aURL || "";=0A=
  var idx =3D url.indexOf(';');=0A=
  if (idx>0)=0A=
    url =3D url.substring(0, idx);=0A=
  idx =3D url.indexOf('?');=0A=
  if (idx>0)=0A=
    url =3D url.substring(0, idx);=0A=
  idx =3D url.indexOf('#');=0A=
  if (idx>0)=0A=
    url =3D url.substring(0, idx);=0A=
  return url;=0A=
}=0A=
=0A=
//  function iter (obj,pre) {=0A=
  =0A=
//    var str =3D "";=0A=
//    for (var y in obj) {=0A=
//      if (typeof obj[y] =3D=3D "object")=0A=
//        str +=3D iter(obj[y],pre+"  ");=0A=
//      else=0A=
//        str +=3D pre+y+" : "+obj[y]+"\n";=0A=
//    }=0A=
//    return str;=0A=
//  }=0A=
=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Flib%2Fhtmlres%2Ftreeview.%25style%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'main': new =
com.hyperwave.res.Template({ templateString_: '	\n\x3cul>\n	($#for =
$entries)\n  \x3cli class=3D\"($#if =
$inpath)expanded($#else)collapsed($#endif)($#if $emph) =
selected($#endif)($#if $level\x3c0) root($#endif)\" ($#if =
$customhtml=3D=3D\"\")title=3D\"($alt_title)\"($#endif)>\n      ($#if =
$anchor)\x3ca id=3D\"hw_cur\">\x3c/a>($#endif)\n      ($#if =
$customhtml=3D=3D\"\")\n        \x3ca href=3D\"($href)\" =
onclick=3D\"($onclick)\" target=3D\"HW_Mainframe\" class=3D\"label\" =
style=3D\"padding-left: ($indent)px\">($#if $doDisplayIcon)\x3cimg =
src=3D\"($icon)\" title=3D\"($alt_title)\" style=3D\"left: =
($indentplus5)px\"/>($#endif)\x3cspan>($title)\x3c/span>\x3c/a>\n        =
($#if $hideExpandCollapseIcon !=3D \"true\")\n				  \x3ca =
onclick=3D\"($navigate)\" class=3D\"toggle\" style=3D\"left: =
($indentplus20)px\">\x3cspan>($#if =
$inpath)expanded($#else)collapsed($#endif)\x3c/span>\x3c/a>\n        =
($#endif)\n      ($#elseif)\n        ($customhtml)\n      ($#endif)\n  =
\x3c/li>\n	($#endfor)\n\x3c/ul>\n'})});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/lib/htmlres/=
treeview.%style%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/standardpage/code/CSFooter.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSFooter.js=0A=
 *  Created:     2002-10-18 by cgoess=0A=
 *  Description: displays the footer using client-side resources=0A=
 *=0A=
 *  $Id: CSFooter.js 162748 2011-05-02 08:14:40Z cgoess $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/** =0A=
 * The class is responsible to write the footer into the document =0A=
 * using client-side reqources.=0A=
 * =0A=
 * @author cgoess=0A=
 */=0A=
// <JSClass Name=3D"CSFooter">=0A=
=0A=
  /**=0A=
   * The CSFooter constructor.=0A=
   *=0A=
   * @param theData: CSObjectCache: the object cache to request=0A=
   *    information=0A=
   * @param theOutput: String: code to access the document of=0A=
   *   the frame that should display the footer=0A=
   */=0A=
  function CSFooter (theData, theOutput)=0A=
  {=0A=
    if ( theOutput =3D=3D "__proto__" )=0A=
      return;=0A=
    =0A=
    // an instance of CSObjectCache=0A=
    this.data_ =3D theData;=0A=
    // the output-frame/layer=0A=
    this.output_ =3D theOutput || "top";=0A=
=0A=
    // need to hold the possible keys to be able=0A=
    // to delete non-existing keys=0A=
    this.res_keys_ =3D {sequencerow_footer: 1, =0A=
                     owner: 1,=0A=
                     time_modified: 1,=0A=
                     is_locked: 1,=0A=
                     is_checkedout: 1,=0A=
                     lock_author: 1,=0A=
                     lock_time: 1,=0A=
                     notes_count: 1,=0A=
                     notes_href: 1,=0A=
                     notes_onclick: 1,=0A=
                     collhead_count: 1,=0A=
                     collhead_href: 1,=0A=
                     collhead_onclick: 1=0A=
    };=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (CSFooter);=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * The method draws the footer into the defined document.=0A=
 *=0A=
 * @param anObj: String: the GOid fo the current object (may be =0A=
 *   collectionhead)=0A=
 * @param theData: Object: the key-value pairs holding the information =0A=
 *   to draw the footer=0A=
 * @param theTargetFrame: Object (optional): a target frame/window =
reference=0A=
 */=0A=
  class$.draw =3D function (anObj, theData, theTargetFrame)=0A=
  {=0A=
    // get output-document=0A=
    if (theTargetFrame) {=0A=
      var doc =3D theTargetFrame.document;=0A=
    }=0A=
    else {=0A=
      var doc =3D eval(this.output_+".document");=0A=
    }=0A=
    if (typeof doc =3D=3D "undefined") {=0A=
      return;=0A=
    }=0A=
=0A=
    var footer_obj =3D this.data_.getObject(anObj);=0A=
    if (footer_obj) {=0A=
      =
top.csfooter_res.setRes("obj_infoicon_src",cs_lib_getInfoIcon(footer_obj)=
);=0A=
      =
top.csfooter_res.setRes("obj_infoicon_onclick",cs_lib_getInfoIcon_onClick=
(footer_obj)); =0A=
    }=0A=
    else {=0A=
      // for insurance=0A=
      top.csfooter_res.setRes("obj_infoicon_src","");=0A=
      top.csfooter_res.setRes("obj_infoicon_onclick",""); =0A=
    }=0A=
      top.csfooter_res.setRes("HW_ui_stylePath",top.gUIStylePath); =0A=
=0A=
    // set resource variables=0A=
    for (var entry in this.res_keys_) {=0A=
      if (typeof theData[entry] !=3D "undefined") {=0A=
        top.csfooter_res.setRes(entry, theData[entry]);=0A=
      }=0A=
      else {=0A=
        top.csfooter_res.setRes(entry, "");=0A=
      }=0A=
    }=0A=
=0A=
    =
top.FrameSetMediator.static_.getInstance().setInfoHtml(top.csfooter_res.t=
oString(true),=0A=
                                                           =
top.FrameSetMediator.static_.FOOTER,=0A=
                                                           =
top.FrameSetMediator.static_.CENTER);=0A=
  };=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Fcomponents%2Fstandardpage%2Fhtmlres%2Fcsfooter.%25style%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'main': new =
com.hyperwave.res.Template({ templateString_: '($#if =
$sequencerow_footer)($sequencerow_footer)($#endif)\n\x3cdiv =
class=3D\"DisplayAreaFooter\">\x3cspan>\n   ($owner_txt): ($owner) =
=E2=80=A2\n   ($time_modified_txt): ($time_modified)\n   ($#if =
$collhead_count)\n      \x3cbr />\n      ($notes_txt):\n      ($#if =
$notes_count)\n        ($notes_1):\n        \x3ca =
href=3D\"($notes_href)\"($#if $notes_onclick) =
onclick=3D\"($notes_onclick)\"($#endif)>($show_txt)\x3c/a>\n        =
($#if $collhead_count) =E2=80=A2 ($#endif)\n      ($#endif)\n      ($#if =
$collhead_count)\n        ($notes_2):\n        \x3ca =
href=3D\"($collhead_href)\"($#if $collhead_onclick) =
onclick=3D\"($collhead_onclick)\"($#endif)>($show_txt)\x3c/a>\n      =
($#endif)\n   ($#else)\n      ($#if $notes_count)\n        ($#if =
$notes_count=3D=3D1)\n          =E2=80=A2 ($notes_3): \n        =
($#else)\n          =E2=80=A2 ($notes_4): \n        ($#endif)\n        =
\x3ca href=3D\"($notes_href)\"($#if $notes_onclick) =
onclick=3D\"($notes_onclick)\"($#endif)>($show_txt)\x3c/a>\n      =
($#endif)\n   ($#endif)\n   ($#if $is_locked)\n      =E2=80=A2\n      =
($#if $is_checkedout)\n        ($checked_out_txt)\n      ($#else)\n      =
  ($locked_txt)\n      ($#endif)\n   ($#endif)\n\x3c/span>\x3c/div>'})});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/components/s=
tandardpage/htmlres/csfooter.%style%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/hw_temporary_objects;
	internal&action=js.execute.action&Parameter=%23%28UIClass%3Acom.hyperwave.util.IncludeManager%29%28Method%3Astatic_.getResource%29&file=%25vd%25%2Fcomponents%2Fstandardpage%2Flangres%2Ffooter_txt.%25lang%25.xml&cachekeY=515488b2-en

com.hyperwave.util.IncludeManager.static_.lastIncluded_ =3D function =
(name) {=0A=
  if (!arguments.callee.cache_)=0A=
    arguments.callee.cache_ =3D new =
com.hyperwave.res.CSResourceReader({'checked_out_txt': new =
com.hyperwave.res.Template({ templateString_: =
'\x3cB>($lock_author)\x3c/B> has checked out the document at =
\x3cB>($lock_time)\x3c/B>.'}), 'locked_txt': new =
com.hyperwave.res.Template({ templateString_: 'It has been =
\x3cB>locked\x3c/B> by \x3cB>($lock_author)\x3c/B> at =
\x3cB>($lock_time)\x3c/B>.'}), 'notes_1': new =
com.hyperwave.res.Template({ templateString_: =
'\x3cB>($notes_count)\x3c/B> attached to this object'}), 'notes_2': new =
com.hyperwave.res.Template({ templateString_: =
'\x3cB>($collhead_count)\x3c/B> attached to the Collection head'}), =
'notes_3': 'There is a \x3cB>note\x3c/B> attached', 'notes_4': new =
com.hyperwave.res.Template({ templateString_: 'There are =
\x3cB>($notes_count) notes\x3c/B> attached'}), 'notes_txt': 'Notes', =
'owner_txt': 'Owner', 'show_txt': 'Show', 'time_modified_txt': 'Last =
modified'});=0A=
  return name ? arguments.callee.cache_.getRes(name) : =
arguments.callee.cache_;=0A=
}=0A=
com.hyperwave.util.IncludeManager.static_._setResource("%vd%/components/s=
tandardpage/langres/footer_txt.%lang%.xml", =
com.hyperwave.util.IncludeManager.static_.lastIncluded_);=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/hw_swapimages.js?cachekeY=515488b2-en

function hw_swapImgRestore(){=0A=
var i,x,a=3Ddocument.hwsi;=0A=
for(i=3D0;a&&i<a.length&&(x=3Da[i])&&x.ois;i++)x.src=3Dx.ois;}=0A=
=0A=
function hw_preloadImages(){=0A=
var d=3Ddocument;  =0A=
if(d.images){if(!d.hwImgs) d.hwImgs =3D new Array();=0A=
var i,j=3Dd.hwImgs.length,a=3Dhw_preloadImages.arguments; =0A=
for(i=3D0;i<a.length;i++) if(a[i].indexOf("#")!=3D0){d.hwImgs[j]=3Dnew =
Image;d.hwImgs[j++].src=3Da[i];}}}=0A=
=0A=
function hw_findObj(n,d){=0A=
var p,i,x;if(!d) d=3Ddocument;=0A=
if((p=3Dn.indexOf("?"))>0&&parent.frames.length) =
{d=3Dparent.frames[n.substring(p+1)].document;n=3Dn.substring(0,p);}=0A=
if(!(x=3Dd[n])&&d.all) x=3Dd.all[n];=0A=
for(i=3D0;!x&&i<d.forms.length;i++) x=3Dd.forms[i][n];=0A=
for(i=3D0;!x&&d.layers&&i<d.layers.length;i++) =
x=3Dhw_findObj(n,d.layers[i].document);=0A=
if(!x && document.getElementById) x=3Ddocument.getElementById(n);=0A=
return x;=0A=
}=0A=
=0A=
function hw_swapImage(img,nis){=0A=
var j=3D0,x;document.hwsi=3Dnew Array;=0A=
if((x=3Dhw_findObj(img))!=3Dnull){document.hwsi[j++]=3Dx;if(!x.ois) =
x.ois=3Dx.src;x.src=3Dnis;}=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/CSFormData.js?cachekeY=515488b2-en

function CSFormData(str)=0A=
{=0A=
  this.data_ =3D new ParameterHandler(str);=0A=
  this.version_ =3D this.data_.getVersion();=0A=
}=0A=
=0A=
CSFormData.prototype.asString =3D function ()=0A=
{=0A=
  return this.data_.asString();=0A=
}=0A=
=0A=
CSFormData.prototype.restoreForm =3D function (form)=0A=
{=0A=
  var elems =3D form.elements;=0A=
  for (var i =3D 0; i < elems.length; i ++)=0A=
  {=0A=
    this.restoreFormElement(elems[i]);=0A=
  }=0A=
}=0A=
=0A=
CSFormData.prototype.restoreFormElement =3D function (elem)=0A=
{=0A=
  var data =3D this.data_;=0A=
  =0A=
  var type =3D elem.type; // form element type=0A=
  var name =3D elem.name; // form element name=0A=
  if (type =3D=3D 'password' || type =3D=3D 'text' || type =3D=3D =
'textarea')=0A=
  { // simple text fields=0A=
    elem.value =3D data.get(name)[0] || '';=0A=
  }=0A=
  else if (type =3D=3D 'checkbox' || type =3D=3D 'radio')=0A=
  { // checkboxes or radios=0A=
    if (data.isIndexOf(name, elem.value))=0A=
    {=0A=
      elem.checked =3D true;=0A=
    }=0A=
    else=0A=
    {=0A=
      elem.checked =3D false;=0A=
    }=0A=
  }=0A=
  else if (type =3D=3D 'select-one' || type =3D=3D 'select-multiple')=0A=
  { // select lists=0A=
    var options =3D elem.options;=0A=
    var is_single =3D type =3D=3D 'select-one';=0A=
    var full_info =3D data.get(name + "_full_restore_informations_");=0A=
    if (full_info.length)=0A=
    {=0A=
      options.length =3D 0;=0A=
      for (var i =3D 0; i < full_info.length; i ++)=0A=
      {=0A=
        var vals =3D full_info[i].split('&');=0A=
        if (this.version_ =3D=3D 1) {=0A=
          options[i] =3D new Option(unescape(vals[0]), =
unescape(vals[1]), vals[2] =3D=3D "true", vals[3] =3D=3D "true");=0A=
        }=0A=
        else {=0A=
          options[i] =3D new Option(decodeURIComponent(vals[0]), =
decodeURIComponent(vals[1]), vals[2] =3D=3D "true", vals[3] =3D=3D =
"true");=0A=
        }=0A=
      }=0A=
    }=0A=
=0A=
    for (var i =3D 0; i < options.length; i ++)=0A=
    {=0A=
      var curr_value =3D options[i].value;=0A=
      if (data.isIndexOf(name, curr_value))=0A=
      {=0A=
        options[i].selected =3D true;=0A=
        if (is_single)=0A=
        { // in case of select one fields we can stop now=0A=
          break;=0A=
        }=0A=
      }=0A=
      else if (!is_single)=0A=
      { // if it's single select -> don't deselect options=0A=
        options[i].selected =3D false;=0A=
      }=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
CSFormData.prototype.readForm =3D function (form, aParam)=0A=
{=0A=
  var data =3D this.data_;=0A=
  var elems =3D form.elements;=0A=
  for (var i =3D 0; i < elems.length; i ++)=0A=
  {=0A=
    if (elems[i].name.indexOf('HW_Hidden'))=0A=
    { // element will be ignored if indexOf('HW_Hidden') is 0=0A=
      this.readFormElement(elems[i], aParam);=0A=
    }=0A=
  }=0A=
  return data.asString();=0A=
}=0A=
=0A=
CSFormData.prototype.readFormElement =3D function (elem, aParam)=0A=
{=0A=
  var pars =3D aParam || {};=0A=
  var full_info_for =3D pars.storeFullList || {};=0A=
  var store_hidden =3D pars.storeHiddenFields || false;=0A=
  var data =3D this.data_;=0A=
=0A=
  var name  =3D elem.name; // element name=0A=
  var type  =3D elem.type; // element type=0A=
  if (((type =3D=3D 'hidden' && store_hidden) || type =3D=3D 'password' =
|| type =3D=3D 'text' || type =3D=3D 'textarea') && (elem.value !=3D ''))=0A=
  { // simple text fields=0A=
    data.add(name, elem.value);=0A=
  }=0A=
  else if ((type =3D=3D 'checkbox' || type =3D=3D 'radio') && =
elem.checked)=0A=
  { // checkboxes or radios=0A=
    data.add(name, elem.value);=0A=
  }=0A=
  else if (type =3D=3D 'select-one' || type =3D=3D 'select-multiple')=0A=
  { // select lists=0A=
    var options =3D elem.options;=0A=
    var is_single =3D type =3D=3D 'select-one';=0A=
    for (var i =3D 0; i < options.length; i ++)=0A=
    {=0A=
      if (options[i].selected)=0A=
      {=0A=
        data.add(name, options[i].value);=0A=
        if (is_single)=0A=
        { // in case of select one fields we can stop now=0A=
          break;=0A=
        }=0A=
      }=0A=
    }=0A=
  }=0A=
  // special handling for local search scopes=0A=
  if (full_info_for[elem.name] && (type =3D=3D 'select-one' || type =
=3D=3D 'select-multiple'))=0A=
  {=0A=
    var options =3D elem.options;=0A=
    for (var i =3D 0; i < options.length; i ++)=0A=
    {=0A=
      if (this.version_ =3D=3D 1) {=0A=
        data.add(elem.name + '_full_restore_informations_', =
escape(options[i].text) + "&" + escape(options[i].value) + "&" + =
options[i].defaultSelected + "&" + options[i].selected);=0A=
      }=0A=
      else {=0A=
        data.add(elem.name + '_full_restore_informations_', =
encodeURIComponent(options[i].text) + "&" + =
encodeURIComponent(options[i].value) + "&" + options[i].defaultSelected =
+ "&" + options[i].selected);=0A=
      }=0A=
    }=0A=
  }=0A=
}=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/lib/ParameterHandler.js?cachekeY=515488b2-en

// initPackage (###PACKAGE###);=0A=
=0A=
//--------------------------------------------------------------------=0A=
/** =0A=
 * This class handles parameters in form of key value(s) pairs.=0A=
 * "(key1:value1)(key2:value2,value3)..."=0A=
 * List of methods:=0A=
 *  asObject()=0A=
 *  asSimpleObject() -> shortcut for asObject({reduce: true})=0A=
 *  asString()=0A=
 *  toString()=0A=
 *  add()=0A=
 *  get()=0A=
 *  getLength()=0A=
 *  remove()=0A=
 *  reset()=0A=
 *  isIndexOf()=0A=
 *  getVersion()=0A=
 *  =0A=
 * @author sweber=0A=
 */=0A=
// <JSClass Name=3D"ParameterHandler">=0A=
=0A=
  /**=0A=
   * The ParameterHandler constructor.=0A=
   *=0A=
   * @param aParam: string: The parameter string.=0A=
   */=0A=
  function ParameterHandler (aParam)=0A=
  {=0A=
    if ( aParam =3D=3D=3D "__proto__" )=0A=
      return;=0A=
=0A=
    this.data_ =3D {};=0A=
    // default version is 2, because of the encodeURIComponent stuff=0A=
    this.version_ =3D 2;=0A=
    if (typeof aParam =3D=3D 'undefined' || aParam =3D=3D "")=0A=
    {=0A=
      return;=0A=
    }=0A=
=0A=
    if (typeof aParam =3D=3D "object") {=0A=
      for (var i in aParam) {=0A=
        var key =3D i;=0A=
        var value =3D aParam[i];=0A=
        if (typeof value =3D=3D "object") {=0A=
          this.data_[key] =3D [];=0A=
          // value should be a string array=0A=
          for (var ctr =3D 0; ctr < value.length; ctr ++) {=0A=
            this.data_[key][ctr] =3D value[ctr] + "";=0A=
          }=0A=
        }=0A=
        else {=0A=
          this.data_[key] =3D [value + ""];=0A=
        }=0A=
      }=0A=
      return;=0A=
    }=0A=
=0A=
    var str =3D aParam.substring((idx =3D aParam.indexOf('(')), =
aParam.lastIndexOf(')') + 1);=0A=
    if (str.length < 2)=0A=
    {=0A=
      return;=0A=
    }=0A=
    var arr =3D str.substring(1, str.length - 1).split(')(');=0A=
    for (var i =3D 0; i < arr.length; i ++)=0A=
    {=0A=
      var temp =3D arr[i].split(':');=0A=
      if (temp.length < 2)=0A=
      {=0A=
        continue;=0A=
      }=0A=
      var key =3D this._decodePart(temp[0]);=0A=
      if (temp[1] =3D=3D '')=0A=
      {=0A=
        var vals =3D [];=0A=
      }=0A=
      else=0A=
      {=0A=
        var vals =3D temp[1].split(',');=0A=
        for (var j =3D 0; j < vals.length; j ++)=0A=
        {=0A=
          vals[j] =3D this._decodePart(vals[j]);=0A=
        }=0A=
      }=0A=
      this.data_[key] =3D vals;=0A=
    }=0A=
  }=0A=
  //--------------------------------------------------------------------=0A=
  // Inheritance call for JavaScript.=0A=
  class$ =3D doInherit (ParameterHandler);=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method returns a java script object including all key value(s) =
pairs.=0A=
   * The value(s) type is an array. Empty keys will be returned as an =
empty array.=0A=
   * A single value will be returned as an array with the length 1.=0A=
   *=0A=
   * @param aParams: object: additional parameters=0A=
   * @param aParams.reduce: boolean: If true, all empty keys will be =
ignored in=0A=
   *        the returned object and keys with the length 1 will be =
transformed=0A=
   *        to strings.=0A=
   * @param aParams.omitDisabled: boolean: Special Default dialog switch.=0A=
   *        If true, all elements disabled in default dialog will be =
truncated.=0A=
   *=0A=
   * @return object: The key value(s) pairs java script object.=0A=
   * e.g.=0A=
   * {key1: [value1], key2: [value2, value3]}=0A=
   */=0A=
  class$.asObject =3D function (aParams)=0A=
  {=0A=
    var p =3D aParams || {};=0A=
    var ret_obj =3D this.data_;=0A=
    if (p.omitDisabled) {=0A=
      var new_data =3D {};=0A=
      var maybe_inactive =3D [];=0A=
      var active =3D [];=0A=
      var state =3D {};=0A=
      for (var i in ret_obj) {=0A=
        // mark all fields as active=0A=
        state[i] =3D true;=0A=
        if (i.indexOf("dd_groupfields_") =3D=3D 0) {=0A=
          // this field(s) contains the information about the related =
(deactivateable) fields=0A=
          // this fields maybe inactive=0A=
          maybe_inactive =3D maybe_inactive.concat(ret_obj[i]);=0A=
          // mark myself as inactive=0A=
          state[i] =3D false;=0A=
        }=0A=
        if (i.indexOf("dd_group_") =3D=3D 0) {=0A=
          // this field contains the information about the activated =
fields=0A=
          // this fields are active (maybe separated by "|")=0A=
          var tmp_arr =3D ret_obj[i];=0A=
          for (var j =3D 0; j < tmp_arr.length; j ++) {=0A=
            active =3D active.concat(tmp_arr[j].split("|"));=0A=
          }=0A=
          // mark myself as inactive=0A=
          state[i] =3D false;=0A=
        }=0A=
      }=0A=
      for (var i =3D 0; i < maybe_inactive.length; i ++) {=0A=
        // mark "maybe inactive" fields as inactive=0A=
        state[maybe_inactive[i]] =3D false;=0A=
      }=0A=
      for (var i =3D 0; i < active.length; i ++) {=0A=
        // mark "active" fields as active=0A=
        state[active[i]] =3D true;=0A=
      }=0A=
      for (var i in ret_obj) {=0A=
        if (state[i]) {=0A=
          new_data[i] =3D ret_obj[i];=0A=
        }=0A=
      }=0A=
      ret_obj =3D new_data;=0A=
    }=0A=
    if (p.reduce)=0A=
    {=0A=
      var new_data =3D {};=0A=
      for (var i in ret_obj)=0A=
      {=0A=
        if (ret_obj[i].length =3D=3D 0)=0A=
          continue;=0A=
        else if (ret_obj[i].length =3D=3D 1)=0A=
          new_data[i] =3D ret_obj[i].toString();=0A=
        else=0A=
          new_data[i] =3D ret_obj[i];=0A=
      }=0A=
      ret_obj =3D new_data;=0A=
    }=0A=
    return ret_obj;=0A=
  }=0A=
=0A=
  /**=0A=
   * @see: #ParameterHandler.asObject=0A=
   */=0A=
  class$.asSimpleObject =3D function (aParams)=0A=
  {=0A=
    aParams =3D aParams || {};=0A=
    aParams.reduce =3D true;=0A=
    return this.asObject(aParams);=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method returnes the key value(s) pairs string.=0A=
   * "(key1:value1)(key2:value2,value3)"=0A=
   *=0A=
   * @ return string: String including the key value(s) pairs.=0A=
   */=0A=
  class$.asString =3D function ()=0A=
  {=0A=
    var ret =3D [];=0A=
    for (var i in this.data_)=0A=
    {=0A=
      if (this.data_[i].length)=0A=
      {=0A=
        var vals =3D [];=0A=
        for (var j =3D 0; j < this.data_[i].length; j ++)=0A=
        {=0A=
          vals[vals.length] =3D this._encodePart(this.data_[i][j]);=0A=
        }=0A=
        ret[ret.length] =3D '(' + this._encodePart(i) + ':' + vals + ')';=0A=
      }=0A=
      else=0A=
      {=0A=
        ret[ret.length] =3D '(' + this._encodePart(i) + ':)';=0A=
      }=0A=
    }=0A=
    return /*"[v2]" + */ret.join('');=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This returnes the key value(s) pairs string as action parameter if =
there are=0A=
   * keys and values.=0A=
   * It can be used building a new url.=0A=
   * e.g.=0A=
   * var parameters =3D new ParameterHandler(the_String);=0A=
   * [...]=0A=
   * var url =3D the_url + ";internal&action=3Dxyz" + parameters;=0A=
   *=0A=
   * @ return string: String including "&Parameter=3D" + the key values =
as string.=0A=
   */=0A=
  class$.toString =3D function ()=0A=
  {=0A=
    var str =3D this.asString();=0A=
    if (str =3D=3D '')=0A=
    {=0A=
      return '';=0A=
    }=0A=
    return '&Parameter=3D' + encodeURIComponent(str);=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method returnes a pointer to a key. If the key doesn't exist =
at this time,=0A=
   * a new empty key will be created.=0A=
   *=0A=
   * @param name: string: Name of the key=0A=
   */=0A=
  class$.getPtr =3D function (name)=0A=
  {=0A=
    if (typeof this.data_[name] =3D=3D 'undefined')=0A=
    {=0A=
      this.data_[name] =3D [];=0A=
    }=0A=
    return this.data_[name];=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method add a new key or add value(s) to an existing key.=0A=
   *=0A=
   * @param name: string: Name of the key.=0A=
   * @param value: string|array: The new value(s) to add.=0A=
   *=0A=
   * @return string|array|boolean: If adding was successful the added =
value(s) will be returned. If not false.=0A=
   */=0A=
  class$.add =3D function (name, value)=0A=
  {=0A=
    var ptr =3D this.getPtr(name);=0A=
    if (typeof value =3D=3D 'undefined')=0A=
    {=0A=
      return false;=0A=
    }=0A=
    if (typeof value =3D=3D 'string')=0A=
    {=0A=
      ptr[ptr.length] =3D value;=0A=
    }=0A=
    else if (typeof value =3D=3D 'number')=0A=
    {=0A=
      ptr[ptr.length] =3D value.toString();=0A=
    }=0A=
    else if (value.length)=0A=
    {=0A=
      for (var i =3D 0; i < value.length; i ++)=0A=
      {=0A=
        ptr[ptr.length] =3D value[i];=0A=
      }=0A=
    }=0A=
    else=0A=
    {=0A=
      return false;=0A=
    }=0A=
    return value;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method returnes values of a given key.=0A=
   * By default all keys will be returned as array.=0A=
   * Optional a start and end index can be declared.=0A=
   * Negativ indices are allowed and will be handled from the end of the =
values.=0A=
   *=0A=
   * @param name: string: Name of the key.=0A=
   * @param start: number: The start index.=0A=
   * @param end: number: The end index.=0A=
   */=0A=
  class$.get =3D function (name, start, end)=0A=
  {=0A=
    var ptr =3D this.getPtr(name);=0A=
    if (!ptr.length)=0A=
    {=0A=
      return ptr;=0A=
    }=0A=
    if (typeof start =3D=3D 'undefined' || typeof start !=3D 'number')=0A=
    {=0A=
      var start =3D 0;=0A=
    }=0A=
    if (typeof end =3D=3D 'undefined' || typeof end !=3D 'number')=0A=
    {=0A=
      var end =3D ptr.length;=0A=
    }=0A=
    if (start < 0)=0A=
    {=0A=
      start +=3D ptr.length;=0A=
    }=0A=
    if (end < 0)=0A=
    {=0A=
      end +=3D ptr.length;=0A=
    }=0A=
    return ptr.slice(start, end);=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method return the length of a given entry.=0A=
   *=0A=
   * @param name: string: Name of the key.=0A=
   *=0A=
   * @return number: The length of the given entry.=0A=
   */=0A=
  class$.getLength =3D function (name)=0A=
  {=0A=
    var ptr =3D this.getPtr(name);=0A=
    return ptr.length;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method get and remove values from a given key.=0A=
   * By default the last value will be returned and remove.=0A=
   * The number of the values to be returned and remove can be declared.=0A=
   *=0A=
   * @param name: string: The name of the key.=0A=
   * @param length: number(1): The number of values to get and remove.=0A=
   *=0A=
   * @return array: The removed values.=0A=
   */=0A=
  class$.remove =3D function (name, length)=0A=
  {=0A=
    var ptr =3D this.getPtr(name);=0A=
    if (typeof length =3D=3D 'undefined' || typeof length !=3D 'number')=0A=
    {=0A=
      var length =3D 1;=0A=
    }=0A=
    if (length =3D=3D -1)=0A=
    {=0A=
      length =3D ptr.length;=0A=
    }=0A=
    var pos =3D ptr.length - length;=0A=
    var extract =3D this.get(name, pos);=0A=
    this.reset(name, ptr.slice(0, pos));=0A=
    return extract;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * This method overwrite all values of a given key.=0A=
   *=0A=
   * @param name: string: The name of the key.=0A=
   * @param values: string|array: The new value(s) of the declared key.=0A=
   */=0A=
  class$.reset =3D function (name, values)=0A=
  {=0A=
    var ptr =3D this.getPtr(name);=0A=
    ptr.length =3D 0;=0A=
    this.add(name, values);=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * ###METHOD DESCRIPTION###=0A=
   *=0A=
   * @param name: string: ###PARAMETER DESCRIPTION###=0A=
   * @param value: string: ###PARAMETER DESCRIPTION###=0A=
   * @return boolean: ###PARAMETER DESCRIPTION###=0A=
   */=0A=
  class$.isIndexOf =3D function (name, value)=0A=
  {=0A=
    var arr =3D this.get(name);=0A=
    for (var i =3D 0; i < arr.length; i++)=0A=
    {=0A=
      if (arr[i] =3D=3D value)=0A=
      {=0A=
        return true;=0A=
      }=0A=
    }=0A=
    return false;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * return version of parameter handler string=0A=
   *=0A=
   * @return number: version number=0A=
   */=0A=
  class$.getVersion =3D function ()=0A=
  {=0A=
    return this.version_;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Tries to decode a substring of the parameter string. If =
decodeURIComponent isn't=0A=
   * successfully, the version is switched to the older ones and =
unescape is used.=0A=
   *=0A=
   * @param part: string: the substring=0A=
   * @return string: the decoded string=0A=
   */=0A=
  class$._decodePart =3D function (part)=0A=
  {=0A=
    var ret =3D "";=0A=
    if (this.version_ =3D=3D 1) {=0A=
      ret =3D unescape(part);=0A=
    }=0A=
    else {=0A=
      try {=0A=
        ret =3D decodeURIComponent(part);=0A=
      }=0A=
      catch (exc) {=0A=
        this.version_ =3D 1;=0A=
        ret =3D unescape(part);=0A=
      }=0A=
    }=0A=
    return ret;=0A=
  }=0A=
=0A=
  //--------------------------------------------------------------------=0A=
  /**=0A=
   * Encodes a substring of the parameters string.=0A=
   *=0A=
   * @param part: string: string to encode=0A=
   * @return string: the encoded string=0A=
   */=0A=
  class$._encodePart =3D function (part)=0A=
  {=0A=
    return encodeURIComponent(part).replace(/\(/g, "%28").replace(/\)/g, =
"%29");=0A=
  }=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/search/code/CSSearch.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        CSSearch.js=0A=
 *  Created:     2003-01-28 by sweber=0A=
 *  Description: client side java script for handling some search actions=0A=
 *=0A=
 *  $Id: CSSearch.js 158904 2010-10-07 09:25:49Z jschipf $=0A=
 * </file>=0A=
 */=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function returns the url from the HW_MainframeUrl cookie=0A=
 * (as fallback, the current window pathname will be used)=0A=
 *=0A=
 * @return string: path for opening windows/locations=0A=
 */=0A=
function getCurrPath()=0A=
{=0A=
  var path =3D "/";=0A=
  var frameset =3D false;=0A=
  try {=0A=
    var win =3D window;=0A=
    if (top.HW_Mainframe) {=0A=
      win =3D top.HW_Mainframe;=0A=
      frameset =3D true;=0A=
    }=0A=
    path =3D win.location.pathname;=0A=
=0A=
    if (frameset) {=0A=
      // in case of main frameset, try to get the url from the global =
var out of the main frame=0A=
      // normaly this fails in case of generic documents -> see above =
... get it from location.pathname=0A=
      try {=0A=
        if (win.gCurrentUrl) {=0A=
          path =3D win.gCurrentUrl;=0A=
        }=0A=
      } catch (e2) { }=0A=
      =0A=
    }=0A=
  }=0A=
  catch (e) {=0A=
    path =3D getCookie("HW_MainframeUrl") || "/";=0A=
  }=0A=
=0A=
  //path =3D path.match(/^(.*?)[\;\?\#].*$/) ? RegExp.$1 : path; // =
normally i would use this regexp,=0A=
                                                               // but it =
doesn't work in mac ie 5.2=0A=
                                                               // =
HWIS/PR-4790=0A=
  path =3D path.match(/^([^\;\?\#]*)[\;\?\#].*$/) ? RegExp.$1 : path;=0A=
  path =3D path || "/";=0A=
  return path;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function is called on submit of search form in userblock=0A=
 * on success, the form should be submitted=0A=
 * this function needs a client side variable=0A=
 *   ~ window.search_alert1 =3D> message should be shown, if no search =
string is entered=0A=
 *=0A=
 * @param theForm: object: reference to the current formular=0A=
 * @param anUrl: string: the url that should be used to submit the search=0A=
 * @return boolean: success or not, submit formular or not=0A=
 */=0A=
function performSearch (theForm, anUrl) {=0A=
  if (!theForm.searchstring.value || =
theForm.searchstring.value.match(/(^[^\*]{0,2}[\*]+$)|(^[\*]+[^\*]{0,2}$)=
|(^[\*]+[^\*]{0,2}[\*]+$)|(^ *\* +)|( \* *$)/)) {=0A=
    // invalid search string is given -> alert the user=0A=
    alert(window.search_alert5);=0A=
    theForm.searchstring.select();=0A=
    theForm.searchstring.focus();=0A=
    return false;=0A=
  }=0A=
  else {=0A=
    // a search string is given=0A=
    // prepare the search parameter=0A=
    var search_pars =3D new ParameterHandler();=0A=
    search_pars.add('Caller', 'UserBlock');=0A=
    // open a dialog window=0A=
    var window_obj =3D =
opDlg("/wavemaster.internal/webapp/lib/empty.html", "search",{height: =
700, width: 1000});=0A=
    // set the formular target to the dialog window=0A=
    if (window_obj && window_obj.name)=0A=
      theForm.target =3D window_obj.name;=0A=
=0A=
    var current_url =3D getCurrPath();=0A=
    if (theForm.original_scope_value) {=0A=
      // restore a possible original scope value=0A=
      theForm.default_scope.value =3D theForm.original_scope_value;=0A=
    }=0A=
    else {=0A=
      // save the initial/original scope value=0A=
      // necessary for value "wholeserver" and "localcollection"=0A=
      theForm.original_scope_value =3D theForm.default_scope.value;=0A=
    }=0A=
    if (theForm.default_scope.value =3D=3D "wholeserver") {=0A=
      theForm.default_scope.value =3D theForm.entire_server_scope.value;=0A=
    }=0A=
    else if (theForm.default_scope.value =3D=3D "localcollection") {=0A=
      theForm.default_scope.value =3D "collection:" + =
decodeURIComponent(current_url);=0A=
    }=0A=
    if (!anUrl) {=0A=
      theForm.action =3D current_url + =
";internal&action=3Dexecute.search.action" + search_pars;=0A=
    }=0A=
    else {=0A=
      theForm.action =3D anUrl;=0A=
    }=0A=
    var form_info =3D new CSFormData();=0A=
    form_info.readForm(theForm, {storeHiddenFields: true});=0A=
    theForm.HW_HiddenFormData.value =3D form_info.asString();=0A=
    return true;=0A=
  }=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * opens the advanced search dialog in a dialog window named "search"=0A=
 * this function is called on click of "advanced search link"=0A=
 *=0A=
 * @param aSearchString: string: the search string=0A=
 * @param anUrl: string: the url that should be used to submit the search=0A=
 * @return boolean: should the current link followed or not=0A=
 */=0A=
function performAdvancedSearch(aSearchString, anUrl) {=0A=
  if (!anUrl) {=0A=
    var params =3D new ParameterHandler();=0A=
    params.add("SearchString", aSearchString);=0A=
    opDlg(getCurrPath() + ';internal&action=3Ddialog.search.action' + =
params, 'search');=0A=
  }=0A=
  else {=0A=
    opDlg(anUrl, 'search');=0A=
  }=0A=
  return false; // do not follow the links=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * perform the current window to show all found expert documents of a =
given user=0A=
 * (executes a search with search string and given owner)=0A=
 *=0A=
 * @param theAuthor: string: the username for who the 'expert documents' =
should be shown=0A=
 */=0A=
function findExpertPerformShowDocument(theAuthor) {=0A=
  var pars =3D new ParameterHandler();=0A=
  pars.add("Caller", "FindExpert");=0A=
  pars.add("Author", theAuthor);=0A=
  pars.add("HistoryLength", 1);=0A=
  pars.add("SearchString", document.bodyform.searchstring.value);=0A=
  window.location.pathname =3D getCurrPath() + =
";internal&action=3Dexecute.search.action" + pars;=0A=
  return false;=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function should be call on submit, it return true|false=0A=
 * this function needs 2 client side variables=0A=
 *   ~ window.search_engine =3D> name of the search engine=0A=
 *   ~ window.search_alert2 =3D> message for an invalid search string=0A=
 *=0A=
 * @param theSearchString: string: the search string=0A=
 * @param theSearchType: string: the type of search ("defaultSearch", =
"findExpert", maybe more)=0A=
 * @return boolean: is the search string valid or not=0A=
 */=0A=
function confirmSearchString(theSearchString, theSearchType) {=0A=
  if (theSearchType =3D=3D "defaultSearch") {=0A=
    return true;=0A=
  }=0A=
  else if (theSearchType =3D=3D "findExpert") {=0A=
    return true;=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
//--> eCS 1.5=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function switches to findExpertSendMultipleMail resp.=0A=
 * contacteCSMultiple=0A=
 *=0A=
 * @param theFormName: object: the dialog formular=0A=
 * @param theCoice: 1=3DeMail 2=3DeCS=0A=
 */=0A=
function contactMultiple(theFormName, theChoice)=0A=
{=0A=
  switch (theChoice) {=0A=
    case "1":=0A=
      findExpertSendMultipleMail(theFormName);=0A=
      break;=0A=
    case "2":=0A=
      contacteCSMultiple(theFormName);=0A=
      break;=0A=
  }=0A=
}=0A=
=0A=
=0A=
/*=0A=
 * this function performs an eCS-invitation with multiple invitees=0A=
 * this function needs 1 client side variable=0A=
 *   ~ window.search_alerteCS =3D>=0A=
 *=0A=
 * @param theForm: object: the dialog formular=0A=
 */=0A=
=0A=
function contacteCSMultiple (theFormName)=0A=
{=0A=
  var elements =3D document[theFormName].elements;=0A=
  var ecs =3D {};=0A=
  for (var id=3D0; id<elements.length;id++) {=0A=
    var elem =3D elements[id];=0A=
    if (elem.type=3D=3D"checkbox" && elem.checked && =
elem.name.substr(0,4)=3D=3D"mail" && elem.name.indexOf("_")!=3D-1) {=0A=
      =
ecs[decodeURIComponent(elem.name.substring(elem.name.indexOf("_")+1))] =
=3D true;=0A=
    }=0A=
  }=0A=
  var users_arr =3D [];=0A=
// --> eCS 1.5=0A=
  for (var entry in ecs)=0A=
    users_arr[users_arr.length] =3D entry;=0A=
=0A=
  if (users_arr.length>0)=0A=
    =
window.location.href=3D"/;internal&action=3Ddialog.ecs_new_session.action=
&users=3D" + encodeURIComponent(users_arr.join(";"));=0A=
  else=0A=
    alert(window.search_alerteCS);=0A=
}=0A=
=0A=
=0A=
//<-- eCS=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function force the browser to open the mailto: dialog with =
multiple emails=0A=
 * this function needs 1 client side wariable=0A=
 *   ~ window.search_alert3 =3D>=0A=
 *=0A=
 * @param theForm: object: the dialog formular=0A=
 */=0A=
function findExpertSendMultipleMail (theFormName)=0A=
{=0A=
  var elements =3D document[theFormName].elements;=0A=
  var contacts =3D {};=0A=
  for (var id=3D0; id<elements.length;id++) {=0A=
    var elem =3D elements[id];=0A=
    if (elem.type=3D=3D"checkbox" && elem.checked && =
elem.name.substr(0,4)=3D=3D"mail") {=0A=
// --> eCS 1.5=0A=
      if (elem.value)=0A=
        contacts[elem.value] =3D true;=0A=
// <-- eCS=0A=
    }=0A=
  }=0A=
  var users_arr =3D [];=0A=
  for (var entry in contacts)=0A=
    users_arr[users_arr.length] =3D entry;=0A=
  if (users_arr.length>0) {=0A=
    com.hyperwave.util.CSMailTo.static_.openMailClient(users_arr);=0A=
  }=0A=
  else=0A=
    alert(window.search_alert3);=0A=
}=0A=
=0A=
=0A=
/*=0A=
 * this function checks the listing collects entries from an external =
index.=0A=
 *=0A=
 * @return boolean: true -> listing has a selected entry from external =
index=0A=
 */=0A=
function isExternalObjectSelected()=0A=
{=0A=
  var theForm =3D getForm("bodyform");=0A=
  for(i =3D 0; i < theForm.length; i++)=0A=
  {=0A=
    var ename=3DtheForm.elements[i].name;=0A=
    if (theForm.elements[i].checked =3D=3D true && ename.substring(0,8) =
=3D=3D "initname")=0A=
    {=0A=
      var value =3D theForm.elements[i].value;=0A=
      if (value.indexOf("0x00000000") !=3D -1)=0A=
      {=0A=
        return true;=0A=
      }=0A=
    }=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
/*=0A=
 * this function needs 2 client side variables=0A=
 *   ~ window.search_alert4 =3D> alert message to remind user to select =
an operation=0A=
 *   ~ window.search_alert_extObjects =3D> alert message to advice the =
user that operateion on external objects are not allowed=0A=
 */=0A=
function executeAction(theType, args) {=0A=
  // case for creating an agent is clicked=0A=
  if (theType =3D=3D 'createagent') {=0A=
    var the_action =3D THE_OBJECT_URL + =
';internal&action=3Ddialog.saveagent.action';=0A=
    var the_target =3D 'createagent';=0A=
  }=0A=
  // case for creating a track is clicked=0A=
  else if (theType =3D=3D 'createtrack') {=0A=
    var the_action =3D THE_OBJECT_URL + =
';internal&action=3Ddialog.createQueryTrack.action';=0A=
    var the_target =3D 'createtrack';=0A=
  }=0A=
  // case for refining the query=0A=
  else if (theType =3D=3D 'refinequery') {=0A=
    freeIterator(document.bodyform.HW_HiddenIteratorId.value);=0A=
    var the_action =3D THE_OBJECT_URL + =
';internal&action=3Ddialog.search.action';=0A=
    document.bodyform.action=3Dthe_action;=0A=
    document.bodyform.submit();=0A=
    return false;=0A=
  }=0A=
  // case for find an expert=0A=
  else if (theType =3D=3D 'findexpert') {=0A=
    var win =3D opDlg(THE_OBJECT_URL + =
';internal&action=3Dsearch.findexpert.action?searchstring=3D' + =
encodeURIComponent(THE_SEARCHSTRING), 'findexpert');=0A=
    return false;=0A=
  }=0A=
  // case for changed number of results=0A=
  else if (theType =3D=3D 'changenumber') {=0A=
    document.bodyform.HW_HiddenEnv_Dir.value =3D "";=0A=
    document.bodyform.HW_HiddenEnv_MaxVisPage.value =3D "1";=0A=
    document.bodyform.HW_HiddenEnv_LastNavStart.value =3D "1";=0A=
    document.bodyform.HW_HiddenEnv_CurrentPage.value =3D "1";=0A=
=0A=
    var pars =3D new =
ParameterHandler(document.bodyform.HW_HiddenFormData.value);=0A=
    pars.reset(args.name, args.value);=0A=
    document.bodyform.HW_HiddenFormData.value =3D pars.asString();=0A=
    document.bodyform.submit();=0A=
    return false;=0A=
  }=0A=
  // case for change search description=0A=
  else if (theType =3D=3D 'changedescription') {=0A=
    try=0A=
    {=0A=
      var fw =3D hw.getFramework();=0A=
      var searchform =3D fw.getUIElement(fw.static_.SEARCHFORM);=0A=
=0A=
      if (searchform) {=0A=
        searchform.searchForm.search_description.value =3D args.value;=0A=
      }=0A=
    }=0A=
    catch (e)=0A=
    { // firefox may rise an exception in case the opener is not in the =
same domain=0A=
    }=0A=
    var pars =3D new =
ParameterHandler(document.bodyform.HW_HiddenFormData.value);=0A=
    pars.reset(args.name, args.value);=0A=
    document.bodyform.HW_HiddenFormData.value =3D pars.asString();=0A=
    document.bodyform.submit();=0A=
    return false;=0A=
  }=0A=
  // case for navigation around the search results=0A=
  else if (theType =3D=3D 'navigate') {=0A=
    document.bodyform.HW_HiddenEnv_Dir.value =3D args;=0A=
    document.bodyform.submit();=0A=
    return false;=0A=
  }=0A=
  // case for a selected operation=0A=
  else if (theType =3D=3D 'operation') {=0A=
    var selected_operation =3D args.form.operation.value; // possible =
values are ""|"move"|"copy"|"link"|"delete"|"bookmark"|"trainAgent"=0A=
    if (!selected_operation) {=0A=
      alert(window.search_alert4);=0A=
    }=0A=
    if (isExternalObjectSelected())=0A=
    {=0A=
      alert(window.search_alert_extObjects);=0A=
      return false;=0A=
    }=0A=
    if (selected_operation =3D=3D "move") {=0A=
      move("movesearch", {target: "choosetarget",=0A=
                          submit: false,=0A=
                          url: getCurrPath() + =
";internal&action=3Ddialog.choosetarget.action&Parameter=3Dmovesearch",=0A=
                          onsel: false});=0A=
    }=0A=
    else if (selected_operation =3D=3D "copy") {=0A=
      move("copysearch", {target: "choosetarget",=0A=
                          submit: false,=0A=
                          url: getCurrPath() + =
";internal&action=3Ddialog.choosetarget.action&Parameter=3Dcopysearch",=0A=
                          onsel: false});=0A=
    }=0A=
    else if (selected_operation =3D=3D "link") {=0A=
      move("linksearch", {target: "choosetarget",=0A=
                          submit: false,=0A=
                          url: getCurrPath() + =
";internal&action=3Ddialog.choosetarget.action&Parameter=3Dlinksearch",=0A=
                          onsel: false});=0A=
    }=0A=
    else if (selected_operation =3D=3D "delete") {=0A=
      submitform("deletesearch");=0A=
    }=0A=
    else if (selected_operation =3D=3D "bookmark") {=0A=
      move("", {target: "Portal_AddBookmarks",=0A=
                submit: false,=0A=
                url: getCurrPath() + =
";internal&action=3Ddialog.portal.addbookmarks.action",=0A=
                onsel: false});=0A=
    }=0A=
    else if (selected_operation =3D=3D "trainAgent") {=0A=
      move("", {target: "TrainAgents",=0A=
                url: trainAgentURL,=0A=
                submit: true});=0A=
    }=0A=
    return false;=0A=
  }=0A=
  else if (theType =3D=3D 'close') {=0A=
    freeIterator(document.bodyform.HW_HiddenIteratorId.value, true);=0A=
    return false;=0A=
  }=0A=
  else if (theType =3D=3D 'badclose') {=0A=
    freeIterator(document.bodyform.HW_HiddenIteratorId.value);=0A=
    return false;=0A=
  }=0A=
  else if (theType.match(/^sort/)) {=0A=
    var f =3D document.bodyform;=0A=
    f.HW_HiddenEnv_Dir.value =3D "";=0A=
    f.HW_HiddenEnv_MaxVisPage.value =3D "1";=0A=
    f.HW_HiddenEnv_LastNavStart.value =3D "1";=0A=
    f.HW_HiddenEnv_CurrentPage.value =3D "1";=0A=
    f.HW_HiddenEnv_Sort.value =3D theType.substr(4);=0A=
    f.submit();=0A=
    return false;=0A=
  }=0A=
  else {=0A=
    return false;=0A=
  }=0A=
  var win =3D opDlg('/wavemaster.internal/webapp/lib/empty.html', =
the_target);=0A=
  var tmp_target =3D document.bodyform.target;=0A=
  var tmp_action =3D document.bodyform.action;=0A=
  document.bodyform.target=3Dwin.name;=0A=
  document.bodyform.action=3Dthe_action;=0A=
  document.bodyform.submit();=0A=
  if (navigator.platform.toLowerCase().indexOf('mac')!=3D-1 &&=0A=
      navigator.appName.toLowerCase().indexOf('netscape')=3D=3D-1)  // =
MacIE=0A=
  {=0A=
    // workaround for MacIE;=0A=
    // submit does not work correct if resetting target too soon=0A=
    var str =3D 'document.bodyform.target =3D "'+tmp_target+'";';=0A=
    str    +=3D 'document.bodyform.action =3D "'+tmp_action+'";';=0A=
    self.setTimeout(str, 200);=0A=
  }=0A=
  else=0A=
  {=0A=
    document.bodyform.target =3D tmp_target;=0A=
    document.bodyform.action =3D tmp_action;=0A=
  }=0A=
  return false;=0A=
}=0A=
=0A=
function freeIterator(theId, useSelfWindow) {=0A=
  if (isNaN(theId)) {=0A=
    return;=0A=
  }=0A=
  if (useSelfWindow) {=0A=
    window.onunload =3D new Function("");=0A=
    window.location.pathname =3D getCurrPath() + =
';internal&action=3Dfree.iterator.action&Parameter=3D' + theId;=0A=
  }=0A=
  else=0A=
  {=0A=
    try=0A=
    {=0A=
      if (top.opener && !top.opener.closed && top.opener.top && typeof =
top.opener.top.callServerFunction =3D=3D 'function') {=0A=
        top.opener.top.callServerFunction({serverFunctionName: =
'HW_Misc.static_.freeIterator', callback: '', parameters: {iteratorId: =
theId}});=0A=
      }=0A=
      else {=0A=
        opDlg(getCurrPath() + =
';internal&action=3Dfree.iterator.action&Parameter=3D' + theId, 'temp', =
'');=0A=
      }=0A=
    }=0A=
    catch (e)=0A=
    { // in firefox top.opener.top.callServerFunction can rise an =
exception=0A=
      opDlg(getCurrPath() + =
';internal&action=3Dfree.iterator.action&Parameter=3D' + theId, 'temp', =
'');=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 * this function converts all possible dates in search formular to user =
selected=0A=
 * date format. this is necessary, because we restore the form values =
onload and=0A=
 * the dates will be restores in HWDate format. this  function has to be =
called=0A=
 * onload, after restoring the fomdata.=0A=
 *=0A=
 * @param theForm: object: a reference to a html formular=0A=
 */=0A=
function convertDatesInSearchForm(theForm) {=0A=
  for (var i =3D 0; i < theForm.elements.length; i ++) {=0A=
    var curr =3D theForm.elements[i];=0A=
    if (SpecArray[curr.name] && SpecArray[curr.name].type =3D=3D =
"HW_API_Date" && curr.value) {=0A=
      // found a form element of type HW_API_Date ... convert inot user =
selected date format=0A=
      convertDateInForm(theForm, curr.name, {sFormat: HWDate, dFormat: =
HW_UI_Date, dateOnly: true});=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
//--------------------------------------------------------------------=0A=
/**=0A=
 *=0A=
 */=0A=
function checkSelectedScopes(isFirstRun)=0A=
{=0A=
  var scope_checks =3D document.getElementsByName("dd_group_scopes_");=0A=
  if (!scope_checks.length) {=0A=
    if (typeof INTERVAL_CHECK_SELECTED_SCOPES !=3D "undefined") {=0A=
      clearInterval(INTERVAL_CHECK_SELECTED_SCOPES);=0A=
    }=0A=
    return;=0A=
  }=0A=
  var mode =3D 0;=0A=
  var ctr =3D 1;=0A=
  for (var i =3D 0; i < scope_checks.length; i ++) {=0A=
    var curr =3D scope_checks[i];=0A=
    if (curr.checked) {=0A=
      mode |=3D ctr;=0A=
    }=0A=
    ctr <<=3D 1;=0A=
  }=0A=
=0A=
  if (!isFirstRun && !mode) {=0A=
    // no checkbox is selected=0A=
    if (LAST_SCOPE_MODE) {=0A=
      var ctr =3D 1;=0A=
      for (var i =3D 0; i < scope_checks.length; i ++) {=0A=
        var curr =3D scope_checks[i];=0A=
        if (!(LAST_SCOPE_MODE & ctr)) {=0A=
          curr.checked =3D true;=0A=
          mode |=3D ctr; // mark as checked=0A=
          if (typeof curr.onclick =3D=3D "function") {=0A=
            curr.onclick();=0A=
          }=0A=
          break;=0A=
        }=0A=
        ctr <<=3D 1;=0A=
      }=0A=
    }=0A=
    else {=0A=
      var curr =3D scope_checks[0];=0A=
      curr.checked =3D true;=0A=
      mode |=3D 1; // mark as checked=0A=
      if (typeof curr.onclick =3D=3D "function") {=0A=
        curr.onclick();=0A=
      }=0A=
    }=0A=
  }=0A=
  LAST_SCOPE_MODE =3D mode;=0A=
}=0A=
=0A=
function initcheckSelectedScopes() {=0A=
  if (document.bodyform &&=0A=
      document.bodyform.dd_group_scopes_ &&=0A=
      typeof INTERVAL_CHECK_SELECTED_SCOPES =3D=3D "undefined") {=0A=
    checkSelectedScopes(true);=0A=
    INTERVAL_CHECK_SELECTED_SCOPES =3D =
setInterval("checkSelectedScopes(false)", 250);=0A=
    addToOnunload("clearInterval(INTERVAL_CHECK_SELECTED_SCOPES);");=0A=
  }=0A=
}=0A=
addToOnload("initcheckSelectedScopes();");=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/bookmarks/code/csjs/BookmarksMediator.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        BookmarksMediator.js=0A=
 *  Created:     2011-05-17 by cgoess=0A=
 *  Description: Handles client side bookmark functionality (e.g. =
handling addBookmark request) =0A=
 *=0A=
 *  $Id: BookmarksMediator.js 163035 2011-05-18 07:33:57Z cgoess $=0A=
 * </file>=0A=
 */=0A=
 =0A=
/* <JSLINT> */=0A=
/*global FrameSetMediator */=0A=
/*global openMenu */=0A=
/* </JSLINT> */=0A=
=0A=
// <JSClass Name=3D"BookmarksMediator">=0A=
/**=0A=
 * The BookmarksMediator constructor.=0A=
 */=0A=
function BookmarksMediator()=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
  =0A=
  com.hyperwave.framework.BaseMediator.apply(this, arguments);=0A=
  =0A=
  this.personal_menu_ =3D null;=0A=
}=0A=
=0A=
// Inheritance call for JavaScript.=0A=
class$ =3D doInherit (BookmarksMediator, =
com.hyperwave.framework.BaseMediator);=0A=
=0A=
class$.setPersonalMenu =3D function (theMenu) {=0A=
  this.personal_menu_ =3D theMenu;=0A=
};=0A=
=0A=
class$.getPersonalMenu =3D function () {=0A=
  return this.personal_menu_;=0A=
};=0A=
=0A=
class$.addBookmark =3D function (theParams) {=0A=
  var mediator =3D FrameSetMediator.static_.getInstance();=0A=
  var param =3D { =0A=
    requestMethod: 'post',=0A=
    method: "HW_Bookmarks.static_.addBookmark",=0A=
    baseurl: mediator.getCurrentUrl(),=0A=
    requestParameters: {}=0A=
  };=0A=
  this.getFramework().ajaxRequest(param, this, window);=0A=
};=0A=
=0A=
class$.onActionDone =3D function (theResult, theData, theWindow) {=0A=
  if (theResult.action =3D=3D "HW_Bookmarks.static_.addBookmark") {=0A=
    if (theData.menuname) {=0A=
      var menu =3D this.getPersonalMenu();=0A=
      if (menu) {=0A=
        menu.destructor();=0A=
      }=0A=
      eval(theData.menustring);=0A=
      this.setPersonalMenu(eval(theData.menuname));=0A=
    }=0A=
    return com.hyperwave.framework.BaseMediator.static_.STOP;=0A=
  }=0A=
  return com.hyperwave.framework.BaseMediator.static_.CONTINUE;=0A=
};=0A=
=0A=
class$.openPersonalBookmarksMenu =3D function (theElement) {=0A=
  var menu =3D this.getPersonalMenu();=0A=
  if (menu) {=0A=
    openMenu(=0A=
      -1,=0A=
      -1, {=0A=
        menu:  menu, =0A=
        oname: 'personalbookmarksmenu', =0A=
        yp:    'b', =0A=
        xp:    'l', =0A=
        ma:    'l', =0A=
        h:     false, =0A=
        event: self.event||arguments[0], =0A=
        element: theElement=0A=
      }=0A=
    );=0A=
  }=0A=
  return false;=0A=
};=0A=
=0A=
class$.onunload =3D function () {=0A=
  var menu =3D this.getPersonalMenu();=0A=
  if (menu) {=0A=
    menu.destructor();=0A=
  }=0A=
};=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/editlocally/code/csjs/EditLocallyDialogController.js?cachekeY=515488b2-en

/*
 * <copyright>
 *  Copyright (c) Hyperwave GmbH 2010
 * </copyright>
 *
 * <file>
 *  Name:        EditLocallyDialogController.js
 *  Created:     2009-06-30 by cgoess
 *  Description: The class resides in the top-frame and controls the =
editlocally dialog. It=20
 *               opens the dialog, or re-uses an already opened dialog =
for adding new documents=20
 *               to the editlocally dialog.
 *
 *  $Id: EditLocallyDialogController.js 157905 2010-08-18 15:29:44Z =
bmarsch $
 *  $Revision: 157905 $
 * </file>
 */

// <JSClass name=3D"EditLocallyDialogController">

/**
 * Constructor
 */
function EditLocallyDialogController (theParams)
{
  if (theParams =3D=3D=3D "__proto__") {
    return;
  }
 =20
  this.instance_ =3D null;
  this.dialog_ =3D null;
  this.url_ =3D null;
}

//--------------------------------------------------------------------
// Inheritance call for JavaScript.
class$ =3D doInherit (EditLocallyDialogController);

/**
 * Singleton for the class.
 *=20
 * @return EditLocallyDialogController: the controller instance
 */
class$.static_.getInstance =3D function () {
  if (!this.instance_) {
    this.instance_ =3D new EditLocallyDialogController();
  }
  return this.instance_;
};

class$.setDialogUrl =3D function (theUrl) {
  this.url_ =3D theUrl;
};

/**
 * Getter for the editlocally dialog window.
 *=20
 * @return window: the editlocally dialog window
 */
class$.getDialog =3D function () {
  return this.dialog_;
};

/**
 * Setter for the editlocally dialog window.
 *=20
 * @params theDialog: window: the editlocally dialog window
 */
class$.setDialog =3D function (theDialog) {
  this.dialog_ =3D theDialog;
};

/**
 * The method opens the editlocally dialog with the given document as =
target for=20
 * editing or adds the given document to the already opened editlocally =
dialog.
 *=20
 * @param theDocumentId: the GOid of the document that should be edited =
locally
 * @param theDocumentTitle: the Title of the document that should be =
edited locally (used for display)
 */
  class$.static_.openDocument =3D function (theDocumentId, =
theDocumentTitle) {
  var instance =3D this.getInstance();
  if (!instance.getDialog() || instance.getDialog().closed) {
    var dialog_url =3D "/"+theDocumentId+";internal";
    if (top.unique) {
      dialog_url +=3D "&Parameter=3D" + top.unique;
    }
    if (top.gCurrentContext) {
      dialog_url +=3D "&ctx=3D" + top.gCurrentContext;
    }
    dialog_url +=3D "&action=3Deditlocally.action";
    instance.setDialog( opDlg(dialog_url, "progress_window") );
  }
  else {
    var dialog_mediator =3D =
instance.getDialog().EditLocallyMediator.static_.getInstance();
    dialog_mediator.addDocument(theDocumentId, theDocumentTitle);
  }
  instance.getDialog().focus();
};
// </JSClass>

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/newsticker/code/csjs/NewsTickerMediator.js?cachekeY=515488b2-en

function NewsTickerMediator()=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
  =0A=
  com.hyperwave.framework.BaseMediator.apply(this, arguments);=0A=
  this.ids =3D [];=0A=
}=0A=
=0A=
// Inheritance call for JavaScript.=0A=
class$ =3D doInherit (NewsTickerMediator, =
com.hyperwave.framework.BaseMediator);=0A=
=0A=
class$.setId =3D function(anId) {=0A=
  this.ids.push(anId);=0A=
};=0A=
=0A=
class$.setConfiguration =3D function(aConfig) {=0A=
  this.configuration =3D aConfig;=0A=
};=0A=
=0A=
class$.onload =3D function() {=0A=
  var conf =3D this.configuration;=0A=
  if (conf.active) {=0A=
    new rssticker_ajax(=0A=
        conf.cachetime,=0A=
        conf.cache,=0A=
        conf.target,=0A=
        conf.action,=0A=
        conf.delay,=0A=
        this.ids[0],=0A=
        conf.display || "");=0A=
  }=0A=
};=0A=
=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/newsticker/code/csjs/rssticker.js?cachekeY=515488b2-en

//-------------------------------------------------------------------=0A=
//Advanced RSS Ticker (Ajax invocation) core file=0A=
//Author: Dynamic Drive (http://www.dynamicdrive.com)=0A=
//-------------------------------------------------------------------=0A=
=0A=
//Relative URL syntax:=0A=
var =
lastrssbridgeurl=3D"/;internal&action=3Djs.execute.action&Parameter=3D%23=
(UIClass%3AHW_MiscUI)(Method%3Astatic_.getCollectionRSS)&ctx=3DeKS?id=3DT=
estdocuments2/coll"=0A=
=0A=
//Absolute URL syntax. Uncomment below line if you wish to use an =
absolute reference:=0A=
//var =
lastrssbridgeurl=3D"http://"+window.location.hostname+"/lastrss/bridge.ph=
p"=0A=
=0A=
////////////No need to edit beyond here//////////////=0A=
=0A=
  function createAjaxObj(){=0A=
  var httprequest=3Dfalse=0A=
  if (window.XMLHttpRequest){ // if Mozilla, Safari etc=0A=
    httprequest=3Dnew XMLHttpRequest()=0A=
    if (httprequest.overrideMimeType)=0A=
      httprequest.overrideMimeType('text/xml')=0A=
  }=0A=
  else if (window.ActiveXObject){ // if IE=0A=
    try {=0A=
      httprequest=3Dnew ActiveXObject("Msxml2.XMLHTTP");=0A=
    }=0A=
    catch (e){=0A=
      try{=0A=
        httprequest=3Dnew ActiveXObject("Microsoft.XMLHTTP");=0A=
      }=0A=
      catch (e){}=0A=
    }=0A=
  }=0A=
  return httprequest=0A=
}=0A=
=0A=
//-------------------------------------------------------------------=0A=
//Main RSS Ticker Object function=0A=
//rssticker_ajax(RSS_id, cachetime, divId, divClass, delay, =
optionallogicswitch)=0A=
//-------------------------------------------------------------------=0A=
=0A=
function rssticker_ajax(cachetime, cachetype, target, action, delay, id, =
logicswitch){=0A=
  this.cachetime=3Dcachetime; //Time to cache feed, in seconds. 0=3Dno =
cache.=0A=
  this.cachetype=3Dcachetype || "privat";=0A=
  this.target=3Dtarget || "top";=0A=
  this.delay=3Ddelay * 1000; //Delay between msg change, in miliseconds.=0A=
  this.action=3Daction;=0A=
  this.tickerid=3Did;=0A=
  this.logicswitch=3D(typeof logicswitch!=3D"undefined")? logicswitch : =
"";=0A=
  this.mouseoverBol=3D0; //Boolean to indicate whether mouse is =
currently over ticker (and pause it if it is)=0A=
  this.rotate_running =3D 0;=0A=
  this.pointer =3D 0;=0A=
  this.opacitysetting=3D0.2; //Opacity value when reset. Internal use.=0A=
  this.ajaxobj=3DcreateAjaxObj();=0A=
  if (window.getComputedStyle) { //detect if moz-opacity is defined in =
external CSS for specified class=0A=
    =
this.mozopacityisdefined=3D(window.getComputedStyle(document.getElementBy=
Id(this.tickerid), "").getPropertyValue("-moz-opacity")=3D=3D1)? 0 : 1;=0A=
  }=0A=
  this.getAjaxcontent(true);=0A=
}=0A=
=0A=
//-------------------------------------------------------------------=0A=
//getAjaxcontent()- Makes asynchronous GET request to "bridge.php" with =
the supplied parameters=0A=
//-------------------------------------------------------------------=0A=
=0A=
rssticker_ajax.prototype.getAjaxcontent=3Dfunction(firsttime){=0A=
  if (this.ajaxobj){=0A=
    var instanceOfTicker=3Dthis;=0A=
//    var =
parameters=3D"id=3D"+encodeURIPath(this.baseurl)+"&cachetime=3D"+this.cac=
hetime+"&cachetype=3D"+this.cachetypenew Date().getTime()=0A=
    if (firsttime) {=0A=
      =
this.ajaxobj.onreadystatechange=3Dfunction(){instanceOfTicker.initialize(=
true);}=0A=
    }=0A=
    else {=0A=
      =
this.ajaxobj.onreadystatechange=3Dfunction(){instanceOfTicker.initialize(=
false);}=0A=
    }=0A=
    this.ajaxobj.open('GET', this.action, true);=0A=
    this.ajaxobj.send(null)=0A=
  }=0A=
}=0A=
=0A=
//-------------------------------------------------------------------=0A=
//initialize()- Initialize ticker method.=0A=
//-Gets contents of RSS content and parse it using JavaScript DOM methods=0A=
//-------------------------------------------------------------------=0A=
=0A=
rssticker_ajax.prototype.initialize=3Dfunction(firsttime){=0A=
  function getValue(item, key) {=0A=
    if (item.getElementsByTagName(key)[0] &&=0A=
        item.getElementsByTagName(key)[0].firstChild) {=0A=
      return item.getElementsByTagName(key)[0].firstChild.nodeValue || =
"";=0A=
    }=0A=
    return "";=0A=
  }=0A=
  if (this.ajaxobj.readyState =3D=3D 4){ //if request of file completed=0A=
    if (this.ajaxobj.status=3D=3D200){ //if request was successful=0A=
      var instanceOfTicker=3Dthis=0A=
      this.title=3D[], this.link=3D[], this.description=3D[], =
this.pubdate=3D[], this.cssclass=3D[], this.feeditems=3D[]; //Arrays to =
hold each component of an RSS item=0A=
      var xmldata=3Dthis.ajaxobj.responseXML=0A=
      if(xmldata.getElementsByTagName("item").length=3D=3D0){ //if no =
<item> elements found in returned content=0A=
        $("newsticker").hide();=0A=
        FrameSetMediator.static_.getInstance().fitFrameSet();=0A=
      }=0A=
      else {=0A=
        this.feeditems=3Dxmldata.getElementsByTagName("item")=0A=
//      Cycle through RSS XML object and store each piece of an item =
inside a corresponding array=0A=
        for (var i=3D0; i<this.feeditems.length; i++) {=0A=
          var curr_item =3D this.feeditems[i];=0A=
          this.title[i]=3DgetValue(curr_item,"title");=0A=
          this.link[i]=3DgetValue(curr_item,"link");=0A=
          this.description[i]=3DgetValue(curr_item,"description");=0A=
          this.pubdate[i]=3DgetValue(curr_item,"pubDate");=0A=
          this.cssclass[i]=3DgetValue(curr_item,"cssClass");=0A=
        }=0A=
        =
document.getElementById(this.tickerid).onmouseover=3Dfunction(){instanceO=
fTicker.mouseoverBol=3D1}=0A=
        =
document.getElementById(this.tickerid).onmouseout=3Dfunction(){instanceOf=
Ticker.mouseoverBol=3D0}=0A=
        if (!this.rotate_running) {=0A=
          this.rotatemsg();=0A=
        }=0A=
        $("newsticker").show();=0A=
        FrameSetMediator.static_.getInstance().fitFrameSet();=0A=
      }=0A=
      setTimeout(function(){=0A=
        instanceOfTicker.getAjaxcontent(false);=0A=
      }, this.cachetime * 1000);=0A=
    }=0A=
  }=0A=
}=0A=
=0A=
//-------------------------------------------------------------------=0A=
//rotatemsg()- Rotate through RSS messages and displays them=0A=
//-------------------------------------------------------------------=0A=
=0A=
rssticker_ajax.prototype.rotatemsg=3Dfunction(){=0A=
  this.rotate_running =3D true;=0A=
  var instanceOfTicker=3Dthis=0A=
  if (this.mouseoverBol=3D=3D1) { //if mouse is currently over ticker, =
do nothing (pause it)=0A=
    setTimeout(function(){instanceOfTicker.rotatemsg()}, 100);=0A=
  }=0A=
  else {=0A=
    if (this.feeditems.length){ //else, construct item, show and rotate =
it!=0A=
      if (this.pointer > this.feeditems.length-1) {=0A=
        this.pointer =3D 0;=0A=
      }=0A=
      var tickerDiv=3D$(this.tickerid);=0A=
      var statusDiv=3DtickerDiv.up();=0A=
      var linktitle=3D'<span class=3D"rsstitle"><a =
href=3D"'+this.link[this.pointer]+'" =
target=3D"'+this.target+'">'+this.title[this.pointer]+'</a></span>';=0A=
      if (this.logicswitch.indexOf("description")!=3D-1 && =
this.description[this.pointer]) {=0A=
        var description=3D'<span =
class=3D"newsdescription">'+this.description[this.pointer]+'</span>';=0A=
      }=0A=
      else {=0A=
        var description =3D "";=0A=
      }=0A=
      if (this.logicswitch.indexOf("date")!=3D-1 && =
this.pubdate[this.pointer]) {=0A=
        var feeddate=3D'<span =
class=3D"newsdate">'+this.pubdate[this.pointer]+'</span>';=0A=
      }=0A=
      else {=0A=
        var feeddate=3D"";=0A=
      }=0A=
      var tickercontent=3Dlinktitle+feeddate+description; //STRING FOR =
FEED CONTENTS=0A=
      this.fadetransition("reset"); //FADE EFFECT- RESET OPACITY=0A=
      tickerDiv.innerHTML=3Dtickercontent;=0A=
      if (this.lastclass) {=0A=
        statusDiv.removeClassName(this.lastclass);=0A=
      }=0A=
      statusDiv.addClassName(this.cssclass[this.pointer]);=0A=
      this.lastclass =3D this.cssclass[this.pointer];=0A=
      =
this.fadetimer1=3DsetInterval(function(){instanceOfTicker.fadetransition(=
'up', 'fadetimer1')}, 100); //FADE EFFECT- PLAY IT=0A=
      this.pointer=3D(this.pointer<this.feeditems.length-1)? =
this.pointer+1 : 0;=0A=
    }=0A=
    setTimeout(function(){instanceOfTicker.rotatemsg()}, this.delay); =
//update container every second=0A=
  }=0A=
}=0A=
=0A=
=0A=
//-------------------------------------------------------------------=0A=
//fadetransition()- cross browser fade method for IE5.5+ and =
Mozilla/Firefox=0A=
//-------------------------------------------------------------------=0A=
=0A=
rssticker_ajax.prototype.fadetransition=3Dfunction(fadetype, timerid){=0A=
  var tickerDiv=3Ddocument.getElementById(this.tickerid);=0A=
  if (fadetype=3D=3D"reset") {=0A=
    this.opacitysetting=3D0.2;=0A=
  }=0A=
  if (tickerDiv.filters && tickerDiv.filters[0]){=0A=
    if (typeof tickerDiv.filters[0].opacity=3D=3D"number") { //IE6+=0A=
      tickerDiv.filters[0].opacity=3Dthis.opacitysetting*100;=0A=
    }=0A=
    else {//IE 5.5=0A=
      =
tickerDiv.style.filter=3D"alpha(opacity=3D"+this.opacitysetting*100+")";=0A=
    }=0A=
  }=0A=
  else if (typeof tickerDiv.style.MozOpacity!=3D"undefined" && =
this.mozopacityisdefined){=0A=
    tickerDiv.style.MozOpacity=3Dthis.opacitysetting;=0A=
  }=0A=
  if (fadetype=3D=3D"up") {=0A=
    this.opacitysetting+=3D0.2;=0A=
  }=0A=
  if (fadetype=3D=3D"up" && this.opacitysetting>1) {=0A=
    clearInterval(this[timerid]);=0A=
  }=0A=
}
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/webapp/components/workflow/code/csjs/WorkflowMediator.js?cachekeY=515488b2-en

/*=0A=
 * <copyright>=0A=
 *  Copyright (c) Hyperwave GmbH 2010=0A=
 * </copyright>=0A=
 *=0A=
 * <file>=0A=
 *  Name:        WorkflowMediator.js=0A=
 *  Created:     2009-11-02 by sweber=0A=
 *  Description: Handles workflow issues (client-side) outside of the =
dashboard, such as =0A=
 *               reacting on changes to the out-of-office-setting in =
preferences and opening =0A=
 *               the start-case-dialog in eks/tws.=0A=
 *=0A=
 *  $Id: WorkflowMediator.js 161463 2011-02-16 11:58:54Z cgoess $=0A=
 * </file>=0A=
 */=0A=
 =0A=
/* <JSLINT> */=0A=
/*global hw */=0A=
/*global HW_Mainframe */=0A=
/* </JSLINT> */=0A=
=0A=
// <JSClass Name=3D"WorkflowMediator">=0A=
/**=0A=
 * The WorkflowMediator constructor.=0A=
 */=0A=
function WorkflowMediator()=0A=
{=0A=
  if (arguments[0] =3D=3D=3D "__proto__") {=0A=
    return;=0A=
  }=0A=
  =0A=
  com.hyperwave.framework.BaseMediator.apply(this, arguments);=0A=
=0A=
  this.dashboardMediator_ =3D null;  =0A=
}=0A=
=0A=
// Inheritance call for JavaScript.=0A=
class$ =3D doInherit (WorkflowMediator, =
com.hyperwave.framework.BaseMediator);=0A=
=0A=
class$.static_.ID_ =3D "eks.workflowmediator";=0A=
=0A=
class$.static_.HTMLRES_PATH_ =3D =
"webapp/components/workflow/htmlres/WorkflowMediator/WorkflowMediator.xml=
";=0A=
class$.static_.LANGRES_PATH_ =3D =
"webapp/components/workflow/langres/WorkflowMediator/WorkflowMediator.%la=
ng%.xml";=0A=
hw.util.IncludeManager.static_.getInstance().loadResource(class$.static_.=
HTMLRES_PATH_);=0A=
hw.util.IncludeManager.static_.getInstance().loadResource(class$.static_.=
LANGRES_PATH_);=0A=
=0A=
class$.getId =3D function() {=0A=
  return this.static_.ID_;=0A=
};=0A=
=0A=
class$.setDashboardMediator =3D function (theMediator) {=0A=
  this.dashboardMediator_ =3D theMediator;=0A=
};=0A=
=0A=
class$.unsetDashboardMediator =3D function () {=0A=
  this.dashboardMediator_ =3D null;=0A=
};=0A=
=0A=
class$.onActionDone =3D function (theResult, theData, theWindow) {=0A=
  if (theResult.action =3D=3D =
"HW_WF_WorkFlowUI.static_.getFormForDefinition") {=0A=
    if (theData.url) {=0A=
      this.openFormDialog({url: theData.url});=0A=
    }=0A=
    else {=0A=
      this.getFramework().displayError({errorMessage: "Unexpected error: =
missing url in response."});=0A=
    }=0A=
    return com.hyperwave.framework.BaseMediator.static_.STOP;=0A=
  }=0A=
  =0A=
  if (theResult.action =3D=3D =
"HW_WF_DashboardItemUI.static_.getCaseInfoByOriginObject") {=0A=
    this.openWorkflowCaseDialog(theData || {}, theResult.event);=0A=
    return com.hyperwave.framework.BaseMediator.static_.STOP;=0A=
  }=0A=
  =0A=
  if (theResult.action =3D=3D "dialog.ebcsave.action") {=0A=
    if (this.dashboardMediator_) {=0A=
      this.dashboardMediator_.refreshDashboard();=0A=
    }=0A=
  }=0A=
  =0A=
  if (theResult.action =3D=3D "HW_MiscUI.static_.getAttributes") {=0A=
    if (theData.error) {=0A=
      hw.getFramework().displayError({errorMessage: theData.error});=0A=
    }=0A=
    else {=0A=
      var wrong_objects =3D [];=0A=
      for (var i =3D 0; i < theData.objects.length; i ++) {=0A=
        if (theData.objects[i].HW_UserLock) {=0A=
          wrong_objects.push(theData.titles[i]);=0A=
        }=0A=
      }=0A=
      if (wrong_objects.length) {=0A=
=0A=
        var resource =3D this.static_.getResource("WrongObjects");=0A=
        resource.setRes("wrong_objects", wrong_objects);=0A=
=0A=
        hw.getFramework().displayError({errorMessage: =
resource.toString()});=0A=
      }=0A=
      else {=0A=
        var param =3D { =0A=
          requestMethod: 'post',=0A=
          method: "HW_WF_WorkFlowUI.static_.getFormForDefinition",=0A=
          baseurl: "/hw_temporary_objects",=0A=
          requestParameters: {=0A=
            theId: theResult.form.theId,=0A=
            theObjectIds: theResult.form.theObjectIds,=0A=
            theAssociatedObjects: theResult.form.theAssociatedObjects,=0A=
            doDisplaySaveButton: theResult.form.doDisplaySaveButton=0A=
          }=0A=
        };=0A=
        this.getFramework().ajaxRequest(param, this, window);=0A=
      }=0A=
    }=0A=
    return com.hyperwave.framework.BaseMediator.static_.STOP;=0A=
  }=0A=
=0A=
  return com.hyperwave.framework.BaseMediator.static_.CONTINUE;=0A=
};=0A=
=0A=
class$.onActionError =3D function (theResult, theData, theWindow) {=0A=
  if (theResult.action =3D=3D =
"HW_WF_WorkFlowUI.static_.getFormForDefinition" ||=0A=
      theResult.action =3D=3D =
"HW_WF_DashboardItemUI.static_.getCaseInfoByOriginObject") {=0A=
    this.getFramework().displayError(theResult);=0A=
    return com.hyperwave.framework.BaseMediator.static_.STOP;=0A=
  }=0A=
  WorkflowMediator.super_.onActionError.call(this, arguments);=0A=
};=0A=
=0A=
class$.initStartCase =3D function (theParams) {=0A=
  var params =3D theParams || {};=0A=
  if (params.theProcessDefinitionId) {=0A=
    var listing_objects =3D this.getSelectedObjects();=0A=
    var wp_objects =3D [];=0A=
    for (var i=3D0; i<listing_objects.length; i++) {=0A=
    	wp_objects.push(listing_objects[i].G);=0A=
    }=0A=
    var param =3D { =0A=
      requestMethod: 'post',=0A=
      method: "HW_WF_WorkFlowUI.static_.getFormForDefinition",=0A=
      baseurl: "/hw_temporary_objects",=0A=
      requestParameters: {=0A=
        theId: params.theProcessDefinitionId,=0A=
        theObjectIds: wp_objects,=0A=
        theAssociatedObjects: params.theAssociatedObjects || [],=0A=
        doDisplaySaveButton: false=0A=
      }=0A=
    };=0A=
=0A=
    if (params.includesPublishBackTask) {=0A=
      param.method =3D "HW_MiscUI.static_.getAttributes";=0A=
      param.requestParameters.ids =3D wp_objects;=0A=
    }=0A=
=0A=
    this.getFramework().ajaxRequest(param, this, window);=0A=
  }=0A=
};=0A=
=0A=
class$.openFormDialog =3D function (theParams) {=0A=
  var params =3D theParams || {};=0A=
  var dialog =3D new top.com.hyperwave.dialogs.IframeDialog(params);=0A=
  dialog.setMaxDimensions();=0A=
  dialog.setUrl(params.url);=0A=
  var reload_window =3D function (theDialog) {=0A=
    if (theDialog.getData("user_action")=3D=3D"done") {=0A=
      =
top.FrameSetMediator.static_.getInstance().getApplicationView().refresh()=
;=0A=
    }=0A=
    return true;=0A=
  };=0A=
  =
dialog.addEventListener(top.com.hyperwave.dialogs.Dialog.static_.EVENTS.C=
LOSE, reload_window.bind(this, dialog));=0A=
  this.getFramework().displayDialog(dialog);=0A=
};=0A=
=0A=
class$.getSelectedObjects =3D function () {=0A=
  if (top.FrameSetMediator) {=0A=
    return =
top.FrameSetMediator.static_.getInstance().getSelectedObjects();=0A=
  }=0A=
  return [];=0A=
};=0A=
=0A=
  =0A=
class$.getWorkflowCaseData =3D function (theGOid, theEvent) {=0A=
  this.getFramework().ajaxRequest(=0A=
    {=0A=
      blockingStyle: this.getFramework().static_.BLOCKINGSTYLE.SOFT,=0A=
      method: "HW_WF_DashboardItemUI.static_.getCaseInfoByOriginObject",=0A=
      event: theEvent,=0A=
      requestParameters: {=0A=
        theGOid: theGOid=0A=
      }=0A=
    },=0A=
    this,=0A=
    window=0A=
  );    =0A=
};=0A=
  =0A=
class$.openWorkflowCaseDialog =3D function (theParams, theEvent) {=0A=
  if (this.caseInfoDialog_) {=0A=
    this.closeCaseInfoDialog();=0A=
  }=0A=
  var dialog =3D new com.hyperwave.dialogs.PopupDialog(theEvent);=0A=
  this.caseInfoDialog_ =3D dialog;=0A=
=0A=
  dialog.setDimensions(200, 100);=0A=
  dialog.setReference("item_mediator", this);=0A=
  =0A=
  var resource =3D new com.hyperwave.res.Resource( =
{templateKey_:"AssociatedCaseDialogContent"} );=0A=
  resource.makeRoot();=0A=
  resource.readAll(this.static_.getHTMLRes());=0A=
  resource.readAll(this.static_.getLangRes());=0A=
  resource.setRes("caseTitle", theParams.caseTitle);=0A=
  resource.setRes("isSuccess", theParams.status =3D=3D "success");=0A=
  resource.setRes("caseUrl", theParams.caseUrl);=0A=
  var content =3D resource.toString(true);=0A=
  dialog.setContent(content);=0A=
=0A=
  var dm =3D com.hyperwave.framework.DisplayManager.static_;  // =
shortcut for constants =0A=
  this.getFramework().displayDialog(=0A=
    dialog, =0A=
    window, {=0A=
      backgroundLayerClass: "hw_framework_clicklayer",=0A=
      backgroundLayerHandler: [{ =0A=
        eventName: "click", =0A=
        handler: =0A=
          (function () { =0A=
            if (this.caseInfoDialog_) {=0A=
              this.getFramework().closeDialog(this.caseInfoDialog_, =
false);=0A=
              this.caseInfoDialog_ =3D null;=0A=
            }=0A=
          }).bind(this)=0A=
      }],=0A=
      position: {=0A=
        element: theEvent.element(),=0A=
        orientation: dm.DIALOG_ORIENTATION_DOWN,=0A=
        offsetx: dm.DIALOG_OFFSETX_LEFT,=0A=
        offsety: dm.DIALOG_OFFSETY_BOTTOM=0A=
      }=0A=
    }=0A=
  );   =0A=
};=0A=
=0A=
class$.closeCaseInfoDialog =3D function () {=0A=
  if (this.caseInfoDialog_) {=0A=
    this.getFramework().closeDialog(this.caseInfoDialog_, false);=0A=
    this.caseInfoDialog_ =3D null;=0A=
  }  =0A=
};=0A=
=0A=
class$.caseOnClick =3D function (theUrl, theEvent) {=0A=
  this.closeCaseInfoDialog();=0A=
  if (theUrl) {=0A=
    HW_Mainframe.location.href =3D theUrl; =0A=
  }=0A=
  theEvent =3D Event.extend(theEvent);=0A=
  theEvent.stop();=0A=
  return false;=0A=
};=0A=
=0A=
class$.attachIsInWorkflowEventHandlers =3D function (theElement, =
theGOid) {=0A=
	theElement.observe("click",=0A=
	  this.isInWorkflowOnClick.bindAsEventListener(this, theGOid)=0A=
	);=0A=
	theElement.observe("mouseover",=0A=
	  this.isInWorkflowOnMouseOver.bindAsEventListener(this, theGOid)=0A=
	);             =0A=
	theElement.observe("mouseout",=0A=
	  this.isInWorkflowOnMouseOut.bindAsEventListener(this, theGOid)=0A=
	);                       	             =0A=
};=0A=
=0A=
class$.isInWorkflowOnClick =3D function (theEvent, theGOid) {=0A=
  if (this.getcasedata_timeout_id_) {=0A=
    clearTimeout(this.getcasedata_timeout_id_);=0A=
  }=0A=
  this.getWorkflowCaseData(theGOid, theEvent);=0A=
};=0A=
  =0A=
class$.isInWorkflowOnMouseOver =3D function (theEvent, theGOid) {=0A=
  this.getcasedata_timeout_id_ =3D setTimeout(=0A=
    this.isInWorkflowOnClick.bind(this, theEvent, theGOid), =0A=
    1000=0A=
  );=0A=
};=0A=
  =0A=
class$.isInWorkflowOnMouseOut =3D function (theEvent, theGOid) {=0A=
  if (this.getcasedata_timeout_id_) {=0A=
    clearTimeout(this.getcasedata_timeout_id_);=0A=
  }=0A=
};=0A=
// </JSClass>=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/prototype/excanvas/excanvas.js?cachekeY=515488b2-en

// Copyright 2006 Google Inc.=0A=
//=0A=
// Licensed under the Apache License, Version 2.0 (the "License");=0A=
// you may not use this file except in compliance with the License.=0A=
// You may obtain a copy of the License at=0A=
//=0A=
//   http://www.apache.org/licenses/LICENSE-2.0=0A=
//=0A=
// Unless required by applicable law or agreed to in writing, software=0A=
// distributed under the License is distributed on an "AS IS" BASIS,=0A=
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or =
implied.=0A=
// See the License for the specific language governing permissions and=0A=
// limitations under the License.=0A=
=0A=
=0A=
// Known Issues:=0A=
//=0A=
// * Patterns are not implemented.=0A=
// * Radial gradient are not implemented. The VML version of these look =
very=0A=
//   different from the canvas one.=0A=
// * Clipping paths are not implemented.=0A=
// * Coordsize. The width and height attribute have higher priority than =
the=0A=
//   width and height style values which isn't correct.=0A=
// * Painting mode isn't implemented.=0A=
// * Canvas width/height should is using content-box by default. IE in=0A=
//   Quirks mode will draw the canvas using border-box. Either change =
your=0A=
//   doctype to HTML5=0A=
//   (http://www.whatwg.org/specs/web-apps/current-work/#the-doctype)=0A=
//   or use Box Sizing Behavior from WebFX=0A=
//   (http://webfx.eae.net/dhtml/boxsizing/boxsizing.html)=0A=
// * Non uniform scaling does not correctly scale strokes.=0A=
// * Optimize. There is always room for speed improvements.=0A=
=0A=
// Only add this code if we do not already have a canvas implementation=0A=
if (!document.createElement('canvas').getContext) {=0A=
=0A=
(function() {=0A=
=0A=
  // alias some functions to make (compiled) code shorter=0A=
  var m =3D Math;=0A=
  var mr =3D m.round;=0A=
  var ms =3D m.sin;=0A=
  var mc =3D m.cos;=0A=
  var abs =3D m.abs;=0A=
  var sqrt =3D m.sqrt;=0A=
=0A=
  // this is used for sub pixel precision=0A=
  var Z =3D 10;=0A=
  var Z2 =3D Z / 2;=0A=
=0A=
  /**=0A=
   * This funtion is assigned to the <canvas> elements as =
element.getContext().=0A=
   * @this {HTMLElement}=0A=
   * @return {CanvasRenderingContext2D_}=0A=
   */=0A=
  function getContext() {=0A=
    return this.context_ ||=0A=
        (this.context_ =3D new CanvasRenderingContext2D_(this));=0A=
  }=0A=
=0A=
  var slice =3D Array.prototype.slice;=0A=
=0A=
  /**=0A=
   * Binds a function to an object. The returned function will always =
use the=0A=
   * passed in {@code obj} as {@code this}.=0A=
   *=0A=
   * Example:=0A=
   *=0A=
   *   g =3D bind(f, obj, a, b)=0A=
   *   g(c, d) // will do f.call(obj, a, b, c, d)=0A=
   *=0A=
   * @param {Function} f The function to bind the object to=0A=
   * @param {Object} obj The object that should act as this when the =
function=0A=
   *     is called=0A=
   * @param {*} var_args Rest arguments that will be used as the initial=0A=
   *     arguments when the function is called=0A=
   * @return {Function} A new function that has bound this=0A=
   */=0A=
  function bind(f, obj, var_args) {=0A=
    var a =3D slice.call(arguments, 2);=0A=
    return function() {=0A=
      return f.apply(obj, a.concat(slice.call(arguments)));=0A=
    };=0A=
  }=0A=
=0A=
  var G_vmlCanvasManager_ =3D {=0A=
    init: function(opt_doc) {=0A=
      if (/MSIE/.test(navigator.userAgent) && !window.opera) {=0A=
        var doc =3D opt_doc || document;=0A=
        // Create a dummy element so that IE will allow canvas elements =
to be=0A=
        // recognized.=0A=
        doc.createElement('canvas');=0A=
        doc.attachEvent('onreadystatechange', bind(this.init_, this, =
doc));=0A=
      }=0A=
    },=0A=
=0A=
    init_: function(doc) {=0A=
      // create xmlns=0A=
      if (!doc.namespaces['g_vml_']) {=0A=
        doc.namespaces.add('g_vml_', 'urn:schemas-microsoft-com:vml',=0A=
                           '#default#VML');=0A=
=0A=
      }=0A=
      if (!doc.namespaces['g_o_']) {=0A=
        doc.namespaces.add('g_o_', =
'urn:schemas-microsoft-com:office:office',=0A=
                           '#default#VML');=0A=
      }=0A=
=0A=
      // Setup default CSS.  Only add one style sheet per document=0A=
      if (!doc.styleSheets['ex_canvas_']) {=0A=
        var ss =3D doc.createStyleSheet();=0A=
        ss.owningElement.id =3D 'ex_canvas_';=0A=
        ss.cssText =3D 'canvas{display:inline-block;overflow:hidden;' +=0A=
            // default size is 300x150 in Gecko and Opera=0A=
            'text-align:left;width:300px;height:150px}' +=0A=
            'g_vml_\\:*{behavior:url(#default#VML)}' +=0A=
            'g_o_\\:*{behavior:url(#default#VML)}';=0A=
=0A=
      }=0A=
=0A=
      // find all canvas elements=0A=
      var els =3D doc.getElementsByTagName('canvas');=0A=
      for (var i =3D 0; i < els.length; i++) {=0A=
        this.initElement(els[i]);=0A=
      }=0A=
    },=0A=
=0A=
    /**=0A=
     * Public initializes a canvas element so that it can be used as =
canvas=0A=
     * element from now on. This is called automatically before the page =
is=0A=
     * loaded but if you are creating elements using createElement you =
need to=0A=
     * make sure this is called on the element.=0A=
     * @param {HTMLElement} el The canvas element to initialize.=0A=
     * @return {HTMLElement} the element that was created.=0A=
     */=0A=
    initElement: function(el) {=0A=
      if (!el.getContext) {=0A=
=0A=
        el.getContext =3D getContext;=0A=
=0A=
        // Remove fallback content. There is no way to hide text nodes =
so we=0A=
        // just remove all childNodes. We could hide all elements and =
remove=0A=
        // text nodes but who really cares about the fallback content.=0A=
        el.innerHTML =3D '';=0A=
=0A=
        // do not use inline function because that will leak memory=0A=
        el.attachEvent('onpropertychange', onPropertyChange);=0A=
        el.attachEvent('onresize', onResize);=0A=
=0A=
        var attrs =3D el.attributes;=0A=
        if (attrs.width && attrs.width.specified) {=0A=
          // TODO: use runtimeStyle and coordsize=0A=
          // el.getContext().setWidth_(attrs.width.nodeValue);=0A=
          el.style.width =3D attrs.width.nodeValue + 'px';=0A=
        } else {=0A=
          el.width =3D el.clientWidth;=0A=
        }=0A=
        if (attrs.height && attrs.height.specified) {=0A=
          // TODO: use runtimeStyle and coordsize=0A=
          // el.getContext().setHeight_(attrs.height.nodeValue);=0A=
          el.style.height =3D attrs.height.nodeValue + 'px';=0A=
        } else {=0A=
          el.height =3D el.clientHeight;=0A=
        }=0A=
        //el.getContext().setCoordsize_()=0A=
      }=0A=
      return el;=0A=
    }=0A=
  };=0A=
=0A=
  function onPropertyChange(e) {=0A=
    var el =3D e.srcElement;=0A=
=0A=
    switch (e.propertyName) {=0A=
      case 'width':=0A=
        el.style.width =3D el.attributes.width.nodeValue + 'px';=0A=
        el.getContext().clearRect();=0A=
        break;=0A=
      case 'height':=0A=
        el.style.height =3D el.attributes.height.nodeValue + 'px';=0A=
        el.getContext().clearRect();=0A=
        break;=0A=
    }=0A=
  }=0A=
=0A=
  function onResize(e) {=0A=
    var el =3D e.srcElement;=0A=
    if (el.firstChild) {=0A=
      el.firstChild.style.width =3D  el.clientWidth + 'px';=0A=
      el.firstChild.style.height =3D el.clientHeight + 'px';=0A=
    }=0A=
  }=0A=
=0A=
  G_vmlCanvasManager_.init();=0A=
=0A=
  // precompute "00" to "FF"=0A=
  var dec2hex =3D [];=0A=
  for (var i =3D 0; i < 16; i++) {=0A=
    for (var j =3D 0; j < 16; j++) {=0A=
      dec2hex[i * 16 + j] =3D i.toString(16) + j.toString(16);=0A=
    }=0A=
  }=0A=
=0A=
  function createMatrixIdentity() {=0A=
    return [=0A=
      [1, 0, 0],=0A=
      [0, 1, 0],=0A=
      [0, 0, 1]=0A=
    ];=0A=
  }=0A=
=0A=
  function matrixMultiply(m1, m2) {=0A=
    var result =3D createMatrixIdentity();=0A=
=0A=
    for (var x =3D 0; x < 3; x++) {=0A=
      for (var y =3D 0; y < 3; y++) {=0A=
        var sum =3D 0;=0A=
=0A=
        for (var z =3D 0; z < 3; z++) {=0A=
          sum +=3D m1[x][z] * m2[z][y];=0A=
        }=0A=
=0A=
        result[x][y] =3D sum;=0A=
      }=0A=
    }=0A=
    return result;=0A=
  }=0A=
=0A=
  function copyState(o1, o2) {=0A=
    o2.fillStyle     =3D o1.fillStyle;=0A=
    o2.lineCap       =3D o1.lineCap;=0A=
    o2.lineJoin      =3D o1.lineJoin;=0A=
    o2.lineWidth     =3D o1.lineWidth;=0A=
    o2.miterLimit    =3D o1.miterLimit;=0A=
    o2.shadowBlur    =3D o1.shadowBlur;=0A=
    o2.shadowColor   =3D o1.shadowColor;=0A=
    o2.shadowOffsetX =3D o1.shadowOffsetX;=0A=
    o2.shadowOffsetY =3D o1.shadowOffsetY;=0A=
    o2.strokeStyle   =3D o1.strokeStyle;=0A=
    o2.globalAlpha   =3D o1.globalAlpha;=0A=
    o2.arcScaleX_    =3D o1.arcScaleX_;=0A=
    o2.arcScaleY_    =3D o1.arcScaleY_;=0A=
    o2.lineScale_    =3D o1.lineScale_;=0A=
  }=0A=
=0A=
  function processStyle(styleString) {=0A=
    var str, alpha =3D 1;=0A=
=0A=
    styleString =3D String(styleString);=0A=
    if (styleString.substring(0, 3) =3D=3D 'rgb') {=0A=
      var start =3D styleString.indexOf('(', 3);=0A=
      var end =3D styleString.indexOf(')', start + 1);=0A=
      var guts =3D styleString.substring(start + 1, end).split(',');=0A=
=0A=
      str =3D '#';=0A=
      for (var i =3D 0; i < 3; i++) {=0A=
        str +=3D dec2hex[Number(guts[i])];=0A=
      }=0A=
=0A=
      if (guts.length =3D=3D 4 && styleString.substr(3, 1) =3D=3D 'a') {=0A=
        alpha =3D guts[3];=0A=
      }=0A=
    } else {=0A=
      str =3D styleString;=0A=
    }=0A=
=0A=
    return {color: str, alpha: alpha};=0A=
  }=0A=
=0A=
  function processLineCap(lineCap) {=0A=
    switch (lineCap) {=0A=
      case 'butt':=0A=
        return 'flat';=0A=
      case 'round':=0A=
        return 'round';=0A=
      case 'square':=0A=
      default:=0A=
        return 'square';=0A=
    }=0A=
  }=0A=
=0A=
  /**=0A=
   * This class implements CanvasRenderingContext2D interface as =
described by=0A=
   * the WHATWG.=0A=
   * @param {HTMLElement} surfaceElement The element that the 2D context =
should=0A=
   * be associated with=0A=
   */=0A=
  function CanvasRenderingContext2D_(surfaceElement) {=0A=
    this.m_ =3D createMatrixIdentity();=0A=
=0A=
    this.mStack_ =3D [];=0A=
    this.aStack_ =3D [];=0A=
    this.currentPath_ =3D [];=0A=
=0A=
    // Canvas context properties=0A=
    this.strokeStyle =3D '#000';=0A=
    this.fillStyle =3D '#000';=0A=
=0A=
    this.lineWidth =3D 1;=0A=
    this.lineJoin =3D 'miter';=0A=
    this.lineCap =3D 'butt';=0A=
    this.miterLimit =3D Z * 1;=0A=
    this.globalAlpha =3D 1;=0A=
    this.canvas =3D surfaceElement;=0A=
=0A=
    var el =3D surfaceElement.ownerDocument.createElement('div');=0A=
    el.style.width =3D  surfaceElement.clientWidth + 'px';=0A=
    el.style.height =3D surfaceElement.clientHeight + 'px';=0A=
    el.style.overflow =3D 'hidden';=0A=
    el.style.position =3D 'absolute';=0A=
    surfaceElement.appendChild(el);=0A=
=0A=
    this.element_ =3D el;=0A=
    this.arcScaleX_ =3D 1;=0A=
    this.arcScaleY_ =3D 1;=0A=
    this.lineScale_ =3D 1;=0A=
  }=0A=
=0A=
  var contextPrototype =3D CanvasRenderingContext2D_.prototype;=0A=
  contextPrototype.clearRect =3D function() {=0A=
    this.element_.innerHTML =3D '';=0A=
  };=0A=
=0A=
  contextPrototype.beginPath =3D function() {=0A=
    // TODO: Branch current matrix so that save/restore has no effect=0A=
    //       as per safari docs.=0A=
    this.currentPath_ =3D [];=0A=
  };=0A=
=0A=
  contextPrototype.moveTo =3D function(aX, aY) {=0A=
    var p =3D this.getCoords_(aX, aY);=0A=
    this.currentPath_.push({type: 'moveTo', x: p.x, y: p.y});=0A=
    this.currentX_ =3D p.x;=0A=
    this.currentY_ =3D p.y;=0A=
  };=0A=
=0A=
  contextPrototype.lineTo =3D function(aX, aY) {=0A=
    var p =3D this.getCoords_(aX, aY);=0A=
    this.currentPath_.push({type: 'lineTo', x: p.x, y: p.y});=0A=
=0A=
    this.currentX_ =3D p.x;=0A=
    this.currentY_ =3D p.y;=0A=
  };=0A=
=0A=
  contextPrototype.bezierCurveTo =3D function(aCP1x, aCP1y,=0A=
                                            aCP2x, aCP2y,=0A=
                                            aX, aY) {=0A=
    var p =3D this.getCoords_(aX, aY);=0A=
    var cp1 =3D this.getCoords_(aCP1x, aCP1y);=0A=
    var cp2 =3D this.getCoords_(aCP2x, aCP2y);=0A=
    bezierCurveTo(this, cp1, cp2, p);=0A=
  };=0A=
=0A=
  // Helper function that takes the already fixed cordinates.=0A=
  function bezierCurveTo(self, cp1, cp2, p) {=0A=
    self.currentPath_.push({=0A=
      type: 'bezierCurveTo',=0A=
      cp1x: cp1.x,=0A=
      cp1y: cp1.y,=0A=
      cp2x: cp2.x,=0A=
      cp2y: cp2.y,=0A=
      x: p.x,=0A=
      y: p.y=0A=
    });=0A=
    self.currentX_ =3D p.x;=0A=
    self.currentY_ =3D p.y;=0A=
  }=0A=
=0A=
  contextPrototype.quadraticCurveTo =3D function(aCPx, aCPy, aX, aY) {=0A=
    // the following is lifted almost directly from=0A=
    // =
http://developer.mozilla.org/en/docs/Canvas_tutorial:Drawing_shapes=0A=
=0A=
    var cp =3D this.getCoords_(aCPx, aCPy);=0A=
    var p =3D this.getCoords_(aX, aY);=0A=
=0A=
    var cp1 =3D {=0A=
      x: this.currentX_ + 2.0 / 3.0 * (cp.x - this.currentX_),=0A=
      y: this.currentY_ + 2.0 / 3.0 * (cp.y - this.currentY_)=0A=
    };=0A=
    var cp2 =3D {=0A=
      x: cp1.x + (p.x - this.currentX_) / 3.0,=0A=
      y: cp1.y + (p.y - this.currentY_) / 3.0=0A=
    };=0A=
=0A=
    bezierCurveTo(this, cp1, cp2, p);=0A=
  };=0A=
=0A=
  contextPrototype.arc =3D function(aX, aY, aRadius,=0A=
                                  aStartAngle, aEndAngle, aClockwise) {=0A=
    aRadius *=3D Z;=0A=
    var arcType =3D aClockwise ? 'at' : 'wa';=0A=
=0A=
    var xStart =3D aX + mc(aStartAngle) * aRadius - Z2;=0A=
    var yStart =3D aY + ms(aStartAngle) * aRadius - Z2;=0A=
=0A=
    var xEnd =3D aX + mc(aEndAngle) * aRadius - Z2;=0A=
    var yEnd =3D aY + ms(aEndAngle) * aRadius - Z2;=0A=
=0A=
    // IE won't render arches drawn counter clockwise if xStart =3D=3D =
xEnd.=0A=
    if (xStart =3D=3D xEnd && !aClockwise) {=0A=
      xStart +=3D 0.125; // Offset xStart by 1/80 of a pixel. Use =
something=0A=
                       // that can be represented in binary=0A=
    }=0A=
=0A=
    var p =3D this.getCoords_(aX, aY);=0A=
    var pStart =3D this.getCoords_(xStart, yStart);=0A=
    var pEnd =3D this.getCoords_(xEnd, yEnd);=0A=
=0A=
    this.currentPath_.push({type: arcType,=0A=
                           x: p.x,=0A=
                           y: p.y,=0A=
                           radius: aRadius,=0A=
                           xStart: pStart.x,=0A=
                           yStart: pStart.y,=0A=
                           xEnd: pEnd.x,=0A=
                           yEnd: pEnd.y});=0A=
=0A=
  };=0A=
=0A=
  contextPrototype.rect =3D function(aX, aY, aWidth, aHeight) {=0A=
    this.moveTo(aX, aY);=0A=
    this.lineTo(aX + aWidth, aY);=0A=
    this.lineTo(aX + aWidth, aY + aHeight);=0A=
    this.lineTo(aX, aY + aHeight);=0A=
    this.closePath();=0A=
  };=0A=
=0A=
  contextPrototype.strokeRect =3D function(aX, aY, aWidth, aHeight) {=0A=
    var oldPath =3D this.currentPath_;=0A=
    this.beginPath();=0A=
=0A=
    this.moveTo(aX, aY);=0A=
    this.lineTo(aX + aWidth, aY);=0A=
    this.lineTo(aX + aWidth, aY + aHeight);=0A=
    this.lineTo(aX, aY + aHeight);=0A=
    this.closePath();=0A=
    this.stroke();=0A=
=0A=
    this.currentPath_ =3D oldPath;=0A=
  };=0A=
=0A=
  contextPrototype.fillRect =3D function(aX, aY, aWidth, aHeight) {=0A=
    var oldPath =3D this.currentPath_;=0A=
    this.beginPath();=0A=
=0A=
    this.moveTo(aX, aY);=0A=
    this.lineTo(aX + aWidth, aY);=0A=
    this.lineTo(aX + aWidth, aY + aHeight);=0A=
    this.lineTo(aX, aY + aHeight);=0A=
    this.closePath();=0A=
    this.fill();=0A=
=0A=
    this.currentPath_ =3D oldPath;=0A=
  };=0A=
=0A=
  contextPrototype.createLinearGradient =3D function(aX0, aY0, aX1, aY1) =
{=0A=
    var gradient =3D new CanvasGradient_('gradient');=0A=
    gradient.x0_ =3D aX0;=0A=
    gradient.y0_ =3D aY0;=0A=
    gradient.x1_ =3D aX1;=0A=
    gradient.y1_ =3D aY1;=0A=
    return gradient;=0A=
  };=0A=
=0A=
  contextPrototype.createRadialGradient =3D function(aX0, aY0, aR0,=0A=
                                                   aX1, aY1, aR1) {=0A=
    var gradient =3D new CanvasGradient_('gradientradial');=0A=
    gradient.x0_ =3D aX0;=0A=
    gradient.y0_ =3D aY0;=0A=
    gradient.r0_ =3D aR0;=0A=
    gradient.x1_ =3D aX1;=0A=
    gradient.y1_ =3D aY1;=0A=
    gradient.r1_ =3D aR1;=0A=
    return gradient;=0A=
  };=0A=
=0A=
  contextPrototype.drawImage =3D function(image, var_args) {=0A=
    var dx, dy, dw, dh, sx, sy, sw, sh;=0A=
=0A=
    // to find the original width we overide the width and height=0A=
    var oldRuntimeWidth =3D image.runtimeStyle.width;=0A=
    var oldRuntimeHeight =3D image.runtimeStyle.height;=0A=
    image.runtimeStyle.width =3D 'auto';=0A=
    image.runtimeStyle.height =3D 'auto';=0A=
=0A=
    // get the original size=0A=
    var w =3D image.width;=0A=
    var h =3D image.height;=0A=
=0A=
    // and remove overides=0A=
    image.runtimeStyle.width =3D oldRuntimeWidth;=0A=
    image.runtimeStyle.height =3D oldRuntimeHeight;=0A=
=0A=
    if (arguments.length =3D=3D 3) {=0A=
      dx =3D arguments[1];=0A=
      dy =3D arguments[2];=0A=
      sx =3D sy =3D 0;=0A=
      sw =3D dw =3D w;=0A=
      sh =3D dh =3D h;=0A=
    } else if (arguments.length =3D=3D 5) {=0A=
      dx =3D arguments[1];=0A=
      dy =3D arguments[2];=0A=
      dw =3D arguments[3];=0A=
      dh =3D arguments[4];=0A=
      sx =3D sy =3D 0;=0A=
      sw =3D w;=0A=
      sh =3D h;=0A=
    } else if (arguments.length =3D=3D 9) {=0A=
      sx =3D arguments[1];=0A=
      sy =3D arguments[2];=0A=
      sw =3D arguments[3];=0A=
      sh =3D arguments[4];=0A=
      dx =3D arguments[5];=0A=
      dy =3D arguments[6];=0A=
      dw =3D arguments[7];=0A=
      dh =3D arguments[8];=0A=
    } else {=0A=
      throw Error('Invalid number of arguments');=0A=
    }=0A=
=0A=
    var d =3D this.getCoords_(dx, dy);=0A=
=0A=
    var w2 =3D sw / 2;=0A=
    var h2 =3D sh / 2;=0A=
=0A=
    var vmlStr =3D [];=0A=
=0A=
    var W =3D 10;=0A=
    var H =3D 10;=0A=
=0A=
    // For some reason that I've now forgotten, using divs didn't work=0A=
    vmlStr.push(' <g_vml_:group',=0A=
                ' coordsize=3D"', Z * W, ',', Z * H, '"',=0A=
                ' coordorigin=3D"0,0"' ,=0A=
                ' style=3D"width:', W, 'px;height:', H, =
'px;position:absolute;');=0A=
=0A=
    // If filters are necessary (rotation exists), create them=0A=
    // filters are bog-slow, so only create them if abbsolutely necessary=0A=
    // The following check doesn't account for skews (which don't exist=0A=
    // in the canvas spec (yet) anyway.=0A=
=0A=
    if (this.m_[0][0] !=3D 1 || this.m_[0][1]) {=0A=
      var filter =3D [];=0A=
=0A=
      // Note the 12/21 reversal=0A=
      filter.push('M11=3D', this.m_[0][0], ',',=0A=
                  'M12=3D', this.m_[1][0], ',',=0A=
                  'M21=3D', this.m_[0][1], ',',=0A=
                  'M22=3D', this.m_[1][1], ',',=0A=
                  'Dx=3D', mr(d.x / Z), ',',=0A=
                  'Dy=3D', mr(d.y / Z), '');=0A=
=0A=
      // Bounding box calculation (need to minimize displayed area so =
that=0A=
      // filters don't waste time on unused pixels.=0A=
      var max =3D d;=0A=
      var c2 =3D this.getCoords_(dx + dw, dy);=0A=
      var c3 =3D this.getCoords_(dx, dy + dh);=0A=
      var c4 =3D this.getCoords_(dx + dw, dy + dh);=0A=
=0A=
      max.x =3D m.max(max.x, c2.x, c3.x, c4.x);=0A=
      max.y =3D m.max(max.y, c2.y, c3.y, c4.y);=0A=
=0A=
      vmlStr.push('padding:0 ', mr(max.x / Z), 'px ', mr(max.y / Z),=0A=
                  'px =
0;filter:progid:DXImageTransform.Microsoft.Matrix(',=0A=
                  filter.join(''), ", sizingmethod=3D'clip');")=0A=
    } else {=0A=
      vmlStr.push('top:', mr(d.y / Z), 'px;left:', mr(d.x / Z), 'px;');=0A=
    }=0A=
=0A=
    vmlStr.push(' ">' ,=0A=
                '<g_vml_:image src=3D"', image.src, '"',=0A=
                ' style=3D"width:', Z * dw, 'px;',=0A=
                ' height:', Z * dh, 'px;"',=0A=
                ' cropleft=3D"', sx / w, '"',=0A=
                ' croptop=3D"', sy / h, '"',=0A=
                ' cropright=3D"', (w - sx - sw) / w, '"',=0A=
                ' cropbottom=3D"', (h - sy - sh) / h, '"',=0A=
                ' />',=0A=
                '</g_vml_:group>');=0A=
=0A=
    this.element_.insertAdjacentHTML('BeforeEnd',=0A=
                                    vmlStr.join(''));=0A=
  };=0A=
=0A=
  contextPrototype.stroke =3D function(aFill) {=0A=
    var lineStr =3D [];=0A=
    var lineOpen =3D false;=0A=
    var a =3D processStyle(aFill ? this.fillStyle : this.strokeStyle);=0A=
    var color =3D a.color;=0A=
    var opacity =3D a.alpha * this.globalAlpha;=0A=
=0A=
    var W =3D 10;=0A=
    var H =3D 10;=0A=
=0A=
    lineStr.push('<g_vml_:shape',=0A=
                 ' filled=3D"', !!aFill, '"',=0A=
                 ' style=3D"position:absolute;width:', W, 'px;height:', =
H, 'px;"',=0A=
                 ' coordorigin=3D"0 0" coordsize=3D"', Z * W, ' ', Z * =
H, '"',=0A=
                 ' stroked=3D"', !aFill, '"',=0A=
                 ' path=3D"');=0A=
=0A=
    var newSeq =3D false;=0A=
    var min =3D {x: null, y: null};=0A=
    var max =3D {x: null, y: null};=0A=
=0A=
    for (var i =3D 0; i < this.currentPath_.length; i++) {=0A=
      var p =3D this.currentPath_[i];=0A=
      var c;=0A=
=0A=
      switch (p.type) {=0A=
        case 'moveTo':=0A=
          c =3D p;=0A=
          lineStr.push(' m ', mr(p.x), ',', mr(p.y));=0A=
          break;=0A=
        case 'lineTo':=0A=
          lineStr.push(' l ', mr(p.x), ',', mr(p.y));=0A=
          break;=0A=
        case 'close':=0A=
          lineStr.push(' x ');=0A=
          p =3D null;=0A=
          break;=0A=
        case 'bezierCurveTo':=0A=
          lineStr.push(' c ',=0A=
                       mr(p.cp1x), ',', mr(p.cp1y), ',',=0A=
                       mr(p.cp2x), ',', mr(p.cp2y), ',',=0A=
                       mr(p.x), ',', mr(p.y));=0A=
          break;=0A=
        case 'at':=0A=
        case 'wa':=0A=
          lineStr.push(' ', p.type, ' ',=0A=
                       mr(p.x - this.arcScaleX_ * p.radius), ',',=0A=
                       mr(p.y - this.arcScaleY_ * p.radius), ' ',=0A=
                       mr(p.x + this.arcScaleX_ * p.radius), ',',=0A=
                       mr(p.y + this.arcScaleY_ * p.radius), ' ',=0A=
                       mr(p.xStart), ',', mr(p.yStart), ' ',=0A=
                       mr(p.xEnd), ',', mr(p.yEnd));=0A=
          break;=0A=
      }=0A=
=0A=
=0A=
      // TODO: Following is broken for curves due to=0A=
      //       move to proper paths.=0A=
=0A=
      // Figure out dimensions so we can do gradient fills=0A=
      // properly=0A=
      if (p) {=0A=
        if (min.x =3D=3D null || p.x < min.x) {=0A=
          min.x =3D p.x;=0A=
        }=0A=
        if (max.x =3D=3D null || p.x > max.x) {=0A=
          max.x =3D p.x;=0A=
        }=0A=
        if (min.y =3D=3D null || p.y < min.y) {=0A=
          min.y =3D p.y;=0A=
        }=0A=
        if (max.y =3D=3D null || p.y > max.y) {=0A=
          max.y =3D p.y;=0A=
        }=0A=
      }=0A=
    }=0A=
    lineStr.push(' ">');=0A=
=0A=
    if (!aFill) {=0A=
      var lineWidth =3D this.lineScale_ * this.lineWidth;=0A=
=0A=
      // VML cannot correctly render a line if the width is less than =
1px.=0A=
      // In that case, we dilute the color to make the line look thinner.=0A=
      if (lineWidth < 1) {=0A=
        opacity *=3D lineWidth;=0A=
      }=0A=
=0A=
      lineStr.push(=0A=
        '<g_vml_:stroke',=0A=
        ' opacity=3D"', opacity, '"',=0A=
        ' joinstyle=3D"', this.lineJoin, '"',=0A=
        ' miterlimit=3D"', this.miterLimit, '"',=0A=
        ' endcap=3D"', processLineCap(this.lineCap), '"',=0A=
        ' weight=3D"', lineWidth, 'px"',=0A=
        ' color=3D"', color, '" />'=0A=
      );=0A=
    } else if (typeof this.fillStyle =3D=3D 'object') {=0A=
      var fillStyle =3D this.fillStyle;=0A=
      var angle =3D 0;=0A=
      var focus =3D {x: 0, y: 0};=0A=
=0A=
      // additional offset=0A=
      var shift =3D 0;=0A=
      // scale factor for offset=0A=
      var expansion =3D 1;=0A=
=0A=
      if (fillStyle.type_ =3D=3D 'gradient') {=0A=
        var x0 =3D fillStyle.x0_ / this.arcScaleX_;=0A=
        var y0 =3D fillStyle.y0_ / this.arcScaleY_;=0A=
        var x1 =3D fillStyle.x1_ / this.arcScaleX_;=0A=
        var y1 =3D fillStyle.y1_ / this.arcScaleY_;=0A=
        var p0 =3D this.getCoords_(x0, y0);=0A=
        var p1 =3D this.getCoords_(x1, y1);=0A=
        var dx =3D p1.x - p0.x;=0A=
        var dy =3D p1.y - p0.y;=0A=
        angle =3D Math.atan2(dx, dy) * 180 / Math.PI;=0A=
=0A=
        // The angle should be a non-negative number.=0A=
        if (angle < 0) {=0A=
          angle +=3D 360;=0A=
        }=0A=
=0A=
        // Very small angles produce an unexpected result because they =
are=0A=
        // converted to a scientific notation string.=0A=
        if (angle < 1e-6) {=0A=
          angle =3D 0;=0A=
        }=0A=
      } else {=0A=
        var p0 =3D this.getCoords_(fillStyle.x0_, fillStyle.y0_);=0A=
        var width  =3D max.x - min.x;=0A=
        var height =3D max.y - min.y;=0A=
        focus =3D {=0A=
          x: (p0.x - min.x) / width,=0A=
          y: (p0.y - min.y) / height=0A=
        };=0A=
=0A=
        width  /=3D this.arcScaleX_ * Z;=0A=
        height /=3D this.arcScaleY_ * Z;=0A=
        var dimension =3D m.max(width, height);=0A=
        shift =3D 2 * fillStyle.r0_ / dimension;=0A=
        expansion =3D 2 * fillStyle.r1_ / dimension - shift;=0A=
      }=0A=
=0A=
      // We need to sort the color stops in ascending order by offset,=0A=
      // otherwise IE won't interpret it correctly.=0A=
      var stops =3D fillStyle.colors_;=0A=
      stops.sort(function(cs1, cs2) {=0A=
        return cs1.offset - cs2.offset;=0A=
      });=0A=
=0A=
      var length =3D stops.length;=0A=
      var color1 =3D stops[0].color;=0A=
      var color2 =3D stops[length - 1].color;=0A=
      var opacity1 =3D stops[0].alpha * this.globalAlpha;=0A=
      var opacity2 =3D stops[length - 1].alpha * this.globalAlpha;=0A=
=0A=
      var colors =3D [];=0A=
      for (var i =3D 0; i < length; i++) {=0A=
        var stop =3D stops[i];=0A=
        colors.push(stop.offset * expansion + shift + ' ' + stop.color);=0A=
      }=0A=
=0A=
      // When colors attribute is used, the meanings of opacity and =
o:opacity2=0A=
      // are reversed.=0A=
      lineStr.push('<g_vml_:fill type=3D"', fillStyle.type_, '"',=0A=
                   ' method=3D"none" focus=3D"100%"',=0A=
                   ' color=3D"', color1, '"',=0A=
                   ' color2=3D"', color2, '"',=0A=
                   ' colors=3D"', colors.join(','), '"',=0A=
                   ' opacity=3D"', opacity2, '"',=0A=
                   ' g_o_:opacity2=3D"', opacity1, '"',=0A=
                   ' angle=3D"', angle, '"',=0A=
                   ' focusposition=3D"', focus.x, ',', focus.y, '" />');=0A=
    } else {=0A=
      lineStr.push('<g_vml_:fill color=3D"', color, '" opacity=3D"', =
opacity,=0A=
                   '" />');=0A=
    }=0A=
=0A=
    lineStr.push('</g_vml_:shape>');=0A=
=0A=
    this.element_.insertAdjacentHTML('beforeEnd', lineStr.join(''));=0A=
  };=0A=
=0A=
  contextPrototype.fill =3D function() {=0A=
    this.stroke(true);=0A=
  }=0A=
=0A=
  contextPrototype.closePath =3D function() {=0A=
    this.currentPath_.push({type: 'close'});=0A=
  };=0A=
=0A=
  /**=0A=
   * @private=0A=
   */=0A=
  contextPrototype.getCoords_ =3D function(aX, aY) {=0A=
    var m =3D this.m_;=0A=
    return {=0A=
      x: Z * (aX * m[0][0] + aY * m[1][0] + m[2][0]) - Z2,=0A=
      y: Z * (aX * m[0][1] + aY * m[1][1] + m[2][1]) - Z2=0A=
    }=0A=
  };=0A=
=0A=
  contextPrototype.save =3D function() {=0A=
    var o =3D {};=0A=
    copyState(this, o);=0A=
    this.aStack_.push(o);=0A=
    this.mStack_.push(this.m_);=0A=
    this.m_ =3D matrixMultiply(createMatrixIdentity(), this.m_);=0A=
  };=0A=
=0A=
  contextPrototype.restore =3D function() {=0A=
    copyState(this.aStack_.pop(), this);=0A=
    this.m_ =3D this.mStack_.pop();=0A=
  };=0A=
=0A=
  function matrixIsFinite(m) {=0A=
    for (var j =3D 0; j < 3; j++) {=0A=
      for (var k =3D 0; k < 2; k++) {=0A=
        if (!isFinite(m[j][k]) || isNaN(m[j][k])) {=0A=
          return false;=0A=
        }=0A=
      }=0A=
    }=0A=
    return true;=0A=
  }=0A=
=0A=
  function setM(ctx, m, updateLineScale) {=0A=
    if (!matrixIsFinite(m)) {=0A=
      return;=0A=
    }=0A=
    ctx.m_ =3D m;=0A=
=0A=
    if (updateLineScale) {=0A=
      // Get the line scale.=0A=
      // Determinant of this.m_ means how much the area is enlarged by =
the=0A=
      // transformation. So its square root can be used as a scale factor=0A=
      // for width.=0A=
      var det =3D m[0][0] * m[1][1] - m[0][1] * m[1][0];=0A=
      ctx.lineScale_ =3D sqrt(abs(det));=0A=
    }=0A=
  }=0A=
=0A=
  contextPrototype.translate =3D function(aX, aY) {=0A=
    var m1 =3D [=0A=
      [1,  0,  0],=0A=
      [0,  1,  0],=0A=
      [aX, aY, 1]=0A=
    ];=0A=
=0A=
    setM(this, matrixMultiply(m1, this.m_), false);=0A=
  };=0A=
=0A=
  contextPrototype.rotate =3D function(aRot) {=0A=
    var c =3D mc(aRot);=0A=
    var s =3D ms(aRot);=0A=
=0A=
    var m1 =3D [=0A=
      [c,  s, 0],=0A=
      [-s, c, 0],=0A=
      [0,  0, 1]=0A=
    ];=0A=
=0A=
    setM(this, matrixMultiply(m1, this.m_), false);=0A=
  };=0A=
=0A=
  contextPrototype.scale =3D function(aX, aY) {=0A=
    this.arcScaleX_ *=3D aX;=0A=
    this.arcScaleY_ *=3D aY;=0A=
    var m1 =3D [=0A=
      [aX, 0,  0],=0A=
      [0,  aY, 0],=0A=
      [0,  0,  1]=0A=
    ];=0A=
=0A=
    setM(this, matrixMultiply(m1, this.m_), true);=0A=
  };=0A=
=0A=
  contextPrototype.transform =3D function(m11, m12, m21, m22, dx, dy) {=0A=
    var m1 =3D [=0A=
      [m11, m12, 0],=0A=
      [m21, m22, 0],=0A=
      [dx,  dy,  1]=0A=
    ];=0A=
=0A=
    setM(this, matrixMultiply(m1, this.m_), true);=0A=
  };=0A=
=0A=
  contextPrototype.setTransform =3D function(m11, m12, m21, m22, dx, dy) =
{=0A=
    var m =3D [=0A=
      [m11, m12, 0],=0A=
      [m21, m22, 0],=0A=
      [dx,  dy,  1]=0A=
    ];=0A=
=0A=
    setM(this, m, true);=0A=
  };=0A=
=0A=
  /******** STUBS ********/=0A=
  contextPrototype.clip =3D function() {=0A=
    // TODO: Implement=0A=
  };=0A=
=0A=
  contextPrototype.arcTo =3D function() {=0A=
    // TODO: Implement=0A=
  };=0A=
=0A=
  contextPrototype.createPattern =3D function() {=0A=
    return new CanvasPattern_;=0A=
  };=0A=
=0A=
  // Gradient / Pattern Stubs=0A=
  function CanvasGradient_(aType) {=0A=
    this.type_ =3D aType;=0A=
    this.x0_ =3D 0;=0A=
    this.y0_ =3D 0;=0A=
    this.r0_ =3D 0;=0A=
    this.x1_ =3D 0;=0A=
    this.y1_ =3D 0;=0A=
    this.r1_ =3D 0;=0A=
    this.colors_ =3D [];=0A=
  }=0A=
=0A=
  CanvasGradient_.prototype.addColorStop =3D function(aOffset, aColor) {=0A=
    aColor =3D processStyle(aColor);=0A=
    this.colors_.push({offset: aOffset,=0A=
                       color: aColor.color,=0A=
                       alpha: aColor.alpha});=0A=
  };=0A=
=0A=
  function CanvasPattern_() {}=0A=
=0A=
  // set up externs=0A=
  G_vmlCanvasManager =3D G_vmlCanvasManager_;=0A=
  CanvasRenderingContext2D =3D CanvasRenderingContext2D_;=0A=
  CanvasGradient =3D CanvasGradient_;=0A=
  CanvasPattern =3D CanvasPattern_;=0A=
=0A=
})();=0A=
=0A=
} // if=0A=

------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/clientlib/prototype/ProtoChart/ProtoChart.js?cachekeY=515488b2-en

/**=0A=
 * Class: ProtoChart =0A=
 * Version: v0.5 beta=0A=
 * =0A=
 * ProtoChart is a charting lib on top of Prototype.=0A=
 * This library is heavily motivated by excellent work done by:=0A=
 * * Flot <http://code.google.com/p/flot/>=0A=
 * * Flotr <http://solutoire.com/flotr/>=0A=
 * =0A=
 * Complete examples can be found at: =
<http://www.deensoft.com/lab/protochart>=0A=
 */=0A=
=0A=
/**=0A=
 * Events:=0A=
 * ProtoChart:mousemove - Fired when mouse is moved over the chart=0A=
 * ProtoChart:plotclick - Fired when graph is clicked=0A=
 * ProtoChart:dataclick - Fired when graph is clicked AND the click is =
on a data point=0A=
 * ProtoChart:selected	- Fired when certain region on the graph is =
selected=0A=
 * ProtoChart:hit		- Fired when mouse is moved near or over certain data =
point on the graph=0A=
 */=0A=
=0A=
=0A=
if(!Proto) var Proto =3D {};=0A=
=0A=
Proto.Chart =3D Class.create({=0A=
	/**=0A=
	 * Function: =0A=
	 * {Object} elem=0A=
	 * {Object} data=0A=
	 * {Object} options=0A=
	 */=0A=
	initialize: function(elem, data, options)=0A=
	{=0A=
		options =3D options || {};=0A=
		this.graphData =3D [];=0A=
		/**=0A=
		 * Property: options=0A=
		 * =0A=
		 * Description: Various options can be set. More details in =
description.=0A=
		 * =0A=
		 * colors:=0A=
		 * {Array}		- pass in a array which contains strings of colors you =
want to use. Default has 6 color set.=0A=
		 * =0A=
		 * legend:=0A=
		 * {BOOL} 		- show				- if you want to show the legend. Default is =
false=0A=
		 * {integer} 	- noColumns			- Number of columns for the legend. =
Default is 1=0A=
		 * {function} 	- labelFormatter	- A function that returns a string. =
The function is called with a string and is expected to return a string. =
Default =3D null=0A=
		 * {string}		- labelBoxBorderColor - border color for the little label =
boxes. Default #CCC=0A=
		 * {HTMLElem}	- container			- an HTML id or HTML element where the =
legend should be rendered. If left null means to put the legend on top =
of the Chart=0A=
		 * {string}		- position			- position for the legend on the Chart. =
Default value 'ne'=0A=
		 * {integer}	- margin			- default valud of 5=0A=
		 * {string} 	- backgroundColor	- default to null (which means =
auto-detect)=0A=
		 * {float} 		- backgroundOpacity - leave it 0 to avoid background=0A=
		 * =0A=
		 * xaxis (yaxis) options:=0A=
		 * {string} 	- mode 		- default is null but you can pass a string =
"time" to indicate time series=0A=
		 * {integer}	- min=0A=
		 * {integer}	- max=0A=
		 * {float}		- autoscaleMargin - in % to add if auto-setting min/max=0A=
		 * {mixed}		- ticks - either [1, 3] or [[1, "a"], 3] or a function =
which gets axis info and returns ticks=0A=
		 * {function} 	- tickFormatter - A function that returns a string as a =
tick label. Default is null=0A=
		 * {float}		- tickDecimals=0A=
		 * {integer}	- tickSize=0A=
		 * {integer} 	- minTickSize=0A=
		 * {array}		- monthNames=0A=
		 * {string}		- timeformat=0A=
		 * =0A=
		 * Points / Lines / Bars options:=0A=
		 * {bool}		- show, default is false=0A=
		 * {integer}	- radius: default is 3=0A=
		 * {integer}	- lineWidth : default is 2=0A=
		 * {bool}		- fill : default is true=0A=
		 * {string}		- fillColor: default is #ffffff=0A=
		 * =0A=
		 * Grid options:=0A=
		 * {string}		- color=0A=
		 * {string}		- backgroundColor 	- defualt is *null*=0A=
		 * {string}		- tickColor			- default is *#dddddd*=0A=
		 * {integer}	- labelMargin		- should be in pixels default is 3=0A=
		 * {integer}	- borderWidth		- default *1*=0A=
		 * {bool}		- clickable 		- default *null* - pass in TRUE if you wish =
to monitor click events=0A=
		 * {mixed}		- coloredAreas 		- default *null* - pass in mixed object =
eg. {x1, x2}=0A=
		 * {string}		- coloredAreasColor	- default *#f4f4f4*=0A=
		 * {bool}		- drawXAxis			- default *true*=0A=
		 * {bool}		- drawYAxis			- default *true*=0A=
		 * =0A=
		 * selection options:=0A=
		 * {string}		- mode : either "x", "y" or "xy"=0A=
		 * {string}		- color : string=0A=
		 */=0A=
		this.options =3D this.merge(options,{=0A=
			colors: ["#edc240", "#00A8F0", "#C0D800", "#cb4b4b", "#4da74d", =
"#9440ed"],=0A=
            legend: {=0A=
                show: false,=0A=
                noColumns: 1,=0A=
                labelFormatter: null,=0A=
                labelBoxBorderColor: "#ccc",=0A=
                container: null, =0A=
                position: "ne",=0A=
                margin: 5,=0A=
                backgroundColor: null,=0A=
                backgroundOpacity: 0.85=0A=
            },=0A=
            xaxis: {=0A=
				mode: null, =0A=
                min: null,=0A=
                max: null,=0A=
                autoscaleMargin: null,=0A=
                ticks: null,=0A=
                tickFormatter: null,=0A=
                tickDecimals: null,=0A=
                tickSize: null,=0A=
                minTickSize: null,=0A=
                monthNames: null,=0A=
                timeformat: null=0A=
            },=0A=
            yaxis: {=0A=
				mode: null,=0A=
				min: null,=0A=
				max: null,=0A=
				ticks: null,=0A=
				tickFormatter: null,=0A=
				tickDecimals: null,=0A=
				tickSize: null,=0A=
				minTickSize: null,=0A=
				monthNames: null,=0A=
				timeformat: null,				=0A=
                autoscaleMargin: 0.02=0A=
            },=0A=
=0A=
            points: {=0A=
                show: false,=0A=
                radius: 3,=0A=
                lineWidth: 2,=0A=
                fill: true,=0A=
                fillColor: "#ffffff"=0A=
            },=0A=
            lines: {=0A=
                show: false,=0A=
                lineWidth: 2,=0A=
                fill: false,=0A=
                fillColor: null=0A=
            },=0A=
            bars: {=0A=
                show: false,=0A=
                lineWidth: 2,=0A=
                barWidth: 1,=0A=
                fill: true,=0A=
                fillColor: null,=0A=
				showShadow: false,=0A=
				fillOpacity: 0.4,=0A=
				autoScale: true=0A=
            },=0A=
			pies: {=0A=
				show: false,=0A=
				radius: 50,=0A=
				borderWidth: 1,=0A=
				fill: true,=0A=
				fillColor: null,=0A=
				fillOpacity: 0.90,=0A=
				labelWidth: 30,=0A=
				fontSize: 11,=0A=
				autoScale: true=0A=
			},=0A=
            grid: {=0A=
                color: "#545454",=0A=
                backgroundColor: null,=0A=
                tickColor: "#dddddd",=0A=
                labelMargin: 3,=0A=
                borderWidth: 1,=0A=
                clickable: null,=0A=
                coloredAreas: null,=0A=
                coloredAreasColor: "#f4f4f4",=0A=
				drawXAxis: true,=0A=
				drawYAxis: true=0A=
            },=0A=
			mouse: {=0A=
				track: false,=0A=
				position: 'se',=0A=
				fixedPosition: true,=0A=
				clsName: 'mouseValHolder',=0A=
				trackFormatter: this.defaultTrackFormatter,=0A=
				margin: 3,=0A=
				color: '#ff3f19',=0A=
				trackDecimals: 1,=0A=
				sensibility: 2,=0A=
				radius: 5,=0A=
				lineColor: '#cb4b4b'=0A=
			},=0A=
            selection: {=0A=
                mode: null,=0A=
                color: "#97CBFF"=0A=
            },=0A=
			allowDataClick: true,=0A=
			makeRandomColor: false,=0A=
            shadowSize: 4			=0A=
		});=0A=
		=0A=
		/*=0A=
		 * Local variables.=0A=
		 */=0A=
		this.canvas =3D null; =0A=
		this.overlay =3D null;=0A=
		this.eventHolder =3D null;=0A=
		this.context =3D null;=0A=
		this.overlayContext =3D null;=0A=
		=0A=
		this.domObj =3D $(elem);=0A=
=0A=
		this.xaxis =3D {};=0A=
		this.yaxis =3D {};=0A=
		this.chartOffset =3D {left: 0, right: 0, top: 0, bottom: 0};=0A=
		this.yLabelMaxWidth =3D 0;=0A=
		this.yLabelMaxHeight =3D 0;=0A=
		this.xLabelBoxWidth =3D 0;=0A=
		this.canvasWidth =3D 0;=0A=
		this.canvasHeight =3D 0;=0A=
		this.chartWidth =3D 0;=0A=
		this.chartHeight =3D 0;=0A=
		this.hozScale =3D 0;=0A=
		this.vertScale =3D 0;=0A=
		this.workarounds =3D {};=0A=
		=0A=
		this.domObj =3D $(elem);=0A=
		=0A=
		this.barDataRange =3D [];=0A=
		=0A=
        this.lastMousePos =3D { pageX: null, pageY: null };=0A=
        this.selection =3D { first: { x: -1, y: -1}, second: { x: -1, y: =
-1} };=0A=
        this.prevSelection =3D null;=0A=
        this.selectionInterval =3D null;=0A=
        this.ignoreClick =3D false;	=0A=
		this.prevHit =3D null;=0A=
			=0A=
		if(this.options.makeRandomColor)=0A=
			this.options.color =3D this.makeRandomColor(this.options.colors);=0A=
		=0A=
		this.setData(data);=0A=
		this.constructCanvas();=0A=
		this.setupGrid();=0A=
		this.draw();=0A=
	},=0A=
	/**=0A=
	 * Private function internally used.=0A=
	 */=0A=
	merge: function(src, dest)=0A=
	{=0A=
		var result =3D dest || {};=0A=
		for(var i in src){		  =0A=
			result[i] =3D (typeof(src[i]) =3D=3D 'object' && !(src[i].constructor =
=3D=3D Array || src[i].constructor =3D=3D RegExp)) ? this.merge(src[i], =
dest[i]) : result[i] =3D src[i];		=0A=
		}=0A=
		return result;	=0A=
	},=0A=
	/**=0A=
	 * Function: setData=0A=
	 * {Object} data=0A=
	 * =0A=
	 * Description:=0A=
	 * Sets datasoruces properly then sets the Bar Width accordingly, then =
copies the default data options and then processes the graph data=0A=
	 * =0A=
	 * Returns: none=0A=
	 * =0A=
	 */	=0A=
	setData: function(data) =0A=
	{=0A=
        this.graphData =3D this.parseData(data);		=0A=
		this.setBarWidth();=0A=
        this.copyGraphDataOptions();=0A=
        this.processGraphData();=0A=
    },=0A=
	/**=0A=
	 * Function: parseData=0A=
	 * {Object} data=0A=
	 * =0A=
	 * Return: =0A=
	 * {Object} result=0A=
	 * =0A=
	 * Description:=0A=
	 * Takes the provided data object and converts it into generic data =
that we can understand. User can pass in data in 3 different ways:=0A=
	 * - [d1, d2]=0A=
	 * - [{data: d1, label: "data1"}, {data: d2, label: "data2"}]=0A=
	 * - [d1, {data: d1, label: "data1"}]=0A=
	 * =0A=
	 * This function parses these senarios and makes it readable=0A=
	 */=0A=
	parseData: function(data)=0A=
	{=0A=
		var res =3D [];=0A=
		data.each(function(d){=0A=
			var s;=0A=
			if(d.data) {=0A=
				s =3D {};=0A=
				for(var v in d) {=0A=
					s[v] =3D d[v];=0A=
				}=0A=
			}=0A=
			else {=0A=
				s =3D {data: d};=0A=
			}=0A=
			res.push(s);=0A=
		}.bind(this));=0A=
		return res;=0A=
	},=0A=
	/**=0A=
	 * function: makeRandomColor=0A=
	 * {Object} colorSet=0A=
	 * =0A=
	 * Return: =0A=
	 * {Array} result - array containing random colors=0A=
	 */=0A=
	makeRandomColor: function(colorSet)=0A=
	{=0A=
		var randNum =3D Math.floor(Math.random() * colorSet.length);=0A=
		var randArr =3D [];=0A=
		var newArr =3D [];=0A=
		randArr.push(randNum);=0A=
		=0A=
		while(randArr.length < colorSet.length)=0A=
		{=0A=
			var tempNum =3D Math.floor(Math.random() * colorSet.length);=0A=
	=0A=
			while(checkExisted(tempNum, randArr))=0A=
				tempNum =3D Math.floor(Math.random() * colorSet.length);=0A=
				=0A=
			randArr.push(tempNum);=0A=
		}=0A=
		=0A=
		randArr.each(function(ra){=0A=
			newArr.push(colorSet[ra]);=0A=
			=0A=
		}.bind(this));=0A=
		return newArr;		=0A=
	},=0A=
	/**=0A=
	 * function: checkExisted=0A=
	 * {Object} needle=0A=
	 * {Object} haystack=0A=
	 * =0A=
	 * return: =0A=
	 * {bool} existed - true if it finds needle in the haystack=0A=
	 */=0A=
	checkExisted: function(needle, haystack)=0A=
	{=0A=
		var existed =3D false;=0A=
		haystack.each(function(aNeedle){=0A=
			if(aNeedle =3D=3D needle) {=0A=
				existed =3D true;=0A=
				throw $break;=0A=
			}=0A=
		}.bind(this));=0A=
		return existed;=0A=
	},=0A=
	/**=0A=
	 * function: setBarWidth=0A=
	 * =0A=
	 * Description: sets the bar width for Bar Graph, you should enable =
*autoScale* property for bar graph=0A=
	 */=0A=
	setBarWidth: function()=0A=
	{=0A=
		if(this.options.bars.show && this.options.bars.autoScale)=0A=
		{=0A=
			this.options.bars.barWidth =3D 1 / this.graphData.length / 1.2;	=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * Function: copyGraphDataOptions=0A=
	 * =0A=
	 * Description: Private function that goes through each graph data =
(series) and assigned the graph=0A=
	 * properties to it.=0A=
	 */=0A=
	copyGraphDataOptions: function()=0A=
	{=0A=
		var i, neededColors =3D this.graphData.length, usedColors =3D [], =
assignedColors =3D [];=0A=
		=0A=
		this.graphData.each(function(gd){=0A=
			var sc =3D gd.color;=0A=
			if(sc) {=0A=
				--neededColors;=0A=
				if(Object.isNumber(sc)) {=0A=
					assignedColors.push(sc);=0A=
				}=0A=
				else {=0A=
					usedColors.push(this.parseColor(sc));=0A=
				}=0A=
			}=0A=
		}.bind(this));=0A=
		=0A=
		=0A=
		assignedColors.each(function(ac){=0A=
			neededColors =3D Math.max(neededColors, ac + 1);=0A=
		});=0A=
=0A=
        var colors =3D [];=0A=
        var variation =3D 0;=0A=
        i =3D 0;=0A=
        while (colors.length < neededColors) {=0A=
            var c;=0A=
            if (this.options.colors.length =3D=3D i) {=0A=
				c =3D new Proto.Color(100, 100, 100);=0A=
			}=0A=
			else {=0A=
				c =3D this.parseColor(this.options.colors[i]);=0A=
			}=0A=
=0A=
            var sign =3D variation % 2 =3D=3D 1 ? -1 : 1;=0A=
            var factor =3D 1 + sign * Math.ceil(variation / 2) * 0.2;=0A=
            c.scale(factor, factor, factor);=0A=
=0A=
            colors.push(c);=0A=
            =0A=
            ++i;=0A=
            if (i >=3D this.options.colors.length) {=0A=
                i =3D 0;=0A=
                ++variation;=0A=
            }=0A=
        }=0A=
=0A=
        var colorIndex =3D 0, s;=0A=
		=0A=
		this.graphData.each(function(gd){=0A=
			if(gd.color =3D=3D null)=0A=
			{=0A=
				gd.color =3D colors[colorIndex].toString();=0A=
				++colorIndex;=0A=
			}=0A=
			else if(Object.isNumber(gd.color)) {=0A=
				gd.color =3D colors[gd.color].toString();=0A=
			}=0A=
			=0A=
            gd.lines =3D Object.extend(Object.clone(this.options.lines), =
gd.lines); =0A=
            gd.points =3D =
Object.extend(Object.clone(this.options.points), gd.points); =0A=
            gd.bars =3D Object.extend(Object.clone(this.options.bars), =
gd.bars); =0A=
            gd.mouse =3D Object.extend(Object.clone(this.options.mouse), =
gd.mouse);=0A=
            if (gd.shadowSize =3D=3D null) {=0A=
                gd.shadowSize =3D this.options.shadowSize;=0A=
			}=0A=
		}.bind(this));=0A=
			=0A=
	},=0A=
	/**=0A=
	 * Function: processGraphData=0A=
	 * =0A=
	 * Description: processes graph data, setup xaxis and yaxis min and max =
points. =0A=
	 */=0A=
	processGraphData: function() {=0A=
		=0A=
		this.xaxis.datamin =3D this.yaxis.datamin =3D Number.MAX_VALUE;=0A=
		this.xaxis.datamax =3D this.yaxis.datamax =3D Number.MIN_VALUE;=0A=
			=0A=
		this.graphData.each(function(gd) {=0A=
			var data =3D gd.data;=0A=
			data.each(function(d){=0A=
				if(d =3D=3D null) {=0A=
					return;=0A=
				}=0A=
				=0A=
				var x =3D d[0], y =3D d[1];=0A=
				if(!x || !y || isNaN(x =3D +x) || isNaN(y =3D +y)) {=0A=
					d =3D null;=0A=
					return;=0A=
				}=0A=
				=0A=
				if (x < this.xaxis.datamin)=0A=
					this.xaxis.datamin =3D x;=0A=
				if (x > this.xaxis.datamax)=0A=
					this.xaxis.datamax =3D x;=0A=
				if (y < this.yaxis.datamin)=0A=
					this.yaxis.datamin =3D y;=0A=
				if (y > this.yaxis.datamax)=0A=
					this.yaxis.datamax =3D y;=0A=
			}.bind(this));=0A=
		}.bind(this));=0A=
=0A=
		=0A=
		if (this.xaxis.datamin =3D=3D Number.MAX_VALUE)=0A=
			this.xaxis.datamin =3D 0;=0A=
		if (this.yaxis.datamin =3D=3D Number.MAX_VALUE)=0A=
			this.yaxis.datamin =3D 0;=0A=
		if (this.xaxis.datamax =3D=3D Number.MIN_VALUE)=0A=
			this.xaxis.datamax =3D 1;=0A=
		if (this.yaxis.datamax =3D=3D Number.MIN_VALUE)=0A=
			this.yaxis.datamax =3D 1;=0A=
	},=0A=
	/**=0A=
	 * Function: constructCanvas=0A=
	 * =0A=
	 * Description: constructs the main canvas for drawing. It replicates =
the HTML elem (usually DIV) passed=0A=
	 * in via constructor. If there is no height/width assigned to the HTML =
elem then we take a default size=0A=
	 * of 400px (width) and 300px (height)=0A=
	 */=0A=
	constructCanvas: function() {=0A=
=0A=
		this.canvasWidth =3D this.domObj.getWidth();=0A=
		this.canvasHeight =3D this.domObj.getHeight();=0A=
		this.domObj.update(""); // clear target=0A=
		this.domObj.setStyle({=0A=
			"position": "relative"=0A=
		}); =0A=
=0A=
		if (this.canvasWidth <=3D 0) {=0A=
			this.canvasWdith =3D 400;=0A=
		}=0A=
		if(this.canvasHeight <=3D 0) {=0A=
			this.canvasHeight =3D 300;=0A=
		}=0A=
		=0A=
		this.canvas =3D (Prototype.Browser.IE) ? =
document.createElement("canvas") : new Element("CANVAS", {'width': =
this.canvasWidth, 'height': this.canvasHeight});=0A=
		Element.extend(this.canvas);=0A=
		this.canvas.style.width =3D this.canvasWidth + "px";=0A=
		this.canvas.style.height =3D this.canvasHeight + "px";=0A=
		=0A=
		this.domObj.appendChild(this.canvas);=0A=
		=0A=
		if (Prototype.Browser.IE) // excanvas hack=0A=
		{=0A=
			this.canvas =3D $(window.G_vmlCanvasManager.initElement(this.canvas));=0A=
		}=0A=
		this.canvas =3D $(this.canvas);=0A=
		=0A=
		this.context =3D this.canvas.getContext("2d");=0A=
=0A=
		this.overlay =3D (Prototype.Browser.IE) ? =
document.createElement("canvas") :  new Element("CANVAS", {'width': =
this.canvasWidth, 'height': this.canvasHeight});=0A=
		Element.extend(this.overlay);=0A=
		this.overlay.style.width =3D this.canvasWidth + "px";=0A=
		this.overlay.style.height =3D this.canvasHeight + "px";=0A=
		this.overlay.style.position =3D "absolute";=0A=
		this.overlay.style.left =3D "0px";=0A=
		this.overlay.style.right =3D "0px";=0A=
		=0A=
		this.overlay.setStyle({=0A=
			'position': 'absolute',=0A=
			'left': '0px',=0A=
			'right': '0px'=0A=
		});=0A=
		this.domObj.appendChild(this.overlay);=0A=
		=0A=
		if (Prototype.Browser.IE) {=0A=
			this.overlay =3D =
$(window.G_vmlCanvasManager.initElement(this.overlay));=0A=
		}=0A=
		=0A=
		this.overlay =3D $(this.overlay);=0A=
		this.overlayContext =3D this.overlay.getContext("2d");=0A=
=0A=
		if(this.options.selection.mode)=0A=
		{=0A=
			this.overlay.observe('mousedown', this.onMouseDown.bind(this));=0A=
			this.overlay.observe('mousemove', this.onMouseMove.bind(this));=0A=
		}=0A=
		if(this.options.grid.clickable) {=0A=
			this.overlay.observe('click', this.onClick.bind(this));=0A=
		}=0A=
		if(this.options.mouse.track)=0A=
		{=0A=
			this.overlay.observe('mousemove', this.onMouseMove.bind(this));=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * function: setupGrid=0A=
	 * =0A=
	 * Description: a container function that does a few interesting things.=0A=
	 * =0A=
	 * 1. calls <extendXRangeIfNeededByBar> function which makes sure that =
our axis are expanded if needed=0A=
	 * =0A=
	 * 2. calls <setRange> function providing xaxis options which fixes the =
ranges according to data points=0A=
	 * =0A=
	 * 3. calls <prepareTickGeneration> function for xaxis which generates =
ticks according to options provided by user=0A=
	 * =0A=
	 * 4. calls <setTicks> function for xaxis that sets the ticks=0A=
	 * =0A=
	 * similar sequence is called for y-axis. =0A=
	 * =0A=
	 * At the end if this is a pie chart than we insert Labels (around the =
pie chart) via <insertLabels> and we also call <insertLegend>=0A=
	 */=0A=
	setupGrid: function()=0A=
	{=0A=
		if(this.options.bars.show)=0A=
		{=0A=
			this.xaxis.max +=3D 0.5;=0A=
			this.xaxis.min -=3D 0.5;=0A=
		}=0A=
		//x-axis=0A=
		this.extendXRangeIfNeededByBar();=0A=
		this.setRange(this.xaxis, this.options.xaxis);=0A=
		this.prepareTickGeneration(this.xaxis, this.options.xaxis);=0A=
		this.setTicks(this.xaxis, this.options.xaxis);=0A=
		=0A=
		=0A=
		//y-axis=0A=
		this.setRange(this.yaxis, this.options.yaxis);=0A=
		this.prepareTickGeneration(this.yaxis, this.options.yaxis);=0A=
		this.setTicks(this.yaxis, this.options.yaxis);=0A=
		this.setSpacing();=0A=
		=0A=
		if(!this.options.pies.show)=0A=
		{=0A=
			this.insertLabels();=0A=
		}=0A=
		this.insertLegend();=0A=
	},=0A=
	/**=0A=
	 * function: setRange=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} axis=0A=
	 * {Object} axisOptions=0A=
	 */=0A=
	setRange: function(axis, axisOptions) {=0A=
		var min =3D axisOptions.min !=3D null ? axisOptions.min : axis.datamin;=0A=
		var max =3D axisOptions.max !=3D null ? axisOptions.max : axis.datamax;=0A=
=0A=
		if (max - min =3D=3D 0.0) {=0A=
			// degenerate case=0A=
			var widen;=0A=
			if (max =3D=3D 0.0)=0A=
				widen =3D 1.0;=0A=
			else=0A=
				widen =3D 0.01;=0A=
=0A=
			min -=3D widen;=0A=
			max +=3D widen;=0A=
		}=0A=
		else {=0A=
			// consider autoscaling=0A=
			var margin =3D axisOptions.autoscaleMargin;=0A=
			if (margin !=3D null) {=0A=
				if (axisOptions.min =3D=3D null) {=0A=
					min -=3D (max - min) * margin;=0A=
					// make sure we don't go below zero if all values=0A=
					// are positive=0A=
					if (min < 0 && axis.datamin >=3D 0)=0A=
						min =3D 0;=0A=
				}=0A=
				if (axisOptions.max =3D=3D null) {=0A=
					max +=3D (max - min) * margin;=0A=
					if (max > 0 && axis.datamax <=3D 0)=0A=
						max =3D 0;=0A=
				}=0A=
			}=0A=
		}=0A=
		axis.min =3D min;=0A=
		axis.max =3D max;=0A=
	},=0A=
	/**=0A=
	 * function: prepareTickGeneration=0A=
	 * =0A=
	 * Parameters:=0A=
	 * {Object} axis=0A=
	 * {Object} axisOptions=0A=
	 */=0A=
	prepareTickGeneration: function(axis, axisOptions) {=0A=
		// estimate number of ticks=0A=
		var noTicks;=0A=
		if (Object.isNumber(axisOptions.ticks) && axisOptions.ticks > 0)=0A=
			noTicks =3D axisOptions.ticks;=0A=
		else if (axis =3D=3D this.xaxis)=0A=
			noTicks =3D this.canvasWidth / 100;=0A=
		else=0A=
			noTicks =3D this.canvasHeight / 60;=0A=
		=0A=
		var delta =3D (axis.max - axis.min) / noTicks;=0A=
		var size, generator, unit, formatter, i, magn, norm;=0A=
=0A=
		if (axisOptions.mode =3D=3D "time") {=0A=
			function formatDate(d, fmt, monthNames) {=0A=
				var leftPad =3D function(n) {=0A=
					n =3D "" + n;=0A=
					return n.length =3D=3D 1 ? "0" + n : n;=0A=
				};=0A=
				=0A=
				var r =3D [];=0A=
				var escape =3D false;=0A=
				if (monthNames =3D=3D null)=0A=
					monthNames =3D ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", =
"Aug", "Sep", "Oct", "Nov", "Dec"];=0A=
				for (var i =3D 0; i < fmt.length; ++i) {=0A=
					var c =3D fmt.charAt(i);=0A=
					=0A=
					if (escape) {=0A=
						switch (c) {=0A=
						case 'h': c =3D "" + d.getHours(); break;=0A=
						case 'H': c =3D leftPad(d.getHours()); break;=0A=
						case 'M': c =3D leftPad(d.getMinutes()); break;=0A=
						case 'S': c =3D leftPad(d.getSeconds()); break;=0A=
						case 'd': c =3D "" + d.getDate(); break;=0A=
						case 'm': c =3D "" + (d.getMonth() + 1); break;=0A=
						case 'y': c =3D "" + d.getFullYear(); break;=0A=
						case 'b': c =3D "" + monthNames[d.getMonth()]; break;=0A=
						}=0A=
						r.push(c);=0A=
						escape =3D false;=0A=
					}=0A=
					else {=0A=
						if (c =3D=3D "%")=0A=
							escape =3D true;=0A=
						else=0A=
							r.push(c);=0A=
					}=0A=
				}=0A=
				return r.join("");=0A=
			}=0A=
			=0A=
				=0A=
			// map of app. size of time units in milliseconds=0A=
			var timeUnitSize =3D {=0A=
				"second": 1000,=0A=
				"minute": 60 * 1000,=0A=
				"hour": 60 * 60 * 1000,=0A=
				"day": 24 * 60 * 60 * 1000,=0A=
				"month": 30 * 24 * 60 * 60 * 1000,=0A=
				"year": 365.2425 * 24 * 60 * 60 * 1000=0A=
			};=0A=
=0A=
=0A=
			// the allowed tick sizes, after 1 year we use=0A=
			// an integer algorithm=0A=
			var spec =3D [=0A=
				[1, "second"], [2, "second"], [5, "second"], [10, "second"],=0A=
				[30, "second"], =0A=
				[1, "minute"], [2, "minute"], [5, "minute"], [10, "minute"],=0A=
				[30, "minute"], =0A=
				[1, "hour"], [2, "hour"], [4, "hour"],=0A=
				[8, "hour"], [12, "hour"],=0A=
				[1, "day"], [2, "day"], [3, "day"],=0A=
				[0.25, "month"], [0.5, "month"], [1, "month"],=0A=
				[2, "month"], [3, "month"], [6, "month"],=0A=
				[1, "year"]=0A=
			];=0A=
=0A=
			var minSize =3D 0;=0A=
			if (axisOptions.minTickSize !=3D null) {=0A=
				if (typeof axisOptions.tickSize =3D=3D "number")=0A=
					minSize =3D axisOptions.tickSize;=0A=
				else=0A=
					minSize =3D axisOptions.minTickSize[0] * =
timeUnitSize[axisOptions.minTickSize[1]];=0A=
			}=0A=
			=0A=
			for (i =3D 0; i < spec.length - 1; ++i) {=0A=
				if (delta < (spec[i][0] * timeUnitSize[spec[i][1]] + spec[i + 1][0] =
* timeUnitSize[spec[i + 1][1]]) / 2 && spec[i][0] * =
timeUnitSize[spec[i][1]] >=3D minSize) {=0A=
					break;=0A=
				}=0A=
			}=0A=
			=0A=
			size =3D spec[i][0];=0A=
			unit =3D spec[i][1];=0A=
			=0A=
			// special-case the possibility of several years=0A=
			if (unit =3D=3D "year") {=0A=
				magn =3D Math.pow(10, Math.floor(Math.log(delta / timeUnitSize.year) =
/ Math.LN10));=0A=
				norm =3D (delta / timeUnitSize.year) / magn;=0A=
				if (norm < 1.5)=0A=
					size =3D 1;=0A=
				else if (norm < 3)=0A=
					size =3D 2;=0A=
				else if (norm < 7.5)=0A=
					size =3D 5;=0A=
				else=0A=
					size =3D 10;=0A=
=0A=
				size *=3D magn;=0A=
			}=0A=
=0A=
			if (axisOptions.tickSize) {=0A=
				size =3D axisOptions.tickSize[0];=0A=
				unit =3D axisOptions.tickSize[1];=0A=
			}=0A=
			=0A=
			var floorInBase =3D this.floorInBase; //gives us a reference to a =
global function.. =0A=
			=0A=
			generator =3D function(axis) {=0A=
				var ticks =3D [],=0A=
					tickSize =3D axis.tickSize[0], unit =3D axis.tickSize[1],=0A=
					d =3D new Date(axis.min);=0A=
				=0A=
				var step =3D tickSize * timeUnitSize[unit];=0A=
				=0A=
				=0A=
				=0A=
				if (unit =3D=3D "second")=0A=
					d.setSeconds(floorInBase(d.getSeconds(), tickSize));=0A=
				if (unit =3D=3D "minute")=0A=
					d.setMinutes(floorInBase(d.getMinutes(), tickSize));=0A=
				if (unit =3D=3D "hour")=0A=
					d.setHours(floorInBase(d.getHours(), tickSize));=0A=
				if (unit =3D=3D "month")=0A=
					d.setMonth(floorInBase(d.getMonth(), tickSize));=0A=
				if (unit =3D=3D "year")=0A=
					d.setFullYear(floorInBase(d.getFullYear(), tickSize));=0A=
				=0A=
				// reset smaller components=0A=
				d.setMilliseconds(0);=0A=
				if (step >=3D timeUnitSize.minute)=0A=
					d.setSeconds(0);=0A=
				if (step >=3D timeUnitSize.hour)=0A=
					d.setMinutes(0);=0A=
				if (step >=3D timeUnitSize.day)=0A=
					d.setHours(0);=0A=
				if (step >=3D timeUnitSize.day * 4)=0A=
					d.setDate(1);=0A=
				if (step >=3D timeUnitSize.year)=0A=
					d.setMonth(0);=0A=
=0A=
=0A=
				var carry =3D 0, v;=0A=
				do {=0A=
					v =3D d.getTime();=0A=
					ticks.push({ v: v, label: axis.tickFormatter(v, axis) });=0A=
					if (unit =3D=3D "month") {=0A=
						if (tickSize < 1) {=0A=
							d.setDate(1);=0A=
							var start =3D d.getTime();=0A=
							d.setMonth(d.getMonth() + 1);=0A=
							var end =3D d.getTime();=0A=
							d.setTime(v + carry * timeUnitSize.hour + (end - start) * =
tickSize);=0A=
							carry =3D d.getHours();=0A=
							d.setHours(0);=0A=
						}=0A=
						else=0A=
							d.setMonth(d.getMonth() + tickSize);=0A=
					}=0A=
					else if (unit =3D=3D "year") {=0A=
						d.setFullYear(d.getFullYear() + tickSize);=0A=
					}=0A=
					else=0A=
						d.setTime(v + step);=0A=
				} while (v < axis.max);=0A=
=0A=
				return ticks;=0A=
			};=0A=
=0A=
			formatter =3D function (v, axis) {=0A=
				var d =3D new Date(v);=0A=
=0A=
				// first check global format=0A=
				if (axisOptions.timeformat !=3D null)=0A=
					return formatDate(d, axisOptions.timeformat, =
axisOptions.monthNames);=0A=
				=0A=
				var t =3D axis.tickSize[0] * timeUnitSize[axis.tickSize[1]];=0A=
				var span =3D axis.max - axis.min;=0A=
				=0A=
				if (t < timeUnitSize.minute)=0A=
					fmt =3D "%h:%M:%S";=0A=
				else if (t < timeUnitSize.day) {=0A=
					if (span < 2 * timeUnitSize.day)=0A=
						fmt =3D "%h:%M";=0A=
					else=0A=
						fmt =3D "%b %d %h:%M";=0A=
				}=0A=
				else if (t < timeUnitSize.month)=0A=
					fmt =3D "%b %d";=0A=
				else if (t < timeUnitSize.year) {=0A=
					if (span < timeUnitSize.year)=0A=
						fmt =3D "%b";=0A=
					else=0A=
						fmt =3D "%b %y";=0A=
				}=0A=
				else=0A=
					fmt =3D "%y";=0A=
				=0A=
				return formatDate(d, fmt, axisOptions.monthNames);=0A=
			};=0A=
		}=0A=
		else {=0A=
			// pretty rounding of base-10 numbers=0A=
			var maxDec =3D axisOptions.tickDecimals;=0A=
			var dec =3D -Math.floor(Math.log(delta) / Math.LN10);=0A=
			if (maxDec !=3D null && dec > maxDec)=0A=
				dec =3D maxDec;=0A=
			=0A=
			magn =3D Math.pow(10, -dec);=0A=
			norm =3D delta / magn; // norm is between 1.0 and 10.0=0A=
			=0A=
			if (norm < 1.5)=0A=
				size =3D 1;=0A=
			else if (norm < 3) {=0A=
				size =3D 2;=0A=
				// special case for 2.5, requires an extra decimal=0A=
				if (norm > 2.25 && (maxDec =3D=3D null || dec + 1 <=3D maxDec)) {=0A=
					size =3D 2.5;=0A=
					++dec;=0A=
				}=0A=
			}=0A=
			else if (norm < 7.5)=0A=
				size =3D 5;=0A=
			else=0A=
				size =3D 10;=0A=
=0A=
			size *=3D magn;=0A=
			=0A=
			if (axisOptions.minTickSize !=3D null && size < =
axisOptions.minTickSize)=0A=
				size =3D axisOptions.minTickSize;=0A=
=0A=
			if (axisOptions.tickSize !=3D null)=0A=
				size =3D axisOptions.tickSize;=0A=
			=0A=
			axis.tickDecimals =3D Math.max(0, (maxDec !=3D null) ? maxDec : dec);=0A=
			=0A=
			var floorInBase =3D this.floorInBase;=0A=
			=0A=
			generator =3D function (axis) {=0A=
				var ticks =3D [];=0A=
				var start =3D floorInBase(axis.min, axis.tickSize);=0A=
				// then spew out all possible ticks=0A=
				var i =3D 0, v;=0A=
				do {=0A=
					v =3D start + i * axis.tickSize;=0A=
					ticks.push({ v: v, label: axis.tickFormatter(v, axis) });=0A=
					++i;=0A=
				} while (v < axis.max);=0A=
				return ticks;=0A=
			};=0A=
=0A=
			formatter =3D function (v, axis) {=0A=
				if(v) {=0A=
				return v.toFixed(axis.tickDecimals);=0A=
				}=0A=
				return 0;=0A=
			};=0A=
		}=0A=
=0A=
		axis.tickSize =3D unit ? [size, unit] : size;=0A=
		axis.tickGenerator =3D generator;=0A=
		if (Object.isFunction(axisOptions.tickFormatter))=0A=
			axis.tickFormatter =3D function (v, axis) { return "" + =
axisOptions.tickFormatter(v, axis); };=0A=
		else=0A=
			axis.tickFormatter =3D formatter;=0A=
	},=0A=
	/**=0A=
	 * function: extendXRangeIfNeededByBar=0A=
	 */=0A=
	extendXRangeIfNeededByBar: function() {=0A=
=0A=
		if (this.options.xaxis.max =3D=3D null) {=0A=
			// great, we're autoscaling, check if we might need a bump=0A=
			var newmax =3D this.xaxis.max;=0A=
			this.graphData.each(function(gd){=0A=
				if(gd.bars.show && gd.bars.barWidth + this.xaxis.datamax > newmax)=0A=
				{=0A=
					newmax =3D this.xaxis.datamax + gd.bars.barWidth;=0A=
				}=0A=
			}.bind(this));=0A=
			this.xaxis.nax =3D newmax;=0A=
			=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * function: setTicks=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} axis=0A=
	 * {Object} axisOptions=0A=
	 */=0A=
	setTicks: function(axis, axisOptions) {=0A=
		axis.ticks =3D [];=0A=
		=0A=
		if (axisOptions.ticks =3D=3D null)=0A=
			axis.ticks =3D axis.tickGenerator(axis);=0A=
		else if (typeof axisOptions.ticks =3D=3D "number") {=0A=
			if (axisOptions.ticks > 0)=0A=
				axis.ticks =3D axis.tickGenerator(axis);=0A=
		}=0A=
		else if (axisOptions.ticks) {=0A=
			var ticks =3D axisOptions.ticks;=0A=
=0A=
			if (Object.isFunction(ticks))=0A=
				// generate the ticks=0A=
				ticks =3D ticks({ min: axis.min, max: axis.max });=0A=
			=0A=
			// clean up the user-supplied ticks, copy them over=0A=
			//var i, v;=0A=
			ticks.each(function(t, i){=0A=
				var v =3D null;=0A=
				var label =3D null;=0A=
				if(typeof t =3D=3D 'object') {=0A=
					v =3D t[0];=0A=
					if(t.length > 1) { label =3D t[1]; }=0A=
				}=0A=
				else {=0A=
					v =3D t;=0A=
				}=0A=
				if(!label) {=0A=
					label =3D axis.tickFormatter(v, axis);=0A=
				}=0A=
				axis.ticks[i] =3D {v: v, label: label}=0A=
			}.bind(this));=0A=
=0A=
		}=0A=
=0A=
		if (axisOptions.autoscaleMargin !=3D null && axis.ticks.length > 0) {=0A=
			if (axisOptions.min =3D=3D null)=0A=
				axis.min =3D Math.min(axis.min, axis.ticks[0].v);=0A=
			if (axisOptions.max =3D=3D null && axis.ticks.length > 1)=0A=
				axis.max =3D Math.min(axis.max, axis.ticks[axis.ticks.length - 1].v);=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * Function: setSpacing=0A=
	 * =0A=
	 * Parameters: none=0A=
	 */=0A=
	setSpacing: function() {=0A=
		// calculate y label dimensions=0A=
		var i, labels =3D [], l;=0A=
		for (i =3D 0; i < this.yaxis.ticks.length; ++i) {=0A=
			l =3D this.yaxis.ticks[i].label;=0A=
=0A=
			if (l)=0A=
				labels.push('<div class=3D"tickLabel">' + l + '</div>');=0A=
		}=0A=
=0A=
		if (labels.length > 0) {=0A=
			var dummyDiv =3D new Element('div', {'style': =
'position:absolute;top:-10000px;font-size:smaller'});=0A=
			dummyDiv.update(labels.join(""));=0A=
			this.domObj.insert(dummyDiv);=0A=
			this.yLabelMaxWidth =3D dummyDiv.getWidth();=0A=
			this.yLabelMaxHeight =3D dummyDiv.select('div')[0].getHeight();=0A=
			dummyDiv.remove();=0A=
		}=0A=
=0A=
		var maxOutset =3D this.options.grid.borderWidth;=0A=
		if (this.options.points.show)=0A=
			maxOutset =3D Math.max(maxOutset, this.options.points.radius + =
this.options.points.lineWidth/2);=0A=
		for (i =3D 0; i < this.graphData.length; ++i) {=0A=
			if (this.graphData[i].points.show)=0A=
				maxOutset =3D Math.max(maxOutset, this.graphData[i].points.radius + =
this.graphData[i].points.lineWidth/2);=0A=
		}=0A=
=0A=
		this.chartOffset.left =3D this.chartOffset.right =3D =
this.chartOffset.top =3D this.chartOffset.bottom =3D maxOutset;=0A=
		=0A=
		this.chartOffset.left +=3D this.yLabelMaxWidth + =
this.options.grid.labelMargin;=0A=
		this.chartWidth =3D this.canvasWidth - this.chartOffset.left - =
this.chartOffset.right;=0A=
=0A=
		this.xLabelBoxWidth =3D this.chartWidth / 6;=0A=
		labels =3D [];=0A=
=0A=
		for (i =3D 0; i < this.xaxis.ticks.length; ++i) {=0A=
			l =3D this.xaxis.ticks[i].label;=0A=
			if (l) {=0A=
				labels.push('<span class=3D"tickLabel" width=3D"' + =
this.xLabelBoxWidth + '">' + l + '</span>');=0A=
			}=0A=
		}=0A=
=0A=
		var xLabelMaxHeight =3D 0;=0A=
		if (labels.length > 0) {=0A=
			var dummyDiv =3D new Element('div', {'style': =
'position:absolute;top:-10000px;font-size:smaller'});=0A=
			dummyDiv.update(labels.join(""));=0A=
			this.domObj.appendChild(dummyDiv);	=0A=
			xLabelMaxHeight =3D dummyDiv.getHeight();=0A=
			dummyDiv.remove();=0A=
		}=0A=
=0A=
		this.chartOffset.bottom +=3D xLabelMaxHeight + =
this.options.grid.labelMargin;=0A=
		this.chartHeight =3D this.canvasHeight - this.chartOffset.bottom - =
this.chartOffset.top;=0A=
		this.hozScale =3D this.chartWidth / (this.xaxis.max - this.xaxis.min);=0A=
		this.vertScale =3D this.chartHeight / (this.yaxis.max - =
this.yaxis.min);=0A=
	},=0A=
	/**=0A=
	 * function: draw=0A=
	 */=0A=
	draw: function() {=0A=
		if(this.options.bars.show)=0A=
		{=0A=
			this.extendXRangeIfNeededByBar();=0A=
			this.setSpacing();=0A=
			this.drawGrid();=0A=
			this.drawBarGraph(this.graphData, this.barDataRange);=0A=
		}=0A=
		else if(this.options.pies.show)=0A=
		{=0A=
			this.preparePieData(this.graphData);=0A=
			this.drawPieGraph(this.graphData);=0A=
		}=0A=
		else=0A=
		{=0A=
			this.drawGrid();=0A=
			for (var i =3D 0; i < this.graphData.length; i++) {=0A=
				this.drawGraph(this.graphData[i]);=0A=
			}=0A=
		}=0A=
	},=0A=
    /**=0A=
     * function: translateHoz=0A=
     * =0A=
     * Paramters:=0A=
     * {Object} x=0A=
     * =0A=
     * Description: Given a value this function translate it to relative =
x coord on canvas=0A=
     */=0A=
	translateHoz: function(x) {=0A=
        return (x - this.xaxis.min) * this.hozScale;=0A=
    },=0A=
	/**=0A=
	 * function: translateVert=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} y=0A=
	 * =0A=
	 * Description: Given a value this function translate it to relative y =
coord on canvas=0A=
	 */=0A=
    translateVert: function(y) {=0A=
        return this.chartHeight - (y - this.yaxis.min) * this.vertScale;=0A=
    },	=0A=
	/**=0A=
	 * function: drawGrid=0A=
	 * =0A=
	 * parameters: none=0A=
	 * =0A=
	 * description: draws the actual grid on the canvas=0A=
	 */=0A=
	drawGrid: function() {=0A=
		var i;=0A=
		=0A=
		this.context.save();=0A=
		this.context.clearRect(0, 0, this.canvasWidth, this.canvasHeight);=0A=
		this.context.translate(this.chartOffset.left, this.chartOffset.top);=0A=
=0A=
		// draw background, if any=0A=
		if (this.options.grid.backgroundColor !=3D null) {=0A=
			this.context.fillStyle =3D this.options.grid.backgroundColor;=0A=
			this.context.fillRect(0, 0, this.chartWidth, this.chartHeight);=0A=
		}=0A=
=0A=
		// draw colored areas=0A=
		if (this.options.grid.coloredAreas) {=0A=
			var areas =3D this.options.grid.coloredAreas;=0A=
			if (Object.isFunction(areas)) {=0A=
				areas =3D areas({ xmin: this.xaxis.min, xmax: this.xaxis.max, ymin: =
this.yaxis.min, ymax: this.yaxis.max });=0A=
			}=0A=
			=0A=
			areas.each(function(a){=0A=
				// clip=0A=
				if (a.x1 =3D=3D null || a.x1 < this.xaxis.min)=0A=
					a.x1 =3D this.xaxis.min;=0A=
				if (a.x2 =3D=3D null || a.x2 > this.xaxis.max)=0A=
					a.x2 =3D this.xaxis.max;=0A=
				if (a.y1 =3D=3D null || a.y1 < this.yaxis.min)=0A=
					a.y1 =3D this.yaxis.min;=0A=
				if (a.y2 =3D=3D null || a.y2 > this.yaxis.max)=0A=
					a.y2 =3D this.yaxis.max;=0A=
=0A=
				var tmp;=0A=
				if (a.x1 > a.x2) {=0A=
					tmp =3D a.x1;=0A=
					a.x1 =3D a.x2;=0A=
					a.x2 =3D tmp;=0A=
				}=0A=
				if (a.y1 > a.y2) {=0A=
					tmp =3D a.y1;=0A=
					a.y1 =3D a.y2;=0A=
					a.y2 =3D tmp;=0A=
				}=0A=
=0A=
				if (a.x1 >=3D this.xaxis.max || a.x2 <=3D this.xaxis.min || a.x1 =
=3D=3D a.x2=0A=
					|| a.y1 >=3D this.yaxis.max || a.y2 <=3D this.yaxis.min || a.y1 =
=3D=3D a.y2)=0A=
					return;=0A=
=0A=
				this.context.fillStyle =3D a.color || =
this.options.grid.coloredAreasColor;=0A=
				this.context.fillRect(Math.floor(this.translateHoz(a.x1)), =
Math.floor(this.translateVert(a.y2)),=0A=
							 Math.floor(this.translateHoz(a.x2) - this.translateHoz(a.x1)), =
Math.floor(this.translateVert(a.y1) - this.translateVert(a.y2)));				=0A=
			}.bind(this));=0A=
=0A=
			=0A=
		}=0A=
		=0A=
		// draw the inner grid=0A=
		this.context.lineWidth =3D 1;=0A=
		this.context.strokeStyle =3D this.options.grid.tickColor;=0A=
		this.context.beginPath();=0A=
		var v;=0A=
		if (this.options.grid.drawXAxis) {=0A=
			this.xaxis.ticks.each(function(aTick){=0A=
				v =3D aTick.v;=0A=
				if(v <=3D this.xaxis.min || v >=3D this.xaxis.max) {=0A=
					return;=0A=
				}=0A=
				this.context.moveTo(Math.floor(this.translateHoz(v)) + =
this.context.lineWidth / 2, 0);=0A=
				this.context.lineTo(Math.floor(this.translateHoz(v)) + =
this.context.lineWidth / 2, this.chartHeight);=0A=
			}.bind(this));=0A=
=0A=
		}=0A=
		=0A=
		if (this.options.grid.drawYAxis) {=0A=
			this.yaxis.ticks.each(function(aTick){=0A=
				v =3D aTick.v;=0A=
				if(v <=3D this.yaxis.min || v >=3D this.yaxis.max) {=0A=
					return;=0A=
				}=0A=
				this.context.moveTo(0, Math.floor(this.translateVert(v)) + =
this.context.lineWidth / 2);=0A=
				this.context.lineTo(this.chartWidth, =
Math.floor(this.translateVert(v)) + this.context.lineWidth / 2);=0A=
			}.bind(this));=0A=
			=0A=
		}=0A=
		this.context.stroke();=0A=
		=0A=
		if (this.options.grid.borderWidth) {=0A=
			// draw border=0A=
			this.context.lineWidth =3D this.options.grid.borderWidth;=0A=
			this.context.strokeStyle =3D this.options.grid.color;=0A=
			this.context.lineJoin =3D "round";=0A=
			this.context.strokeRect(0, 0, this.chartWidth, this.chartHeight);=0A=
			this.context.restore();=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * function: insertLabels=0A=
	 * =0A=
	 * parameters: none=0A=
	 * =0A=
	 * description: inserts the label with proper spacing. Both on X and Y =
axis=0A=
	 */=0A=
	insertLabels: function() {=0A=
		this.domObj.select(".tickLabels").invoke('remove');=0A=
		=0A=
		var i, tick;=0A=
		var html =3D '<div class=3D"tickLabels" =
style=3D"font-size:smaller;color:' + this.options.grid.color + '">';=0A=
		=0A=
		// do the x-axis=0A=
		this.xaxis.ticks.each(function(tick){=0A=
			if (!tick.label || tick.v < this.xaxis.min || tick.v > this.xaxis.max)=0A=
				return;=0A=
			html +=3D '<div style=3D"position:absolute;top:' + =
(this.chartOffset.top + this.chartHeight + =
this.options.grid.labelMargin) + 'px;left:' + (this.chartOffset.left + =
this.translateHoz(tick.v) - this.xLabelBoxWidth/2) + 'px;width:' + =
this.xLabelBoxWidth + 'px;text-align:center" class=3D"tickLabel">' + =
tick.label + "</div>";=0A=
			=0A=
		}.bind(this));=0A=
		=0A=
		// do the y-axis=0A=
		this.yaxis.ticks.each(function(tick){=0A=
			if (!tick.label || tick.v < this.yaxis.min || tick.v > this.yaxis.max)=0A=
				return;=0A=
			html +=3D '<div id=3D"ylabels" style=3D"position:absolute;top:' + =
(this.chartOffset.top + this.translateVert(tick.v) - =
this.yLabelMaxHeight/2) + 'px;left:0;width:' + this.yLabelMaxWidth + =
'px;text-align:right" class=3D"tickLabel">' + tick.label + "</div>";=0A=
		}.bind(this));=0A=
=0A=
		html +=3D '</div>';=0A=
		=0A=
		this.domObj.insert(html);=0A=
	},=0A=
	/**=0A=
	 * function: drawGraph=0A=
	 * =0A=
	 * Paramters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * Description: given a graphData (series) this function calls a proper =
lower level method to draw it.=0A=
	 */=0A=
	drawGraph: function(graphData) {=0A=
		if (graphData.lines.show || (!graphData.bars.show && =
!graphData.points.show))=0A=
			this.drawGraphLines(graphData);=0A=
		if (graphData.bars.show)=0A=
			this.drawGraphBar(graphData);=0A=
		if (graphData.points.show)=0A=
			this.drawGraphPoints(graphData);=0A=
	},=0A=
	/**=0A=
	 * function: plotLine=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} data=0A=
	 * {Object} offset=0A=
	 * =0A=
	 * description: =0A=
	 * Helper function that plots a line based on the data provided=0A=
	 */=0A=
	plotLine: function(data, offset) {=0A=
        var prev, cur =3D null, drawx =3D null, drawy =3D null;=0A=
        =0A=
        this.context.beginPath();=0A=
        for (var i =3D 0; i < data.length; ++i) {=0A=
            prev =3D cur;=0A=
            cur =3D data[i];=0A=
=0A=
            if (prev =3D=3D null || cur =3D=3D null)=0A=
                continue;=0A=
            =0A=
            var x1 =3D prev[0], y1 =3D prev[1],=0A=
                x2 =3D cur[0], y2 =3D cur[1];=0A=
=0A=
            // clip with ymin=0A=
            if (y1 <=3D y2 && y1 < this.yaxis.min) {=0A=
                if (y2 < this.yaxis.min)=0A=
                    continue;   // line segment is outside=0A=
                // compute new intersection point=0A=
                x1 =3D (this.yaxis.min - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y1 =3D this.yaxis.min;=0A=
            }=0A=
            else if (y2 <=3D y1 && y2 < this.yaxis.min) {=0A=
                if (y1 < this.yaxis.min)=0A=
                    continue;=0A=
                x2 =3D (this.yaxis.min - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y2 =3D this.yaxis.min;=0A=
            }=0A=
=0A=
            // clip with ymax=0A=
            if (y1 >=3D y2 && y1 > this.yaxis.max) {=0A=
                if (y2 > this.yaxis.max)=0A=
                    continue;=0A=
                x1 =3D (this.yaxis.max - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y1 =3D this.yaxis.max;=0A=
            }=0A=
            else if (y2 >=3D y1 && y2 > this.yaxis.max) {=0A=
                if (y1 > this.yaxis.max)=0A=
                    continue;=0A=
                x2 =3D (this.yaxis.max - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y2 =3D this.yaxis.max;=0A=
            }=0A=
=0A=
            // clip with xmin=0A=
            if (x1 <=3D x2 && x1 < this.xaxis.min) {=0A=
                if (x2 < this.xaxis.min)=0A=
                    continue;=0A=
                y1 =3D (this.xaxis.min - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x1 =3D this.xaxis.min;=0A=
            }=0A=
            else if (x2 <=3D x1 && x2 < this.xaxis.min) {=0A=
                if (x1 < this.xaxis.min)=0A=
                    continue;=0A=
                y2 =3D (this.xaxis.min - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x2 =3D this.xaxis.min;=0A=
            }=0A=
=0A=
            // clip with xmax=0A=
            if (x1 >=3D x2 && x1 > this.xaxis.max) {=0A=
                if (x2 > this.xaxis.max)=0A=
                    continue;=0A=
                y1 =3D (this.xaxis.max - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x1 =3D this.xaxis.max;=0A=
            }=0A=
            else if (x2 >=3D x1 && x2 > this.xaxis.max) {=0A=
                if (x1 > this.xaxis.max)=0A=
                    continue;=0A=
                y2 =3D (this.xaxis.max - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x2 =3D this.xaxis.max;=0A=
            }=0A=
=0A=
            if (drawx !=3D this.translateHoz(x1) || drawy !=3D =
this.translateVert(y1) + offset)=0A=
                this.context.moveTo(this.translateHoz(x1), =
this.translateVert(y1) + offset);=0A=
            =0A=
            drawx =3D this.translateHoz(x2);=0A=
            drawy =3D this.translateVert(y2) + offset;=0A=
            this.context.lineTo(drawx, drawy);=0A=
        }=0A=
        this.context.stroke();=0A=
    },=0A=
	/**=0A=
	 * function: plotLineArea=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} data=0A=
	 * =0A=
	 * description:=0A=
	 * Helper functoin that plots a colored line graph. This function=0A=
	 * takes the data nad then fill in the area on the graph properly=0A=
	 */=0A=
	plotLineArea: function(data) {=0A=
        var prev, cur =3D null;=0A=
        =0A=
        var bottom =3D Math.min(Math.max(0, this.yaxis.min), =
this.yaxis.max);=0A=
        var top, lastX =3D 0;=0A=
=0A=
        var areaOpen =3D false;=0A=
        =0A=
        for (var i =3D 0; i < data.length; ++i) {=0A=
            prev =3D cur;=0A=
            cur =3D data[i];=0A=
=0A=
            if (areaOpen && prev !=3D null && cur =3D=3D null) {=0A=
                // close area=0A=
                this.context.lineTo(this.translateHoz(lastX), =
this.translateVert(bottom));=0A=
                this.context.fill();=0A=
                areaOpen =3D false;=0A=
                continue;=0A=
            }=0A=
=0A=
            if (prev =3D=3D null || cur =3D=3D null)=0A=
                continue;=0A=
                =0A=
            var x1 =3D prev[0], y1 =3D prev[1],=0A=
                x2 =3D cur[0], y2 =3D cur[1];=0A=
=0A=
            // clip x values=0A=
            =0A=
            // clip with xmin=0A=
            if (x1 <=3D x2 && x1 < this.xaxis.min) {=0A=
                if (x2 < this.xaxis.min)=0A=
                    continue;=0A=
                y1 =3D (this.xaxis.min - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x1 =3D this.xaxis.min;=0A=
            }=0A=
            else if (x2 <=3D x1 && x2 < this.xaxis.min) {=0A=
                if (x1 < this.xaxis.min)=0A=
                    continue;=0A=
                y2 =3D (this.xaxis.min - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x2 =3D this.xaxis.min;=0A=
            }=0A=
=0A=
            // clip with xmax=0A=
            if (x1 >=3D x2 && x1 > this.xaxis.max) {=0A=
                if (x2 > this.xaxis.max)=0A=
                    continue;=0A=
                y1 =3D (this.xaxis.max - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x1 =3D this.xaxis.max;=0A=
            }=0A=
            else if (x2 >=3D x1 && x2 > this.xaxis.max) {=0A=
                if (x1 > this.xaxis.max)=0A=
                    continue;=0A=
                y2 =3D (this.xaxis.max - x1) / (x2 - x1) * (y2 - y1) + =
y1;=0A=
                x2 =3D this.xaxis.max;=0A=
            }=0A=
=0A=
            if (!areaOpen) {=0A=
                // open area=0A=
                this.context.beginPath();=0A=
                this.context.moveTo(this.translateHoz(x1), =
this.translateVert(bottom));=0A=
                areaOpen =3D true;=0A=
            }=0A=
            =0A=
            // now first check the case where both is outside=0A=
            if (y1 >=3D this.yaxis.max && y2 >=3D this.yaxis.max) {=0A=
                this.context.lineTo(this.translateHoz(x1), =
this.translateVert(this.yaxis.max));=0A=
                this.context.lineTo(this.translateHoz(x2), =
this.translateVert(this.yaxis.max));=0A=
                continue;=0A=
            }=0A=
            else if (y1 <=3D this.yaxis.min && y2 <=3D this.yaxis.min) {=0A=
                this.context.lineTo(this.translateHoz(x1), =
this.translateVert(this.yaxis.min));=0A=
                this.context.lineTo(this.translateHoz(x2), =
this.translateVert(this.yaxis.min));=0A=
                continue;=0A=
            }=0A=
            =0A=
            var x1old =3D x1, x2old =3D x2;=0A=
=0A=
            // clip with ymin=0A=
            if (y1 <=3D y2 && y1 < this.yaxis.min && y2 >=3D =
this.yaxis.min) {=0A=
                x1 =3D (this.yaxis.min - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y1 =3D this.yaxis.min;=0A=
            }=0A=
            else if (y2 <=3D y1 && y2 < this.yaxis.min && y1 >=3D =
this.yaxis.min) {=0A=
                x2 =3D (this.yaxis.min - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y2 =3D this.yaxis.min;=0A=
            }=0A=
=0A=
            // clip with ymax=0A=
            if (y1 >=3D y2 && y1 > this.yaxis.max && y2 <=3D =
this.yaxis.max) {=0A=
                x1 =3D (this.yaxis.max - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y1 =3D this.yaxis.max;=0A=
            }=0A=
            else if (y2 >=3D y1 && y2 > this.yaxis.max && y1 <=3D =
this.yaxis.max) {=0A=
                x2 =3D (this.yaxis.max - y1) / (y2 - y1) * (x2 - x1) + =
x1;=0A=
                y2 =3D this.yaxis.max;=0A=
            }=0A=
=0A=
=0A=
            // if the x value was changed we got a rectangle=0A=
            // to fill=0A=
            if (x1 !=3D x1old) {=0A=
                if (y1 <=3D this.yaxis.min)=0A=
                    top =3D this.yaxis.min;=0A=
                else=0A=
                    top =3D this.yaxis.max;=0A=
                =0A=
                this.context.lineTo(this.translateHoz(x1old), =
this.translateVert(top));=0A=
                this.context.lineTo(this.translateHoz(x1), =
this.translateVert(top));=0A=
            }=0A=
            =0A=
            // fill the triangles=0A=
            this.context.lineTo(this.translateHoz(x1), =
this.translateVert(y1));=0A=
            this.context.lineTo(this.translateHoz(x2), =
this.translateVert(y2));=0A=
=0A=
            // fill the other rectangle if it's there=0A=
            if (x2 !=3D x2old) {=0A=
                if (y2 <=3D this.yaxis.min)=0A=
                    top =3D this.yaxis.min;=0A=
                else=0A=
                    top =3D this.yaxis.max;=0A=
                =0A=
                this.context.lineTo(this.translateHoz(x2old), =
this.translateVert(top));=0A=
                this.context.lineTo(this.translateHoz(x2), =
this.translateVert(top));=0A=
            }=0A=
=0A=
            lastX =3D Math.max(x2, x2old);=0A=
        }=0A=
=0A=
        if (areaOpen) {=0A=
            this.context.lineTo(this.translateHoz(lastX), =
this.translateVert(bottom));=0A=
            this.context.fill();=0A=
        }=0A=
    },		=0A=
	/**=0A=
	 * function: drawGraphLines=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * description:=0A=
	 * Main function that daws the line graph. This function is called =0A=
	 * if <options> lines property is set to show or no other type of =0A=
	 * graph is specified. This function depends on <plotLineArea> and =0A=
	 * <plotLine> functions.=0A=
	 */=0A=
	drawGraphLines: function(graphData) {=0A=
        this.context.save();=0A=
        this.context.translate(this.chartOffset.left, =
this.chartOffset.top);=0A=
        this.context.lineJoin =3D "round";=0A=
=0A=
        var lw =3D graphData.lines.lineWidth;=0A=
        var sw =3D graphData.shadowSize;=0A=
        // FIXME: consider another form of shadow when filling is turned =
on=0A=
        if (sw > 0) {=0A=
            // draw shadow in two steps=0A=
            this.context.lineWidth =3D sw / 2;=0A=
            this.context.strokeStyle =3D "rgba(0,0,0,0.1)";=0A=
            this.plotLine(graphData.data, lw/2 + sw/2 + =
this.context.lineWidth/2);=0A=
=0A=
            this.context.lineWidth =3D sw / 2;=0A=
            this.context.strokeStyle =3D "rgba(0,0,0,0.2)";=0A=
            this.plotLine(graphData.data, lw/2 + =
this.context.lineWidth/2);=0A=
        }=0A=
=0A=
        this.context.lineWidth =3D lw;=0A=
        this.context.strokeStyle =3D graphData.color;=0A=
        if (graphData.lines.fill) {=0A=
            this.context.fillStyle =3D graphData.lines.fillColor !=3D =
null ? graphData.lines.fillColor : =
this.parseColor(graphData.color).scale(null, null, null, 0.4).toString();=0A=
            this.plotLineArea(graphData.data, 0);=0A=
        }=0A=
=0A=
        this.plotLine(graphData.data, 0);=0A=
        this.context.restore();=0A=
    },=0A=
	/**=0A=
	 * function: plotPoints=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} data=0A=
	 * {Object} radius=0A=
	 * {Object} fill=0A=
	 * =0A=
	 * description:=0A=
	 * Helper function that draws the point graph according to the data =
provided. Size of each =0A=
	 * point is provided by radius variable and fill specifies if points =0A=
	 * are filled=0A=
	 */=0A=
	plotPoints: function(data, radius, fill) {=0A=
        for (var i =3D 0; i < data.length; ++i) {=0A=
            if (data[i] =3D=3D null)=0A=
                continue;=0A=
            =0A=
            var x =3D data[i][0], y =3D data[i][1];=0A=
            if (x < this.xaxis.min || x > this.xaxis.max || y < =
this.yaxis.min || y > this.yaxis.max)=0A=
                continue;=0A=
            =0A=
            this.context.beginPath();=0A=
            this.context.arc(this.translateHoz(x), =
this.translateVert(y), radius, 0, 2 * Math.PI, true);=0A=
            if (fill)=0A=
                this.context.fill();=0A=
            this.context.stroke();=0A=
        }=0A=
    },=0A=
	/**=0A=
	 * function: plotPointShadows=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} data=0A=
	 * {Object} offset=0A=
	 * {Object} radius=0A=
	 * =0A=
	 * description: =0A=
	 * Helper function that draws the shadows for the points.=0A=
	 */=0A=
    plotPointShadows: function(data, offset, radius) {=0A=
        for (var i =3D 0; i < data.length; ++i) {=0A=
            if (data[i] =3D=3D null)=0A=
                continue;=0A=
            =0A=
            var x =3D data[i][0], y =3D data[i][1];=0A=
            if (x < this.xaxis.min || x > this.xaxis.max || y < =
this.yaxis.min || y > this.yaxis.max)=0A=
                continue;=0A=
            this.context.beginPath();=0A=
            this.context.arc(this.translateHoz(x), this.translateVert(y) =
+ offset, radius, 0, Math.PI, false);=0A=
            this.context.stroke();=0A=
        }=0A=
    },=0A=
	/**=0A=
	 * function: drawGraphPoints=0A=
	 * =0A=
	 * paramters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * description:=0A=
	 * Draws the point graph onto the canvas. This function depends on =
helper =0A=
	 * functions <plotPointShadows> and <plotPoints>=0A=
	 */=0A=
    drawGraphPoints: function(graphData) {=0A=
       	this.context.save();=0A=
        this.context.translate(this.chartOffset.left, =
this.chartOffset.top);=0A=
=0A=
        var lw =3D graphData.lines.lineWidth;=0A=
        var sw =3D graphData.shadowSize;=0A=
        if (sw > 0) {=0A=
            // draw shadow in two steps=0A=
            this.context.lineWidth =3D sw / 2;=0A=
            this.context.strokeStyle =3D "rgba(0,0,0,0.1)";=0A=
            this.plotPointShadows(graphData.data, sw/2 + =
this.context.lineWidth/2, graphData.points.radius);=0A=
=0A=
            this.context.lineWidth =3D sw / 2;=0A=
            this.context.strokeStyle =3D "rgba(0,0,0,0.2)";=0A=
            this.plotPointShadows(graphData.data, =
this.context.lineWidth/2, graphData.points.radius);=0A=
        }=0A=
=0A=
        this.context.lineWidth =3D graphData.points.lineWidth;=0A=
        this.context.strokeStyle =3D graphData.color;=0A=
        this.context.fillStyle =3D graphData.points.fillColor !=3D null =
? graphData.points.fillColor : graphData.color;=0A=
        this.plotPoints(graphData.data, graphData.points.radius, =
graphData.points.fill);=0A=
        this.context.restore();=0A=
    },=0A=
	/**=0A=
	 * function: preparePieData=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * Description: =0A=
	 * Helper function that manipulates the given data stream so that it =
can =0A=
	 * be plotted as a Pie Chart=0A=
	 */=0A=
	preparePieData: function(graphData)=0A=
	{=0A=
		for(i =3D 0; i < graphData.length; i++)=0A=
		{=0A=
			var data =3D 0;=0A=
			for(j =3D 0; j < graphData[i].data.length; j++){=0A=
				data +=3D parseInt(graphData[i].data[j][1]);=0A=
			}=0A=
			graphData[i].data =3D data;=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * function: drawPieShadow=0A=
	 * =0A=
	 * {Object} anchorX=0A=
	 * {Object} anchorY=0A=
	 * {Object} radius=0A=
	 * =0A=
	 * description:=0A=
	 * Helper function that draws a shadow for the Pie Chart. This just =
draws =0A=
	 * a circle with offset that simulates shadow. We do not give each =
piece =0A=
	 * of the pie an individual shadow.=0A=
	 */=0A=
	drawPieShadow: function(anchorX, anchorY, radius)=0A=
	{=0A=
		this.context.beginPath();=0A=
		this.context.moveTo(anchorX, anchorY);=0A=
		this.context.fillStyle =3D 'rgba(0,0,0,' + 0.1 + ')';=0A=
		startAngle =3D 0;=0A=
		endAngle =3D (Math.PI/180)*360;	=0A=
		this.context.arc(anchorX + 2, anchorY +2, radius + =
(this.options.shadowSize/2), startAngle, endAngle, false);=0A=
		this.context.fill();=0A=
		this.context.closePath();=0A=
	},=0A=
	/**=0A=
	 * function: drawPieGraph=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * description: =0A=
	 * Draws the actual pie chart. This function depends on helper function =0A=
	 * <drawPieShadow> to draw the actual shadow=0A=
	 */=0A=
	drawPieGraph: function(graphData)=0A=
	{=0A=
		var sumData =3D 0;=0A=
		var radius =3D 0;=0A=
		var centerX =3D this.chartWidth/2;=0A=
		var centerY =3D this.chartHeight/2;=0A=
		var startAngle =3D 0;=0A=
		var endAngle =3D 0;=0A=
		var fontSize =3D this.options.pies.fontSize;=0A=
		var labelWidth =3D this.options.pies.labelWidth;=0A=
=0A=
		//determine Pie Radius=0A=
		if(!this.options.pies.autoScale)=0A=
			radius =3D this.options.pies.radius;=0A=
		else=0A=
			radius =3D (this.chartHeight * 0.85)/2;=0A=
=0A=
		var labelRadius =3D radius * 1.05;=0A=
=0A=
		for(i =3D 0; i < graphData.length; i++)=0A=
			sumData +=3D graphData[i].data;=0A=
=0A=
		// used to adjust labels so that everything adds up to 100%=0A=
		totalPct =3D 0;=0A=
		=0A=
		//lets draw the shadow first.. we don't need an individual shadow to =
every pie rather we just=0A=
		//draw a circle underneath to simulate the shadow...=0A=
		this.drawPieShadow(centerX, centerY, radius, 0, 0); =0A=
		=0A=
		//lets draw the actual pie chart now.=0A=
		graphData.each(function(gd, j){=0A=
			var pct =3D gd.data / sumData;=0A=
			startAngle =3D endAngle;=0A=
			endAngle +=3D pct * (2 * Math.PI);=0A=
			var sliceMiddle =3D (endAngle - startAngle) / 2 + startAngle;=0A=
			var labelX =3D centerX + Math.cos(sliceMiddle) * labelRadius;=0A=
			var labelY =3D centerY + Math.sin(sliceMiddle) * labelRadius;=0A=
			var anchorX =3D centerX;=0A=
			var anchorY =3D centerY;=0A=
			var textAlign =3D null;=0A=
			var verticalAlign =3D null;=0A=
			var left =3D 0;=0A=
			var top =3D 0;=0A=
			=0A=
			//draw pie:=0A=
			//drawing pie	=0A=
			this.context.beginPath();=0A=
			this.context.moveTo(anchorX, anchorY);				=0A=
			this.context.arc(anchorX, anchorY, radius, startAngle, endAngle, =
false);=0A=
			this.context.closePath();=0A=
			this.context.fillStyle =3D this.parseColor(gd.color).scale(null, =
null, null, this.options.pies.fillOpacity).toString();=0A=
=0A=
			if(this.options.pies.fill)	{ this.context.fill(); }=0A=
=0A=
			// drawing labels=0A=
			if (sliceMiddle <=3D 0.25 * (2 * Math.PI)) =0A=
			{=0A=
				// text on top and align left=0A=
				textAlign =3D "left";=0A=
				verticalAlign =3D "top";=0A=
				left =3D labelX;=0A=
				top =3D labelY + fontSize;=0A=
			}=0A=
			else if (sliceMiddle > 0.25 * (2 * Math.PI) && sliceMiddle <=3D 0.5 * =
(2 * Math.PI)) =0A=
			{=0A=
				// text on bottom and align left=0A=
				textAlign =3D "left";=0A=
				verticalAlign =3D "bottom";=0A=
				left =3D labelX - labelWidth;=0A=
				top =3D labelY;=0A=
			}=0A=
			else if (sliceMiddle > 0.5 * (2 * Math.PI) && sliceMiddle <=3D 0.75 * =
(2 * Math.PI)) =0A=
			{=0A=
				// text on bottom and align right=0A=
				textAlign =3D "right";=0A=
				verticalAlign =3D "bottom";=0A=
				left =3D labelX - labelWidth;=0A=
				top =3D labelY - fontSize;=0A=
			}=0A=
			else =0A=
			{=0A=
				// text on top and align right=0A=
				textAlign =3D "right";=0A=
				verticalAlign =3D "bottom";=0A=
				left =3D labelX;=0A=
				top =3D labelY - fontSize;=0A=
			}=0A=
=0A=
			left =3D left + "px";=0A=
			top =3D top + "px";=0A=
			var textVal =3D Math.round(pct * 100);=0A=
=0A=
			if (j =3D=3D graphData.length - 1) {=0A=
				if (textVal + totalPct < 100) {=0A=
					textVal =3D textVal + 1;=0A=
				} else if (textVal + totalPct > 100) {=0A=
					textVal =3D textVal - 1;=0A=
				};=0A=
			}=0A=
=0A=
			var html =3D "<div style=3D\"position: absolute;zindex:11; width:" + =
labelWidth + "px;fontSize:" + fontSize + "px;overflow:hidden;top:"+ top =
+ ";left:"+ left + ";textAlign:" + textAlign + ";verticalAlign:" + =
verticalAlign +"\">" +  textVal + "%</div>";=0A=
			//$(html).appendTo(target);=0A=
			this.domObj.insert(html);=0A=
=0A=
			totalPct =3D totalPct + textVal;			=0A=
		}.bind(this));=0A=
		=0A=
	},=0A=
	/**=0A=
	 * function: drawBarGraph=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * {Object} barDataRange=0A=
	 * =0A=
	 * description: =0A=
	 * Goes through each series in graphdata and passes it onto =
<drawBarGraphs> function=0A=
	 */=0A=
	drawBarGraph: function(graphData, barDataRange)=0A=
	{=0A=
		graphData.each(function(gd, i){=0A=
			this.drawGraphBars(gd, i, graphData.size(), barDataRange);=0A=
		}.bind(this));=0A=
	},=0A=
	/**=0A=
	 * function: drawGraphBar=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * =0A=
	 * description:=0A=
	 * This function is called when an individual series in GraphData is =
bar graph and plots it=0A=
	 */=0A=
	drawGraphBar: function(graphData)=0A=
	{=0A=
		this.drawGraphBars(graphData, 0, this.graphData.length, =
this.barDataRange);			=0A=
	},	=0A=
	/**=0A=
	 * function: plotBars=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * {Object} data=0A=
	 * {Object} barWidth=0A=
	 * {Object} offset=0A=
	 * {Object} fill=0A=
	 * {Object} counter=0A=
	 * {Object} total=0A=
	 * {Object} barDataRange=0A=
	 * =0A=
	 * description: =0A=
	 * Helper function that draws the bar graph based on data.=0A=
	 */=0A=
	plotBars: function(graphData, data, barWidth, offset, fill,counter, =
total, barDataRange) {=0A=
		var shift =3D 0;=0A=
		=0A=
		if(total % 2 =3D=3D 0)=0A=
		{=0A=
			shift =3D (1 + ((counter  - total /2 ) - 1)) * barWidth;=0A=
		}=0A=
		else=0A=
		{=0A=
			var interval =3D 0.5;			=0A=
			if(counter =3D=3D (total/2 - interval )) {=0A=
				shift =3D - barWidth * interval;=0A=
			}=0A=
			else {=0A=
				shift =3D (interval + (counter  - Math.round(total/2))) * barWidth;=0A=
			}=0A=
		}=0A=
=0A=
		var rangeData =3D [];=0A=
		data.each(function(d){=0A=
			if(!d) return;=0A=
			=0A=
			var x =3D d[0], y =3D d[1];=0A=
			var drawLeft =3D true, drawTop =3D true, drawRight =3D true;=0A=
			var left =3D x + shift, right =3D x + barWidth + shift, bottom =3D 0, =
top =3D y;=0A=
			var rangeDataPoint =3D {};=0A=
			rangeDataPoint.left =3D left;=0A=
			rangeDataPoint.right =3D right;=0A=
			rangeDataPoint.value =3D top;=0A=
			rangeData.push(rangeDataPoint);=0A=
=0A=
			if (right < this.xaxis.min || left > this.xaxis.max || top < =
this.yaxis.min || bottom > this.yaxis.max)=0A=
				return;=0A=
=0A=
			// clip=0A=
			if (left < this.xaxis.min) {=0A=
				left =3D this.xaxis.min;=0A=
				drawLeft =3D false;=0A=
			}=0A=
=0A=
			if (right > this.xaxis.max) {=0A=
				right =3D this.xaxis.max;=0A=
				drawRight =3D false;=0A=
			}=0A=
=0A=
			if (bottom < this.yaxis.min)=0A=
				bottom =3D this.yaxis.min;=0A=
=0A=
			if (top > this.yaxis.max) {=0A=
				top =3D this.yaxis.max;=0A=
				drawTop =3D false;=0A=
			}=0A=
			=0A=
			if(graphData.bars.showShadow && graphData.shadowSize > 0)=0A=
				this.plotShadowOutline(graphData, this.context.strokeStyle, left, =
bottom, top, right, drawLeft, drawRight, drawTop);=0A=
				=0A=
			// fill the bar=0A=
			if (fill) {=0A=
				this.context.beginPath();=0A=
				this.context.moveTo(this.translateHoz(left), =
this.translateVert(bottom) + offset);=0A=
				this.context.lineTo(this.translateHoz(left), this.translateVert(top) =
+ offset);=0A=
				this.context.lineTo(this.translateHoz(right), =
this.translateVert(top) + offset);=0A=
				this.context.lineTo(this.translateHoz(right), =
this.translateVert(bottom) + offset);=0A=
				this.context.fill();=0A=
			}=0A=
=0A=
			// draw outline=0A=
			if (drawLeft || drawRight || drawTop) {=0A=
				this.context.beginPath();=0A=
				this.context.moveTo(this.translateHoz(left), =
this.translateVert(bottom) + offset);=0A=
				if (drawLeft)=0A=
					this.context.lineTo(this.translateHoz(left), =
this.translateVert(top) + offset);=0A=
				else=0A=
					this.context.moveTo(this.translateHoz(left), =
this.translateVert(top) + offset);=0A=
=0A=
				if (drawTop)=0A=
					this.context.lineTo(this.translateHoz(right), =
this.translateVert(top) + offset);=0A=
				else=0A=
					this.context.moveTo(this.translateHoz(right), =
this.translateVert(top) + offset);=0A=
				if (drawRight)=0A=
					this.context.lineTo(this.translateHoz(right), =
this.translateVert(bottom) + offset);=0A=
				else=0A=
					this.context.moveTo(this.translateHoz(right), =
this.translateVert(bottom) + offset);=0A=
				this.context.stroke();=0A=
			}=0A=
		}.bind(this));=0A=
		=0A=
		barDataRange.push(rangeData);=0A=
	},=0A=
	/**=0A=
	 * function: plotShadowOutline=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData=0A=
	 * {Object} orgStrokeStyle=0A=
	 * {Object} left=0A=
	 * {Object} bottom=0A=
	 * {Object} top=0A=
	 * {Object} right=0A=
	 * {Object} drawLeft=0A=
	 * {Object} drawRight=0A=
	 * {Object} drawTop=0A=
	 * =0A=
	 * description:=0A=
	 * Helper function that draws a outline simulating shadow for bar chart=0A=
	 */=0A=
	plotShadowOutline: function(graphData, orgStrokeStyle, left, bottom, =
top, right, drawLeft, drawRight, drawTop)=0A=
	{=0A=
		var orgOpac =3D 0.3;=0A=
		=0A=
		for(var n =3D 1; n <=3D this.options.shadowSize/2; n++)=0A=
		{=0A=
			var opac =3D orgOpac * n;=0A=
			this.context.beginPath();=0A=
			this.context.strokeStyle =3D "rgba(0,0,0," + opac + ")";=0A=
=0A=
			this.context.moveTo(this.translateHoz(left) + n, =
this.translateVert(bottom));=0A=
=0A=
			if(drawLeft)=0A=
				this.context.lineTo(this.translateHoz(left) + n, =
this.translateVert(top) - n);=0A=
			else=0A=
				this.context.moveTo(this.translateHoz(left) + n, =
this.translateVert(top) - n);=0A=
=0A=
			if(drawTop)	=0A=
				this.context.lineTo(this.translateHoz(right) + n, =
this.translateVert(top) - n);=0A=
			else=0A=
				this.context.moveTo(this.translateHoz(right) + n, =
this.translateVert(top) - n);=0A=
=0A=
			if(drawRight)=0A=
				this.context.lineTo(this.translateHoz(right) + n, =
this.translateVert(bottom));=0A=
			else=0A=
				this.context.lineTo(this.translateHoz(right) + n, =
this.translateVert(bottom));=0A=
=0A=
			this.context.stroke();=0A=
			this.context.closePath();=0A=
		}=0A=
=0A=
		this.context.strokeStyle =3D orgStrokeStyle;=0A=
	},=0A=
	/**=0A=
	 * function: drawGraphBars=0A=
	 * =0A=
	 * parameters:=0A=
	 * {Object} graphData =0A=
	 * {Object} counter=0A=
	 * {Object} total=0A=
	 * {Object} barDataRange=0A=
	 * =0A=
	 * description:=0A=
	 * Draws the actual bar graphs. Calls <plotBars> to draw the individual =
bar=0A=
	 */=0A=
	drawGraphBars: function(graphData, counter, total, barDataRange){=0A=
		this.context.save();=0A=
		this.context.translate(this.chartOffset.left, this.chartOffset.top);=0A=
		this.context.lineJoin =3D "round";=0A=
=0A=
		var bw =3D graphData.bars.barWidth;=0A=
		var lw =3D Math.min(graphData.bars.lineWidth, bw);=0A=
=0A=
=0A=
		this.context.lineWidth =3D lw;=0A=
		this.context.strokeStyle =3D graphData.color;=0A=
		if (graphData.bars.fill) {=0A=
			this.context.fillStyle =3D graphData.bars.fillColor !=3D null ? =
graphData.bars.fillColor : this.parseColor(graphData.color).scale(null, =
null, null, this.options.bars.fillOpacity).toString();=0A=
		}=0A=
		this.plotBars(graphData, graphData.data, bw, 0, graphData.bars.fill, =
counter, total, barDataRange);=0A=
		this.context.restore();=0A=
	},=0A=
	/**=0A=
	 * function: insertLegend=0A=
	 * =0A=
	 * description:=0A=
	 * inserts legend onto the graph. *legend: {show: true}* must be set in =
<options> =0A=
	 * for for this to work.=0A=
	 */=0A=
	insertLegend: function() {=0A=
		this.domObj.select(".legend").invoke('remove');=0A=
=0A=
		if (!this.options.legend.show)=0A=
			return;=0A=
		=0A=
		var fragments =3D [];=0A=
		var rowStarted =3D false;=0A=
		this.graphData.each(function(gd, index){=0A=
			if(!gd.label) {=0A=
				return;=0A=
			}=0A=
			if(index % this.options.legend.noColumns =3D=3D 0) {=0A=
				if(rowStarted) {=0A=
					fragments.push('</tr>');=0A=
				}=0A=
				fragments.push('<tr>');=0A=
				rowStarted =3D true;=0A=
			}=0A=
			var label =3D gd.label;=0A=
			if(this.options.legend.labelFormatter !=3D null) {=0A=
				label =3D this.options.legend.labelFormatter(label);=0A=
			}=0A=
			=0A=
			fragments.push(=0A=
				'<td class=3D"legendColorBox"><div style=3D"border:1px solid ' + =
this.options.legend.labelBoxBorderColor + ';padding:1px"><div =
style=3D"width:14px;height:10px;background-color:' + gd.color + =
';overflow:hidden"></div></div></td>' +=0A=
				'<td class=3D"legendLabel">' + label + '</td>');=0A=
			=0A=
		}.bind(this));=0A=
=0A=
		if (rowStarted)=0A=
			fragments.push('</tr>');=0A=
		=0A=
		if(fragments.length > 0){=0A=
			var table =3D '<table style=3D"font-size:smaller;color:' + =
this.options.grid.color + '">' + fragments.join("") + '</table>';=0A=
			if($(this.options.legend.container) !=3D null){=0A=
				$(this.options.legend.container).insert(table);=0A=
			}else{=0A=
				var pos =3D '';=0A=
				var p =3D this.options.legend.position, m =3D =
this.options.legend.margin;=0A=
				=0A=
				if(p.charAt(0) =3D=3D 'n') pos +=3D 'top:' + (m + =
this.chartOffset.top) + 'px;';=0A=
				else if(p.charAt(0) =3D=3D 's') pos +=3D 'bottom:' + (m + =
this.chartOffset.bottom) + 'px;';					=0A=
				if(p.charAt(1) =3D=3D 'e') pos +=3D 'right:' + (m + =
this.chartOffset.right) + 'px;';=0A=
				else if(p.charAt(1) =3D=3D 'w') pos +=3D 'left:' + (m + =
this.chartOffset.bottom) + 'px;';=0A=
				var div =3D this.domObj.insert('<div class=3D"ProtoChart-legend" =
style=3D"border: 1px solid '+this.options.legend.borderColor+'; =
position:absolute;z-index:2;' + pos +'">' + table + =
'</div>').getElementsBySelector('div.ProtoChart-legend').first();=0A=
				=0A=
				if(this.options.legend.backgroundOpacity !=3D 0.0){=0A=
					var c =3D this.options.legend.backgroundColor;=0A=
					if(c =3D=3D null){=0A=
						var tmp =3D (this.options.grid.backgroundColor !=3D null) ? =
this.options.grid.backgroundColor : this.extractColor(div);=0A=
						c =3D this.parseColor(tmp).adjust(null, null, null, 1).toString();=0A=
					}=0A=
					this.domObj.insert('<div class=3D"ProtoChart-legend-bg" =
style=3D"position:absolute;width:' + div.getWidth() + 'px;height:' + =
div.getHeight() + 'px;' + pos +'background-color:' + c + ';"> =
</div>').select('div.ProtoChart-legend-bg').first().setStyle({=0A=
						'opacity': this.options.legend.backgroundOpacity=0A=
					});						=0A=
				}=0A=
			}=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * Function: onMouseMove=0A=
	 * =0A=
	 * parameters:=0A=
	 * event: {Object} ev=0A=
	 * =0A=
	 * Description:=0A=
	 * Called whenever the mouse is moved on the graph. This takes care of =
the mousetracking.=0A=
	 * This event also fires <ProtoChart:mousemove> event, which gets =
current position of the =0A=
	 * mouse as a parameters. =0A=
	 */=0A=
	onMouseMove: function(ev) {=0A=
		var e =3D ev || window.event;=0A=
		if (e.pageX =3D=3D null && e.clientX !=3D null) {=0A=
			var de =3D document.documentElement, b =3D $(document.body);=0A=
			this.lastMousePos.pageX =3D e.clientX + (de && de.scrollLeft || =
b.scrollLeft || 0);=0A=
			this.lastMousePos.pageY =3D e.clientY + (de && de.scrollTop || =
b.scrollTop || 0);=0A=
		}=0A=
		else {=0A=
			this.lastMousePos.pageX =3D e.pageX;=0A=
			this.lastMousePos.pageY =3D e.pageY;=0A=
		}=0A=
		=0A=
		var offset =3D this.overlay.cumulativeOffset();=0A=
		var pos =3D {=0A=
			x: this.xaxis.min + (e.pageX - offset.left - this.chartOffset.left) / =
this.hozScale,=0A=
			y: this.yaxis.max - (e.pageY - offset.top - this.chartOffset.top) / =
this.vertScale=0A=
		};=0A=
		=0A=
		if(this.options.mouse.track && this.selectionInterval =3D=3D null) {=0A=
			this.hit(ev, pos);=0A=
		}=0A=
		this.domObj.fire("ProtoChart:mousemove", [ pos ]);=0A=
	},=0A=
	/**=0A=
	 * Function: onMouseDown=0A=
	 * =0A=
	 * Parameters:=0A=
	 * Event - {Object} e=0A=
	 * =0A=
	 * Description:=0A=
	 * Called whenever the mouse is clicked.=0A=
	 */=0A=
	onMouseDown: function(e) {=0A=
		if (e.which !=3D 1)  // only accept left-click=0A=
			return;=0A=
		=0A=
		document.body.focus();=0A=
=0A=
		if (document.onselectstart !=3D=3D undefined && =
this.workarounds.onselectstart =3D=3D null) {=0A=
			this.workarounds.onselectstart =3D document.onselectstart;=0A=
			document.onselectstart =3D function () { return false; };=0A=
		}=0A=
		if (document.ondrag !=3D=3D undefined && this.workarounds.ondrag =
=3D=3D null) {=0A=
			this.workarounds.ondrag =3D document.ondrag;=0A=
			document.ondrag =3D function () { return false; };=0A=
		}=0A=
		=0A=
		this.setSelectionPos(this.selection.first, e);=0A=
			=0A=
		if (this.selectionInterval !=3D null)=0A=
			clearInterval(this.selectionInterval);=0A=
		this.lastMousePos.pageX =3D null;=0A=
		this.selectionInterval =3D =
setInterval(this.updateSelectionOnMouseMove.bind(this), 200);=0A=
=0A=
		this.overlay.observe("mouseup", this.onSelectionMouseUp.bind(this));=0A=
	},=0A=
	/**=0A=
	 * Function: onClick=0A=
	 * parameters:=0A=
	 * Event - {Object} e=0A=
	 * Description: =0A=
	 * Handles the "click" event on the chart. This function fires =
<ProtoChart:plotclick> event. If=0A=
	 * <options.allowDataClick> is enabled then it also fires =
<ProtoChart:dataclick> event which gives=0A=
	 * you access to exact data point where user clicked.=0A=
	 */=0A=
	onClick: function(e) {=0A=
		if (this.ignoreClick) {=0A=
			this.ignoreClick =3D false;=0A=
			return;=0A=
		}=0A=
		var offset =3D this.overlay.cumulativeOffset(); =0A=
		var pos =3D{=0A=
			x: this.xaxis.min + (e.pageX - offset.left - this.chartOffset.left) / =
this.hozScale,=0A=
			y: this.yaxis.max - (e.pageY - offset.top - this.chartOffset.top) / =
this.vertScale=0A=
		};=0A=
		this.domObj.fire("ProtoChart:plotclick", [ pos ]);=0A=
=0A=
		if(this.options.allowDataClick)=0A=
		{=0A=
			var dataPoint =3D {};=0A=
			if(this.options.points.show)=0A=
			{=0A=
				dataPoint =3D this.getDataClickPoint(pos, this.options);=0A=
				this.domObj.fire("ProtoChart:dataclick", [dataPoint]);=0A=
			}=0A=
			else if(this.options.lines.show && this.options.points.show)=0A=
			{=0A=
				dataPoint =3D this.getDataClickPoint(pos, this.options);=0A=
				this.domObj.fire("ProtoChart:dataclick", [dataPoint]);=0A=
			}=0A=
			else if(this.options.bars.show)=0A=
			{=0A=
				if(this.barDataRange.length > 0)=0A=
				{=0A=
					dataPoint =3D this.getDataClickPoint(pos, this.options, =
this.barDataRange);=0A=
					this.domObj.fire("ProtoChart:dataclick", [dataPoint]);=0A=
				}=0A=
			}=0A=
		}=0A=
	},=0A=
	/**=0A=
	 * Internal function used by onClick method.=0A=
	 */=0A=
	getDataClickPoint: function(pos, options, barDataRange)=0A=
	{=0A=
		pos.x =3D parseInt(pos.x);=0A=
		pos.y =3D parseInt(pos.y);=0A=
		var yClick =3D pos.y.toFixed(0);=0A=
		var dataVal =3D {};=0A=
=0A=
		dataVal.position =3D pos;=0A=
		dataVal.value =3D '';=0A=
=0A=
		if(options.points.show)=0A=
		{=0A=
			this.graphData.each(function(gd){=0A=
				var temp =3D gd.data;=0A=
				var xClick =3D parseInt(pos.x.toFixed(0));=0A=
				if(xClick < 0) { xClick =3D 0; }=0A=
				if(temp[xClick] && yClick >=3D temp[xClick][1] - =
(this.options.points.radius * 10) && yClick <=3D temp[xClick][1] + =
(this.options.points.radius * 10)) {=0A=
					dataVal.value =3D temp[xClick][1];=0A=
					throw $break;=0A=
				}=0A=
				=0A=
			}.bind(this));=0A=
		}=0A=
		else if(options.bars.show)=0A=
		{=0A=
			xClick =3D pos.x;=0A=
			this.barDataRange.each(function(barData){=0A=
				barData.each(function(data){=0A=
					var temp =3D data;=0A=
					if(xClick > temp.left && xClick < temp.right) {=0A=
						dataVal.value =3D temp.value;=0A=
						throw $break;=0A=
					}=0A=
				}.bind(this));=0A=
			}.bind(this));=0A=
=0A=
		}=0A=
=0A=
		return dataVal;=0A=
	},=0A=
	/**=0A=
	 * Function: triggerSelectedEvent=0A=
	 * =0A=
	 * Description:=0A=
	 * Internal function called when a selection on the graph is made. This =
function=0A=
	 * fires <ProtoChart:selected> event which has a parameter representing =
the selection=0A=
	 * {=0A=
	 * 	x1: {int}, y1: {int},=0A=
	 * 	x2: {int}, y2: {int}=0A=
	 * }=0A=
	 */=0A=
	triggerSelectedEvent: function() {=0A=
		var x1, x2, y1, y2;=0A=
		if (this.selection.first.x <=3D this.selection.second.x) {=0A=
			x1 =3D this.selection.first.x;=0A=
			x2 =3D this.selection.second.x;=0A=
		}=0A=
		else {=0A=
			x1 =3D this.selection.second.x;=0A=
			x2 =3D this.selection.first.x;=0A=
		}=0A=
=0A=
		if (this.selection.first.y >=3D this.selection.second.y) {=0A=
			y1 =3D this.selection.first.y;=0A=
			y2 =3D this.selection.second.y;=0A=
		}=0A=
		else {=0A=
			y1 =3D this.selection.second.y;=0A=
			y2 =3D this.selection.first.y;=0A=
		}=0A=
		=0A=
		x1 =3D this.xaxis.min + x1 / this.hozScale;=0A=
		x2 =3D this.xaxis.min + x2 / this.hozScale;=0A=
=0A=
		y1 =3D this.yaxis.max - y1 / this.vertScale;=0A=
		y2 =3D this.yaxis.max - y2 / this.vertScale;=0A=
=0A=
		this.domObj.fire("ProtoChart:selected", [ { x1: x1, y1: y1, x2: x2, =
y2: y2 } ]);=0A=
	},=0A=
	/**=0A=
	 * Internal function=0A=
	 */=0A=
	onSelectionMouseUp: function(e) {=0A=
		if (document.onselectstart !=3D=3D undefined)=0A=
			document.onselectstart =3D this.workarounds.onselectstart;=0A=
		if (document.ondrag !=3D=3D undefined)=0A=
			document.ondrag =3D this.workarounds.ondrag;=0A=
		=0A=
		if (this.selectionInterval !=3D null) {=0A=
			clearInterval(this.selectionInterval);=0A=
			this.selectionInterval =3D null;=0A=
		}=0A=
=0A=
		this.setSelectionPos(this.selection.second, e);=0A=
		this.clearSelection();=0A=
		if (!this.selectionIsSane() || e.which !=3D 1)=0A=
			return false;=0A=
		=0A=
		this.drawSelection();=0A=
		this.triggerSelectedEvent();=0A=
		this.ignoreClick =3D true;=0A=
=0A=
		return false;=0A=
	},=0A=
	setSelectionPos: function(pos, e) {=0A=
		var offset =3D $(this.overlay).cumulativeOffset();=0A=
		if (this.options.selection.mode =3D=3D "y") {=0A=
			if (pos =3D=3D this.selection.first)=0A=
				pos.x =3D 0;=0A=
			else=0A=
				pos.x =3D this.chartWidth;=0A=
		}=0A=
		else {=0A=
			pos.x =3D e.pageX - offset.left - this.chartOffset.left;=0A=
			pos.x =3D Math.min(Math.max(0, pos.x), this.chartWidth);=0A=
		}=0A=
=0A=
		if (this.options.selection.mode =3D=3D "x") {=0A=
			if (pos =3D=3D this.selection.first)=0A=
				pos.y =3D 0;=0A=
			else=0A=
				pos.y =3D this.chartHeight;=0A=
		}=0A=
		else {=0A=
			pos.y =3D e.pageY - offset.top - this.chartOffset.top;=0A=
			pos.y =3D Math.min(Math.max(0, pos.y), this.chartHeight);=0A=
		}=0A=
	},=0A=
	updateSelectionOnMouseMove: function() {=0A=
		if (this.lastMousePos.pageX =3D=3D null)=0A=
			return;=0A=
		=0A=
		this.setSelectionPos(this.selection.second, this.lastMousePos);=0A=
		this.clearSelection();=0A=
		if (this.selectionIsSane())=0A=
			this.drawSelection();=0A=
	},=0A=
	clearSelection: function() {=0A=
		if (this.prevSelection =3D=3D null)=0A=
			return;=0A=
=0A=
		var x =3D Math.min(this.prevSelection.first.x, =
this.prevSelection.second.x),=0A=
			y =3D Math.min(this.prevSelection.first.y, =
this.prevSelection.second.y),=0A=
			w =3D Math.abs(this.prevSelection.second.x - =
this.prevSelection.first.x),=0A=
			h =3D Math.abs(this.prevSelection.second.y - =
this.prevSelection.first.y);=0A=
		=0A=
		this.overlayContext.clearRect(x + this.chartOffset.left - =
this.overlayContext.lineWidth,=0A=
					   		y + this.chartOffset.top - this.overlayContext.lineWidth,=0A=
					   		w + this.overlayContext.lineWidth*2,=0A=
					   		h + this.overlayContext.lineWidth*2);=0A=
		=0A=
		this.prevSelection =3D null;=0A=
	},=0A=
	/**=0A=
	 * Function: setSelection=0A=
	 * =0A=
	 * Parameters:=0A=
	 * Area - {Object} area represented as a range like: {x1: 3, y1: 3, x2: =
4, y2: 8}=0A=
	 * =0A=
	 * Description: =0A=
	 * Sets the current graph selection to the provided range. Calls =
<drawSelection> and =0A=
	 * <triggerSelectedEvent> functions internally.=0A=
	 */=0A=
	setSelection: function(area) {=0A=
		this.clearSelection();=0A=
		=0A=
		if (this.options.selection.mode =3D=3D "x") {=0A=
			this.selection.first.y =3D 0;=0A=
			this.selection.second.y =3D this.chartHeight;=0A=
		}=0A=
		else {=0A=
			this.selection.first.y =3D (this.yaxis.max - area.y1) * =
this.vertScale;=0A=
			this.selection.second.y =3D (this.yaxis.max - area.y2) * =
this.vertScale;=0A=
		}=0A=
		if (this.options.selection.mode =3D=3D "y") {=0A=
			this.selection.first.x =3D 0;=0A=
			this.selection.second.x =3D this.chartWidth;=0A=
		}=0A=
		else {=0A=
			this.selection.first.x =3D (area.x1 - this.xaxis.min) * this.hozScale;=0A=
			this.selection.second.x =3D (area.x2 - this.xaxis.min) * =
this.hozScale;=0A=
		}=0A=
=0A=
		this.drawSelection();=0A=
		this.triggerSelectedEvent();=0A=
	},=0A=
	/**=0A=
	 * Function: drawSelection=0A=
	 * Description: Internal function called to draw the selection made on =
the graph. =0A=
	 */=0A=
	drawSelection: function() {=0A=
		if (this.prevSelection !=3D null &&=0A=
			this.selection.first.x =3D=3D this.prevSelection.first.x &&=0A=
			this.selection.first.y =3D=3D this.prevSelection.first.y && =0A=
			this.selection.second.x =3D=3D this.prevSelection.second.x &&=0A=
			this.selection.second.y =3D=3D this.prevSelection.second.y)=0A=
		{=0A=
			return;	=0A=
		}=0A=
		=0A=
		this.overlayContext.strokeStyle =3D =
this.parseColor(this.options.selection.color).scale(null, null, null, =
0.8).toString();=0A=
		this.overlayContext.lineWidth =3D 1;=0A=
		this.context.lineJoin =3D "round";=0A=
		this.overlayContext.fillStyle =3D =
this.parseColor(this.options.selection.color).scale(null, null, null, =
0.4).toString();=0A=
=0A=
		this.prevSelection =3D { first:  { x: this.selection.first.x,=0A=
									y: this.selection.first.y },=0A=
						  second: { x: this.selection.second.x,=0A=
									y: this.selection.second.y } };=0A=
=0A=
		var x =3D Math.min(this.selection.first.x, this.selection.second.x),=0A=
			y =3D Math.min(this.selection.first.y, this.selection.second.y),=0A=
			w =3D Math.abs(this.selection.second.x - this.selection.first.x),=0A=
			h =3D Math.abs(this.selection.second.y - this.selection.first.y);=0A=
		=0A=
		this.overlayContext.fillRect(x + this.chartOffset.left, y + =
this.chartOffset.top, w, h);=0A=
		this.overlayContext.strokeRect(x + this.chartOffset.left, y + =
this.chartOffset.top, w, h);=0A=
	},=0A=
	/**=0A=
	 * Internal function=0A=
	 */=0A=
	selectionIsSane: function() {=0A=
		var minSize =3D 5;=0A=
		return Math.abs(this.selection.second.x - this.selection.first.x) >=3D =
minSize &&=0A=
			Math.abs(this.selection.second.y - this.selection.first.y) >=3D =
minSize;=0A=
	},=0A=
	/**=0A=
	 * Internal function that formats the track. This is the format the =
text is shown when mouse=0A=
	 * tracking is enabled.=0A=
	 */=0A=
	defaultTrackFormatter: function(val)=0A=
	{=0A=
		return '['+val.x+', '+val.y+']';=0A=
	},=0A=
	/**=0A=
	 * Function: clearHit=0A=
	 */=0A=
	clearHit: function(){=0A=
		if(this.prevHit){=0A=
			this.overlayContext.clearRect(=0A=
				this.translateHoz(this.prevHit.x) + this.chartOffset.left - =
this.options.mouse.radius*2,=0A=
				this.translateVert(this.prevHit.y) + this.chartOffset.top - =
this.options.mouse.radius*2,=0A=
				this.options.mouse.radius*3 + this.options.points.lineWidth*3, =0A=
				this.options.mouse.radius*3 + this.options.points.lineWidth*3=0A=
			);=0A=
			this.prevHit =3D null;=0A=
		}		=0A=
	},	=0A=
	/**=0A=
	 * Function: hit=0A=
	 * =0A=
	 * Parameters: =0A=
	 * 	event - {Object} event object=0A=
	 * 	mouse - {Object} mouse object that is used to keep track of mouse =
movement=0A=
	 * =0A=
	 * Description:=0A=
	 * 	If hit occurs this function will fire a ProtoChart:hit event.=0A=
	 */=0A=
	hit: function(event, mouse){	=0A=
		/**=0A=
		 * Nearest data element.=0A=
		 */=0A=
		var n =3D {=0A=
			dist:Number.MAX_VALUE,=0A=
			x:null,=0A=
			y:null,=0A=
			mouse:null=0A=
		};=0A=
		=0A=
		=0A=
		for(var i =3D 0, data, xsens, ysens; i < this.graphData.length; i++){=0A=
			if(!this.graphData[i].mouse.track) continue;=0A=
			data =3D this.graphData[i].data;				=0A=
			xsens =3D (this.hozScale*this.graphData[i].mouse.sensibility);=0A=
			ysens =3D (this.vertScale*this.graphData[i].mouse.sensibility);=0A=
			for(var j =3D 0, xabs, yabs; j < data.length; j++){=0A=
				xabs =3D this.hozScale*Math.abs(data[j][0] - mouse.x);=0A=
				yabs =3D this.vertScale*Math.abs(data[j][1] - mouse.y);=0A=
				=0A=
				if(xabs < xsens && yabs < ysens && (xabs+yabs) < n.dist){=0A=
					n.dist =3D (xabs+yabs);=0A=
					n.x =3D data[j][0];=0A=
					n.y =3D data[j][1];=0A=
					n.mouse =3D this.graphData[i].mouse;=0A=
				}=0A=
			}=0A=
		}=0A=
		=0A=
		if(n.mouse && n.mouse.track && !this.prevHit || (this.prevHit && n.x =
!=3D this.prevHit.x && n.y !=3D this.prevHit.y)){=0A=
			var el =3D this.domObj.select('.'+this.options.mouse.clsName).first();=0A=
			if(!el){=0A=
				var pos =3D '', p =3D this.options.mouse.position, m =3D =
this.options.mouse.margin;					=0A=
				if(p.charAt(0) =3D=3D 'n') pos +=3D 'top:' + (m + =
this.chartOffset.top) + 'px;';=0A=
				else if(p.charAt(0) =3D=3D 's') pos +=3D 'bottom:' + (m + =
this.chartOffset.bottom) + 'px;';					=0A=
				if(p.charAt(1) =3D=3D 'e') pos +=3D 'right:' + (m + =
this.chartOffset.right) + 'px;';=0A=
				else if(p.charAt(1) =3D=3D 'w') pos +=3D 'left:' + (m + =
this.chartOffset.bottom) + 'px;';=0A=
				=0A=
				this.domObj.insert('<div class=3D"'+this.options.mouse.clsName+'" =
style=3D"display:none;position:absolute;'+pos+'"></div>');=0A=
				return;=0A=
			}=0A=
			if(n.x !=3D=3D null && n.y !=3D=3D null){=0A=
				el.setStyle({display:'block'});					=0A=
				=0A=
				this.clearHit();=0A=
				if(n.mouse.lineColor !=3D null){=0A=
					this.overlayContext.save();=0A=
					this.overlayContext.translate(this.chartOffset.left, =
this.chartOffset.top);=0A=
					this.overlayContext.lineWidth =3D this.options.points.lineWidth;=0A=
					this.overlayContext.strokeStyle =3D n.mouse.lineColor;=0A=
					this.overlayContext.fillStyle =3D '#ffffff';=0A=
					this.overlayContext.beginPath();=0A=
					=0A=
					=0A=
					this.overlayContext.arc(this.translateHoz(n.x), =
this.translateVert(n.y), this.options.mouse.radius, 0, 2 * Math.PI, =
true);=0A=
					this.overlayContext.fill();=0A=
					this.overlayContext.stroke();=0A=
					this.overlayContext.restore();=0A=
				} =0A=
				this.prevHit =3D n;=0A=
								=0A=
				var decimals =3D n.mouse.trackDecimals;=0A=
				if(decimals =3D=3D null || decimals < 0) decimals =3D 0;=0A=
				if(!this.options.mouse.fixedPosition)=0A=
				{=0A=
					el.setStyle({=0A=
						left: (this.translateHoz(n.x) + this.options.mouse.radius + 10) + =
"px",=0A=
						top: (this.translateVert(n.y) + this.options.mouse.radius + 10) + =
"px"=0A=
					});=0A=
				}=0A=
				el.innerHTML =3D n.mouse.trackFormatter({x: n.x.toFixed(decimals), =
y: n.y.toFixed(decimals)});=0A=
				this.domObj.fire( 'ProtoChart:hit', [n] )					=0A=
			}else if(this.options.prevHit){=0A=
				el.setStyle({display:'none'});=0A=
				this.clearHit();=0A=
			}=0A=
		}=0A=
	},	=0A=
	/**=0A=
	 * Internal function=0A=
	 */=0A=
	floorInBase: function(n, base) {=0A=
        return base * Math.floor(n / base);=0A=
    },	=0A=
	/**=0A=
	 * Function: extractColor=0A=
	 * =0A=
	 * Parameters:=0A=
	 * 		element - HTML element or ID of an HTML element=0A=
	 * =0A=
	 * Returns: =0A=
	 * 		color in string format=0A=
	 */=0A=
	extractColor: function(element)=0A=
	{=0A=
		var color;=0A=
		do=0A=
		{=0A=
			color =3D $(element).getStyle('background-color').toLowerCase();=0A=
			if(color  !=3D '' && color !=3D 'transparent')=0A=
			{=0A=
				break;=0A=
			}=0A=
			element =3D element.up(0); //or else just get the parent ....=0A=
		} while(element.nodeName.toLowerCase() !=3D 'body');=0A=
		=0A=
		//safari fix=0A=
		if(color =3D=3D 'rgba(0, 0, 0, 0)') =0A=
			return 'transparent';=0A=
		return color;=0A=
	},=0A=
	/**=0A=
	 * Function: parseColor=0A=
	 * =0A=
	 * Parameters: =0A=
	 * 		str - color string in different formats=0A=
	 * =0A=
	 * Returns:=0A=
	 * 		a Proto.Color Object - use toString() function to retreive the =
color in rgba/rgb format=0A=
	 */=0A=
	parseColor: function(str)=0A=
	{=0A=
		var result;=0A=
	=0A=
		/**=0A=
		 * rgb(num,num,num)=0A=
		 */=0A=
		if((result =3D =
/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(st=
r)))=0A=
			return new Proto.Color(parseInt(result[1]), parseInt(result[2]), =
parseInt(result[3]));=0A=
	=0A=
		/**=0A=
		 * rgba(num,num,num,num)=0A=
		 */=0A=
		if((result =3D =
/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]=
+(?:\.[0-9]+)?)\s*\)/.exec(str)))=0A=
			return new Proto.Color(parseInt(result[1]), parseInt(result[2]), =
parseInt(result[3]), parseFloat(result[4]));=0A=
			=0A=
		/**=0A=
		 * rgb(num%,num%,num%)=0A=
		 */=0A=
		if((result =3D =
/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-=
9]+(?:\.[0-9]+)?)\%\s*\)/.exec(str)))=0A=
			return new Proto.Color(parseFloat(result[1])*2.55, =
parseFloat(result[2])*2.55, parseFloat(result[3])*2.55);=0A=
	=0A=
		/**=0A=
		 * rgba(num%,num%,num%,num)=0A=
		 */=0A=
		if((result =3D =
/rgba\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0=
-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\s*\)/.exec(str)))=0A=
			return new Proto.Color(parseFloat(result[1])*2.55, =
parseFloat(result[2])*2.55, parseFloat(result[3])*2.55, =
parseFloat(result[4]));=0A=
			=0A=
		/**=0A=
		 * #a0b1c2=0A=
		 */=0A=
		if((result =3D =
/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(str)))=0A=
			return new Proto.Color(parseInt(result[1],16), =
parseInt(result[2],16), parseInt(result[3],16));=0A=
	=0A=
		/**=0A=
		 * #fff=0A=
		 */=0A=
		if((result =3D /#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(str)))=0A=
			return new Proto.Color(parseInt(result[1]+result[1],16), =
parseInt(result[2]+result[2],16), parseInt(result[3]+result[3],16));=0A=
=0A=
		/**=0A=
		 * Otherwise, check if user wants transparent .. or we just return a =
standard color;=0A=
		 */=0A=
		var name =3D str.strip().toLowerCase();=0A=
		if(name =3D=3D 'transparent'){=0A=
			return new Proto.Color(255, 255, 255, 0);=0A=
		}=0A=
=0A=
		return new Proto.Color(100,100,100, 1);=0A=
					=0A=
	}		=0A=
});=0A=
=0A=
if(!Proto) var Proto =3D {};=0A=
=0A=
/**=0A=
 * Class: Proto.Color=0A=
 * =0A=
 * Helper class that manipulates colors using RGBA values. =0A=
 * =0A=
 */=0A=
=0A=
Proto.Color =3D Class.create({=0A=
	initialize: function(r, g, b, a) {=0A=
		this.rgba =3D ['r', 'g', 'b', 'a'];=0A=
		var x =3D 4;=0A=
		while(-1<--x) {=0A=
			this[this.rgba[x]] =3D arguments[x] || ((x=3D=3D3) ? 1.0 : 0);=0A=
		}=0A=
	},=0A=
	toString: function()  {=0A=
		if(this.a >=3D 1.0) {=0A=
			return "rgb(" + [this.r, this.g, this.b].join(",") +")";=0A=
		}=0A=
		else {=0A=
			return "rgba("+[this.r, this.g, this.b, this.a].join(",")+")";=0A=
		}=0A=
	},=0A=
	scale: function(rf, gf, bf, af) {=0A=
		x =3D 4;=0A=
		while(-1<--x) {=0A=
			if(arguments[x] !=3D null) {=0A=
				this[this.rgba[x]] *=3D arguments[x];=0A=
			}=0A=
		}=0A=
		return this.normalize();=0A=
	},=0A=
	adjust: function(rd, gd, bd, ad) {=0A=
        x =3D 4; //rgba.length=0A=
        while (-1<--x) {=0A=
            if (arguments[x] !=3D null)=0A=
                this[this.rgba[x]] +=3D arguments[x];=0A=
        }=0A=
        return this.normalize();		=0A=
	},=0A=
	clone: function() {=0A=
        return new Proto.Color(this.r, this.b, this.g, this.a);=0A=
    },=0A=
	limit: function(val,minVal,maxVal) {=0A=
        return Math.max(Math.min(val, maxVal), minVal);=0A=
    },=0A=
    normalize: function() {=0A=
        this.r =3D this.limit(parseInt(this.r), 0, 255);=0A=
        this.g =3D this.limit(parseInt(this.g), 0, 255);=0A=
        this.b =3D this.limit(parseInt(this.b), 0, 255);=0A=
        this.a =3D this.limit(this.a, 0, 1);=0A=
        return this;=0A=
    }=0A=
});
------=_NextPart_000_0000_01CE307B.330E2A00
mime-version: 1.0
content-type: application/octet-stream
content-transfer-encoding: quoted-printable
content-location: http://hyperwave.barnsley.gov.uk/wavemaster.internal/lib/base/v1.x/lang/datejs/date.js?cachekeY=515488b2-en

/**
 * Version: 1.0 Alpha-1=20
 * Build Date: 13-Nov-2007
 * Copyright (c) 2006-2007, Coolite Inc. (http://www.coolite.com/). All =
rights reserved.
 * License: Licensed under The MIT License. See license.txt and =
http://www.datejs.com/license/.=20
 * Website: http://www.datejs.com/ or http://www.coolite.com/datejs/
 */
Date.CultureInfo=3D{name:"en-US",englishName:"English (United =
States)",nativeName:"English (United =
States)",dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Fr=
iday","Saturday"],abbreviatedDayNames:["Sun","Mon","Tue","Wed","Thu","Fri=
","Sat"],shortestDayNames:["Su","Mo","Tu","We","Th","Fr","Sa"],firstLette=
rDayNames:["S","M","T","W","T","F","S"],monthNames:["January","February",=
"March","April","May","June","July","August","September","October","Novem=
ber","December"],abbreviatedMonthNames:["Jan","Feb","Mar","Apr","May","Ju=
n","Jul","Aug","Sep","Oct","Nov","Dec"],amDesignator:"AM",pmDesignator:"P=
M",firstDayOfWeek:0,twoDigitYearMax:2029,dateElementOrder:"mdy",formatPat=
terns:{shortDate:"M/d/yyyy",longDate:"dddd, MMMM dd, =
yyyy",shortTime:"h:mm tt",longTime:"h:mm:ss tt",fullDateTime:"dddd, MMMM =
dd, yyyy h:mm:ss =
tt",sortableDateTime:"yyyy-MM-ddTHH:mm:ss",universalSortableDateTime:"yyy=
y-MM-dd HH:mm:ssZ",rfc1123:"ddd, dd MMM yyyy HH:mm:ss =
GMT",monthDay:"MMMM dd",yearMonth:"MMMM, =
yyyy"},regexPatterns:{jan:/^jan(uary)?/i,feb:/^feb(ruary)?/i,mar:/^mar(ch=
)?/i,apr:/^apr(il)?/i,may:/^may/i,jun:/^jun(e)?/i,jul:/^jul(y)?/i,aug:/^a=
ug(ust)?/i,sep:/^sep(t(ember)?)?/i,oct:/^oct(ober)?/i,nov:/^nov(ember)?/i=
,dec:/^dec(ember)?/i,sun:/^su(n(day)?)?/i,mon:/^mo(n(day)?)?/i,tue:/^tu(e=
(s(day)?)?)?/i,wed:/^we(d(nesday)?)?/i,thu:/^th(u(r(s(day)?)?)?)?/i,fri:/=
^fr(i(day)?)?/i,sat:/^sa(t(urday)?)?/i,future:/^next/i,past:/^last|past|p=
rev(ious)?/i,add:/^(\+|after|from)/i,subtract:/^(\-|before|ago)/i,yesterd=
ay:/^yesterday/i,today:/^t(oday)?/i,tomorrow:/^tomorrow/i,now:/^n(ow)?/i,=
millisecond:/^ms|milli(second)?s?/i,second:/^sec(ond)?s?/i,minute:/^min(u=
te)?s?/i,hour:/^h(ou)?rs?/i,week:/^w(ee)?k/i,month:/^m(o(nth)?s?)?/i,day:=
/^d(ays?)?/i,year:/^y((ea)?rs?)?/i,shortMeridian:/^(a|p)/i,longMeridian:/=
^(a\.?m?\.?|p\.?m?\.?)/i,timezone:/^((e(s|d)t|c(s|d)t|m(s|d)t|p(s|d)t)|((=
gmt)?\s*(\+|\-)\s*\d\d\d\d?)|gmt)/i,ordinalSuffix:/^\s*(st|nd|rd|th)/i,ti=
meContext:/^\s*(\:|a|p)/i},abbreviatedTimeZoneStandard:{GMT:"-000",EST:"-=
0400",CST:"-0500",MST:"-0600",PST:"-0700"},abbreviatedTimeZoneDST:{GMT:"-=
000",EDT:"-0500",CDT:"-0600",MDT:"-0700",PDT:"-0800"}};=0A=
Date.getMonthNumberFromName=3Dfunction(name){var =
n=3DDate.CultureInfo.monthNames,m=3DDate.CultureInfo.abbreviatedMonthName=
s,s=3Dname.toLowerCase();for(var =
i=3D0;i<n.length;i++){if(n[i].toLowerCase()=3D=3Ds||m[i].toLowerCase()=3D=
=3Ds){return i;}}=0A=
return-1;};Date.getDayNumberFromName=3Dfunction(name){var =
n=3DDate.CultureInfo.dayNames,m=3DDate.CultureInfo.abbreviatedDayNames,o=3D=
Date.CultureInfo.shortestDayNames,s=3Dname.toLowerCase();for(var =
i=3D0;i<n.length;i++){if(n[i].toLowerCase()=3D=3Ds||m[i].toLowerCase()=3D=
=3Ds){return i;}}=0A=
return-1;};Date.isLeapYear=3Dfunction(year){return(((year%4=3D=3D=3D0)&&(=
year%100!=3D=3D0))||(year%400=3D=3D=3D0));};Date.getDaysInMonth=3Dfunctio=
n(year,month){return[31,(Date.isLeapYear(year)?29:28),31,30,31,30,31,31,3=
0,31,30,31][month];};Date.getTimezoneOffset=3Dfunction(s,dst){return(dst|=
|false)?Date.CultureInfo.abbreviatedTimeZoneDST[s.toUpperCase()]:Date.Cul=
tureInfo.abbreviatedTimeZoneStandard[s.toUpperCase()];};Date.getTimezoneA=
bbreviation=3Dfunction(offset,dst){var =
n=3D(dst||false)?Date.CultureInfo.abbreviatedTimeZoneDST:Date.CultureInfo=
.abbreviatedTimeZoneStandard,p;for(p in =
n){if(n[p]=3D=3D=3Doffset){return p;}}=0A=
return null;};Date.prototype.clone=3Dfunction(){return new =
Date(this.getTime());};Date.prototype.compareTo=3Dfunction(date){if(isNaN=
(this)){throw new Error(this);}=0A=
if(date instanceof =
Date&&!isNaN(date)){return(this>date)?1:(this<date)?-1:0;}else{throw new =
TypeError(date);}};Date.prototype.equals=3Dfunction(date){return(this.com=
pareTo(date)=3D=3D=3D0);};Date.prototype.between=3Dfunction(start,end){va=
r t=3Dthis.getTime();return =
t>=3Dstart.getTime()&&t<=3Dend.getTime();};Date.prototype.addMilliseconds=
=3Dfunction(value){this.setMilliseconds(this.getMilliseconds()+value);ret=
urn this;};Date.prototype.addSeconds=3Dfunction(value){return =
this.addMilliseconds(value*1000);};Date.prototype.addMinutes=3Dfunction(v=
alue){return =
this.addMilliseconds(value*60000);};Date.prototype.addHours=3Dfunction(va=
lue){return =
this.addMilliseconds(value*3600000);};Date.prototype.addDays=3Dfunction(v=
alue){return =
this.addMilliseconds(value*86400000);};Date.prototype.addWeeks=3Dfunction=
(value){return =
this.addMilliseconds(value*604800000);};Date.prototype.addMonths=3Dfuncti=
on(value){var =
n=3Dthis.getDate();this.setDate(1);this.setMonth(this.getMonth()+value);t=
his.setDate(Math.min(n,this.getDaysInMonth()));return =
this;};Date.prototype.addYears=3Dfunction(value){return =
this.addMonths(value*12);};Date.prototype.add=3Dfunction(config){if(typeo=
f config=3D=3D"number"){this._orient=3Dconfig;return this;}=0A=
var =
x=3Dconfig;if(x.millisecond||x.milliseconds){this.addMilliseconds(x.milli=
second||x.milliseconds);}=0A=
if(x.second||x.seconds){this.addSeconds(x.second||x.seconds);}=0A=
if(x.minute||x.minutes){this.addMinutes(x.minute||x.minutes);}=0A=
if(x.hour||x.hours){this.addHours(x.hour||x.hours);}=0A=
if(x.month||x.months){this.addMonths(x.month||x.months);}=0A=
if(x.year||x.years){this.addYears(x.year||x.years);}=0A=
if(x.day||x.days){this.addDays(x.day||x.days);}=0A=
return this;};Date._validate=3Dfunction(value,min,max,name){if(typeof =
value!=3D"number"){throw new TypeError(value+" is not a Number.");}else =
if(value<min||value>max){throw new RangeError(value+" is not a valid =
value for "+name+".");}=0A=
return true;};Date.validateMillisecond=3Dfunction(n){return =
Date._validate(n,0,999,"milliseconds");};Date.validateSecond=3Dfunction(n=
){return =
Date._validate(n,0,59,"seconds");};Date.validateMinute=3Dfunction(n){retu=
rn =
Date._validate(n,0,59,"minutes");};Date.validateHour=3Dfunction(n){return=
 =
Date._validate(n,0,23,"hours");};Date.validateDay=3Dfunction(n,year,month=
){return =
Date._validate(n,1,Date.getDaysInMonth(year,month),"days");};Date.validat=
eMonth=3Dfunction(n){return =
Date._validate(n,0,11,"months");};Date.validateYear=3Dfunction(n){return =
Date._validate(n,1,9999,"seconds");};Date.prototype.set=3Dfunction(config=
){var =
x=3Dconfig;if(!x.millisecond&&x.millisecond!=3D=3D0){x.millisecond=3D-1;}=0A=
if(!x.second&&x.second!=3D=3D0){x.second=3D-1;}=0A=
if(!x.minute&&x.minute!=3D=3D0){x.minute=3D-1;}=0A=
if(!x.hour&&x.hour!=3D=3D0){x.hour=3D-1;}=0A=
if(!x.day&&x.day!=3D=3D0){x.day=3D-1;}=0A=
if(!x.month&&x.month!=3D=3D0){x.month=3D-1;}=0A=
if(!x.year&&x.year!=3D=3D0){x.year=3D-1;}=0A=
if(x.millisecond!=3D-1&&Date.validateMillisecond(x.millisecond)){this.add=
Milliseconds(x.millisecond-this.getMilliseconds());}=0A=
if(x.second!=3D-1&&Date.validateSecond(x.second)){this.addSeconds(x.secon=
d-this.getSeconds());}=0A=
if(x.minute!=3D-1&&Date.validateMinute(x.minute)){this.addMinutes(x.minut=
e-this.getMinutes());}=0A=
if(x.hour!=3D-1&&Date.validateHour(x.hour)){this.addHours(x.hour-this.get=
Hours());}=0A=
if(x.month!=3D=3D-1&&Date.validateMonth(x.month)){this.addMonths(x.month-=
this.getMonth());}=0A=
if(x.year!=3D-1&&Date.validateYear(x.year)){this.addYears(x.year-this.get=
FullYear());}=0A=
if(x.day!=3D-1&&Date.validateDay(x.day,this.getFullYear(),this.getMonth()=
)){this.addDays(x.day-this.getDate());}=0A=
if(x.timezone){this.setTimezone(x.timezone);}=0A=
if(x.timezoneOffset){this.setTimezoneOffset(x.timezoneOffset);}=0A=
return =
this;};Date.prototype.clearTime=3Dfunction(){this.setHours(0);this.setMin=
utes(0);this.setSeconds(0);this.setMilliseconds(0);return =
this;};Date.prototype.isLeapYear=3Dfunction(){var =
y=3Dthis.getFullYear();return(((y%4=3D=3D=3D0)&&(y%100!=3D=3D0))||(y%400=3D=
=3D=3D0));};Date.prototype.isWeekday=3Dfunction(){return!(this.is().sat()=
||this.is().sun());};Date.prototype.getDaysInMonth=3Dfunction(){return =
Date.getDaysInMonth(this.getFullYear(),this.getMonth());};Date.prototype.=
moveToFirstDayOfMonth=3Dfunction(){return =
this.set({day:1});};Date.prototype.moveToLastDayOfMonth=3Dfunction(){retu=
rn =
this.set({day:this.getDaysInMonth()});};Date.prototype.moveToDayOfWeek=3D=
function(day,orient){var =
diff=3D(day-this.getDay()+7*(orient||+1))%7;return =
this.addDays((diff=3D=3D=3D0)?diff+=3D7*(orient||+1):diff);};Date.prototy=
pe.moveToMonth=3Dfunction(month,orient){var =
diff=3D(month-this.getMonth()+12*(orient||+1))%12;return =
this.addMonths((diff=3D=3D=3D0)?diff+=3D12*(orient||+1):diff);};Date.prot=
otype.getDayOfYear=3Dfunction(){return Math.floor((this-new =
Date(this.getFullYear(),0,1))/86400000);};Date.prototype.getWeekOfYear=3D=
function(firstDayOfWeek){var =
y=3Dthis.getFullYear(),m=3Dthis.getMonth(),d=3Dthis.getDate();var =
dow=3DfirstDayOfWeek||Date.CultureInfo.firstDayOfWeek;var =
offset=3D7+1-new Date(y,0,1).getDay();if(offset=3D=3D8){offset=3D1;}=0A=
var =
daynum=3D((Date.UTC(y,m,d,0,0,0)-Date.UTC(y,0,1,0,0,0))/86400000)+1;var =
w=3DMath.floor((daynum-offset+7)/7);if(w=3D=3D=3Ddow){y--;var =
prevOffset=3D7+1-new =
Date(y,0,1).getDay();if(prevOffset=3D=3D2||prevOffset=3D=3D8){w=3D53;}els=
e{w=3D52;}}=0A=
return w;};Date.prototype.isDST=3Dfunction(){console.log('isDST');return =
this.toString().match(/(E|C|M|P)(S|D)T/)[2]=3D=3D"D";};Date.prototype.get=
Timezone=3Dfunction(){return =
Date.getTimezoneAbbreviation(this.getUTCOffset,this.isDST());};Date.proto=
type.setTimezoneOffset=3Dfunction(s){var =
here=3Dthis.getTimezoneOffset(),there=3DNumber(s)*-6/10;this.addMinutes(t=
here-here);return this;};Date.prototype.setTimezone=3Dfunction(s){return =
this.setTimezoneOffset(Date.getTimezoneOffset(s));};Date.prototype.getUTC=
Offset=3Dfunction(){var =
n=3Dthis.getTimezoneOffset()*-10/6,r;if(n<0){r=3D(n-10000).toString();ret=
urn =
r[0]+r.substr(2);}else{r=3D(n+10000).toString();return"+"+r.substr(1);}};=
Date.prototype.getDayName=3Dfunction(abbrev){return =
abbrev?Date.CultureInfo.abbreviatedDayNames[this.getDay()]:Date.CultureIn=
fo.dayNames[this.getDay()];};Date.prototype.getMonthName=3Dfunction(abbre=
v){return =
abbrev?Date.CultureInfo.abbreviatedMonthNames[this.getMonth()]:Date.Cultu=
reInfo.monthNames[this.getMonth()];};Date.prototype._toString=3DDate.prot=
otype.toString;Date.prototype.toString=3Dfunction(format){var =
self=3Dthis;var p=3Dfunction =
p(s){return(s.toString().length=3D=3D1)?"0"+s:s;};return =
format?format.replace(/dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?/=
g,function(format){switch(format){case"hh":return =
p(self.getHours()<13?self.getHours():(self.getHours()-12));case"h":return=
 self.getHours()<13?self.getHours():(self.getHours()-12);case"HH":return =
p(self.getHours());case"H":return self.getHours();case"mm":return =
p(self.getMinutes());case"m":return self.getMinutes();case"ss":return =
p(self.getSeconds());case"s":return self.getSeconds();case"yyyy":return =
self.getFullYear();case"yy":return =
self.getFullYear().toString().substring(2,4);case"dddd":return =
self.getDayName();case"ddd":return self.getDayName(true);case"dd":return =
p(self.getDate());case"d":return =
self.getDate().toString();case"MMMM":return =
self.getMonthName();case"MMM":return =
self.getMonthName(true);case"MM":return =
p((self.getMonth()+1));case"M":return self.getMonth()+1;case"t":return =
self.getHours()<12?Date.CultureInfo.amDesignator.substring(0,1):Date.Cult=
ureInfo.pmDesignator.substring(0,1);case"tt":return =
self.getHours()<12?Date.CultureInfo.amDesignator:Date.CultureInfo.pmDesig=
nator;case"zzz":case"zz":case"z":return"";}}):this._toString();};=0A=
Date.now=3Dfunction(){return new Date();};Date.today=3Dfunction(){return =
Date.now().clearTime();};Date.prototype._orient=3D+1;Date.prototype.next=3D=
function(){this._orient=3D+1;return =
this;};Date.prototype.last=3DDate.prototype.prev=3DDate.prototype.previou=
s=3Dfunction(){this._orient=3D-1;return =
this;};Date.prototype._is=3Dfalse;Date.prototype.is=3Dfunction(){this._is=
=3Dtrue;return =
this;};Number.prototype._dateElement=3D"day";Number.prototype.fromNow=3Df=
unction(){var c=3D{};c[this._dateElement]=3Dthis;return =
Date.now().add(c);};Number.prototype.ago=3Dfunction(){var =
c=3D{};c[this._dateElement]=3Dthis*-1;return =
Date.now().add(c);};(function(){var =
$D=3DDate.prototype,$N=3DNumber.prototype;var dx=3D("sunday monday =
tuesday wednesday thursday friday saturday").split(/\s/),mx=3D("january =
february march april may june july august september october november =
december").split(/\s/),px=3D("Millisecond Second Minute Hour Day Week =
Month Year").split(/\s/),de;var df=3Dfunction(n){return =
function(){if(this._is){this._is=3Dfalse;return this.getDay()=3D=3Dn;}=0A=
return this.moveToDayOfWeek(n,this._orient);};};for(var =
i=3D0;i<dx.length;i++){$D[dx[i]]=3D$D[dx[i].substring(0,3)]=3Ddf(i);}=0A=
var mf=3Dfunction(n){return =
function(){if(this._is){this._is=3Dfalse;return =
this.getMonth()=3D=3D=3Dn;}=0A=
return this.moveToMonth(n,this._orient);};};for(var =
j=3D0;j<mx.length;j++){$D[mx[j]]=3D$D[mx[j].substring(0,3)]=3Dmf(j);}=0A=
var ef=3Dfunction(j){return =
function(){if(j.substring(j.length-1)!=3D"s"){j+=3D"s";}=0A=
return this["add"+j](this._orient);};};var nf=3Dfunction(n){return =
function(){this._dateElement=3Dn;return this;};};for(var =
k=3D0;k<px.length;k++){de=3Dpx[k].toLowerCase();$D[de]=3D$D[de+"s"]=3Def(=
px[k]);$N[de]=3D$N[de+"s"]=3Dnf(de);}}());Date.prototype.toJSONString=3Df=
unction(){return =
this.toString("yyyy-MM-ddThh:mm:ssZ");};Date.prototype.toShortDateString=3D=
function(){return =
this.toString(Date.CultureInfo.formatPatterns.shortDatePattern);};Date.pr=
ototype.toLongDateString=3Dfunction(){return =
this.toString(Date.CultureInfo.formatPatterns.longDatePattern);};Date.pro=
totype.toShortTimeString=3Dfunction(){return =
this.toString(Date.CultureInfo.formatPatterns.shortTimePattern);};Date.pr=
ototype.toLongTimeString=3Dfunction(){return =
this.toString(Date.CultureInfo.formatPatterns.longTimePattern);};Date.pro=
totype.getOrdinal=3Dfunction(){switch(this.getDate()){case 1:case =
21:case 31:return"st";case 2:case 22:return"nd";case 3:case =
23:return"rd";default:return"th";}};=0A=
(function(){Date.Parsing=3D{Exception:function(s){this.message=3D"Parse =
error at '"+s.substring(0,10)+" ...'";}};var $P=3DDate.Parsing;var =
_=3D$P.Operators=3D{rtoken:function(r){return function(s){var =
mx=3Ds.match(r);if(mx){return([mx[0],s.substring(mx[0].length)]);}else{th=
row new $P.Exception(s);}};},token:function(s){return function(s){return =
_.rtoken(new RegExp("^\s*"+s+"\s*"))(s);};},stoken:function(s){return =
_.rtoken(new RegExp("^"+s));},until:function(p){return function(s){var =
qx=3D[],rx=3Dnull;while(s.length){try{rx=3Dp.call(this,s);}catch(e){qx.pu=
sh(rx[0]);s=3Drx[1];continue;}=0A=
break;}=0A=
return[qx,s];};},many:function(p){return function(s){var =
rx=3D[],r=3Dnull;while(s.length){try{r=3Dp.call(this,s);}catch(e){return[=
rx,s];}=0A=
rx.push(r[0]);s=3Dr[1];}=0A=
return[rx,s];};},optional:function(p){return function(s){var =
r=3Dnull;try{r=3Dp.call(this,s);}catch(e){return[null,s];}=0A=
return[r[0],r[1]];};},not:function(p){return =
function(s){try{p.call(this,s);}catch(e){return[null,s];}=0A=
throw new $P.Exception(s);};},ignore:function(p){return =
p?function(s){var =
r=3Dnull;r=3Dp.call(this,s);return[null,r[1]];}:null;},product:function()=
{var =
px=3Darguments[0],qx=3DArray.prototype.slice.call(arguments,1),rx=3D[];fo=
r(var i=3D0;i<px.length;i++){rx.push(_.each(px[i],qx));}=0A=
return rx;},cache:function(rule){var cache=3D{},r=3Dnull;return =
function(s){try{r=3Dcache[s]=3D(cache[s]||rule.call(this,s));}catch(e){r=3D=
cache[s]=3De;}=0A=
if(r instanceof $P.Exception){throw r;}else{return =
r;}};},any:function(){var px=3Darguments;return function(s){var =
r=3Dnull;for(var i=3D0;i<px.length;i++){if(px[i]=3D=3Dnull){continue;}=0A=
try{r=3D(px[i].call(this,s));}catch(e){r=3Dnull;}=0A=
if(r){return r;}}=0A=
throw new $P.Exception(s);};},each:function(){var px=3Darguments;return =
function(s){var rx=3D[],r=3Dnull;for(var =
i=3D0;i<px.length;i++){if(px[i]=3D=3Dnull){continue;}=0A=
try{r=3D(px[i].call(this,s));}catch(e){throw new $P.Exception(s);}=0A=
rx.push(r[0]);s=3Dr[1];}=0A=
return[rx,s];};},all:function(){var px=3Darguments,_=3D_;return =
_.each(_.optional(px));},sequence:function(px,d,c){d=3Dd||_.rtoken(/^\s*/=
);c=3Dc||null;if(px.length=3D=3D1){return px[0];}=0A=
return function(s){var r=3Dnull,q=3Dnull;var rx=3D[];for(var =
i=3D0;i<px.length;i++){try{r=3Dpx[i].call(this,s);}catch(e){break;}=0A=
rx.push(r[0]);try{q=3Dd.call(this,r[1]);}catch(ex){q=3Dnull;break;}=0A=
s=3Dq[1];}=0A=
if(!r){throw new $P.Exception(s);}=0A=
if(q){throw new $P.Exception(q[1]);}=0A=
if(c){try{r=3Dc.call(this,r[1]);}catch(ey){throw new =
$P.Exception(r[1]);}}=0A=
return[rx,(r?r[1]:s)];};},between:function(d1,p,d2){d2=3Dd2||d1;var =
_fn=3D_.each(_.ignore(d1),p,_.ignore(d2));return function(s){var =
rx=3D_fn.call(this,s);return[[rx[0][0],r[0][2]],rx[1]];};},list:function(=
p,d,c){d=3Dd||_.rtoken(/^\s*/);c=3Dc||null;return(p instanceof =
Array?_.each(_.product(p.slice(0,-1),_.ignore(d)),p.slice(-1),_.ignore(c)=
):_.each(_.many(_.each(p,_.ignore(d))),px,_.ignore(c)));},set:function(px=
,d,c){d=3Dd||_.rtoken(/^\s*/);c=3Dc||null;return function(s){var =
r=3Dnull,p=3Dnull,q=3Dnull,rx=3Dnull,best=3D[[],s],last=3Dfalse;for(var =
i=3D0;i<px.length;i++){q=3Dnull;p=3Dnull;r=3Dnull;last=3D(px.length=3D=3D=
1);try{r=3Dpx[i].call(this,s);}catch(e){continue;}=0A=
rx=3D[[r[0]],r[1]];if(r[1].length>0&&!last){try{q=3Dd.call(this,r[1]);}ca=
tch(ex){last=3Dtrue;}}else{last=3Dtrue;}=0A=
if(!last&&q[1].length=3D=3D=3D0){last=3Dtrue;}=0A=
if(!last){var qx=3D[];for(var =
j=3D0;j<px.length;j++){if(i!=3Dj){qx.push(px[j]);}}=0A=
p=3D_.set(qx,d).call(this,q[1]);if(p[0].length>0){rx[0]=3Drx[0].concat(p[=
0]);rx[1]=3Dp[1];}}=0A=
if(rx[1].length<best[1].length){best=3Drx;}=0A=
if(best[1].length=3D=3D=3D0){break;}}=0A=
if(best[0].length=3D=3D=3D0){return best;}=0A=
if(c){try{q=3Dc.call(this,best[1]);}catch(ey){throw new =
$P.Exception(best[1]);}=0A=
best[1]=3Dq[1];}=0A=
return best;};},forward:function(gr,fname){return function(s){return =
gr[fname].call(this,s);};},replace:function(rule,repl){return =
function(s){var =
r=3Drule.call(this,s);return[repl,r[1]];};},process:function(rule,fn){ret=
urn function(s){var =
r=3Drule.call(this,s);return[fn.call(this,r[0]),r[1]];};},min:function(mi=
n,rule){return function(s){var =
rx=3Drule.call(this,s);if(rx[0].length<min){throw new $P.Exception(s);}=0A=
return rx;};}};var _generator=3Dfunction(op){return function(){var =
args=3Dnull,rx=3D[];if(arguments.length>1){args=3DArray.prototype.slice.c=
all(arguments);}else if(arguments[0]instanceof =
Array){args=3Darguments[0];}=0A=
if(args){for(var =
i=3D0,px=3Dargs.shift();i<px.length;i++){args.unshift(px[i]);rx.push(op.a=
pply(null,args));args.shift();return rx;}}else{return =
op.apply(null,arguments);}};};var gx=3D"optional not ignore =
cache".split(/\s/);for(var =
i=3D0;i<gx.length;i++){_[gx[i]]=3D_generator(_[gx[i]]);}=0A=
var _vector=3Dfunction(op){return function(){if(arguments[0]instanceof =
Array){return op.apply(null,arguments[0]);}else{return =
op.apply(null,arguments);}};};var vx=3D"each any =
all".split(/\s/);for(var =
j=3D0;j<vx.length;j++){_[vx[j]]=3D_vector(_[vx[j]]);}}());(function(){var=
 flattenAndCompact=3Dfunction(ax){var rx=3D[];for(var =
i=3D0;i<ax.length;i++){if(ax[i]instanceof =
Array){rx=3Drx.concat(flattenAndCompact(ax[i]));}else{if(ax[i]){rx.push(a=
x[i]);}}}=0A=
return rx;};Date.Grammar=3D{};Date.Translator=3D{hour:function(s){return =
function(){this.hour=3DNumber(s);};},minute:function(s){return =
function(){this.minute=3DNumber(s);};},second:function(s){return =
function(){this.second=3DNumber(s);};},meridian:function(s){return =
function(){this.meridian=3Ds.slice(0,1).toLowerCase();};},timezone:functi=
on(s){return function(){var =
n=3Ds.replace(/[^\d\+\-]/g,"");if(n.length){this.timezoneOffset=3DNumber(=
n);}else{this.timezone=3Ds.toLowerCase();}};},day:function(x){var =
s=3Dx[0];return =
function(){this.day=3DNumber(s.match(/\d+/)[0]);};},month:function(s){ret=
urn =
function(){this.month=3D((s.length=3D=3D3)?Date.getMonthNumberFromName(s)=
:(Number(s)-1));};},year:function(s){return function(){var =
n=3DNumber(s);this.year=3D((s.length>2)?n:(n+(((n+2000)<Date.CultureInfo.=
twoDigitYearMax)?2000:1900)));};},rday:function(s){return =
function(){switch(s){case"yesterday":this.days=3D-1;break;case"tomorrow":=
this.days=3D1;break;case"today":this.days=3D0;break;case"now":this.days=3D=
0;this.now=3Dtrue;break;}};},finishExact:function(x){x=3D(x instanceof =
Array)?x:[x];var now=3Dnew =
Date();this.year=3Dnow.getFullYear();this.month=3Dnow.getMonth();this.day=
=3D1;this.hour=3D0;this.minute=3D0;this.second=3D0;for(var =
i=3D0;i<x.length;i++){if(x[i]){x[i].call(this);}}=0A=
this.hour=3D(this.meridian=3D=3D"p"&&this.hour<13)?this.hour+12:this.hour=
;if(this.day>Date.getDaysInMonth(this.year,this.month)){throw new =
RangeError(this.day+" is not a valid value for days.");}=0A=
var r=3Dnew =
Date(this.year,this.month,this.day,this.hour,this.minute,this.second);if(=
this.timezone){r.set({timezone:this.timezone});}else =
if(this.timezoneOffset){r.set({timezoneOffset:this.timezoneOffset});}=0A=
return r;},finish:function(x){x=3D(x instanceof =
Array)?flattenAndCompact(x):[x];if(x.length=3D=3D=3D0){return null;}=0A=
for(var i=3D0;i<x.length;i++){if(typeof =
x[i]=3D=3D"function"){x[i].call(this);}}=0A=
if(this.now){return new Date();}=0A=
var today=3DDate.today();var method=3Dnull;var =
expression=3D!!(this.days!=3Dnull||this.orient||this.operator);if(express=
ion){var =
gap,mod,orient;orient=3D((this.orient=3D=3D"past"||this.operator=3D=3D"su=
btract")?-1:1);if(this.weekday){this.unit=3D"day";gap=3D(Date.getDayNumbe=
rFromName(this.weekday)-today.getDay());mod=3D7;this.days=3Dgap?((gap+(or=
ient*mod))%mod):(orient*mod);}=0A=
if(this.month){this.unit=3D"month";gap=3D(this.month-today.getMonth());mo=
d=3D12;this.months=3Dgap?((gap+(orient*mod))%mod):(orient*mod);this.month=
=3Dnull;}=0A=
if(!this.unit){this.unit=3D"day";}=0A=
if(this[this.unit+"s"]=3D=3Dnull||this.operator!=3Dnull){if(!this.value){=
this.value=3D1;}=0A=
if(this.unit=3D=3D"week"){this.unit=3D"day";this.value=3Dthis.value*7;}=0A=
this[this.unit+"s"]=3Dthis.value*orient;}=0A=
return =
today.add(this);}else{if(this.meridian&&this.hour){this.hour=3D(this.hour=
<13&&this.meridian=3D=3D"p")?this.hour+12:this.hour;}=0A=
if(this.weekday&&!this.day){this.day=3D(today.addDays((Date.getDayNumberF=
romName(this.weekday)-today.getDay()))).getDate();}=0A=
if(this.month&&!this.day){this.day=3D1;}=0A=
return today.set(this);}}};var =
_=3DDate.Parsing.Operators,g=3DDate.Grammar,t=3DDate.Translator,_fn;g.dat=
ePartDelimiter=3D_.rtoken(/^([\s\-\.\,\/\x27]+)/);g.timePartDelimiter=3D_=
.stoken(":");g.whiteSpace=3D_.rtoken(/^\s*/);g.generalDelimiter=3D_.rtoke=
n(/^(([\s\,]|at|on)+)/);var _C=3D{};g.ctoken=3Dfunction(keys){var =
fn=3D_C[keys];if(!fn){var c=3DDate.CultureInfo.regexPatterns;var =
kx=3Dkeys.split(/\s+/),px=3D[];for(var =
i=3D0;i<kx.length;i++){px.push(_.replace(_.rtoken(c[kx[i]]),kx[i]));}=0A=
fn=3D_C[keys]=3D_.any.apply(null,px);}=0A=
return fn;};g.ctoken2=3Dfunction(key){return =
_.rtoken(Date.CultureInfo.regexPatterns[key]);};g.h=3D_.cache(_.process(_=
.rtoken(/^(0[0-9]|1[0-2]|[1-9])/),t.hour));g.hh=3D_.cache(_.process(_.rto=
ken(/^(0[0-9]|1[0-2])/),t.hour));g.H=3D_.cache(_.process(_.rtoken(/^([0-1=
][0-9]|2[0-3]|[0-9])/),t.hour));g.HH=3D_.cache(_.process(_.rtoken(/^([0-1=
][0-9]|2[0-3])/),t.hour));g.m=3D_.cache(_.process(_.rtoken(/^([0-5][0-9]|=
[0-9])/),t.minute));g.mm=3D_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.mi=
nute));g.s=3D_.cache(_.process(_.rtoken(/^([0-5][0-9]|[0-9])/),t.second))=
;g.ss=3D_.cache(_.process(_.rtoken(/^[0-5][0-9]/),t.second));g.hms=3D_.ca=
che(_.sequence([g.H,g.mm,g.ss],g.timePartDelimiter));g.t=3D_.cache(_.proc=
ess(g.ctoken2("shortMeridian"),t.meridian));g.tt=3D_.cache(_.process(g.ct=
oken2("longMeridian"),t.meridian));g.z=3D_.cache(_.process(_.rtoken(/^(\+=
|\-)?\s*\d\d\d\d?/),t.timezone));g.zz=3D_.cache(_.process(_.rtoken(/^(\+|=
\-)\s*\d\d\d\d/),t.timezone));g.zzz=3D_.cache(_.process(g.ctoken2("timezo=
ne"),t.timezone));g.timeSuffix=3D_.each(_.ignore(g.whiteSpace),_.set([g.t=
t,g.zzz]));g.time=3D_.each(_.optional(_.ignore(_.stoken("T"))),g.hms,g.ti=
meSuffix);g.d=3D_.cache(_.process(_.each(_.rtoken(/^([0-2]\d|3[0-1]|\d)/)=
,_.optional(g.ctoken2("ordinalSuffix"))),t.day));g.dd=3D_.cache(_.process=
(_.each(_.rtoken(/^([0-2]\d|3[0-1])/),_.optional(g.ctoken2("ordinalSuffix=
"))),t.day));g.ddd=3Dg.dddd=3D_.cache(_.process(g.ctoken("sun mon tue =
wed thu fri sat"),function(s){return =
function(){this.weekday=3Ds;};}));g.M=3D_.cache(_.process(_.rtoken(/^(1[0=
-2]|0\d|\d)/),t.month));g.MM=3D_.cache(_.process(_.rtoken(/^(1[0-2]|0\d)/=
),t.month));g.MMM=3Dg.MMMM=3D_.cache(_.process(g.ctoken("jan feb mar apr =
may jun jul aug sep oct nov =
dec"),t.month));g.y=3D_.cache(_.process(_.rtoken(/^(\d\d?)/),t.year));g.y=
y=3D_.cache(_.process(_.rtoken(/^(\d\d)/),t.year));g.yyy=3D_.cache(_.proc=
ess(_.rtoken(/^(\d\d?\d?\d?)/),t.year));g.yyyy=3D_.cache(_.process(_.rtok=
en(/^(\d\d\d\d)/),t.year));_fn=3Dfunction(){return =
_.each(_.any.apply(null,arguments),_.not(g.ctoken2("timeContext")));};g.d=
ay=3D_fn(g.d,g.dd);g.month=3D_fn(g.M,g.MMM);g.year=3D_fn(g.yyyy,g.yy);g.o=
rientation=3D_.process(g.ctoken("past future"),function(s){return =
function(){this.orient=3Ds;};});g.operator=3D_.process(g.ctoken("add =
subtract"),function(s){return =
function(){this.operator=3Ds;};});g.rday=3D_.process(g.ctoken("yesterday =
tomorrow today now"),t.rday);g.unit=3D_.process(g.ctoken("minute hour =
day week month year"),function(s){return =
function(){this.unit=3Ds;};});g.value=3D_.process(_.rtoken(/^\d\d?(st|nd|=
rd|th)?/),function(s){return =
function(){this.value=3Ds.replace(/\D/g,"");};});g.expression=3D_.set([g.=
rday,g.operator,g.value,g.unit,g.orientation,g.ddd,g.MMM]);_fn=3Dfunction=
(){return =
_.set(arguments,g.datePartDelimiter);};g.mdy=3D_fn(g.ddd,g.month,g.day,g.=
year);g.ymd=3D_fn(g.ddd,g.year,g.month,g.day);g.dmy=3D_fn(g.ddd,g.day,g.m=
onth,g.year);g.date=3Dfunction(s){return((g[Date.CultureInfo.dateElementO=
rder]||g.mdy).call(this,s));};g.format=3D_.process(_.many(_.any(_.process=
(_.rtoken(/^(dd?d?d?|MM?M?M?|yy?y?y?|hh?|HH?|mm?|ss?|tt?|zz?z?)/),functio=
n(fmt){if(g[fmt]){return g[fmt];}else{throw =
Date.Parsing.Exception(fmt);}}),_.process(_.rtoken(/^[^dMyhHmstz]+/),func=
tion(s){return _.ignore(_.stoken(s));}))),function(rules){return =
_.process(_.each.apply(null,rules),t.finishExact);});var _F=3D{};var =
_get=3Dfunction(f){return =
_F[f]=3D(_F[f]||g.format(f)[0]);};g.formats=3Dfunction(fx){if(fx =
instanceof Array){var rx=3D[];for(var =
i=3D0;i<fx.length;i++){rx.push(_get(fx[i]));}=0A=
return _.any.apply(null,rx);}else{return =
_get(fx);}};g._formats=3Dg.formats(["yyyy-MM-ddTHH:mm:ss","ddd, MMM dd, =
yyyy H:mm:ss tt","ddd MMM d yyyy HH:mm:ss =
zzz","d"]);g._start=3D_.process(_.set([g.date,g.time,g.expression],g.gene=
ralDelimiter,g.whiteSpace),t.finish);g.start=3Dfunction(s){try{var =
r=3Dg._formats.call({},s);if(r[1].length=3D=3D=3D0){return r;}}catch(e){}=0A=
return =
g._start.call({},s);};}());Date._parse=3DDate.parse;Date.parse=3Dfunction=
(s){var r=3Dnull;if(!s){return null;}=0A=
try{r=3DDate.Grammar.start.call({},s);}catch(e){return null;}=0A=
return((r[1].length=3D=3D=3D0)?r[0]:null);};Date.getParseFunction=3Dfunct=
ion(fx){var fn=3DDate.Grammar.formats(fx);return function(s){var =
r=3Dnull;try{r=3Dfn.call({},s);}catch(e){return null;}=0A=
return((r[1].length=3D=3D=3D0)?r[0]:null);};};Date.parseExact=3Dfunction(=
s,fx){return Date.getParseFunction(fx)(s);};

------=_NextPart_000_0000_01CE307B.330E2A00--
