if(typeof (nitobi)=="undefined"||typeof (nitobi.lang)=="undefined"){
alert("The Nitobi framework source could not be found. Is it included before any other Nitobi components?");
}
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.build="6573";
nitobi.combo.version="3.55.6573";
if(typeof (nitobi)=="undefined"){
nitobi={};
}
if(typeof (nitobi.Browser)=="undefined"){
nitobi.Browser={};
}
nitobi.Browser.Unload=function(){
};
nitobi.Browser.GetScrollBarWidth=nitobi.html.getScrollBarWidth;
nitobi.Browser.GetBrowserType=function(){
try{
return (navigator.appName=="Microsoft Internet Explorer"?this.nitobi.Browser.IE:this.nitobi.Browser.UNKNOWN);
}
catch(err){
}
};
nitobi.Browser.GetBrowserDetails=function(){
try{
return (this.GetBrowserType()==this.nitobi.Browser.IE?window.clientInformation:null);
}
catch(err){
}
};
nitobi.Browser.IsObjectInView=function(_1,_2,_3,_4){
try{
var _5=_1.getBoundingClientRect();
var _6=_2.getBoundingClientRect();
if(nitobi.browser.MOZ){
_6.top+=_2.scrollTop;
_6.bottom+=_2.scrollTop;
_6.left+=_2.scrollLeft;
_6.right+=_2.scrollLeft;
}
var _7=((true==_3?(_5.top==_6.top):(_5.top>=_6.top)&&(_5.bottom<=_6.bottom))&&(_4?true:(_5.right<=_6.right)&&(_5.left>=_6.left)));
return _7;
}
catch(err){
}
};
nitobi.Browser.VAdjust=function(_8,_9){
var v=(_8.offsetParent?_8.offsetParent.offsetTop:0);
var id=_8.id;
var _c=id.substring(0,1+id.lastIndexOf("_"))+"0";
var _d=_9.ownerDocument;
if(null==_d){
_d=_9.document;
}
var oF=_d.getElementById(_c);
return v-(oF.offsetParent?oF.offsetParent.offsetTop:0);
};
nitobi.Browser.WheelUntil=function(_f,inc,_11,idx,_13,_14){
var min=(inc?-1:0);
var max=(inc?_13:_13+1);
while(idx>min&&idx<max){
if(inc){
idx++;
}else{
idx--;
}
var r=_11.GetRow(idx);
var _18=this.IsObjectInView(r,_14,false,true);
if(_18==_f){
return idx;
}
}
return idx;
};
nitobi.Browser.WheelUp=function(_19){
var top=_19.GetRow(0);
var _1b=_19.GetXmlDataSource().GetNumberRows()-1;
var _1c=_19.GetRow(_1b);
var _1d=_19.GetSectionHTMLTagObject(EBAComboBoxListBody);
var i=parseInt(_1d.scrollTop/top.offsetHeight);
var r=(i>_1b?_1c:_19.GetRow(i));
var _20=r.offsetTop-_1d.scrollTop+nitobi.Browser.VAdjust(r,_1d);
if(this.IsObjectInView(r,_1d,false,true)){
i=this.WheelUntil(false,false,_19,i,_1b,_1d);
}else{
if(_20<0){
i=this.WheelUntil(true,true,_19,i,_1b,_1d);
i--;
}else{
i=this.WheelUntil(true,false,_19,i,_1b,_1d);
i=this.WheelUntil(false,false,_19,i,_1b,_1d);
}
}
this.ScrollIntoView(_19.GetRow(i),_1d,true,false);
};
nitobi.Browser.WheelDown=function(_21){
var top=_21.GetRow(0);
var _23=_21.GetXmlDataSource().GetNumberRows()-1;
var _24=_21.GetRow(_23);
var _25=_21.GetSectionHTMLTagObject(EBAComboBoxListBody);
var i=parseInt(_25.scrollTop/top.offsetHeight);
var r=(i>_23?_24:_21.GetRow(i));
var _28=r.offsetTop-_25.scrollTop+nitobi.Browser.VAdjust(r,_25);
if(this.IsObjectInView(r,_25,false,true)){
i=1+this.WheelUntil(false,false,_21,i,_23,_25);
}else{
if(_28<0){
i=this.WheelUntil(true,true,_21,i,_23,_25);
}else{
i=this.WheelUntil(true,false,_21,i,_23,_25);
i=1+this.WheelUntil(false,false,_21,i,_23,_25);
}
}
r=_21.GetRow(i);
_28=r.offsetTop-_25.scrollTop+nitobi.Browser.VAdjust(r,_25);
if(0==_28&&i!=_23){
r=_21.GetRow(1+i);
}
this.ScrollIntoView(r,_25,true,false);
};
nitobi.Browser.ScrollIntoView=function(_29,_2a,Top,_2c){
try{
var _2d=_29.getBoundingClientRect();
var _2e=_2a.getBoundingClientRect();
var _2f=_29.offsetTop-_2a.scrollTop;
var v=nitobi.Browser.VAdjust(_29,_2a);
_2f+=v;
var _31=_29.offsetLeft-_2a.scrollLeft;
var _32=_31+_29.offsetWidth-_2a.offsetWidth;
var _33=_2f+_29.offsetHeight-_2a.offsetHeight;
var _34=0;
var _35=0;
var _36=this.GetScrollBarWidth(_2a);
if(this.GetVerticalScrollBarStatus(_2a)==true){
_34=_36;
}
if(_31<0){
_2a.scrollLeft+=_31;
}else{
if(_32>0){
if(_2d.left-_32>_2e.left){
_2a.scrollLeft+=_32+_34;
}else{
_2a.scrollLeft+=_31;
}
}
}
if((_2f<0||true==Top)&&true!=_2c){
_2a.scrollTop+=_2f;
}else{
if(_33>0||true==_2c){
if(_2d.top-_33>_2e.top||true==_2c){
_2a.scrollTop+=_33+_35;
}else{
_2a.scrollTop+=_2f;
}
}
}
}
catch(err){
}
};
nitobi.Browser.GetVerticalScrollBarStatus=function(_37){
try{
return this.GetScrollBarWidth(_37)>0;
}
catch(err){
}
};
nitobi.Browser.GetHorizontalScrollBarStatus=function(_38){
try{
return (_38.scrollWidth>_38.offsetWidth-this.GetScrollBarWidth(_38));
}
catch(err){
}
};
nitobi.Browser.HTMLUnencode=function(_39){
try{
var _3a=_39;
var _3b=new Array(/&amp;/g,/&lt;/g,/&quot;/g,/&gt;/g,/&nbsp;/g);
var _3c=new Array("&","<","\"",">"," ");
for(var i=0;i<_3b.length;i++){
_3a=_3a.replace(_3b[i],_3c[i]);
}
return (_3a);
}
catch(err){
}
};
nitobi.Browser.EncodeAngleBracketsInTagAttributes=function(str,_3f){
str=str.replace(/'"'/g,"\"&quot;\"");
try{
_3f.ShowWarning(str.match(/ComboValue .*?[a-z]='/g)==null,"cw002");
}
catch(err){
}
var _40=str.match(/".*?"/g);
if(_40){
for(var i=0;i<_40.length;i++){
val=_40[i];
val=val.replace(/</g,"&lt;");
val=val.replace(/>/g,"&gt;");
str=str.replace(_40[i],val);
}
}
return str;
};
nitobi.Browser.LoadPageFromUrl=function(Url,_43){
if(_43==null){
_43="GET";
}
var _44=xbXMLHTTP.create();
_44.abort();
_44.open(_43,Url,false,"","");
_44.send("EBA Combo Box Get Page Request");
return (_44.responseText);
};
nitobi.Browser.GetMeasurementUnitType=function(_45){
try{
if(_45==null||_45==""){
return "";
}
var _46=_45.search(/\D/g);
var _47=_45.substring(_46);
return (_47);
}
catch(err){
}
};
nitobi.Browser.GetMeasurementUnitValue=function(_48){
try{
var _49=_48.search(/\D/g);
var _4a=_48.substring(0,_49);
return Number(_4a);
}
catch(err){
}
};
nitobi.Browser.GetElementWidth=function(_4b){
try{
if(_4b==null){
throw ("Element in GetElementWidth is null");
}
var _4c=_4b.style;
var top=_4c.top;
var _4e=_4c.display;
var _4f=_4c.position;
var _50=_4c.visibility;
var _51=nitobi.html.Css.getStyle(_4b,"visibility");
var _52=nitobi.html.Css.getStyle(_4b,"display");
var _53=0;
if(_52=="none"||_51=="hidden"){
_4c.position="absolute";
_4c.top=-1000;
_4c.display="inline";
_4c.visibility="visible";
}
var _54=nitobi.html.getWidth(_4b);
if(_4c.display=="inline"){
_4c.position=_4f;
_4c.top=top;
_4c.display=_4e;
_4c.visibility=_50;
}
return parseInt(_54);
}
catch(err){
}
};
nitobi.Browser.GetElementHeight=function(_55){
try{
if(_55==null){
throw ("Element in GetElementHeight is null");
}
var _56=_55.style;
var top=_56.top;
var _58=_56.display;
var _59=_56.position;
var _5a=_56.visibility;
if(_56.display=="none"||_56.visibility!="visible"){
_56.position="absolute";
_56.top="-1000px";
_56.display="inline";
_56.visibility="visible";
}
var _5b=nitobi.html.getHeight(_55);
if(_56.display=="inline"){
_56.position=_59;
_56.top=top;
_56.display=_58;
_56.visibility=_5a;
}
return parseInt(_5b);
}
catch(err){
}
};
nitobi.Browser.GetParentElementByTagName=function(_5c,_5d){
try{
_5d=_5d.toLowerCase();
var _5e;
do{
_5c=_5c.parentElement;
if(_5c!=null){
_5e=_5c.tagName.toLowerCase();
}
}while((_5e!=_5d)&&(_5c!=null));
return _5c;
}
catch(err){
return null;
}
};
nitobi.lang.defineNs("nitobi.drawing");
nitobi.drawing.rgb=function(r,g,b){
return "#"+((r*65536)+(g*256)+b).toString(16);
};
nitobi.drawing.align=function(_62,_63,_64,oh,ow,oy,ox,_69){
oh=oh||0;
ow=ow||0;
oy=oy||0;
ox=ox||0;
var a=_64;
var td,sd,tt,tb,tl,tr,th,tw,st,sb,sl,sr,sh,sw;
if(nitobi.browser.IE){
td=_63.getBoundingClientRect();
sd=_62.getBoundingClientRect();
tt=td.top;
tb=td.bottom;
tl=td.left;
tr=td.right;
th=Math.abs(tb-tt);
tw=Math.abs(tr-tl);
st=sd.top;
sb=sd.bottom;
sl=sd.left;
sr=sd.right;
sh=Math.abs(sb-st);
sw=Math.abs(sr-sl);
}
if(nitobi.browser.MOZ){
td=document.getBoxObjectFor(_63);
sd=document.getBoxObjectFor(_62);
tt=td.y;
tl=td.x;
tw=td.width;
th=td.height;
st=sd.y;
sl=sd.x;
sw=sd.width;
sh=sd.height;
}
if(a&268435456){
_62.style.height=th+oh;
}
if(a&16777216){
_62.style.width=tw+ow;
}
if(a&1048576){
_62.style.top=nitobi.html.getStyleTop(_62)+tt-st+oy;
}
if(a&65536){
_62.style.top=nitobi.html.getStyleTop(_62)+tt-st+th-sh+oy;
}
if(a&4096){
_62.style.left=nitobi.html.getStyleLeft(_62)-sl+tl+ox;
}
if(a&256){
_62.style.left=nitobi.html.getStyleLeft(_62)-sl+tl+tw-sw+ox;
}
if(a&16){
_62.style.top=nitobi.html.getStyleTop(_62)+tt-st+oy+Math.floor((th-sh)/2);
}
if(a&1){
_62.style.left=nitobi.html.getStyleLeft(_62)-sl+tl+ox+Math.floor((tw-sw)/2);
}
if(_69){
src.style.top=st-2;
src.style.left=sl-2;
src.style.height=sh;
src.style.width=sw;
tgt.style.top=tt-2;
tgt.style.left=tl-2;
tgt.style.height=th;
tgt.style.width=tw;
if(document.getBoundingClientRect){
sd=_62.getBoundingClientRect();
st=sd.top;
sb=sd.bottom;
sl=sd.left;
sr=sd.right;
sh=Math.abs(sb-st);
sw=Math.abs(sr-sl);
}
if(document.getBoxObjectFor){
sd=document.getBoxObjectFor(_62);
st=sd.screenY;
sl=sd.screenX;
sw=sd.width;
sh=sd.height;
}
src2.style.top=st-2;
src2.style.left=sl-2;
src2.style.height=sh;
src2.style.width=sw;
}
};
nitobi.drawing.align.SAMEHEIGHT=268435456;
nitobi.drawing.align.SAMEWIDTH=16777216;
nitobi.drawing.align.ALIGNTOP=1048576;
nitobi.drawing.align.ALIGNBOTTOM=65536;
nitobi.drawing.align.ALIGNLEFT=4096;
nitobi.drawing.align.ALIGNRIGHT=256;
nitobi.drawing.align.ALIGNMIDDLEVERT=16;
nitobi.drawing.align.ALIGNMIDDLEHORIZ=1;
nitobi.drawing.alignOuterBox=function(_79,_7a,_7b,oh,ow,oy,ox,_80){
oh=oh||0;
ow=ow||0;
oy=oy||0;
ox=ox||0;
if(nitobi.browser.MOZ){
td=document.getBoxObjectFor(_7a);
sd=document.getBoxObjectFor(_79);
var _81=parseInt(document.defaultView.getComputedStyle(_7a,"").getPropertyValue("border-left-width"));
var _82=parseInt(document.defaultView.getComputedStyle(_7a,"").getPropertyValue("border-top-width"));
var _83=parseInt(document.defaultView.getComputedStyle(_79,"").getPropertyValue("border-top-width"));
var _84=parseInt(document.defaultView.getComputedStyle(_79,"").getPropertyValue("border-bottom-width"));
var _85=parseInt(document.defaultView.getComputedStyle(_79,"").getPropertyValue("border-left-width"));
var _86=parseInt(document.defaultView.getComputedStyle(_79,"").getPropertyValue("border-right-width"));
oy=oy+_83-_82;
ox=ox+_85-_81;
}
nitobi.drawing.align(_79,_7a,_7b,oh,ow,oy,ox,_80);
};
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.Button=function(_87,_88){
try{
var _89="ntb-combobox-button";
var _8a="ntb-combobox-button-pressed";
var _8b="";
var _8c="";
this.SetCombo(_88);
var _8d=(_87?_87.getAttribute("Width"):null);
((null==_8d)||(_8d==""))?this.SetWidth(_8b):this.SetWidth(_8d);
var _8e=(_87?_87.getAttribute("Height"):null);
((null==_8e)||(_8e==""))?this.SetHeight(_8c):this.SetHeight(_8e);
var _8f=(_87?_87.getAttribute("DefaultCSSClassName"):null);
((null==_8f)||(_8f==""))?this.SetDefaultCSSClassName(_89):this.SetDefaultCSSClassName(_8f);
var _90=(_87?_87.getAttribute("PressedCSSClassName"):null);
((null==_90)||(_90==""))?this.SetPressedCSSClassName(_8a):this.SetPressedCSSClassName(_90);
this.SetCSSClassName(this.GetDefaultCSSClassName());
this.m_userTag=_87;
this.m_prevImgClass="ntb-combobox-button-img";
}
catch(err){
}
};
nitobi.combo.Button.prototype.Unload=Button_Unload;
function Button_Unload(){
}
nitobi.combo.Button.prototype.GetDefaultCSSClassName=Button_GetDefaultCSSClassName;
function Button_GetDefaultCSSClassName(){
try{
return this.m_DefaultCSSClassName;
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetDefaultCSSClassName=Button_SetDefaultCSSClassName;
function Button_SetDefaultCSSClassName(_91){
try{
this.m_DefaultCSSClassName=_91;
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetPressedCSSClassName=Button_GetPressedCSSClassName;
function Button_GetPressedCSSClassName(){
try{
return this.m_PressedCSSClassName;
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetPressedCSSClassName=Button_SetPressedCSSClassName;
function Button_SetPressedCSSClassName(_92){
try{
this.m_PressedCSSClassName=_92;
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetHeight=Button_GetHeight;
function Button_GetHeight(){
try{
return (null==this.m_HTMLTagObject?this.m_Height:this.m_HTMLTagObject.style.height);
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetHeight=Button_SetHeight;
function Button_SetHeight(_93){
try{
if(null==this.m_HTMLTagObject){
this.m_Height=_93;
}else{
this.m_HTMLTagObject.style.height=_93;
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetWidth=Button_GetWidth;
function Button_GetWidth(){
try{
if(null==this.m_HTMLTagObject){
return this.m_Width;
}else{
return this.m_HTMLTagObject.style.width;
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetWidth=Button_SetWidth;
function Button_SetWidth(_94){
try{
if(null==this.m_HTMLTagObject){
this.m_Width=_94;
}else{
this.m_HTMLTagObject.style.width=_94;
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetHTMLTagObject=Button_GetHTMLTagObject;
function Button_GetHTMLTagObject(){
try{
return this.m_HTMLTagObject;
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetHTMLTagObject=Button_SetHTMLTagObject;
function Button_SetHTMLTagObject(_95){
try{
this.m_HTMLTagObject=_95;
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetCombo=Button_GetCombo;
function Button_GetCombo(){
try{
return this.m_Combo;
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetCombo=Button_SetCombo;
function Button_SetCombo(_96){
try{
this.m_Combo=_96;
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetCSSClassName=Button_GetCSSClassName;
function Button_GetCSSClassName(){
try{
return (null==this.m_HTMLTagObject?this.m_CSSClassName:this.m_HTMLTagObject.className);
}
catch(err){
}
}
nitobi.combo.Button.prototype.SetCSSClassName=Button_SetCSSClassName;
function Button_SetCSSClassName(_97){
try{
if(null==this.m_HTMLTagObject){
this.m_CSSClassName=_97;
}else{
this.m_HTMLTagObject.className=_97;
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.OnMouseOver=Button_OnMouseOver;
function Button_OnMouseOver(_98,_99){
try{
if(this.GetCombo().GetEnabled()){
if(null==_98){
_98=this.m_Img;
}
this.m_prevImgClass="ntb-combobox-button-img-over";
_98.className=this.m_prevImgClass;
if(_99){
this.GetCombo().GetTextBox().OnMouseOver(false);
}
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.OnMouseOut=Button_OnMouseOut;
function Button_OnMouseOut(_9a,_9b){
try{
if(null==_9a){
_9a=this.m_Img;
}
this.m_prevImgClass="ntb-combobox-button-img";
_9a.className=this.m_prevImgClass;
if(_9b){
this.GetCombo().GetTextBox().OnMouseOut(false);
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.OnMouseDown=Button_OnMouseDown;
function Button_OnMouseDown(_9c){
try{
if(this.GetCombo().GetEnabled()){
if(null!=_9c){
_9c.className="ntb-combobox-button-img-pressed";
}
this.OnClick();
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.OnMouseUp=Button_OnMouseUp;
function Button_OnMouseUp(_9d){
try{
if(this.GetCombo().GetEnabled()){
if(null!=_9d){
_9d.className=this.m_prevImgClass;
}
}
}
catch(err){
}
}
nitobi.combo.Button.prototype.OnClick=Button_OnClick;
function Button_OnClick(){
try{
var _9e=this.GetCombo();
var _9f=window.document.getElementsByTagName(nitobi.browser.MOZ?"ntb:Combo":"combo");
for(var i=0;i<_9f.length;i++){
var _a1=_9f[i].object;
try{
if(_9e.GetId()!=_a1.GetId()){
_a1.GetList().Hide();
}
}
catch(err){
}
}
var l=_9e.GetList();
l.Toggle();
var t=_9e.GetTextBox();
var tb=t.GetHTMLTagObject();
if(t.focused){
t.m_skipFocusOnce=true;
}
tb.focus();
}
catch(err){
}
}
nitobi.combo.Button.prototype.GetHTMLRenderString=Button_GetHTMLRenderString;
function Button_GetHTMLRenderString(){
try{
var _a5=this.GetCombo().GetId();
var uid=this.GetCombo().GetUniqueId();
var w=this.GetWidth();
var h=this.GetHeight();
if(nitobi.browser.MOZ){
var _a9="<span id='EBAComboBoxButton"+uid+"' "+"class='"+this.GetDefaultCSSClassName()+"' "+"style='"+(null!=w&&""!=w?"width:"+w+";":"")+(null!=h&&""!=h?"height:"+h+";":"")+"'>"+"<img src='javascript:void(0);' class='ntb-combobox-button-img' id='EBAComboBoxButtonImg"+uid+"' "+"onmouseover='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseOver(this, true)' "+"onmouseout='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseOut(this, true)' "+"onmousedown='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseDown(this);return false;' "+"onmouseup='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseUp(this)' "+"onmousemove='return false;' "+"></img></span>";
}else{
var _a9="<span id='EBAComboBoxButton"+uid+"' "+"class='"+this.GetDefaultCSSClassName()+"' "+"style='"+(null!=w&&""!=w?"width:"+w+";":"")+(null!=h&&""!=h?"height:"+h+";":"")+"'>"+"<img class='ntb-combobox-button-img' id='EBAComboBoxButtonImg"+uid+"' "+"onmouseover='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseOver(this, true)' "+"onmouseout='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseOut(this, true)' "+"onmousedown='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseDown(this);return false;' "+"onmouseup='window.document.getElementById(\""+_a5+"\").object.GetButton().OnMouseUp(this)' "+"onmousemove='return false;' "+"></img></span>";
}
return _a9;
}
catch(err){
}
}
nitobi.combo.Button.prototype.Initialize=Button_Initialize;
function Button_Initialize(){
try{
var _aa=this.GetCombo();
var uid=_aa.GetUniqueId();
this.SetHTMLTagObject(window.document.getElementById("EBAComboBoxButton"+uid));
var img=window.document.getElementById("EBAComboBoxButtonImg"+uid);
var _ad=nitobi.html.Css.getStyle(img,"background-image");
_ad=_ad.replace(/button\.gif/g,"blank.gif");
if(nitobi.browser.IE){
_ad=_ad.substr(5,_ad.length-7);
}else{
_ad=_ad.substr(4,_ad.length-5);
_ad=_ad.replace(/\\\(/g,"(");
_ad=_ad.replace(/\\\)/g,")");
}
img.src=_ad;
this.m_Img=img;
this._onmouseover=img.onmouseover;
this._onmouseout=img.onmouseout;
this._onclick=img.onclick;
this._onmousedown=img.onmousedown;
this._onmouseup=img.onmouseup;
if(!this.GetCombo().GetEnabled()){
this.Disable();
}
this.m_userTag=null;
}
catch(err){
}
}
nitobi.combo.Button.prototype.Disable=Button_Disable;
function Button_Disable(){
var img=this.m_Img;
img.onmouseover=null;
img.onmouseout=null;
img.onclick=null;
img.onmousedown=null;
img.onmouseup=null;
img.className="ntb-combobox-button-img-disabled";
}
nitobi.combo.Button.prototype.Enable=Button_Enable;
function Button_Enable(){
var img=this.m_Img;
img.onmouseover=this._onmouseover;
img.onmouseout=this._onmouseout;
img.onclick=this._onclick;
img.onmousedown=this._onmousedown;
img.onmouseup=this._onmouseup;
img.className="ntb-combobox-button-img";
}
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.numCombosToLoad=0;
nitobi.combo.numCombosToLoadInitially=4;
nitobi.combo.loadDelayMultiplier=10;
nitobi.getCombo=function(id){
return document.getElementById(id).jsObject;
};
nitobi.combo.initBase=function(){
if(nitobi.combo.initBase.done==false){
Debug=new Debug;
var _b1=[];
var _b2=window.document.getElementsByTagName(nitobi.browser.MOZ?"eba:ComboPanel":"combopanel");
var _b3=(nitobi.browser.MOZ?window.document.getElementsByTagName("ntb:ComboPanel"):[]);
for(var i=0;i<_b3.length;i++){
_b1.push(_b3[i]);
}
for(var i=0;i<_b2.length;i++){
_b1.push(_b2[i]);
}
for(var i=0;i<_b1.length;i++){
_b1[i].style.display="none";
}
g_EbaTimer=null;
nitobi.combo.createLanguagePack();
try{
g_EbaTimer=new Timer();
}
catch(err){
g_EbaTimer=null;
}
if(nitobi.browser.IE){
nitobi.combo.iframeBacker=window.document.createElement("IFRAME");
nitobi.combo.iframeBacker.style.position="absolute";
nitobi.combo.iframeBacker.style.zindex="1000";
nitobi.combo.iframeBacker.style.visibility="hidden";
nitobi.combo.iframeBacker.name="nitobi.combo.iframeBacker_Id";
nitobi.combo.iframeBacker.id="nitobi.combo.iframeBacker_Id";
nitobi.combo.iframeBacker.frameBorder=0;
nitobi.combo.iframeBacker.src="javascript:true";
window.document.body.insertAdjacentElement("afterBegin",nitobi.combo.iframeBacker);
}
nitobi.combo.initBase.done=true;
}
};
nitobi.combo.initBase.done=false;
nitobi.initCombo=function(el){
nitobi.combo.initBase();
var tag;
if(typeof (el)=="string"){
tag=document.getElementById(el);
}else{
tag=el;
}
tag.object=new nitobi.combo.Combo(tag);
tag.object.Initialize();
tag.object.GetList().Render();
return tag.object;
};
nitobi.initCombos=function(){
nitobi.combo.initBase();
var _b7=[];
var _b8=window.document.getElementsByTagName(nitobi.browser.MOZ?"eba:Combo":"combo");
var _b9=(nitobi.browser.MOZ?window.document.getElementsByTagName("ntb:Combo"):[]);
for(var i=0;i<_b9.length;i++){
_b7.push(_b9[i]);
}
for(var i=0;i<_b8.length;i++){
_b7.push(_b8[i]);
}
if(0==window.document.styleSheets.length){
alert("You are missing a link to the Web ComboBoxes' style sheet.");
}else{
nitobi.combo.numCombosToLoad=_b7.length;
for(var i=0;i<_b7.length;i++){
try{
if(i>=nitobi.combo.numCombosToLoadInitially){
var _bb=i*nitobi.combo.loadDelayMultiplier;
window.setTimeout("try{document.getElementById('"+_b7[i].id+"').object = new nitobi.combo.Combo(document.getElementById('"+_b7[i].id+"'));document.getElementById('"+_b7[i].id+"').object.Initialize();}catch(err){alert(err.message);}",_bb);
}else{
nitobi.initCombo(_b7[i]);
}
}
catch(err){
alert(err.message);
}
}
}
};
function InitializeEbaCombos(){
nitobi.initCombos();
}
nitobi.combo.finishInit=function(){
nitobi.combo.resize();
nitobi.html.attachEvent(window,"resize",nitobi.combo.resize);
if(window.addEventListener){
window.addEventListener("unload",nitobi.combo.unloadAll,false);
}else{
if(document.addEventListener){
document.addEventListener("unload",nitobi.combo.unloadAll,false);
}else{
if(window.attachEvent){
window.attachEvent("onunload",nitobi.combo.unloadAll);
}else{
if(window.onunload){
window.XTRonunload=window.onunload;
}
window.onunload=nitobi.combo.unloadAll;
}
}
}
try{
eval("try{OnAfterIntializeEbaCombos()} catch(err){}");
}
catch(err){
}
};
nitobi.combo.unloadAll=function(){
try{
var _bc=[];
var _bd=window.document.getElementsByTagName(nitobi.browser.MOZ?"eba:Combo":"combo");
var _be=(nitobi.browser.MOZ?window.document.getElementsByTagName("ntb:Combo"):[]);
for(var i=0;i<_be.length;i++){
_bc.push(_be[i]);
}
for(var i=0;i<_bd.length;i++){
_bc.push(_bd[i]);
}
if(_bc){
for(var i=0;i<_bc.length;i++){
if((_bc[i])&&(_bc[i].object)){
_bc[i].object.Unload();
_bc[i].object=null;
}
}
_bc=null;
}
if(nitobi.browser.IE){
if(nitobi.combo.iframeBacker){
delete nitobi.combo.iframeBacker;
nitobi.combo.iframeBacker=null;
}
}
}
catch(e){
}
};
nitobi.combo.resize=function(){
var _c0=[];
var _c1=window.document.getElementsByTagName(nitobi.browser.MOZ?"eba:Combo":"combo");
var _c2=(nitobi.browser.MOZ?window.document.getElementsByTagName("ntb:Combo"):[]);
for(var i=0;i<_c2.length;i++){
_c0.push(_c2[i]);
}
for(var i=0;i<_c1.length;i++){
_c0.push(_c1[i]);
}
for(var i=0;i<_c0.length;i++){
var _c4=_c0[i].object;
if("smartlist"!=_c4.mode){
if(_c4.GetWidth()!=null){
var _c5=_c4.GetUniqueId();
var _c6=_c4.GetTextBox();
var _c7=_c4.GetList();
var _c8=document.getElementById(_c4.GetId());
var _c9=parseInt(_c4.GetWidth());
if(nitobi.browser.MOZ&&nitobi.Browser.GetMeasurementUnitType(_c4.GetWidth())=="px"){
_c9=parseInt(_c4.GetWidth());
}
var _ca=document.getElementById("EBAComboBoxButtonImg"+_c5);
var _cb;
if(null!=_ca){
_cb=nitobi.html.getWidth(_ca);
}else{
_cb=0;
}
_c6.SetWidth((_c9-_cb)+"px");
_c7.OnWindowResized();
}
}
}
};
if(false){
nitobi.combo=function(){
};
}
nitobi.combo.Combo=function(_cc){
try{
nitobi.prepare();
var _cd="";
var _ce="GET";
this.Timer=null;
try{
this.Timer=new Timer();
}
catch(err){
this.Timer=null;
}
var _cf="You must specify an Id for the combo box";
var _d0="ntb:Combo could not correctly transform XML data. Do you have the MS XML libraries installed? These are typically installed with your browser and are freely available from Microsoft.";
this.Version="3.5";
((null==_cc.id)||(""==_cc.id))?alert(_cf):this.SetId(_cc.id);
var _d1=null;
var _d2=null;
var _d3=null;
var _d4=null;
_cc.object=this;
_cc.jsObject=this;
this.m_userTag=_cc;
var _d5=null;
this.BuildWarningList();
var _d6=this.m_userTag.getAttribute("DisabledWarningMessages");
if(!((null==_d6)||(""==_d6))){
this.SetDisabledWarningMessages(_d6);
}
var _d7=this.m_userTag.getAttribute("ErrorLevel");
((null==_d7)||(""==_d7))?this.SetErrorLevel(""):this.SetErrorLevel(_d7);
_cc.innerHTML=_cc.innerHTML.replace(/>\s+</g,"><").replace(/^\s+</,"<").replace(/>\s+$/,">");
var dtf=_cc.getAttribute("DataTextField");
var dvf=_cc.getAttribute("DataValueField");
if((null==dtf)||(""==dtf)){
dtf=dvf;
_cc.setAttribute("DataTextField",dtf);
}
this.SetDataTextField(dtf);
this.SetDataValueField(dvf);
if((null!=dtf)&&(""!=dtf)){
if((null==dvf)||(""==dvf)){
dvf=dtf;
}
this.SetDataValueField(dvf);
}
for(var i=0;i<_cc.childNodes.length;i++){
var _db=_cc.childNodes[i];
var n=_db.tagName;
if(n){
n=n.toLowerCase().replace(/^eba:/,"").replace(/^ntb:/,"");
switch(n){
case "combobutton":
_d3=_db;
break;
case "combotextbox":
_d4=_db;
break;
case "combolist":
_d2=_db;
break;
case "xmldatasource":
_d1=_db;
break;
case "combovalues":
_d5=_db;
}
}
}
var _dd="default";
var _de=this.m_userTag.getAttribute("Mode");
if(null!=_de){
_de=_de.toLowerCase();
}
switch(_de){
case "smartsearch":
case "smartlist":
case "compact":
case "filter":
case "unbound":
this.mode=_de;
break;
default:
this.mode=_dd;
}
var _df=(_d2==null?null:_d2.getAttribute("DatasourceUrl"));
if((_d5==null&&_df==null)&&this.mode!="compact"){
this.mode=_dd;
}
var _e0=25;
if(null!=_d2){
var ps=_d2.getAttribute("PageSize");
if(ps!=null&&ps!=""){
_e0=ps;
}
}
var _e2=_cc.getAttribute("InitialSearch");
this.m_InitialSearch="";
if((null==_e2)||(""==_e2)){
this.m_InitialSearch=_cd;
}else{
this.m_InitialSearch=_e2;
}
var rt=_cc.getAttribute("HttpRequestMethod");
((null==rt)||(""==rt))?this.SetHttpRequestMethod(_ce):this.SetHttpRequestMethod(rt);
this.m_NoDataIsland=_d5==null&&_df!=null&&_d1==null;
if(this.m_NoDataIsland){
var id=_cc.id+"XmlDataSource";
_d2.setAttribute("XmlId",id);
_d1=_d2;
var d=xbDOM.create();
d.async=false;
_df+=(_df.indexOf("?")==-1?"?":"&");
_df+="PageSize="+_e0;
_df+="&StartingRecordIndex=0"+"&ComboId="+encodeURI(this.GetId())+"&LastString=";
if(this.m_InitialSearch!=null&&this.m_InitialSearch!=""){
_df+="&SearchSubstring="+encodeURI(this.m_InitialSearch);
}
var _e6=nitobi.Browser.LoadPageFromUrl(_df,this.GetHttpRequestMethod());
var _e7=_e6.indexOf("<?xml");
if(_e7!=-1){
d.loadXML(_e6.substr(_e7));
}else{
d.loadXML(_e6);
}
try{
this.ShowWarning(d.xml!=""&&d.parseError==0,"cw003",d.parseError.reason);
}
catch(err){
this.ShowWarning(d.xml!="","cw003");
}
var d2=xbDOM.create();
d2.loadXML(d.xml.replace(/>\s+</g,"><"));
d2=xbClipXml(d2,"root","e",_e0);
eval("window.document."+id+"=d2;");
}
var _e9=(this.mode==_dd||this.mode=="unbound");
if(_e9){
this.SetButton(new nitobi.combo.Button(_d3,this));
}
this.SetList(new nitobi.combo.List(_d2,_d1,_d5,this));
this.SetTextBox(new nitobi.combo.TextBox(_d4,this,_e9));
this.m_Over=false;
}
catch(err){
}
};
nitobi.combo.Combo.prototype.BuildWarningList=Combo_BuildWarningList;
function Combo_BuildWarningList(){
this.m_WarningMessagesEnabled=new Array();
this.m_DisableAllWarnings=false;
this.m_WarningMessages=new Array();
this.m_WarningMessages["cw001"]="The combo tried to search the server datasource for data.  "+"The server returned data, but no match was found within this data by the combo. The most "+"likely cause for this warning is that the combo mode does not match the gethandler SQL query type: "+"the sql query is not matching in the same way the combo is. Consult the documentation to see what "+"matches to use given the combo's mode.";
this.m_WarningMessages["cw002"]="The combo tried to load XML data from the page. However, it encountered a tag attribute of the form <tag att='___'/> instead"+" of the form <tag att=\"___\"/>. A possible reason for this is encoding ' as &apos;. To fix this error correct the tag to use "+"<tag att=\"__'___\"/>. If you are manually encoding data, eg. for an unbound combo, do not encode ' as &apos; and do not use ' as your string literal. If you believe, "+"this warning was generated in error, you can disable it.";
this.m_WarningMessages["cw003"]="The combo failed to load and parse the XML sent by the gethandler. Check your gethandler to ensure that it is delivering valid XML.";
}
nitobi.combo.Combo.prototype.SetDisabledWarningMessages=Combo_SetDisabledWarningMessages;
function Combo_SetDisabledWarningMessages(_ea){
if(_ea=="*"){
this.m_DisableAllWarnings=true;
}else{
this.m_DisableAllWarnings=false;
_ea=_ea.toLowerCase();
_ea=_ea.split(",");
for(var i=0;i<_ea.length;i++){
this.m_WarningMessagesEnabled[_ea[i]]=false;
}
}
}
nitobi.combo.Combo.prototype.IsWarningEnabled=Combo_IsWarningEnabled;
function Combo_IsWarningEnabled(_ec){
if(this.m_ErrorLevel==""){
return;
}else{
if(this.m_WarningMessagesEnabled[_ec]==null){
this.m_WarningMessagesEnabled[_ec]=true;
}
return this.m_WarningMessagesEnabled[_ec]&&this.m_DisableAllWarnings==false;
}
}
nitobi.combo.Combo.prototype.ShowWarning=Combo_ShowWarning;
function Combo_ShowWarning(_ed,_ee,_ef){
if(_ed==false&&this.IsWarningEnabled(_ee)){
var s="NTB:Combo Warning "+_ee+" from "+this.GetId()+"\n\n"+this.m_WarningMessages[_ee]+"\n\nTo disable this and other warnings "+"use the Combo.DisableWarnings tag attribute, e.g., DisableWarnings='"+_ee+",cw101,cw102'";
if(_ef!=null){
s+="\n\nExtra Information\n\t"+_ef;
}
alert(s);
this.m_WarningMessagesEnabled[_ee]=false;
}
}
nitobi.combo.Combo.prototype.SetErrorLevel=Combo_SetErrorLevel;
function Combo_SetErrorLevel(_f1){
this.m_ErrorLevel=_f1.toLowerCase();
}
nitobi.combo.Combo.prototype.GetWidth=Combo_GetWidth;
function Combo_GetWidth(){
return this.m_Width;
}
nitobi.combo.Combo.prototype.SetWidth=Combo_SetWidth;
function Combo_SetWidth(_f2){
this.m_Width=_f2;
}
nitobi.combo.Combo.prototype.GetHeight=Combo_GetHeight;
function Combo_GetHeight(){
return this.m_Height;
}
nitobi.combo.Combo.prototype.SetHeight=Combo_SetHeight;
function Combo_SetHeight(_f3){
this.m_Height=_f3;
}
function _EBAMemScrub(_f4){
for(var _f5 in _f4){
if((_f5.indexOf("m_")==0)||(_f5.indexOf("$")==0)){
_f4[_f5]=null;
}
}
}
nitobi.combo.Combo.prototype.Unload=Combo_Unload;
function Combo_Unload(){
if(this.m_Callback){
delete this.m_Callback;
this.m_Callback=null;
}
if(this.m_TextBox){
this.m_TextBox.Unload();
delete this.m_TextBox;
this.m_TextBox=null;
}
if(this.m_List){
this.m_List.Unload();
delete this.m_List;
this.m_List=null;
}
if(this.m_Button){
this.m_Button.Unload();
delete m_Button;
}
var _f6=this.GetHTMLTagObject();
_EBAMemScrub(this);
_EBAMemScrub(_f6);
}
nitobi.combo.Combo.prototype.GetHttpRequestMethod=Combo_GetHttpRequestMethod;
function Combo_GetHttpRequestMethod(){
try{
return this.m_HttpRequestMethod;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetHttpRequestMethod=Combo_SetHttpRequestMethod;
function Combo_SetHttpRequestMethod(_f7){
try{
if(null==this.m_HTMLTagObject){
this.m_HttpRequestMethod=_f7;
}else{
this.m_HTMLTagObject.className=_f7;
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetCSSClassName=Combo_GetCSSClassName;
function Combo_GetCSSClassName(){
try{
return (null==this.m_HTMLTagObject?this.m_CSSClassName:this.m_HTMLTagObject.className);
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetCSSClassName=Combo_SetCSSClassName;
function Combo_SetCSSClassName(_f8){
try{
if(null==this.m_HTMLTagObject){
this.m_CSSClassName=_f8;
}else{
this.m_HTMLTagObject.className=_f8;
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetInitialSearch=Combo_GetInitialSearch;
function Combo_GetInitialSearch(){
return this.m_InitialSearch;
}
nitobi.combo.Combo.prototype.SetInitialSearch=Combo_SetInitialSearch;
function Combo_SetInitialSearch(_f9){
this.m_InitialSearch=_f9;
}
nitobi.combo.Combo.prototype.GetListZIndex=Combo_GetListZIndex;
function Combo_GetListZIndex(){
return this.m_ListZIndex;
}
nitobi.combo.Combo.prototype.SetListZIndex=Combo_SetListZIndex;
function Combo_SetListZIndex(_fa){
this.m_ListZIndex=_fa;
}
nitobi.combo.Combo.prototype.GetMode=Combo_GetMode;
function Combo_GetMode(){
return this.mode;
}
nitobi.combo.Combo.prototype.GetOnBlurEvent=Combo_GetOnBlurEvent;
function Combo_GetOnBlurEvent(){
try{
return this.m_OnBlurEvent;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnBlurEvent=Combo_SetOnBlurEvent;
function Combo_SetOnBlurEvent(_fb){
try{
this.m_OnBlurEvent=_fb;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.OnBlurEvent=Combo_OnBlurEvent;
function Combo_OnBlurEvent(){
try{
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetFocus=Combo_SetFocus;
function Combo_SetFocus(){
this.GetTextBox().m_HTMLTagObject.focus();
}
nitobi.combo.Combo.prototype.GetOnFocusEvent=Combo_GetOnFocusEvent;
function Combo_GetOnFocusEvent(){
try{
return this.m_OnFocusEvent;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnFocusEvent=Combo_SetOnFocusEvent;
function Combo_SetOnFocusEvent(_fc){
try{
this.m_OnFocusEvent=_fc;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetOnLoadEvent=Combo_GetOnLoadEvent;
function Combo_GetOnLoadEvent(){
if("void"==this.m_OnLoadEvent){
return "";
}
return this.m_OnLoadEvent;
}
nitobi.combo.Combo.prototype.SetOnLoadEvent=Combo_SetOnLoadEvent;
function Combo_SetOnLoadEvent(_fd){
this.m_OnLoadEvent=_fd;
}
nitobi.combo.Combo.prototype.GetOnSelectEvent=Combo_GetOnSelectEvent;
function Combo_GetOnSelectEvent(){
try{
if("void"==this.m_OnSelectEvent){
return "";
}
return this.m_OnSelectEvent;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnSelectEvent=Combo_SetOnSelectEvent;
function Combo_SetOnSelectEvent(_fe){
try{
this.m_OnSelectEvent=_fe;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetOnBeforeSelectEvent=Combo_GetOnBeforeSelectEvent;
function Combo_GetOnBeforeSelectEvent(){
try{
if("void"==this.m_OnBeforeSelectEvent){
return "";
}
return this.m_OnBeforeSelectEvent;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnBeforeSelectEvent=Combo_SetOnBeforeSelectEvent;
function Combo_SetOnBeforeSelectEvent(_ff){
try{
this.m_OnBeforeSelectEvent=_ff;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetHTMLTagObject=Combo_GetHTMLTagObject;
function Combo_GetHTMLTagObject(){
try{
return this.m_HTMLTagObject;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetHTMLTagObject=Combo_SetHTMLTagObject;
function Combo_SetHTMLTagObject(_100){
try{
this.m_HTMLTagObject=_100;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetUniqueId=Combo_GetUniqueId;
function Combo_GetUniqueId(){
try{
return this.m_UniqueId;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetUniqueId=Combo_SetUniqueId;
function Combo_SetUniqueId(_101){
try{
this.m_UniqueId=_101;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetId=Combo_GetId;
function Combo_GetId(){
try{
return this.m_Id;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetId=Combo_SetId;
function Combo_SetId(Id){
try{
this.m_Id=Id;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetButton=Combo_GetButton;
function Combo_GetButton(){
try{
return this.m_Button;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetButton=Combo_SetButton;
function Combo_SetButton(_103){
try{
this.m_Button=_103;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetList=Combo_GetList;
function Combo_GetList(){
try{
return this.m_List;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetList=Combo_SetList;
function Combo_SetList(List){
try{
this.m_List=List;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetTextBox=Combo_GetTextBox;
function Combo_GetTextBox(){
try{
return this.m_TextBox;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetTextBox=Combo_SetTextBox;
function Combo_SetTextBox(_105){
try{
this.m_TextBox=_105;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetDebug=Combo_GetDebug;
function Combo_GetDebug(){
try{
return this.m_Debug;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetDebug=Combo_SetDebug;
function Combo_SetDebug(_106){
try{
this.m_Debug=_106;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetTextValue=Combo_GetTextValue;
function Combo_GetTextValue(){
try{
return this.GetTextBox().GetValue();
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetTextValue=Combo_SetTextValue;
function Combo_SetTextValue(_107){
try{
this.GetTextBox().SetValue(_107);
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetSelectedRowValues=Combo_GetSelectedRowValues;
function Combo_GetSelectedRowValues(){
try{
return this.GetList().GetSelectedRowValues();
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetSelectedRowValues=Combo_SetSelectedRowValues;
function Combo_SetSelectedRowValues(_108){
try{
this.GetList().SetSelectedRowValues(_108);
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetSelectedRowIndex=Combo_GetSelectedRowIndex;
function Combo_GetSelectedRowIndex(){
try{
return this.GetList().GetSelectedRowIndex();
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetSelectedRowIndex=Combo_SetSelectedRowIndex;
function Combo_SetSelectedRowIndex(_109){
try{
this.GetList().SetSelectedRowIndex(_109);
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetDataTextField=Combo_GetDataTextField;
function Combo_GetDataTextField(){
try{
return this.m_DataTextField;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetDataTextField=Combo_SetDataTextField;
function Combo_SetDataTextField(_10a){
try{
this.m_DataTextField=_10a;
var _10b=window.document.getElementById(this.GetId()+"DataTextFieldIndex");
if(null!=_10b){
var _10c=this.GetList().GetXmlDataSource().GetColumnIndex(_10a);
_10b.value=_10c;
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetDataValueField=Combo_GetDataValueField;
function Combo_GetDataValueField(){
try{
return this.m_DataValueField;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetDataValueField=Combo_SetDataValueField;
function Combo_SetDataValueField(_10d){
try{
this.m_DataValueField=_10d;
var _10e=window.document.getElementById(this.GetId()+"DataValueFieldIndex");
if(null!=_10e){
var _10f=this.GetList().GetXmlDataSource().GetColumnIndex(_10d);
_10e.value=_10f;
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetSelectedItem=Combo_GetSelectedItem;
function Combo_GetSelectedItem(){
try{
var _110=new Object;
_110.Value=null;
_110.Text=null;
var _111=this.GetList().GetSelectedRowIndex();
if(-1!=_111){
var _112=this.GetList().GetXmlDataSource();
var row=_112.GetRow(_111);
var _114=_112.GetColumnIndex(this.GetDataValueField());
if(-1!=_114){
_110.Value=row[_114];
}
_114=_112.GetColumnIndex(this.GetDataTextField());
if(-1!=_114){
_110.Text=row[_114];
}
}
return _110;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetOnHideEvent=Combo_GetOnHideEvent;
function Combo_GetOnHideEvent(){
try{
return this.GetList().GetOnHideEvent();
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnHideEvent=Combo_SetOnHideEvent;
function Combo_SetOnHideEvent(_115){
try{
this.GetList().SetOnHideEvent(_115);
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetOnTabEvent=Combo_GetOnTabEvent;
function Combo_GetOnTabEvent(){
try{
return this.m_OnTabEvent;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetOnTabEvent=Combo_SetOnTabEvent;
function Combo_SetOnTabEvent(_116){
try{
this.m_OnTabEvent=_116;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetEventObject=Combo_GetEventObject;
function Combo_GetEventObject(){
try{
return this.m_EventObject;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetEventObject=Combo_SetEventObject;
function Combo_SetEventObject(_117){
try{
this.m_EventObject=_117;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetSmartListSeparator=Combo_GetSmartListSeparator;
function Combo_GetSmartListSeparator(){
return this.SmartListSeparator;
}
nitobi.combo.Combo.prototype.SetSmartListSeparator=Combo_SetSmartListSeparator;
function Combo_SetSmartListSeparator(_118){
this.SmartListSeparator=_118;
}
nitobi.combo.Combo.prototype.GetTabIndex=Combo_GetTabIndex;
function Combo_GetTabIndex(){
try{
return this.m_TabIndex;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetTabIndex=Combo_SetTabIndex;
function Combo_SetTabIndex(_119){
try{
this.m_TabIndex=_119;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.GetEnabled=Combo_GetEnabled;
function Combo_GetEnabled(){
try{
return this.m_Enabled;
}
catch(err){
}
}
nitobi.combo.Combo.prototype.SetEnabled=Combo_SetEnabled;
function Combo_SetEnabled(_11a){
try{
this.m_Enabled=_11a;
var t=this.GetTextBox();
if(null!=t.GetHTMLTagObject()){
if(_11a){
t.Enable();
}else{
t.Disable();
}
}
var b=this.GetButton();
if(null!=b&&null!=b.m_Img){
if(_11a){
b.Enable();
}else{
b.Disable();
}
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.Initialize=Combo_Initialize;
function Combo_Initialize(){
try{
var _11d="ComboBox";
var _11e="outlook";
var _11f="";
var _120="";
var _121="";
var _122="";
var _123="";
var _124="";
var _125="0";
var _126=true;
var _127="default";
var _128=1000;
var _129=",";
var _12a="";
var _12b="";
var _12c=this.m_userTag.getAttribute("ListZIndex");
((null==_12c)||(""==_12c))?this.SetListZIndex(_128):this.SetListZIndex(_12c);
this.SetWidth(this.m_userTag.getAttribute("Width"));
this.SetHeight(this.m_userTag.getAttribute("Height"));
this.theme=this.m_userTag.getAttribute("theme");
if((this.theme==null)||(""==this.theme)){
this.theme=_11e;
}
var sls=this.m_userTag.getAttribute("SmartListSeparator");
((null==sls)||(""==sls))?this.SetSmartListSeparator(_129):this.SetSmartListSeparator(sls);
var _12e=this.m_userTag.getAttribute("Enabled");
((null==_12e)||(""==_12e))?this.SetEnabled(_126):this.SetEnabled("true"==_12e.toLowerCase());
var _12f=this.m_userTag.getAttribute("TabIndex");
((null==_12f)||(""==_12f))?this.SetTabIndex(_125):this.SetTabIndex(_12f);
var _130=this.m_userTag.getAttribute("OnTabEvent");
((null==_130)||(""==_130))?this.SetOnTabEvent(_124):this.SetOnTabEvent(_130);
this.SetEventObject(null);
var _131=this.m_userTag.getAttribute("OnFocusEvent");
((null==_131)||(""==_131))?this.SetOnFocusEvent(_123):this.SetOnFocusEvent(_131);
var _132=this.m_userTag.getAttribute("OnBlurEvent");
((null==_132)||(""==_132))?this.SetOnBlurEvent(_122):this.SetOnBlurEvent(_132);
var ose=this.m_userTag.getAttribute("OnSelectEvent");
((null==ose)||(""==ose))?this.SetOnSelectEvent(_11f):this.SetOnSelectEvent(ose);
var ole=this.m_userTag.getAttribute("OnLoadEvent");
((null==ole)||(""==ole))?this.SetOnLoadEvent(_120):this.SetOnLoadEvent(ole);
var obse=this.m_userTag.getAttribute("OnBeforeSelectEvent");
((null==obse)||(""==obse))?this.SetOnBeforeSelectEvent(_121):this.SetOnBeforeSelectEvent(obse);
var css=this.m_userTag.getAttribute("CSSClassName");
((null==css)||(""==css))?this.SetCSSClassName(_11d):this.SetCSSClassName(css);
var _137=this.m_userTag.uniqueID;
this.SetUniqueId(_137);
if(this.GetWidth()!=null){
if("smartlist"==this.mode){
this.m_TextBox.SetWidth(this.GetWidth());
this.m_TextBox.SetHeight(this.GetHeight());
}
if(nitobi.Browser.GetMeasurementUnitType(this.GetWidth())=="%"){
this.m_userTag.style.display="block";
}else{
this.m_userTag.style.display="inline";
}
if("smartlist"==this.mode){
this.m_userTag.style.height=this.GetHeight();
}else{
this.m_userTag.style.overflow="hidden";
}
}
var html="<span id='EBAComboBox"+_137+"' class=' ntb "+this.GetCSSClassName()+"' "+"onMouseOver='window.document.getElementById(\""+this.GetId()+"\").object.m_Over=true' "+"onMouseOut='window.document.getElementById(\""+this.GetId()+"\").object.m_Over=false'>"+"<span id='EBAComboBoxTextAndButton"+_137+"' class='ComboBoxTextAndButton'><nobr>";
var id="";
var _13a=this.GetId();
for(var i=0,n=this.GetList().GetXmlDataSource().GetNumberColumns();i<n;i++){
id=_13a+"SelectedValue"+i;
html+="<input type='HIDDEN' id='"+id+"' name='"+id+"'></input>";
}
id=_13a+"SelectedRowIndex";
html+="<input type='HIDDEN' id='"+id+"' name='"+id+"' value='"+this.GetSelectedRowIndex()+"'></input>";
var _13d=this.GetDataTextField();
id=_13a+"DataTextFieldIndex";
var _13e=this.GetList().m_XmlDataSource.GetColumnIndex(_13d);
html+="<input type='HIDDEN' id='"+id+"' name='"+id+"' value='"+_13e+"'></input>";
id=_13a+"DataValueFieldIndex";
var _13f=this.GetDataValueField();
_13e=this.GetList().m_XmlDataSource.GetColumnIndex(_13f);
html+="<input type='HIDDEN' id='"+id+"' name='"+id+"' value='"+_13e+"'></input>";
html+="<div class=\" ntb-combo-reset "+this.theme+"\">";
html+=this.GetTextBox().GetHTMLRenderString();
var _140=(this.mode=="default"||this.mode=="unbound");
if(_140){
html+=this.GetButton().GetHTMLRenderString();
}
html+="<div style=\"overflow: hidden; display: block; clear: both; float: none; height: 0px; width: auto;\"><!-- --></div>";
html+="</div></div>";
html+="</nobr></span></span>";
this.m_userTag.insertAdjacentHTML("beforeEnd",html);
this.SetHTMLTagObject(window.document.getElementById("EBAComboBox"+_137));
this.GetTextBox().Initialize();
if(_140){
this.GetButton().Initialize();
}
var is=this.m_InitialSearch;
if(null!=is&&""!=is){
this.InitialSearch(is);
}
eval(this.GetOnLoadEvent());
this.m_userTag=null;
nitobi.combo.numCombosToLoad--;
if(nitobi.combo.numCombosToLoad==0){
nitobi.combo.finishInit();
}
}
catch(err){
}
}
nitobi.combo.Combo.prototype.InitialSearch=Combo_InitialSearch;
function Combo_InitialSearch(_142){
try{
var list=this.GetList();
var tb=this.GetTextBox();
var dfi=tb.GetDataFieldIndex();
list.SetDatabaseSearchTimeoutStatus(EBADatabaseSearchTimeoutStatus_EXPIRED);
list.InitialSearchOnce=true;
this.m_Callback=_EbaComboCallback;
list.Search(_142,dfi,this.m_Callback,this.m_NoDataIsland);
}
catch(err){
}
}
function _EbaComboCallback(_146,list){
if(_146>=0){
var tb=list.GetCombo().GetTextBox();
var row=list.GetRow(_146);
list.SetActiveRow(row);
list.SetSelectedRow(_146);
tb.SetValue(list.GetSelectedRowValues()[tb.GetDataFieldIndex()]);
list.scrollOnce=true;
list.InitialSearchOnce=false;
}else{
var _14a=list.GetCombo();
_14a.SetTextValue(_14a.GetInitialSearch());
}
}
nitobi.combo.Combo.prototype.GetFieldFromActiveRow=Combo_GetFieldFromActiveRow;
function Combo_GetFieldFromActiveRow(_14b){
try{
var l=this.GetList();
if(null!=l){
var r=l.GetActiveRow();
if(null!=r){
var y=l.GetRowIndex(r);
var d=l.GetXmlDataSource();
var x=d.GetColumnIndex(_14b);
return d.GetRowCol(y,x);
}
}
return null;
}
catch(err){
}
}
function Debug(){
this.m_CallStack=new Array;
this.m_CallStackMarker=0;
try{
_ebaWatch.value="";
}
catch(err){
}
}
Debug.prototype.GetCallStack=Debug_GetCallStack;
function Debug_GetCallStack(){
return this.m_CallStack;
}
Debug.prototype.SetCallStack=Debug_SetCallStack;
function Debug_SetCallStack(_151){
this.m_CallStack=_151;
}
Debug.prototype.GetCurrentFunction=Debug_GetCurrentFunction;
function Debug_GetCurrentFunction(){
return this.m_CallStack[this.m_CallStackMarker-1];
}
Debug.prototype.GetState=Debug_GetState;
function Debug_GetState(){
return this.m_State;
}
Debug.prototype.SetState=Debug_SetState;
function Debug_SetState(_152){
this.m_State=_152;
}
Debug.prototype.Assert=Debug_Assert;
function Debug_Assert(_153,_154){
if(this.GetState()&&!_153){
alert("Assert ("+this.GetCurrentFunction()+"): "+_154+"\nStack trace: \n"+this.ShowCallStack());
}
}
Debug.prototype.EnterFunction=Debug_EnterFunction;
function Debug_EnterFunction(_155){
this.m_CallStack[this.m_CallStackMarker++]=_155;
}
Debug.prototype.ExitFunction=Debug_ExitFunction;
function Debug_ExitFunction(){
this.m_CallStack[--this.m_CallStackMarker];
}
Debug.prototype.ShowCallStack=Debug_ShowCallStack;
function Debug_ShowCallStack(){
var s="";
var tabs="\t";
for(var i=0;i<this.m_CallStackMarker;i++){
s+=tabs+this.m_CallStack[i]+"\n";
tabs+="\t";
}
return s;
}
Debug.prototype.SetWatch=Debug_SetWatch;
function Debug_SetWatch(_159,_15a){
this.EnterFunction("SetWatch");
try{
_ebaWatch.value=_159+" = "+_15a+"\n"+_ebaWatch.value;
this.ExitFunction();
}
catch(err){
this.ExitFunction();
}
}
Debug.prototype.Echo=Debug_Echo;
function Debug_Echo(Msg){
this.EnterFunction("Echo");
try{
_ebaWatch.value="**"+Msg+"\n"+_ebaWatch.value;
this.ExitFunction();
}
catch(err){
this.ExitFunction();
}
}
Debug.prototype.StartTimer=Debug_StartTimer;
function Debug_StartTimer(_15c,_15d){
try{
_15c.Start(_15d);
}
catch(err){
}
}
Debug.prototype.StopTimer=Debug_StopTimer;
function Debug_StopTimer(_15e,_15f){
try{
_15e.Stop(_15f);
}
catch(err){
}
}
Debug.prototype.ShowTimer=Debug_ShowTimer;
function Debug_ShowTimer(_160,_161,_162){
try{
}
catch(err){
}
}
Debug.prototype.WriteLog=Debug_WriteLog;
function Debug_WriteLog(_163){
try{
writeLog(_163);
}
catch(err){
}
}
Debug.prototype.StopAndShowTimer=Debug_StopAndShowTimer;
function Debug_StopAndShowTimer(_164,_165,_166){
try{
this.StopTimer(_165,_166);
this.ShowTimer(_164,_165,_166);
}
catch(err){
}
}
Debug.printGlobals=function(){
for(var o in window){
writeLog(o);
}
};
function Iframe(_168,h,w,_16b){
if(!_168){
var msg="Iframe constructor: attachee is null!";
alert(msg);
throw msg;
}
var d=window.document;
var oIF=d.createElement("IFRAME");
var s=oIF.style;
this.oIFStyle=s;
this.attachee=_168;
this.attach();
s.position="absolute";
w=w||_168.offsetWidth;
s.width=w;
s.height=h||0;
s.display="none";
s.overflow="hidden";
var name="IFRAME"+oIF.uniqueID;
oIF.name=name;
oIF.id=name;
oIF.frameBorder=0;
oIF.src="javascript:true";
var _171=Browser_GetParentElementByTagName(_16b,"form");
if(null==_171){
_171=d.body;
}
_171.appendChild(oIF);
var oF=window.frames[name];
var oD=oF.window.document;
oD.open();
oD.write("<html><head></head><body style=\"margin:0;background-color:white;\"><span id=\"bodySpan\" class=\"ntb-combobox-list-outer-border\" style=\"overflow:hidden;float:left;border-width:1px;border-style:solid;width:"+(w-(nitobi.browser.MOZ?2:0))+";height:"+(h-(nitobi.browser.MOZ?2:0))+";\"></span></body></html>");
oD.close();
var dss=d.styleSheets;
var ss=oD.createElement("LINK");
for(var i=0,n=dss.length;i<n;i++){
var ss2=ss.cloneNode(true);
ss2.rel=(nitobi.browser.IE?dss[i].owningElement.rel:dss[i].ownerNode.rel);
ss2.type="text/css";
ss2.href=dss[i].href;
ss2.title=dss[i].title;
oD.body.appendChild(ss2);
}
var head=oD.getElementsByTagName("head")[0];
var ds=(d.scripts?d.scripts:d.getElementsByTagName("script"));
var st=oD.createElement("SCRIPT");
var src=null;
for(var i=0,n=ds.length;i<n;i++){
src=ds[i].src;
if(""!=src){
var st2=st.cloneNode(true);
st2.language=ds[i].language;
st2.src=src;
head.appendChild(st2);
}
}
this.oIF=oIF;
this.oF=oF;
this.d=oD;
this.bodySpan=oD.getElementById("bodySpan");
this.bodySpanStyle=this.bodySpan.style;
if(window.addEventListener){
window.addEventListener("resize",this,false);
}else{
if(window.attachEvent){
if(!window.g_Iframe_oIFs){
window.g_Iframe_oIFs=new Array;
window.g_Iframe_onresize=window.onresize;
Iframe_oResize();
window.onresize=window.oResize.check1;
}
window.g_Iframe_oIFs[name]=this;
}
}
}
Iframe.prototype.Unload=Iframe_Unload;
function Iframe_Unload(){
if(this.oIF){
delete this.oIF;
}
}
var g_Iframe_oIFs=null;
var g_Iframe_onresize=null;
function Iframe_onafterresize(){
for(var f in window.g_Iframe_oIFs){
var oIF=window.g_Iframe_oIFs[f];
oIF.attach();
}
if(window.g_Iframe_onresize){
window.g_Iframe_onresize();
}
}
function Iframe_dfxWinXY(w){
var b,d,x,y;
x=y=0;
var d=window.document;
if(d.body){
b=d.documentElement.clientWidth?d.documentElement:d.body;
x=b.clientWidth||0;
y=b.clientHeight||0;
}
return {x:x,y:y};
}
function Iframe_oResize(){
window.oResize={CHECKTIME:500,oldXY:Iframe_dfxWinXY(window),timerId:0,check1:function(){
window.oResize.check2();
},check2:function(){
if(this.timerId){
window.clearTimeout(this.timerId);
}
this.timerId=setTimeout("window.oResize.check3()",this.CHECKTIME);
},check3:function(){
var _185=Iframe_dfxWinXY(window);
this.timerId=0;
if((_185.x!=this.oldXY.x)||(_185.y!=this.oldXY.y)){
this.oldXY=_185;
Iframe_onafterresize();
}
}};
}
Iframe.prototype.handleEvent=Iframe_handleEvent;
function Iframe_handleEvent(evt){
switch(evt.type){
case "resize":
if(this.isVisible()){
this.attach();
}
break;
}
}
Iframe.prototype.offset=Iframe_offset;
function Iframe_offset(o,attr,a){
var x=(a?o[attr]:0);
var _o=o;
while(o){
x+=(a?0:o[attr]);
if(nitobi.browser.IE&&"TABLE"==o.tagName&&"0"!=o.border&&""!=o.border){
x++;
}
o=o.offsetParent;
}
return x;
}
Iframe.prototype.setHeight=Iframe_setHeight;
function Iframe_setHeight(h,_18d){
h=parseInt(h);
this.oIFStyle.height=h;
if(_18d!=true){
this.bodySpanStyle.height=(h-(nitobi.browser.MOZ?parseInt(this.bodySpanStyle.borderTopWidth)+parseInt(this.bodySpanStyle.borderBottomWidth):0));
}
}
Iframe.prototype.setWidth=Iframe_setWidth;
function Iframe_setWidth(w){
w=parseInt(w);
this.oIFStyle.width=w;
this.bodySpanStyle.width=(w-(nitobi.browser.MOZ?parseInt(this.bodySpanStyle.borderLeftWidth)+parseInt(this.bodySpanStyle.borderRightWidth):0));
}
Iframe.prototype.show=Iframe_show;
function Iframe_show(){
this.attach();
this.oIFStyle.display="inline";
}
Iframe.prototype.hide=Iframe_hide;
function Iframe_hide(){
this.oIFStyle.display="none";
}
Iframe.prototype.toggle=Iframe_toggle;
function Iframe_toggle(){
if(this.isVisible()){
this.hide();
}else{
this.show();
}
}
Iframe.prototype.isVisible=Iframe_isVisible;
function Iframe_isVisible(){
return "inline"==this.oIFStyle.display;
}
Iframe.prototype.attach=Iframe_attach;
function Iframe_attach(){
var _18f=this.attachee;
var a=(_18f.offsetParent&&"absolute"==_18f.offsetParent.style.position);
this.oIFStyle.top=this.offset(_18f,"offsetTop",a)+_18f.offsetHeight-1+(a?parseInt(_18f.offsetParent.style.top):0);
this.oIFStyle.left=this.offset(_18f,"offsetLeft",a)+(a?parseInt(_18f.offsetParent.style.left):0);
}
var EbaComboUiServerError=0;
var EbaComboUiNoRecords=1;
var EbaComboUiEndOfRecords=2;
var EbaComboUiNumRecords=3;
var EbaComboUiPleaseWait=4;
nitobi.combo.createLanguagePack=function(){
try{
if(typeof (EbaComboUi)=="undefined"){
EbaComboUi=new Array();
EbaComboUi[EbaComboUiServerError]="ERROR: Favor intente de nuevo";
EbaComboUi[EbaComboUiNoRecords]="No hay localidades.";
EbaComboUi[EbaComboUiEndOfRecords]="Fin de localidades.";
EbaComboUi[EbaComboUiNumRecords]=" localidades.";
EbaComboUi[EbaComboUiPleaseWait]="Favor espere...";
}
}
catch(err){
alert("The default language pack could not be loaded.  "+err.message);
}
};
nitobi.lang.defineNs("nitobi.combo");
EBAComboBoxListHeader=0;
EBAComboBoxListBody=1;
EBAComboBoxListFooter=2;
EBAComboBoxListBodyTable=3;
EBAComboBoxListNumSections=4;
EBAComboBoxList=5;
EBADatabaseSearchTimeoutStatus_WAIT=0;
EBADatabaseSearchTimeoutStatus_EXPIRED=1;
EBADatabaseSearchTimeoutStatus_NONE=2;
EBADatabaseSearchTimeoutWait=200;
EBAMoveAction_UP=0;
EBAMoveAction_DOWN=1;
EBAScrollToNone=0;
EBAScrollToTop=1;
EBAScrollToBottom=2;
EBAScrollToNewTop=3;
EBAScrollToTypeAhead=4;
EBAScrollToNewBottom=5;
EBAComboSearchNoRecords=0;
EBAComboSearchNewRecords=1;
EBADefaultScrollbarSize=18;
nitobi.combo.List=function(_191,_192,_193,_194){
try{
this.m_Rendered=false;
var _195="ntb-combobox-button";
var _196="150px";
var _197=new Array("50px","100px","50px");
var _198=new Array("ntb-combobox-list-header","ntb-combobox-list-body","ntb-combobox-list-footer","ntb-combobox-list-body-table");
var _199="ntb-combobox-list-body-table-row-highlighted";
var _19a="highlight";
var _19b="highlighttext";
var _19c="";
var _19d=-1;
var _19e=_194.mode=="default";
var _19f="hidden";
var _1a0=false;
var _1a1=_194.mode!="default";
var _1a2;
if(_194.mode!="classic"){
_1a2=10;
}else{
_1a2=25;
}
var _1a3="";
var _1a4="";
var _1a5="";
var _1a6="";
var _1a7=0;
var _1a8=0;
var _1a9="EBA:Combo could not correctly transform XML data. Do you have the MS XML libraries installed? These are typically installed with your browser and are freely available from Microsoft.";
var _1aa="<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0' xmlns:eba='http://developer.ebusiness-apps.com' xmlns:ntb='http://www.nitobi.com' exclude-result-prefixes='eba ntb'>"+"<xsl:output method='xml' version='4.0' omit-xml-declaration='yes' />"+"<xsl:template match='/'>"+"<xsl:apply-templates select='eba:ComboValues|ntb:ComboValues'/>"+"</xsl:template>"+"<xsl:template match='/eba:ComboValues|ntb:ComboValues'>"+"<root>"+"<xsl:attribute name='fields'><xsl:value-of select='@fields' /></xsl:attribute>"+"\t<xsl:apply-templates/>"+"</root>"+"</xsl:template>"+"<xsl:template match='eba:ComboValue|eba:combovalue|ntb:ComboValue|ntb:combovalue'>"+"\t<e><xsl:for-each select='@*'><xsl:attribute name='{name()}'><xsl:value-of select=\".\"/></xsl:attribute></xsl:for-each></e>"+"</xsl:template>"+"</xsl:stylesheet>";
this.SetCombo(_194);
var ps=(_191?_191.getAttribute("PageSize"):null);
((null==ps)||(""==ps))?this.SetPageSize(_1a2):this.SetPageSize(parseInt(ps));
this.clip=(_194.mode=="smartsearch"||_194.mode=="smartlist"||_194.mode=="filter");
var _1ac=(_191?_191.getAttribute("ClipLength"):null);
((null==_1ac)||(""==_1ac))?this.SetClipLength(this.GetPageSize()):this.SetClipLength(_1ac);
this.SetXmlDataSource(new nitobi.combo.XmlDataSource(_192,this.clip,this.clipLength,_194));
this.m_httpRequest=xbXMLHTTP.create();
this.unboundMode=false;
if(!_192){
this.unboundMode=true;
var _1ad=null;
var _1ae="<eba:ComboValues fields='"+_193.getAttribute("fields")+"' xmlns:eba='http://developer.ebusiness-apps.com' xmlns:ntb='http://www.nitobi.com'>";
if(nitobi.browser.IE){
var _1af=_193.innerHTML.match(/<\?xml:namespace.*?\/>(.*)/);
_1ae+=_1af[1]+"</eba:ComboValues>";
}else{
_1ae+=_193.innerHTML+"</eba:ComboValues>";
}
_1ae=nitobi.Browser.EncodeAngleBracketsInTagAttributes(_1ae,_194).replace(/&nbsp;/g,"&#160;").replace(/>\s+</g,"><");
try{
var oXSL=xbDOM.create();
oXSL.loadXML(_1aa);
tmp=xbDOM.create();
tmp.loadXML(_1ae);
xmlObject=xbDOM.create();
tmp.transformNodeToObject(oXSL,xmlObject);
this.GetXmlDataSource().SetXmlObject(xmlObject);
this.GetXmlDataSource().m_Dirty=false;
}
catch(err){
alert(_1a9);
}
}
this.m_SectionHTMLTagObjects=new Array;
this.m_SectionCSSClassNames=new Array;
this.m_SectionHeights=new Array;
this.m_ListColumnDefinitions=new Array;
var _1b1=null;
var _1b2=0;
var _1b3=null;
var _1b4=this.GetCombo().GetDataTextField();
var _1b5=false;
var _1b6=true;
while(_1b6){
if(_1b4!=null||_1b5==true){
var _1b7=new Object;
_1b7.DataFieldIndex=this.GetXmlDataSource().GetColumnIndex(_1b4);
_1b7.DataValueIndex=this.GetXmlDataSource().GetColumnIndex(_194.GetDataValueField());
_1b7.HeaderLabel="";
_1b7.Width="100%";
this.m_ListColumnDefinitions[0]=new nitobi.combo.ListColumnDefinition(_1b7);
_1b6=false;
}else{
var _1b8=_191;
if((null==_191)||(0==_191.childNodes.length)){
_1b8=_194.m_userTag;
}
var _1b9=null;
for(var i=0;i<_1b8.childNodes.length;i++){
_1b1=_1b8.childNodes[i];
_1b9=_1b1.tagName;
if(_1b9){
_1b9=_1b9.toLowerCase().replace(/^eba:/,"").replace(/^ntb:/,"");
if(_1b9=="combocolumndefinition"){
this.m_ListColumnDefinitions[_1b2]=new nitobi.combo.ListColumnDefinition(_1b1);
_1b2++;
_1b6=false;
}
}
}
_1b5=true;
}
}
var _1bb=(_191?_191.getAttribute("Width"):null);
((null==_1bb)||(""==_1bb))?this.SetWidth(_196):this.SetWidth(_1bb);
var _1bc=(_191?_191.getAttribute("Overflow-y"):null);
this.m_overflowy=((null==_1bc)||(""==_1bc))?_19f:_1bc;
var chh=(_191?_191.getAttribute("CustomHTMLHeader"):null);
((null==chh)||(""==chh))?this.SetCustomHTMLHeader(""):this.SetCustomHTMLHeader(chh);
for(var i=0;i<EBAComboBoxListNumSections;i++){
this.SetSectionCSSClassName(i,_198[i]);
}
for(var i=0;i<=EBAComboBoxListFooter;i++){
this.SetSectionHeight(i,_197[i]);
}
var _1be=(_191?_191.getAttribute("Height"):null);
((null==_1be)||(""==_1be))?null:this.SetHeight(parseInt(_1be));
var hccn=(_191?_191.getAttribute("HighlightCSSClassName"):null);
if((null==hccn)||(""==hccn)){
this.SetHighlightCSSClassName(_199);
this.m_UseHighlightClass=false;
}else{
this.SetHighlightCSSClassName(hccn);
this.m_UseHighlightClass=true;
}
var bhc=(_191?_191.getAttribute("BackgroundHighlightColor"):null);
((null==bhc)||(""==bhc))?this.SetBackgroundHighlightColor(_19a):this.SetBackgroundHighlightColor(bhc);
var ohe=(_191?_191.getAttribute("OnHideEvent"):null);
((null==ohe)||(""==ohe))?this.SetOnHideEvent(_1a3):this.SetOnHideEvent(ohe);
var ose=(_191?_191.getAttribute("OnShowEvent"):null);
((null==ose)||(""==ose))?this.SetOnShowEvent(_1a4):this.SetOnShowEvent(ose);
var onbs=(_191?_191.getAttribute("OnBeforeSearchEvent"):null);
((null==onbs)||(""==onbs))?this.SetOnBeforeSearchEvent(_1a5):this.SetOnBeforeSearchEvent(onbs);
var onas=(_191?_191.getAttribute("OnAfterSearchEvent"):null);
((null==onas)||(""==onas))?this.SetOnAfterSearchEvent(_1a6):this.SetOnAfterSearchEvent(onas);
var fhc=(_191?_191.getAttribute("ForegroundHighlightColor"):null);
((null==fhc)||(""==fhc))?this.SetForegroundHighlightColor(_19b):this.SetForegroundHighlightColor(fhc);
var offx=(_191?_191.getAttribute("OffsetX"):null);
((null==offx)||(""==offx))?this.SetOffsetX(_1a7):this.SetOffsetX(offx);
var offy=(_191?_191.getAttribute("OffsetY"):null);
((null==offy)||(""==offy))?this.SetOffsetY(_1a8):this.SetOffsetY(offy);
var sri=(_191?_191.parentNode.getAttribute("SelectedRowIndex"):null);
((null==sri)||(""==sri))?this.SetSelectedRowIndex(_19d):this.SetSelectedRowIndex(parseInt(sri));
var chd=(_191?_191.getAttribute("CustomHTMLDefinition"):null);
((null==chd)||(""==chd))?this.SetCustomHTMLDefinition(_19c):this.SetCustomHTMLDefinition(chd);
var ap=(_191?_191.getAttribute("AllowPaging"):null);
((null==ap)||(""==ap))?this.SetAllowPaging(_19e):this.SetAllowPaging(ap.toLowerCase()=="true");
var fz=(_191?_191.getAttribute("FuzzySearchEnabled"):null);
((null==fz)||(""==fz))?this.SetFuzzySearchEnabled(_1a0):this.SetFuzzySearchEnabled(fz.toLowerCase()=="true");
var eds=(_191?_191.getAttribute("EnableDatabaseSearch"):null);
((null==eds)||(""==eds))?this.SetEnableDatabaseSearch(this.unboundMode==false&&_1a1):this.SetEnableDatabaseSearch(this.unboundMode==false&&eds.toLowerCase()=="true");
if(_194.mode=="default"&&this.GetAllowPaging()==true){
this.SetClipLength(this.GetPageSize());
this.clip=true;
}
this.widestColumn=new Array(this.m_ListColumnDefinitions.length);
for(var i=0;i<this.widestColumn.length;i++){
this.widestColumn[i]=0;
}
this.SetDatabaseSearchTimeoutStatus(EBADatabaseSearchTimeoutStatus_NONE);
var durl=(_191?_191.getAttribute("DatasourceUrl"):null);
if((null==durl)||(""==durl)||this.unboundMode==true){
this.SetDatasourceUrl(window.document.location.toString());
this.SetEnableDatabaseSearch(false);
this.unboundMode=true;
}else{
this.SetDatasourceUrl(durl);
this.SetEnableDatabaseSearch(true);
}
this.m_httpRequestReady=true;
this.SetNumPagesLoaded(0);
this.m_userTag=_191;
}
catch(err){
}
};
nitobi.combo.List.prototype.Unload=List_Unload;
function List_Unload(){
if(this.IF){
this.IF.Unload();
delete this.IF;
}
_EBAMemScrub(this);
}
nitobi.combo.List.prototype.SetClipLength=List_SetClipLength;
function List_SetClipLength(_1ce){
this.clipLength=_1ce;
}
nitobi.combo.List.prototype.GetHTMLTagObject=List_GetHTMLTagObject;
function List_GetHTMLTagObject(){
try{
this.Render();
return this.m_HTMLTagObject;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetHTMLTagObject=List_SetHTMLTagObject;
function List_SetHTMLTagObject(_1cf){
try{
this.m_HTMLTagObject=_1cf;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetHighlightCSSClassName=List_GetHighlightCSSClassName;
function List_GetHighlightCSSClassName(){
try{
return this.m_HighlightCSSClassName;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetHighlightCSSClassName=List_SetHighlightCSSClassName;
function List_SetHighlightCSSClassName(_1d0){
try{
this.m_HighlightCSSClassName=_1d0;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetListColumnDefinitions=List_GetListColumnDefinitions;
function List_GetListColumnDefinitions(){
try{
return this.m_ListColumnDefinitions;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetListColumnDefinitions=List_SetListColumnDefinitions;
function List_SetListColumnDefinitions(_1d1){
try{
this.m_ListColumnDefinitions=_1d1;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetCustomHTMLDefinition=List_GetCustomHTMLDefinition;
function List_GetCustomHTMLDefinition(){
try{
return this.m_CustomHTMLDefinition;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetCustomHTMLDefinition=List_SetCustomHTMLDefinition;
function List_SetCustomHTMLDefinition(_1d2){
try{
this.m_CustomHTMLDefinition=_1d2;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetCustomHTMLHeader=List_GetCustomHTMLHeader;
function List_GetCustomHTMLHeader(){
try{
return this.m_CustomHTMLHeader;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetCustomHTMLHeader=List_SetCustomHTMLHeader;
function List_SetCustomHTMLHeader(_1d3){
try{
this.m_CustomHTMLHeader=_1d3;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetCombo=List_GetCombo;
function List_GetCombo(){
try{
return this.m_Combo;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetCombo=List_SetCombo;
function List_SetCombo(_1d4){
try{
this.m_Combo=_1d4;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetXmlDataSource=List_GetXmlDataSource;
function List_GetXmlDataSource(){
try{
return this.m_XmlDataSource;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetXmlDataSource=List_SetXmlDataSource;
function List_SetXmlDataSource(_1d5){
try{
this.m_XmlDataSource=_1d5;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetWidth=List_GetWidth;
function List_GetWidth(){
try{
return this.m_Width;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetWidth=List_SetWidth;
function List_SetWidth(_1d6){
try{
this.m_Width=_1d6;
if(this.m_Rendered){
this.GetHTMLTagObject().style.width=this.GetDesiredPixelWidth();
for(var i=0;i<=EBAComboBoxListFooter;i++){
if(i!=EBAComboBoxListBodyTable){
var _1d8=this.GetSectionHTMLTagObject(i);
if(_1d8!=null){
_1d8.style.width=this.GetDesiredPixelWidth();
}
}
}
this.GenerateCss();
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetDesiredPixelWidth=List_GetDesiredPixelWidth;
function List_GetDesiredPixelWidth(){
var _1d9=this.GetCombo();
var _1da=document.getElementById(_1d9.GetId());
var _1db=nitobi.html.getWidth(_1da);
var _1dc=this.GetWidth();
if(nitobi.Browser.GetMeasurementUnitType(_1dc)=="%"){
var w=(_1d9.GetWidth()==null?_1d9.GetTextBox().GetWidth():_1d9.GetWidth());
var _1de=1/(parseInt(w)/100);
var _1dc=parseInt(_1dc)/100;
return (Math.floor(_1db*_1de*_1dc-2)+"px");
}else{
return _1dc;
}
}
nitobi.combo.List.prototype.GetActualPixelWidth=List_GetActualPixelWidth;
function List_GetActualPixelWidth(){
try{
var tag=this.GetHTMLTagObject();
if(null==tag){
return this.GetDesiredPixelWidth();
}else{
return nitobi.Browser.GetElementWidth(tag);
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetCSSClassName=List_GetCSSClassName;
function List_GetCSSClassName(){
try{
return (null==this.m_HTMLTagObject?this.m_CSSClassName:this.GetHTMLTagObject().className);
}
catch(err){
}
}
nitobi.combo.List.prototype.SetCSSClassName=List_SetCSSClassName;
function List_SetCSSClassName(_1e0){
try{
if(null==this.m_HTMLTagObject){
this.m_CSSClassName=_1e0;
}else{
this.GetHTMLTagObject().className=_1e0;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetSectionHTMLTagObject=List_GetSectionHTMLTagObject;
function List_GetSectionHTMLTagObject(_1e1){
try{
this.Render();
return this.m_SectionHTMLTagObjects[_1e1];
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSectionHTMLTagObject=List_SetSectionHTMLTagObject;
function List_SetSectionHTMLTagObject(_1e2,_1e3){
try{
this.m_SectionHTMLTagObjects[_1e2]=_1e3;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetSectionCSSClassName=List_GetSectionCSSClassName;
function List_GetSectionCSSClassName(_1e4){
try{
return (null==this.m_HTMLTagObject?this.m_SectionCSSClassNames[_1e4]:this.GetSectionHTMLTagObject(_1e4).className);
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSectionCSSClassName=List_SetSectionCSSClassName;
function List_SetSectionCSSClassName(_1e5,_1e6){
try{
if(null==this.m_HTMLTagObject){
this.m_SectionCSSClassNames[_1e5]=_1e6;
}else{
this.GetSectionHTMLTagObject(_1e5).className=_1e6;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetSectionHeight=List_GetSectionHeight;
function List_GetSectionHeight(_1e7){
try{
if(this.m_HTMLTagObject==null){
return parseInt(this.m_SectionHeights[_1e7]);
}else{
var _1e8=this.m_HTMLTagObject.style;
var top=_1e8.top;
var _1ea=_1e8.display;
var _1eb=_1e8.position;
var _1ec=_1e8.visibility;
if(_1e8.display=="none"||_1e8.visibility!="visible"){
_1e8.position="absolute";
_1e8.top="-1000px";
_1e8.display="inline";
}
var _1ed=null;
if(this.m_SectionHTMLTagObjects[_1e7]!=null){
_1ed=nitobi.html.getHeight(this.m_SectionHTMLTagObjects[_1e7]);
}
if(_1e8.display=="inline"){
_1e8.position=_1eb;
_1e8.display=_1ea;
_1e8.top=top;
}
return _1ed;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSectionHeight=List_SetSectionHeight;
function List_SetSectionHeight(_1ee,_1ef){
try{
if(null==this.m_HTMLTagObject){
this.m_SectionHeights[_1ee]=_1ef;
}else{
this.GetSectionHTMLTagObject(_1ee).style.height=_1ef;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetSelectedRowIndex=List_GetSelectedRowIndex;
function List_GetSelectedRowIndex(){
try{
if(null==this.m_HTMLTagObject){
return parseInt(this.m_SelectedRowIndex);
}else{
return parseInt(window.document.getElementById(this.GetCombo().GetId()+"SelectedRowIndex").value);
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSelectedRowIndex=List_SetSelectedRowIndex;
function List_SetSelectedRowIndex(_1f0){
try{
if(null==this.m_HTMLTagObject){
this.m_SelectedRowIndex=_1f0;
}else{
window.document.getElementById(this.GetCombo().GetId()+"SelectedRowIndex").value=_1f0;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetAllowPaging=List_GetAllowPaging;
function List_GetAllowPaging(){
try{
return this.m_AllowPaging;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetAllowPaging=List_SetAllowPaging;
function List_SetAllowPaging(_1f1){
try{
if(this.m_HTMLTagObject!=null){
if(_1f1){
this.ShowFooter();
}else{
this.HideFooter();
}
}
this.m_AllowPaging=_1f1;
}
catch(err){
}
}
nitobi.combo.List.prototype.IsFuzzySearchEnabled=List_IsFuzzySearchEnabled;
function List_IsFuzzySearchEnabled(){
try{
return this.m_FuzzySearchEnabled;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetFuzzySearchEnabled=List_SetFuzzySearchEnabled;
function List_SetFuzzySearchEnabled(_1f2){
try{
this.m_FuzzySearchEnabled=_1f2;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetPageSize=List_GetPageSize;
function List_GetPageSize(){
try{
return this.m_PageSize;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetPageSize=List_SetPageSize;
function List_SetPageSize(_1f3){
try{
this.m_PageSize=_1f3;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetNumPagesLoaded=List_GetNumPagesLoaded;
function List_GetNumPagesLoaded(){
try{
return this.m_NumPagesLoaded;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetNumPagesLoaded=List_SetNumPagesLoaded;
function List_SetNumPagesLoaded(_1f4){
try{
this.m_NumPagesLoaded=_1f4;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetActiveRow=List_GetActiveRow;
function List_GetActiveRow(){
try{
return this.m_ActiveRow;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetActiveRow=List_SetActiveRow;
function List_SetActiveRow(_1f5){
try{
var _1f6;
if(null!=this.m_ActiveRow){
_1f6=document.getElementById("ContainingTableFor"+this.m_ActiveRow.id);
if(this.m_UseHighlightClass){
_1f6.className=this.m_OriginalRowClass;
}else{
_1f6.style.backgroundColor=this.m_OriginalBackgroundHighlightColor;
_1f6.style.color=this.m_OriginalForegroundHighlightColor;
}
var _1f7=this.GetListColumnDefinitions();
for(var i=0,n=_1f7.length;i<n;i++){
var _1fa=document.getElementById("ContainingSpanFor"+this.m_ActiveRow.id+"_"+i);
if(_1fa!=null){
_1fa.style.color=_1fa.savedColor;
_1fa.style.backgroundColor=_1fa.savedBackgroundColor;
}
}
}
this.m_ActiveRow=_1f5;
if(null!=_1f5){
if("compact"==this.GetCombo().mode&&_1f5!=null){
var _1fb=this.GetRowIndex(_1f5);
this.SetSelectedRow(_1fb);
}
_1f6=document.getElementById("ContainingTableFor"+_1f5.id);
_1fa=document.getElementById("ContainingSpanFor"+this.m_ActiveRow.id);
if(this.m_UseHighlightClass){
this.m_OriginalRowClass=_1f6.className;
_1f6.className=this.GetHighlightCSSClassName();
}else{
this.m_OriginalBackgroundHighlightColor=_1f6.style.backgroundColor;
this.m_OriginalForegroundHighlightColor=_1f6.style.color;
_1f6.style.backgroundColor=this.m_BackgroundHighlightColor;
_1f6.style.color=this.m_ForegroundHighlightColor;
}
var _1f7=this.GetListColumnDefinitions();
for(var i=0,n=_1f7.length;i<n;i++){
var _1fa=document.getElementById("ContainingSpanFor"+this.m_ActiveRow.id+"_"+i);
if(_1fa!=null){
_1fa.savedColor=_1fa.style.color;
_1fa.savedBackgroundColor=_1fa.style.backgroundColor;
_1fa.style.color=_1f6.style.color;
_1fa.style.backgroundColor=_1f6.style.backgroundColor;
}
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetSelectedRowValues=List_GetSelectedRowValues;
function List_GetSelectedRowValues(){
try{
var _1fc=new Array;
for(var i=0;i<this.GetXmlDataSource().GetNumberColumns();i++){
_1fc[i]=window.document.getElementById(this.GetCombo().GetId()+"SelectedValue"+i).value;
}
return _1fc;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSelectedRowValues=List_SetSelectedRowValues;
function List_SetSelectedRowValues(_1fe,Row){
try{
this.m_SelectedRowValues=_1fe;
var _200=this.GetCombo().GetId();
var _201=this.GetXmlDataSource().GetNumberColumns();
if((null==_1fe)&&(null==Row)){
for(var i=0;i<_201;i++){
window.document.getElementById(_200+"SelectedValue"+i).value="";
}
}else{
if(null==Row){
for(var i=0;i<_201;i++){
window.document.getElementById(_200+"SelectedValue"+i).value=_1fe[i];
}
}else{
var _203=this.GetCombo().GetUniqueId();
var _204=this.GetRowIndex(Row);
var _205=this.GetXmlDataSource().GetRow(_204);
this.SetSelectedRowValues(_205,null);
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetEnableDatabaseSearch=List_GetEnableDatabaseSearch;
function List_GetEnableDatabaseSearch(){
try{
return this.m_EnableDatabaseSearch;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetEnableDatabaseSearch=List_SetEnableDatabaseSearch;
function List_SetEnableDatabaseSearch(_206){
try{
this.m_EnableDatabaseSearch=_206;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetFooterText=List_GetFooterText;
function List_GetFooterText(){
try{
if(null==this.m_HTMLTagObject){
return this.m_FooterText;
}else{
var _207=document.getElementById("EBAComboBoxListFooterPageNextButton"+this.GetCombo().GetUniqueId());
return (null!=_207?_207.innerHTML:"");
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetFooterText=List_SetFooterText;
function List_SetFooterText(_208){
try{
if(null==this.m_HTMLTagObject){
this.m_FooterText=_208;
}else{
var _209=this.GetSectionHTMLTagObject(EBAComboBoxListFooter);
if(null!=_209){
_209=document.getElementById("EBAComboBoxListFooterPageNextButton"+this.GetCombo().GetUniqueId());
if(null!=_209){
_209.innerHTML=_208;
}
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetDatabaseSearchTimeoutStatus=List_GetDatabaseSearchTimeoutStatus;
function List_GetDatabaseSearchTimeoutStatus(){
try{
return this.m_DatabaseSearchTimeoutStatus;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetDatabaseSearchTimeoutStatus=List_SetDatabaseSearchTimeoutStatus;
function List_SetDatabaseSearchTimeoutStatus(_20a){
try{
this.m_DatabaseSearchTimeoutStatus=_20a;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetDatabaseSearchTimeoutId=List_GetDatabaseSearchTimeoutId;
function List_GetDatabaseSearchTimeoutId(){
try{
return this.m_DatabaseSearchTimeoutId;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetDatabaseSearchTimeoutId=List_SetDatabaseSearchTimeoutId;
function List_SetDatabaseSearchTimeoutId(_20b){
try{
this.m_DatabaseSearchTimeoutId=_20b;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetHeight=List_GetHeight;
function List_GetHeight(){
try{
return this.GetSectionHeight(EBAComboBoxListBody);
}
catch(err){
}
}
nitobi.combo.List.prototype.SetHeight=List_SetHeight;
function List_SetHeight(_20c){
try{
this.SetSectionHeight(EBAComboBoxListBody,parseInt(_20c));
}
catch(err){
}
}
nitobi.combo.List.prototype.GetActualHeight=List_GetActualPixelHeight;
nitobi.combo.List.prototype.GetActualPixelHeight=List_GetActualPixelHeight;
function List_GetActualPixelHeight(){
try{
var uid=this.GetCombo().GetUniqueId();
var tag=this.GetHTMLTagObject();
var _20f=nitobi.Browser.GetElementHeight(tag);
return _20f;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetBackgroundHighlightColor=List_GetBackgroundHighlightColor;
function List_GetBackgroundHighlightColor(){
try{
return this.m_BackgroundHighlightColor;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetBackgroundHighlightColor=List_SetBackgroundHighlightColor;
function List_SetBackgroundHighlightColor(_210){
try{
this.m_BackgroundHighlightColor=_210;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetForegroundHighlightColor=List_GetForegroundHighlightColor;
function List_GetForegroundHighlightColor(){
try{
return this.m_ForegroundHighlightColor;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetForegroundHighlightColor=List_SetForegroundHighlightColor;
function List_SetForegroundHighlightColor(_211){
try{
this.m_ForegroundHighlightColor=_211;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetDatasourceUrl=List_GetDatasourceUrl;
function List_GetDatasourceUrl(){
try{
return this.m_DatasourceUrl;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetDatasourceUrl=List_SetDatasourceUrl;
function List_SetDatasourceUrl(_212){
try{
this.m_DatasourceUrl=_212;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOnHideEvent=List_GetOnHideEvent;
function List_GetOnHideEvent(){
try{
return this.m_OnHideEvent;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOnHideEvent=List_SetOnHideEvent;
function List_SetOnHideEvent(_213){
try{
this.m_OnHideEvent=_213;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOnShowEvent=List_GetOnShowEvent;
function List_GetOnShowEvent(){
try{
return this.m_OnShowEvent;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOnShowEvent=List_SetOnShowEvent;
function List_SetOnShowEvent(_214){
try{
this.m_OnShowEvent=_214;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOnBeforeSearchEvent=List_GetOnBeforeSearchEvent;
function List_GetOnBeforeSearchEvent(){
try{
return this.m_OnBeforeSearchEvent;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOnBeforeSearchEvent=List_SetOnBeforeSearchEvent;
function List_SetOnBeforeSearchEvent(_215){
try{
this.m_OnBeforeSearchEvent=_215;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOnAfterSearchEvent=List_GetOnAfterSearchEvent;
function List_GetOnAfterSearchEvent(){
try{
return this.m_OnAfterSearchEvent;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOnAfterSearchEvent=List_SetOnAfterSearchEvent;
function List_SetOnAfterSearchEvent(_216){
try{
this.m_OnAfterSearchEvent=_216;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOffsetX=List_GetOffsetX;
function List_GetOffsetX(){
try{
return this.m_OffsetX;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOffsetX=List_SetOffsetX;
function List_SetOffsetX(_217){
try{
this.m_OffsetX=parseInt(_217);
}
catch(err){
}
}
nitobi.combo.List.prototype.GetOffsetY=List_GetOffsetY;
function List_GetOffsetY(){
try{
return this.m_OffsetY;
}
catch(err){
}
}
nitobi.combo.List.prototype.SetOffsetY=List_SetOffsetY;
function List_SetOffsetY(_218){
try{
this.m_OffsetY=parseInt(_218);
}
catch(err){
}
}
nitobi.combo.List.prototype.AdjustSize=List_AdjustSize;
function List_AdjustSize(){
var list=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
var tag=this.GetHTMLTagObject();
var _21b=tag.style;
if(true==nitobi.Browser.GetVerticalScrollBarStatus(list)){
if(nitobi.Browser.GetMeasurementUnitType(this.GetWidth())!="%"){
listWidth=parseInt(this.GetWidth())+nitobi.Browser.GetScrollBarWidth(list)-(nitobi.browser.MOZ?EBADefaultScrollbarSize:0);
listWidth=this.GetDesiredPixelWidth();
}else{
listWidth=this.GetDesiredPixelWidth();
}
list.style.width=listWidth;
header=this.GetSectionHTMLTagObject(EBAComboBoxListHeader);
footer=this.GetSectionHTMLTagObject(EBAComboBoxListFooter);
if(header!=null){
header.style.width=listWidth;
}
if(footer!=null){
footer.style.width=listWidth;
}
_21b.width=(listWidth);
if(nitobi.browser.IE){
var _21c=nitobi.combo.iframeBacker.style;
_21c.width=_21b.width;
}
}
if(nitobi.browser.IE){
var _21c=nitobi.combo.iframeBacker.style;
_21c.height=_21b.height;
}
}
nitobi.combo.List.prototype.IsVisible=List_IsVisible;
function List_IsVisible(){
if(!this.m_Rendered){
return false;
}
var tag=this.GetHTMLTagObject();
var _21e=tag.style;
return (_21e.visibility=="visible");
}
nitobi.combo.List.prototype.Show=List_Show;
function List_Show(){
try{
var _21f=this.GetCombo();
var mode=_21f.mode;
this.Render();
if(!this.m_HTMLTagObject||this.IsVisible()||mode=="compact"||this.GetXmlDataSource().GetNumberRows()==0||((mode!="default"&&mode!="unbound")&&_21f.GetTextBox().m_HTMLTagObject.value=="")){
return;
}
var tag=this.GetHTMLTagObject();
var _222=_21f.GetTextBox().GetHTMLContainerObject();
var _223=tag.style;
var _224=nitobi.html.getHeight(_222);
var _225=(nitobi.browser.MOZ?0:(document.parentWindow.self.frameElement==null?0:0));
var top=nitobi.html.getCoords(_222).y+_224-_225;
var left=nitobi.html.getCoords(_222).x-_225;
var _228=parseInt(this.GetActualPixelHeight());
var _229=parseInt(this.GetActualPixelWidth());
_223.top=top+"px";
_223.left=left+"px";
_223.zIndex=_21f.m_ListZIndex;
var _22a=nitobi.html.getBodyArea().clientWidth;
var _22b=nitobi.html.getBodyArea().clientHeight;
var _22c=(document.body.scrollTop==""||parseInt(document.documentElement.scrollTop==0)?0:parseInt(document.body.scrollTop));
var _22d=(document.body.scrollLeft==""||parseInt(document.documentElement.scrollLeft==0)?0:parseInt(document.body.scrollLeft));
if(parseInt(top)-_22c+_228>_22b){
var _22e=parseInt(_223.top)-_228-_224;
if(_22e>=0){
_223.top=_22e+"px";
}
}
if(parseInt(left)-parseInt(_22d)+_229>_22a){
var _22f=document.getElementById(_21f.GetId());
var _230=nitobi.html.getWidth(_22f);
if(_229>_230){
var _231=_229-_230;
var _232=left-_231;
if(_232>=0){
_223.left=_232+"px";
}
}
}
_223.position="absolute";
_223.display="inline";
this.AdjustSize();
this.GenerateCss();
_223.visibility="visible";
this.SetIFrameDimensions();
this.ShowIFrame();
eval(this.GetOnShowEvent());
}
catch(err){
}
}
nitobi.combo.List.prototype.SetX=function(x){
var tag=this.GetHTMLTagObject();
tag.style.left=x;
};
nitobi.combo.List.prototype.GetX=function(){
var _235=this.GetCombo();
var _236=nitobi.html.getCoords(_235.GetHTMLTagObject());
return _236.x;
};
nitobi.combo.List.prototype.SetY=function(y){
var tag=this.GetHTMLTagObject();
tag.style.top=y;
};
nitobi.combo.List.prototype.GetY=function(){
var _239=this.GetCombo().GetTextBox().GetHTMLContainerObject();
var _23a=nitobi.html.getHeight(_239);
var y=nitobi.html.getCoords(_239).y+_23a;
return y;
};
nitobi.combo.List.prototype.SetFrameX=function(x){
if(nitobi.browser.ie){
nitobi.combo.iframeBacker.style.left=x;
}
};
nitobi.combo.List.prototype.SetFrameY=function(y){
if(nitobi.browser.ie){
nitobi.combo.iframeBacker.style.top=y;
}
};
nitobi.combo.List.prototype.GetFrame=function(){
if(nitobi.browser.ie){
return nitobi.combo.iframeBacker;
}else{
return null;
}
};
nitobi.combo.List.prototype.ShowIFrame=List_ShowIFrame;
function List_ShowIFrame(){
try{
if(nitobi.browser.IE){
var _23e=nitobi.combo.iframeBacker.style;
_23e.visibility="visible";
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetIFrameDimensions=List_SetIFrameDimensions;
function List_SetIFrameDimensions(){
try{
if(nitobi.browser.IE){
var tag=this.GetHTMLTagObject();
var _240=nitobi.combo.iframeBacker.style;
var _241=tag.style;
_240.top=_241.top;
_240.left=_241.left;
_240.width=nitobi.Browser.GetElementWidth(tag);
_240.height=nitobi.Browser.GetElementHeight(tag);
_240.zIndex=parseInt(_241.zIndex)-1;
}
}
catch(err){
}
}
nitobi.combo.List.prototype.Hide=List_Hide;
function List_Hide(){
try{
if(!this.m_Rendered){
return false;
}
var tag=this.GetHTMLTagObject();
var _243=tag.style;
_243.visibility="hidden";
if(nitobi.browser.MOZ){
_243.display="none";
}
if(nitobi.browser.IE){
var _244=nitobi.combo.iframeBacker.style;
_244.visibility="hidden";
}
eval(this.GetOnHideEvent());
}
catch(err){
}
}
nitobi.combo.List.prototype.Toggle=List_Toggle;
function List_Toggle(){
try{
if(this.IsVisible()){
this.Hide();
this.GetCombo().GetTextBox().ToggleHidden();
}else{
this.Show();
this.GetCombo().GetTextBox().ToggleShow();
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetActiveRowAsSelected=List_SetActiveRowAsSelected;
function List_SetActiveRowAsSelected(){
try{
var _245=this.GetCombo();
var t=_245.GetTextBox();
var row=null;
row=this.GetActiveRow();
if(null!=row){
eval(_245.GetOnBeforeSelectEvent());
}
if(row!=null){
this.SetSelectedRow(this.GetRowIndex(row));
if(_245.mode!="smartlist"){
t.SetValue(this.GetSelectedRowValues()[t.GetDataFieldIndex()]);
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.SetSelectedRow=List_SetSelectedRow;
function List_SetSelectedRow(_248){
this.SetSelectedRowIndex(_248);
var _249=this.GetXmlDataSource().GetRow(_248);
this.SetSelectedRowValues(_249,null);
}
nitobi.combo.List.prototype.OnClick=List_OnClick;
function List_OnClick(Row){
try{
eval(this.GetCombo().GetOnBeforeSelectEvent());
var _24b=this.GetRowIndex(Row);
this.SetSelectedRowIndex(_24b);
var _24c=this.GetXmlDataSource().GetRow(_24b);
this.SetSelectedRowValues(_24c,null);
var _24d=this.GetCombo();
var tb=_24d.GetTextBox();
var _24f=tb.GetDataFieldIndex();
if(_24c.length<=_24f){
alert("You have bound the textbox to a column that does not exist.\nThe textboxDataFieldIndex is "+_24f+".\nThe number of values in the selected row is "+_24c.length+".");
}else{
tb.SetValue(_24c[_24f],_24d.mode=="smartlist");
}
this.Hide();
eval(_24d.GetOnSelectEvent());
}
catch(err){
}
}
nitobi.combo.List.prototype.OnMouseWheel=List_OnMouseWheel;
function List_OnMouseWheel(evt){
try{
if(nitobi.browser.IE){
var b=nitobi.Browser;
var lb=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
var top=this.GetRow(0);
var bot=this.GetRow(this.GetXmlDataSource().GetNumberRows()-1);
if(null!=top){
if(evt.wheelDelta>=120){
b.WheelUp(this);
}else{
if(evt.wheelDelta<=-120){
b.WheelDown(this);
}
}
evt.cancelBubble=true;
evt.returnValue=false;
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.Render=List_Render;
function List_Render(){
try{
if(!this.m_Rendered){
this.m_Rendered=true;
var _255=this.GetCombo();
var _256=document.body;
_256.insertAdjacentHTML("afterBegin",this.GetHTMLRenderString());
this.Initialize(window.document.getElementById("EBAComboBoxText"+_255.GetId()));
this.OnWindowResized();
this.GenerateCss();
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetHTMLRenderString=List_GetHTMLRenderString;
function List_GetHTMLRenderString(){
try{
var _257=this.GetCombo();
var _258="outlook";
var _259=_257.GetUniqueId();
var _25a=_257.GetId();
var _25b=parseInt(this.GetDesiredPixelWidth());
var _25c=false;
var _25d="";
if(this.m_XmlDataSource.GetXmlObject()){
var xml=null;
if(_257.mode=="default"||_257.mode=="unbound"){
xml=this.m_XmlDataSource.GetXmlObject().xml;
}else{
xml="<root></root>";
}
_25d=this.GetRowHTML(xml);
}
var _25f=this.GetListColumnDefinitions();
var s="";
s="<span class=\" ntb-combo-reset "+_257.theme+"\"><span id=\"EBAComboBoxList"+_259+"\" class=\"ntb-combobox-list"+"\" style=\"width: "+_25b+"px;\" "+"onMouseOver=\"document.getElementById('"+this.GetCombo().GetId()+"').object.m_Over=true\" "+"onMouseOut=\"document.getElementById('"+this.GetCombo().GetId()+"').object.m_Over=false\" "+"onClick=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnFocus()\">\n";
var tag=this.m_userTag;
var _262=tag.childNodes;
var _263="<span class='ntb-combobox-combo-menus ComboListWidth"+_259+"'>";
var _264=false;
for(var i=0;i<_262.length;i++){
if(_262[i].nodeName.toLowerCase().replace(/^eba:/,"").replace(/^ntb:/,"")=="combopanel"){
s+=_262[i].innerHTML;
}
if(_262[i].nodeName.toLowerCase().replace(/^eba:/,"").replace(/^ntb:/,"")=="combomenu"){
_264=true;
var icon=_262[i].getAttribute("icon");
_263+="<div style='"+(nitobi.browser.MOZ&&i==0?"":"")+";' class='ntb-combobox-combo-menu ComboListWidth"+_259+"' onMouseOver=\"this.className='ntb-combobox-combo-menu-highlight ComboListWidth"+_259+"'\" onmouseout=\"this.className='ntb-combobox-combo-menu ComboListWidth"+_259+"'\" onclick=\""+_262[i].getAttribute("OnClickEvent")+"\">";
if(icon!=""){
_263+="<img class='ntb-combobox-combo-menu-icon' align='absmiddle' src='"+icon+"'>";
}
_263+=_262[i].getAttribute("text")+"</div>";
}
}
_263+="</span>";
if(_257.mode=="default"||_257.mode=="filter"||_257.mode=="unbound"){
for(var i=0;i<_25f.length;i++){
if(_25f[i].GetHeaderLabel()!=""){
_25c=true;
}
}
var _267=this.GetCustomHTMLHeader();
if((_25c==true)||(_267!="")){
s+="<span id='EBAComboBoxListHeader"+_259+"' class='ntb-combobox-list-header' style='padding:0px; margin:0px; width: "+_25b+"px;' >\n";
if(_267!=""){
s+=_267;
}else{
s+="<table cellspacing='0' cellpadding='0' style='border-collapse:collapse;' class='ComboHeader"+_259+"'>\n";
s+="<tr style='width:100%' id='EBAComboBoxColumnLabels"+_259+"' class='ntb-combobox-column-labels'>\n";
var _268="";
var _269=false;
for(var i=0;i<_25f.length;i++){
var _26a=_25f[i].GetWidth();
_268="";
if(_25f[i].GetColumnType().toLowerCase()=="hidden"){
_268+="style='display: none;'";
_25f[i].SetWidth("0%");
}
var _26b="comboColumn_"+i+"_"+_259;
var _26c=(i>0?"style='padding-left:0px'":"");
s+="<td "+_26c+" align='"+_25f[i].GetAlign()+"' class='ntb-combobox-column-label "+_26b+"' "+_268+">";
s+="<div class='"+_26b+" ntb-combobox-column-label-text'>"+_25f[i].GetHeaderLabel()+"</div>";
s+="</td>\n";
}
s+="</tr>\n";
s+="</table>\n";
}
s+="</span><br>\n";
}
}
if(_264){
s+=_263;
}
s+="<span id='EBAComboBoxListBody"+_259+"' class='ntb-combobox-list-body"+"' style='width:"+_25b+"px;"+(_257.mode=="default"||_257.mode=="unbound"||(_257.mode=="smartsearch"&&this.GetAllowPaging())?"height: "+this.GetSectionHeight(EBAComboBoxListBody)+"px"+(this.m_overflowy=="auto"?";_overflow-y:;_overflow:auto":""):"overflow:visible")+";' onscroll=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetTextBox().GetHTMLTagObject().focus()\" "+"onmousewheel=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnMouseWheel(event)\" "+"onfocus=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnFocus()\">\n";
s+=_25d+"</table>\n"+"</span>\n";
s+="<br><span id='EBAComboBoxListFooter"+_259+"' style='width:"+_25b+"px; display:"+(this.GetAllowPaging()?"inline":"none")+"' class='ntb-combobox-list-footer'>\n";
s+="<span id=\"EBAComboBoxListFooterPageNextButton"+_259+"\" style=\"width:100%\""+" class=\"ntb-combobox-list-footer-page-next-button\" "+"onMouseOver='this.className=\"ntb-combobox-list-footer-page-next-button-highlight\"' "+"onMouseOut='this.className=\"ntb-combobox-list-footer-page-next-button\"'"+"onClick=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnGetNextPage(null, true);\"></span>\n";
s+="</span>\n"+"</span>\n";
s+="</span>\n</div>";
return s;
}
catch(err){
}
}
nitobi.combo.List.prototype.Initialize=List_Initialize;
function List_Initialize(_26d){
try{
this.attachee=_26d;
var c=this.GetCombo();
var d=document;
var _270=c.GetUniqueId();
this.SetHTMLTagObject(d.getElementById("EBAComboBoxList"+_270));
this.SetSectionHTMLTagObject(EBAComboBoxListHeader,d.getElementById("EBAComboBoxListHeader"+_270));
this.SetSectionHTMLTagObject(EBAComboBoxListBody,d.getElementById("EBAComboBoxListBody"+_270));
this.SetSectionHTMLTagObject(EBAComboBoxListFooter,d.getElementById("EBAComboBoxListFooter"+_270));
this.SetSectionHTMLTagObject(EBAComboBoxListBodyTable,d.getElementById("EBAComboBoxListBodyTable"+_270));
this.SetSectionHTMLTagObject(EBAComboBoxList,d.getElementById("EBAComboBoxList"+_270));
if(c.mode=="default"&&true==this.GetAllowPaging()){
this.SetFooterText(this.GetXmlDataSource().GetNumberRows()+EbaComboUi[EbaComboUiNumRecords]);
}
this.Hide();
}
catch(err){
}
}
nitobi.combo.List.prototype.OnMouseOver=List_OnMouseOver;
function List_OnMouseOver(Row){
try{
this.SetActiveRow(Row);
}
catch(err){
}
}
nitobi.combo.List.prototype.OnMouseOut=List_OnMouseOut;
function List_OnMouseOut(Row){
try{
this.SetActiveRow(null);
}
catch(err){
}
}
nitobi.combo.List.prototype.OnFocus=List_OnFocus;
function List_OnFocus(){
try{
var t=this.GetCombo().GetTextBox();
t.m_skipFocusOnce=true;
t.m_HTMLTagObject.focus();
}
catch(err){
}
}
nitobi.combo.List.prototype.OnGetNextPage=List_OnGetNextPage;
function List_OnGetNextPage(_274,_275){
try{
if(this.m_httpRequestReady){
var _276=this.GetXmlDataSource();
var last=null;
if(_275==true){
var n=_276.GetNumberRows();
if(n>0){
last=_276.GetRowCol(n-1,this.GetCombo().GetTextBox().GetDataFieldIndex());
}
}
this.GetPage(_276.GetNumberRows(),this.GetPageSize(),this.GetCombo().GetTextBox().GetIndexSearchTerm(),_274,last);
this.GetCombo().GetTextBox().GetHTMLTagObject().focus();
}
}
catch(err){
}
}
nitobi.combo.List.prototype.OnWindowResized=List_OnWindowResized;
function List_OnWindowResized(){
if(!this.m_Rendered){
return;
}
if(nitobi.Browser.GetMeasurementUnitType(this.GetWidth())=="%"){
this.SetWidth(this.GetWidth());
}
}
nitobi.combo.List.prototype.GenerateCss=List_GenerateCss;
function List_GenerateCss(){
var _279=this.GetListColumnDefinitions();
var uid=this.GetCombo().GetUniqueId();
var _27b="";
var _27c=-1;
var list=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
var sb=nitobi.Browser.GetScrollBarWidth(list);
var _27f=(nitobi.browser.MOZ?6:0);
var _280=0;
for(var i=0;i<this.widestColumn.length;i++){
_280+=this.widestColumn[i];
}
if(_280<parseInt(this.GetDesiredPixelWidth())){
_280=parseInt(this.GetDesiredPixelWidth());
}
var _282=_280-sb-_27f;
var _283=_280-sb-_27f;
_27b+=".ComboRow"+uid+"{width:"+(_280-sb)+"px;}";
_27b+=".ComboHeader"+uid+"{width:"+(_280-sb+3)+"px;}";
_27b+=".ComboListWidth"+uid+"{width:"+(_280)+"px;}";
for(var i=0;i<_279.length;i++){
var _284=_279[i].GetWidth();
if(nitobi.Browser.GetMeasurementUnitType(_284)=="%"&&_284!="*"){
_284=Math.floor((parseInt(_284)/100)*_283);
}else{
if(_284!="*"){
_284=parseInt(_284);
}
}
if(_284=="*"||(i==_279.length-1&&_27c==-1)){
_27c=i;
}else{
if(_284<this.widestColumn[i]){
_284=this.widestColumn[i];
}
_282-=parseInt(_284);
_27b+=".comboColumn_"+i+"_"+uid+"{ width: "+(_284)+"px;}";
}
}
if(_27c!=-1){
_27b+=".comboColumn_"+_27c+"_"+uid+"{ width: "+_282+"px;}";
}
if(this.stylesheet==null){
this.stylesheet=document.createStyleSheet();
}
this.stylesheet.cssText=_27b;
}
nitobi.combo.List.prototype.ClearCss=List_ClearCss;
function List_ClearCss(){
if(this.stylesheet==null){
this.stylesheet=document.createStyleSheet();
}
this.stylesheet.cssText="";
}
nitobi.combo.List.prototype.GetRowHTML=List_GetRowHTML;
function List_GetRowHTML(XML,_286){
try{
var _287=this.GetCombo();
var _288=_287.GetId();
var _289=_287.GetUniqueId();
var _28a=this.GetListColumnDefinitions();
var _28b=parseInt(this.GetWidth());
var xsl="";
if(nitobi.browser.IE){
xsl="<xsl:stylesheet version=\"1.0\" xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\" xmlns:msxsl=\"urn:schemas-microsoft-com:xslt\" xmlns:jstring=\"http://www.ebusiness-apps.com/comboxsl\"  extension-element-prefixes=\"msxsl\" exclude-result-prefixes=\"jstring\">";
}else{
xsl="<xsl:stylesheet xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\" version=\"1.0\"  >";
}
xsl+="<xsl:output method='xml' version='4.0' omit-xml-declaration='yes' />\n"+"<xsl:template match='/'>"+"<table cellspacing='0' cellpadding='0' id='EBAComboBoxListBodyTable"+_289+"_"+this.GetNumPagesLoaded()+"' class='ntb-combobox-list-body-table ComboRow"+_289+"'>\n"+"<xsl:apply-templates>"+"</xsl:apply-templates>"+"</table>"+"</xsl:template>";
xsl+="<xsl:template match='e'>";
xsl+="<tr onclick=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnClick(this)\" "+"onmouseover=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnMouseOver(this)\" "+"onmouseout=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnMouseOut(this)\">";
xsl+="<xsl:attribute name='id'>";
var _28d="position()+"+(this.GetXmlDataSource().GetNumberRows()-this.GetXmlDataSource().GetLastPageSize())+"-1";
var _28e="EBAComboBoxRow"+_289+"_<xsl:value-of select='"+_28d+"'/>";
xsl+=_28e+"</xsl:attribute>"+"<td class='ComboRowContainerParent'><table cellspacing='0' cellpadding='0' class='ntb-combobox-list-body-table-row "+"ComboRow"+_289+"'>"+"<xsl:attribute name='id'>"+"ContainingTableFor"+_28e+"</xsl:attribute>"+"<tr class='ComboRowContainer'>";
var _28f=this.GetCustomHTMLDefinition();
var _290;
if(""==_28f){
for(var i=0;i<_28a.length;i++){
var _292="";
var _293=_28a[i].GetColumnType().toLowerCase();
if(_293=="hidden"){
_292+="style='display: none;'";
}
var _294="comboColumn_"+i+"_"+_289;
xsl+="<td align='"+_28a[i].GetAlign()+"' "+"class='"+_294+" "+_28a[i].GetCSSClassName()+"' "+_292+">";
xsl+="<div class=\""+(nitobi.browser.IE?_294+" ":"")+_28a[i].GetCSSClassName()+"Cell\" style=\"color:"+_28a[i].GetTextColor()+";overflow:hidden;\" onfocus=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnFocus()\""+" onmouseover=\"document.getElementById('"+this.GetCombo().GetId()+"').object.GetList().OnFocus()\">";
xsl+="<xsl:attribute name='id'>"+"ContainingSpanFor"+_28e+"_"+i+"</xsl:attribute>"+"<xsl:text disable-output-escaping='yes'>"+"<![CDATA["+_28a[i].GetHTMLPrefix()+""+"]]>"+"</xsl:text>";
_290=_28a[i].GetDataFieldIndex();
if(null==_290){
_290=i;
}
_290=parseInt(_290);
var _295="";
if(_293=="image"){
_295=_28a[i].GetImageHandlerURL();
_295.indexOf("?")==-1?_295+="?":_295+="&";
_295+="image=";
xsl+="<img> <xsl:attribute name='align'><xsl:value-of  select='absmiddle'/></xsl:attribute>"+"<xsl:attribute name='src'><xsl:value-of select=\"concat('"+(_28a[i].ImageUrlFromData?"":_295)+"',"+"@"+String.fromCharCode(97+_290)+")\"/></xsl:attribute>"+"</img>";
}
if((_286!=null)&&(_293!="image")){
xsl+="<xsl:call-template name=\"bold\"><xsl:with-param name=\"string\">";
}
if(_293!="image"){
xsl+="<xsl:value-of select=\"@"+String.fromCharCode(97+_290)+"\"></xsl:value-of>";
}
if((_286!=null)&&(_293!="image")){
xsl+="</xsl:with-param><xsl:with-param name=\"pattern\" select='"+EbaConstructValidXpathQuery(_286,true)+"'></xsl:with-param></xsl:call-template>";
}
xsl+="<xsl:text disable-output-escaping='yes'>"+"<![CDATA["+_28a[i].GetHTMLSuffix()+""+"]]>"+"</xsl:text>";
xsl+="</div>";
xsl+="</td>";
}
}else{
xsl+="<td width='100%'>";
var done=false;
var _297=0;
var _298=0;
var _299=0;
var _29a;
while(!done){
_297=_28f.indexOf("${",_298);
if(_297!=-1){
_298=_28f.indexOf("}",_297);
_29a=_28f.substr(_297+2,_298-_297-2);
xsl+="<xsl:text disable-output-escaping='yes'>"+"<![CDATA["+_28f.substr(_299,_297-_299)+"]]>"+"</xsl:text>";
xsl+="<xsl:value-of select=\"@"+String.fromCharCode(parseInt(_29a)+97)+"\"></xsl:value-of>";
_299=_298+1;
}else{
xsl+="<xsl:text disable-output-escaping='yes'>"+"<![CDATA["+_28f.substr(_299)+"]]>"+"</xsl:text>";
done=true;
}
}
xsl+="</td>";
}
xsl+="</tr></table></td></tr>\n"+"</xsl:template>";
if(_286!=null){
if(nitobi.browser.IE){
xsl+="<msxsl:script language=\"javascript\" implements-prefix=\"jstring\">"+"<![CDATA["+"f"+"unction lowerCase(s) "+"{"+"\treturn s.toLowerCase();"+"}"+"]]>"+"</msxsl:script>";
}
xsl+="<xsl:template name=\"bold\">"+"<xsl:param name=\"string\" select=\"''\" /><xsl:param name=\"pattern\" select=\"''\" /><xsl:param name=\"carryover\" select=\"''\" />";
if(nitobi.browser.IE){
xsl+="<xsl:variable name=\"lcstring\" select=\"jstring:lowerCase(string($string))\"/>"+"<xsl:variable name=\"lcpattern\" select=\"jstring:lowerCase(string($pattern))\"/>";
}else{
xsl+="<xsl:variable name=\"lcstring\" select=\"translate($string,'ABCDEFGHIJKLMNOPQRSTUVWXYZ','abcdefghijklmnopqrstuvwxyz')\"/>"+"<xsl:variable name=\"lcpattern\" select=\"translate($pattern,'ABCDEFGHIJKLMNOPQRSTUVWXYZ','abcdefghijklmnopqrstuvwxyz')\"/>";
}
xsl+="<xsl:choose>"+"<xsl:when test=\"$pattern != '' and $string != '' and contains($lcstring,$lcpattern)\">"+"<xsl:variable name=\"newpattern\" select=\"substring($string,string-length(substring-before($lcstring,$lcpattern)) + 1, string-length($pattern))\"/>"+"<xsl:variable name=\"before\" select=\"substring-before($string, $newpattern)\" />"+"<xsl:variable name=\"len\" select=\"string-length($before)\" />"+"<xsl:variable name=\"newcarryover\" select=\"boolean($len&gt;0 and contains(substring($before,$len,1),'%'))\" />"+"<xsl:value-of select=\"$before\" />"+"<xsl:choose>"+"<xsl:when test=\"($len=0 and $carryover) or $newcarryover or ($len&gt;1 and contains(substring($before,$len - 1,1),'%'))\">"+"<xsl:copy-of select=\"$newpattern\" />"+"</xsl:when>"+"<xsl:otherwise>"+"<b><xsl:copy-of select=\"$newpattern\" /></b>"+"</xsl:otherwise></xsl:choose>"+"<xsl:call-template name=\"bold\">"+"<xsl:with-param name=\"string\" select=\"substring-after($string, $newpattern)\" />"+"<xsl:with-param name=\"pattern\" select=\"$pattern\" />"+"<xsl:with-param name=\"carryover\" select=\"$newcarryover\" />"+"</xsl:call-template>"+"</xsl:when>"+"<xsl:otherwise>"+"<xsl:value-of select=\"$string\" />"+"</xsl:otherwise>"+"</xsl:choose>"+"</xsl:template>";
}
xsl+="</xsl:stylesheet>";
oXSL=xbDOM.create();
oXSL.loadXML(xsl);
tmp=xbDOM.create();
tmp.loadXML(XML.replace(/>\s+</g,"><"));
var html=tmp.transformNode(oXSL);
return html;
}
catch(err){
}
}
nitobi.combo.List.prototype.ScrollIntoView=List_ScrollIntoView;
function List_ScrollIntoView(Row,Top,_29e){
try{
if(Row&&this.GetCombo().mode!="compact"){
var _29f=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
if(nitobi.Browser.IsObjectInView(Row,_29f,Top,_29e)==false){
nitobi.Browser.ScrollIntoView(Row,_29f,Top);
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.GetRowIndex=List_GetRowIndex;
function List_GetRowIndex(Row){
try{
var vals=Row.id.split("_");
var _2a2=vals[vals.length-1];
return _2a2;
}
catch(err){
}
}
EBAComboListDatasourceAccessStatus_BUSY=0;
EBAComboListDatasourceAccessStatus_READY=1;
nitobi.combo.List.prototype.GetDatasourceAccessStatus=List_GetDatasourceAccessStatus;
function List_GetDatasourceAccessStatus(){
if(this.m_httpRequestReady){
return EBAComboListDatasourceAccessStatus_READY;
}else{
return EBAComboListDatasourceAccessStatus_BUSY;
}
}
nitobi.combo.List.prototype.Eval=List_Eval;
function List_Eval(_2a3){
eval(_2a3);
}
nitobi.combo.List.prototype.GetPage=List_GetPage;
function List_GetPage(_2a4,_2a5,_2a6,_2a7,_2a8,_2a9,_2aa,_2ab){
try{
this.SetFooterText(EbaComboUi[EbaComboUiPleaseWait]);
if(_2a8==null){
_2a8="";
}
this.m_httpRequest.abort();
if(null==_2a7){
_2a7=EBAScrollToNone;
}
var _2ac=nitobi.Browser;
this.m_OriginalSearchSubstring=_2a6;
var _2ad=this.GetDatasourceUrl();
_2ad.indexOf("?")==-1?_2ad+="?":_2ad+="&";
_2ad+="StartingRecordIndex="+_2a4+"&PageSize="+_2a5+"&SearchSubstring="+encodeURIComponent(_2a6)+"&ComboId="+encodeURI(this.GetCombo().GetId())+"&LastString="+encodeURIComponent(_2a8);
this.m_httpRequest.open(this.GetCombo().GetHttpRequestMethod(),_2ad,true,"","");
var _2ae=this.GetCombo().GetId();
this.m_httpRequest.onreadystatechange=function(){
try{
var _2af=window.document.getElementById(_2ae);
var co=_2af.object;
if((_2af==null)||(co==null)){
alert(EbaComboUi[EbaComboUiServerError]);
}
var t=co.GetTextBox();
var list=co.GetList();
if(list==null){
alert(EbaComboUi[EbaComboUiServerError]);
}
if(list.m_httpRequest.readyState==4){
var _2b3=list.m_httpRequest.responseText;
var _2b4=_2b3.indexOf("<?xml");
if(_2b4!=-1){
_2b3=_2b3.substr(_2b4);
}
var _2b5=list.GetXmlDataSource();
var _2b6=_2b5.GetNumberRows();
var tmp=xbDOM.create();
tmp.loadXML(_2b3);
if(true==list.clip){
tmp=xbClipXml(tmp,"root","e",list.clipLength);
_2b3=tmp.xml;
}
var _2b8=tmp.selectNodes("//e").length;
var _2b9=co.mode!="default"&&!(co.mode=="smartsearch"&&list.GetAllowPaging());
if((_2b8>0)&&(_2a4==0)||_2b9){
list.Clear();
_2b5.Clear();
}
if(_2b8==0&&_2b9){
list.Hide();
}
if(_2b8>0){
_2b5.AddPage(_2b3);
var ss=null;
if(co.mode=="smartsearch"||co.mode=="smartlist"){
ss=list.searchSubstring;
}
list.AddPage(_2b3,ss);
if((_2a4==0)&&(list.GetCombo().GetTextBox().GetSearchTerm()!="")){
list.SetActiveRow(list.GetRow(0));
}
var _2bb=false;
try{
if(!list.IsFuzzySearchEnabled()){
var _2bc=_2b5.Search(list.m_OriginalSearchSubstring,t.GetDataFieldIndex(),co.mode=="smartsearch"||co.mode=="smartlist");
_2bb=(_2bc==-1);
co.ShowWarning(_2bc!=-1,"cw001");
}
}
catch(err){
}
var _2bd;
_2bd=list.IsVisible();
if(EBAScrollToBottom==_2a7){
var r=list.GetRow(_2b6-1);
list.SetActiveRow(r);
list.ScrollIntoView(r,false);
}else{
if(EBAScrollToNewTop==_2a7||EBAScrollToNewBottom==_2a7){
var r=list.GetRow(_2b6);
list.SetActiveRow(r);
list.ScrollIntoView(r,EBAScrollToNewTop==_2a7);
var tb=t.m_HTMLTagObject;
tb.value=list.GetXmlDataSource().GetRowCol(_2b6,t.GetDataFieldIndex());
xbPutCur(tb,tb.value.length);
t.Paging=false;
}else{
if(_2bd){
list.ScrollIntoView(list.GetActiveRow(),true);
}
}
}
try{
if(!_2bb&&_2a9){
_2a9(EBAComboSearchNewRecords,list,_2a6,_2aa,_2ab);
}
}
catch(err){
}
}else{
try{
if(_2a9){
_2a9(EBAComboSearchNoRecords,list,_2a6,_2aa,_2ab);
}
}
catch(err){
}
list.SetFooterText(EbaComboUi[EbaComboUiNoRecords]);
list.SetActiveRow(null);
}
if(list.InitialSearchOnce==true&&_2b8>0){
list.InitialSearchOnce=false;
var row=list.GetRow(0);
list.SetActiveRow(row);
list.SetSelectedRowValues(null,row);
list.SetSelectedRowIndex(0);
var tb=co.GetTextBox();
tb.SetValue(list.GetSelectedRowValues()[tb.GetDataFieldIndex()]);
}
}
list.m_httpRequestReady=true;
t.Paging=false;
}
catch(err){
alert(EbaComboUi[EbaComboUiServerError]+" "+err.message);
}
};
this.m_httpRequestReady=false;
this.m_httpRequest.setRequestHeader("Content-Type","application/x-www-form-urlencoded");
var vs=document.getElementsByName("__VIEWSTATE");
if((vs!=null)&&(vs["__VIEWSTATE"]!=null)){
var _2c2="__VIEWSTATE="+encodeURI(vs["__VIEWSTATE"].value).replace(/\+/g,"%2B");
var _2c3="__EVENTTARGET="+encodeURI(this.GetCombo().GetId());
var args="__EVENTARGUMENT=GetPage";
var _2c5=_2c3+"&"+args+"&"+_2c2;
this.m_httpRequest.send(_2c5);
}else{
this.m_httpRequest.send("EBA Combo Box Get Page Request");
}
return true;
}
catch(err){
alert(EbaComboUi[EbaComboUiServerError]);
}
}
nitobi.combo.List.prototype.Search=List_Search;
function List_Search(_2c6,_2c7,_2c8,_2c9){
try{
var _2ca=this.GetCombo();
var _2cb=this.GetXmlDataSource();
if(_2ca.mode!="default"&&_2c6==""){
this.Hide();
return;
}
if(null==_2c9){
_2c9=false;
}
eval(this.GetOnBeforeSearchEvent());
var _2cc=-1;
if(!this.GetEnableDatabaseSearch()||!_2cb.m_Dirty||_2ca.mode=="unbound"){
_2cc=_2cb.Search(_2c6,_2c7,_2ca.mode=="smartsearch"||_2ca.mode=="smartlist");
if(_2cc>-1&&this.InitialSearchOnce!=true){
this.Show();
}
if(-1!=_2cc){
if(_2c8){
try{
_2c8(_2cc,this);
}
catch(err){
}
}
eval(this.GetOnAfterSearchEvent());
}
if(-1==_2cc&&(false==this.GetEnableDatabaseSearch()||_2c9)){
if(_2c8){
try{
_2c8(_2cc,this);
}
catch(err){
}
}
eval(this.GetOnAfterSearchEvent());
}
}
this.searchSubstring=_2c6;
if((-1==_2cc)&&(this.GetEnableDatabaseSearch()==true&&(_2c9==false))){
var _2cd=this.GetDatabaseSearchTimeoutStatus();
var _2ce="var list = window.document.getElementById('"+_2ca.GetId()+"').object.GetList(); "+"list.SetDatabaseSearchTimeoutStatus(EBADatabaseSearchTimeoutStatus_EXPIRED);"+"var textbox = window.document.getElementById('"+_2ca.GetId()+"').object.GetTextBox();"+"list.Search(textbox.GetSearchTerm(),textbox.GetDataFieldIndex(),textbox.m_Callback);";
var _2cf=this.GetDatabaseSearchTimeoutId();
_2ca.GetTextBox().SetIndexSearchTerm(_2c6);
switch(_2cd){
case (EBADatabaseSearchTimeoutStatus_EXPIRED):
if(_2cf!=null){
window.clearTimeout(_2cf);
}
this.SetDatabaseSearchTimeoutStatus(EBADatabaseSearchTimeoutStatus_NONE);
var _2d0=_EbaListGetPageCallback;
this.GetPage(0,this.GetPageSize(),_2c6,EBAScrollToTypeAhead,null,_2d0,_2c7,_2c8);
break;
case (EBADatabaseSearchTimeoutStatus_WAIT):
if(_2cf!=null){
window.clearTimeout(_2cf);
}
var _2cf=window.setTimeout(_2ce,EBADatabaseSearchTimeoutWait);
this.SetDatabaseSearchTimeoutId(_2cf);
case (EBADatabaseSearchTimeoutStatus_NONE):
this.SetDatabaseSearchTimeoutStatus(EBADatabaseSearchTimeoutStatus_WAIT);
var _2cf=window.setTimeout(_2ce,EBADatabaseSearchTimeoutWait);
this.SetDatabaseSearchTimeoutId(_2cf);
}
}
}
catch(err){
}
}
function _EbaListGetPageCallback(_2d1,list,_2d3,_2d4,_2d5){
if((list==null)){
alert(EbaComboUi[EbaComboUiServerError]);
}
if(_2d1==EBAComboSearchNewRecords){
if(!list.IsFuzzySearchEnabled()){
list.Search(_2d3,_2d4,_2d5);
}else{
list.Show();
}
}else{
_2d5(-1,list);
list.Eval(list.GetOnAfterSearchEvent());
}
}
nitobi.combo.List.prototype.Clear=List_Clear;
function List_Clear(){
try{
var _2d6=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
_2d6.innerHTML="";
this.SetSelectedRowIndex(-1);
this.SetSelectedRowValues(null);
}
catch(err){
}
}
nitobi.combo.List.prototype.FitContent=List_FitContent;
function List_FitContent(){
try{
var _2d7=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
var _2d8=_2d7.childNodes[_2d7.childNodes.length-1];
var row=_2d8;
while(row.childNodes[0]!=null&&row.childNodes[0].className.indexOf("ComboBoxListColumnDefinition")==-1){
row=row.childNodes[0];
}
for(var i=0;i<row.childNodes.length;i++){
var _2db=nitobi.html.getWidth(row.childNodes[0]);
if(this.widestColumn[i]<_2db){
this.widestColumn[i]=_2db;
}
}
}
catch(err){
}
}
nitobi.combo.List.prototype.AddPage=List_AddPage;
function List_AddPage(_2dc,_2dd){
try{
var _2de=this.GetXmlDataSource();
var tmp=xbDOM.create();
tmp.loadXML(_2dc);
var _2e0=tmp.selectNodes("//e").length;
if(_2e0>0){
var html=this.GetRowHTML(_2dc,_2dd);
var _2e2=this.GetSectionHTMLTagObject(EBAComboBoxListBody);
_2e2.insertAdjacentHTML("beforeEnd",html,true);
this.GenerateCss();
}
var _2e3=_2de.GetLastPageSize();
if(0==_2e0){
this.SetFooterText(EbaComboUi[EbaComboUiEndOfRecords]);
}else{
this.SetFooterText(_2de.GetNumberRows()+EbaComboUi[EbaComboUiNumRecords]);
}
this.AdjustSize();
this.SetIFrameDimensions();
}
catch(err){
}
}
nitobi.combo.List.prototype.HideFooter=List_HideFooter;
function List_HideFooter(){
try{
var _2e4=this.GetSectionHTMLTagObject(EBAComboBoxListFooter);
var _2e5=_2e4.style;
_2e5.display="none";
}
catch(err){
}
}
nitobi.combo.List.prototype.ShowFooter=List_ShowFooter;
function List_ShowFooter(){
try{
var _2e6=this.GetSectionHTMLTagObject(EBAComboBoxListFooter);
var _2e7=_2e6.style;
_2e7.display="inline";
}
catch(err){
}
}
nitobi.combo.List.prototype.AddRow=List_AddRow;
function List_AddRow(_2e8){
try{
var xml="<root><e ";
for(var i=0;i<_2e8.length;i++){
xml+=String.fromCharCode(i+97)+"='"+EbaXmlEncode(_2e8[i])+"' ";
}
xml+="/></root>";
this.GetXmlDataSource().AddPage(xml);
this.AddPage(xml);
}
catch(err){
alert("Error. The values must be valid XML attributes.");
}
}
nitobi.combo.List.prototype.Move=List_Move;
function List_Move(_2eb){
try{
var _2ec=this.GetCombo();
var mode=_2ec.mode;
if(mode=="compact"||this.GetXmlDataSource().GetNumberRows()==0||(mode!="default"&&mode!="unbound"&&_2ec.GetTextBox().m_HTMLTagObject.value=="")){
return false;
}
var _2ee=this.GetActiveRow();
this.Show();
if(null==_2ee){
_2ee=this.GetRow(0,null);
}else{
var _2ef=this.GetRowIndex(this.GetActiveRow());
switch(_2eb){
case (EBAMoveAction_UP):
_2ef--;
break;
case (EBAMoveAction_DOWN):
_2ef++;
break;
default:
}
if((_2ef>=0)&&(_2ef<this.GetXmlDataSource().GetNumberRows())){
_2ee=this.GetRow(_2ef,null);
}
}
this.SetActiveRow(_2ee);
this.ScrollIntoView(_2ee,false,true);
return true;
}
catch(err){
}
}
nitobi.combo.List.prototype.GetRow=List_GetRow;
function List_GetRow(_2f0,Id){
try{
if(null!=_2f0){
return document.getElementById("EBAComboBoxRow"+this.GetCombo().GetUniqueId()+"_"+_2f0);
}
if(null!=Id){
return document.getElementById(Id);
}
}
catch(err){
}
}
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.ListColumnDefinition=function(_2f2){
try{
if(!_2f2.getAttribute){
_2f2.getAttribute=function(a){
return this[a];
};
}
var _2f4="50px";
var _2f5="ntb-combobox-list-column-definition";
var _2f6="text";
var _2f7="";
var _2f8="left";
var _2f9="#000";
var _2fa=(_2f2?_2f2.getAttribute("TextColor"):null);
((null==_2fa)||(""==_2fa))?this.SetTextColor(_2f9):this.SetTextColor(_2fa);
var _2fb=(_2f2?_2f2.getAttribute("Align"):null);
((null==_2fb)||(""==_2fb))?this.SetAlign(_2f8):this.SetAlign(_2fb);
var _2fc=(_2f2?_2f2.getAttribute("Width"):null);
((null==_2fc)||(""==_2fc))?this.SetWidth(_2f4):this.SetWidth(_2fc);
var ihu=(_2f2?_2f2.getAttribute("ImageHandlerURL"):null);
((null==ihu)||(""==ihu))?this.SetImageHandlerURL(_2f7):this.SetImageHandlerURL(ihu);
var ct=(_2f2?_2f2.getAttribute("ColumnType"):null);
((null==ct)||(""==ct))?this.SetColumnType(_2f6):this.SetColumnType(ct.toLowerCase());
this.ImageUrlFromData=((this.GetColumnType()=="image")&&((null==ihu)||(""==ihu)));
var ccn=(_2f2?_2f2.getAttribute("CSSClassName"):null);
((null==ccn)||(""==ccn))?this.SetCSSClassName(_2f5):this.SetCSSClassName(ccn);
var hp=(_2f2?_2f2.getAttribute("HTMLPrefix"):null);
((null==hp)||(""==hp))?this.SetHTMLPrefix(""):this.SetHTMLPrefix(hp);
var hs=(_2f2?_2f2.getAttribute("HTMLSuffix"):null);
((null==hs)||(""==hs))?this.SetHTMLSuffix(""):this.SetHTMLSuffix(hs);
var hl=(_2f2?_2f2.getAttribute("HeaderLabel"):null);
((null==hl)||(""==hl))?this.SetHeaderLabel(""):this.SetHeaderLabel(hl);
var dfi=(_2f2?_2f2.getAttribute("DataFieldIndex"):null);
((null==dfi)||(""==dfi))?this.SetDataFieldIndex(0):this.SetDataFieldIndex(dfi);
}
catch(err){
}
};
nitobi.combo.ListColumnDefinition.prototype.GetAlign=ListColumnDefinition_GetAlign;
function ListColumnDefinition_GetAlign(){
try{
return this.m_Align;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetAlign=ListColumnDefinition_SetAlign;
function ListColumnDefinition_SetAlign(_304){
try{
_304=_304.toLowerCase();
if("right"!=_304&&"left"!=_304&&"center"!=_304){
_304="left";
}
this.m_Align=_304;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetTextColor=ListColumnDefinition_GetTextColor;
function ListColumnDefinition_GetTextColor(){
try{
return this.m_TextColor;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetTextColor=ListColumnDefinition_SetTextColor;
function ListColumnDefinition_SetTextColor(_305){
try{
this.m_TextColor=_305;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetHTMLSuffix=ListColumnDefinition_GetHTMLSuffix;
function ListColumnDefinition_GetHTMLSuffix(){
try{
return this.m_HTMLSuffix;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetHTMLSuffix=ListColumnDefinition_SetHTMLSuffix;
function ListColumnDefinition_SetHTMLSuffix(_306){
try{
this.m_HTMLSuffix=_306;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetHTMLPrefix=ListColumnDefinition_GetHTMLPrefix;
function ListColumnDefinition_GetHTMLPrefix(){
try{
return this.m_HTMLPrefix;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetHTMLPrefix=ListColumnDefinition_SetHTMLPrefix;
function ListColumnDefinition_SetHTMLPrefix(_307){
try{
this.m_HTMLPrefix=_307;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetCSSClassName=ListColumnDefinition_GetCSSClassName;
function ListColumnDefinition_GetCSSClassName(){
try{
return this.m_CSSClassName;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetCSSClassName=ListColumnDefinition_SetCSSClassName;
function ListColumnDefinition_SetCSSClassName(_308){
try{
this.m_CSSClassName=_308;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetColumnType=ListColumnDefinition_GetColumnType;
function ListColumnDefinition_GetColumnType(){
try{
return this.m_ColumnType;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetColumnType=ListColumnDefinition_SetColumnType;
function ListColumnDefinition_SetColumnType(_309){
try{
this.m_ColumnType=_309;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetHeaderLabel=ListColumnDefinition_GetHeaderLabel;
function ListColumnDefinition_GetHeaderLabel(){
try{
return this.m_HeaderLabel;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetHeaderLabel=ListColumnDefinition_SetHeaderLabel;
function ListColumnDefinition_SetHeaderLabel(_30a){
try{
this.m_HeaderLabel=_30a;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetWidth=ListColumnDefinition_GetWidth;
function ListColumnDefinition_GetWidth(){
try{
return this.m_Width;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetWidth=ListColumnDefinition_SetWidth;
function ListColumnDefinition_SetWidth(_30b){
try{
this.m_Width=_30b;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetDataFieldIndex=ListColumnDefinition_GetDataFieldIndex;
function ListColumnDefinition_GetDataFieldIndex(){
try{
return this.m_DataFieldIndex;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetDataFieldIndex=ListColumnDefinition_SetDataFieldIndex;
function ListColumnDefinition_SetDataFieldIndex(_30c){
try{
this.m_DataFieldIndex=_30c;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.GetImageHandlerURL=ListColumnDefinition_GetImageHandlerURL;
function ListColumnDefinition_GetImageHandlerURL(){
try{
return this.m_ImageHandlerURL;
}
catch(err){
}
}
nitobi.combo.ListColumnDefinition.prototype.SetImageHandlerURL=ListColumnDefinition_SetImageHandlerURL;
function ListColumnDefinition_SetImageHandlerURL(_30d){
try{
this.m_ImageHandlerURL=_30d;
}
catch(err){
}
}
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.TextBox=function(_30e,_30f,_310){
try{
var _311="";
if(nitobi.browser.IE){
_311="ntb-combobox-text-ie";
}else{
_311="ntb-combobox-text-moz";
}
var _312="100px";
var _313="";
var _314=true;
var _315="";
var _316=0;
var _317="";
var _318="";
this.SetCombo(_30f);
var oeku=(_30e?_30e.getAttribute("OnEditKeyUpEvent"):null);
((null==oeku)||(""==oeku))?this.SetOnEditKeyUpEvent(_318):this.SetOnEditKeyUpEvent(oeku);
var _31a=(_30e?_30e.getAttribute("Width"):null);
((null==_31a)||(""==_31a))?this.SetWidth(_312):this.SetWidth(_31a);
var _31b=(_30e?_30e.getAttribute("Height"):null);
((null==_31b)||(""==_31b))?this.SetHeight(_313):this.SetHeight(_31b);
var ccn=(_30e?_30e.getAttribute("CSSClassName"):null);
((null==ccn)||(""==ccn))?this.SetCSSClassName(_311):this.SetCSSClassName(ccn);
var _31d=(_30e?_30e.getAttribute("Editable"):null);
((null==_31d)||(""==_31d))?this.SetEditable(_314):this.SetEditable(_31d);
var _31e=(_30e?_30e.getAttribute("Value"):null);
((null==_31e)||(""==_31e))?this.SetValue(_315):this.SetValue(_31e);
var _31f=_30f.GetDataTextField();
if(_31f!=null){
this.SetDataFieldIndex(_30f.GetList().GetXmlDataSource().GetColumnIndex(_31f));
}else{
var dfi=(_30e?_30e.getAttribute("DataFieldIndex"):null);
((null==dfi)||(""==dfi))?this.SetDataFieldIndex(_316):this.SetDataFieldIndex(dfi);
}
var st=(_30e?_30e.getAttribute("SearchTerm"):null);
if((null==st)||(""==st)){
this.SetSearchTerm(_317);
this.SetIndexSearchTerm(_317);
}else{
this.SetSearchTerm(st);
this.SetIndexSearchTerm(st);
}
this.hasButton=_310;
this.m_userTag=_30e;
}
catch(err){
}
};
nitobi.combo.TextBox.prototype.Unload=TextBox_Unload;
function TextBox_Unload(){
if(this.m_List){
delete this.m_List;
this.m_List=null;
}
if(this.m_Callback){
delete this.m_Callback;
this.m_Callback=null;
}
_EBAMemScrub(this);
}
nitobi.combo.TextBox.prototype.GetCSSClassName=TextBox_GetCSSClassName;
function TextBox_GetCSSClassName(){
try{
return (null==this.m_HTMLTagObject?this.m_CSSClassName:this.m_HTMLTagObject.className);
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetCSSClassName=TextBox_SetCSSClassName;
function TextBox_SetCSSClassName(_322){
try{
if(null==this.m_HTMLTagObject){
this.m_CSSClassName=_322;
}else{
this.m_HTMLTagObject.className=_322;
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetHeight=TextBox_GetHeight;
function TextBox_GetHeight(){
try{
return (null==this.m_HTMLTagObject?this.m_Height:nitobi.html.Css.getStyle(this.m_HTMLTagObject,"height"));
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetHeight=TextBox_SetHeight;
function TextBox_SetHeight(_323){
try{
if(null==this.m_HTMLTagObject){
this.m_Height=_323;
}else{
this.m_HTMLTagObject.style.height=_323;
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetWidth=TextBox_GetWidth;
function TextBox_GetWidth(){
try{
if(null==this.m_HTMLTagObject){
return this.m_Width;
}else{
return nitobi.html.Css.getStyle(this.GetHTMLContainerObject(),"width");
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetWidth=TextBox_SetWidth;
function TextBox_SetWidth(_324){
try{
this.m_Width=_324;
if(null!=this.m_HTMLTagObject){
this.m_HTMLTagObject.style.width=_324;
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetHTMLTagObject=TextBox_GetHTMLTagObject;
function TextBox_GetHTMLTagObject(){
try{
return this.m_HTMLTagObject;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetHTMLTagObject=TextBox_SetHTMLTagObject;
function TextBox_SetHTMLTagObject(_325){
try{
this.m_HTMLTagObject=_325;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetHTMLContainerObject=function(){
return document.getElementById("EBAComboBoxTextContainer"+this.GetCombo().GetUniqueId());
};
nitobi.combo.TextBox.prototype.GetEditable=TextBox_GetEditable;
function TextBox_GetEditable(){
try{
if(null==this.m_HTMLTagObject){
return this.m_Editable;
}else{
return this.m_HTMLTagObject.getAttribute("contentEditable");
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetEditable=TextBox_SetEditable;
function TextBox_SetEditable(_326){
try{
if(null==this.m_HTMLTagObject){
this.m_Editable=_326;
}else{
this.m_HTMLTagObject.setAttribute("contentEditable",_326);
if(_326==true){
this.m_HTMLTagObject.removeAttribute("readonly");
}else{
this.m_HTMLTagObject.setAttribute("readonly","true");
}
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetValue=TextBox_GetValue;
function TextBox_GetValue(){
try{
if(null==this.m_HTMLTagObject){
return this.m_Value;
}else{
return this.m_HTMLTagObject.value;
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetValue=TextBox_SetValue;
function TextBox_SetValue(_327,_328){
try{
if(null==this.m_HTMLTagObject){
this.m_Value=_327;
}else{
if(this.GetCombo().mode=="smartlist"){
this.SmartSetValue(_327,_328);
}else{
this.m_HTMLTagObject.value=_327;
this.m_TextValueTag.value=_327;
}
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SmartSetValue=TextBox_SmartSetValue;
function TextBox_SmartSetValue(_329,_32a){
try{
var t=this.m_HTMLTagObject;
var _32c=this.GetCombo();
var lio=t.value.lastIndexOf(_32c.SmartListSeparator);
if(lio>-1){
_329=t.value.substring(0,lio)+_32c.SmartListSeparator+" "+_329;
}
if(_32a){
_329+=_32c.SmartListSeparator+" ";
}
t.value=_329;
this.m_TextValueTag.value=_329;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetDataFieldIndex=TextBox_GetDataFieldIndex;
function TextBox_GetDataFieldIndex(){
try{
return this.m_DataFieldIndex;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetDataFieldIndex=TextBox_SetDataFieldIndex;
function TextBox_SetDataFieldIndex(_32e){
try{
this.m_DataFieldIndex=parseInt(_32e);
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetCombo=TextBox_GetCombo;
function TextBox_GetCombo(){
try{
return this.m_Combo;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetCombo=TextBox_SetCombo;
function TextBox_SetCombo(_32f){
try{
this.m_Combo=_32f;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetSearchTerm=TextBox_GetSearchTerm;
function TextBox_GetSearchTerm(){
try{
return this.m_SearchTerm;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetSearchTerm=TextBox_SetSearchTerm;
function TextBox_SetSearchTerm(_330){
try{
this.m_SearchTerm=_330;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetIndexSearchTerm=TextBox_GetIndexSearchTerm;
function TextBox_GetIndexSearchTerm(){
try{
return this.m_IndexSearchTerm;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetIndexSearchTerm=TextBox_SetIndexSearchTerm;
function TextBox_SetIndexSearchTerm(_331){
try{
this.m_IndexSearchTerm=_331;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.OnChanged=TextBox_OnChanged;
function TextBox_OnChanged(e){
try{
this.m_skipBlur=true;
var _333=this.GetCombo();
var list=_333.GetList();
list.SetActiveRow(null);
var _335=this.GetValue();
this.m_TextValueTag.value=_335;
var _336=this.GetSearchTerm();
if(_333.mode=="smartsearch"||_333.mode=="smartlist"||_333.mode=="filter"||_333.mode=="compact"){
list.GetXmlDataSource().m_Dirty=true;
}
if(_333.mode=="smartlist"){
var lio=_335.lastIndexOf(_333.SmartListSeparator);
if(lio>-1){
_335=_335.substring(lio+_333.SmartListSeparator.length).replace(/^\s+/,"");
}
}
if((_336.indexOf(_335)==0&&_336!=_335)){
list.GetXmlDataSource().m_Dirty=true;
}
this.SetSearchTerm(_335);
if(e!=null){
this.prevKeyCode=e.keyCode;
}
var dfi=this.GetDataFieldIndex();
var This=this;
var _33a=(e!=null?e.keyCode:0);
this.m_CurrentKeyCode=_33a;
this.m_List=list;
this.m_Event=e;
this.m_Callback=_EbaTextboxCallback;
this.m_skipBlur=false;
this.m_List.Search(_335,dfi,this.m_Callback);
}
catch(err){
}
}
function _EbaTextboxCallback(_33b,list){
try{
var _33d=list.GetCombo();
var tb=_33d.GetTextBox();
var e=tb.m_Event;
var _340=tb.m_CurrentKeyCode;
list.SetSelectedRowValues(null);
list.SetSelectedRowIndex(-1);
var _341=tb.GetSearchTerm();
var tb=list.GetCombo().GetTextBox();
var row=null;
if(_33b>-1){
var _343="EBAComboBoxRow"+_33d.GetUniqueId()+"_"+_33b;
row=document.getElementById(_343);
if(""!=tb.searchValue&&(null==e||(_340!=46&&_340!=8))&&(null!=e||(tb.prevKeyCode!=46&&tb.prevKeyCode!=8))&&_33d.mode!="smartlist"&&_33d.mode!="smartsearch"){
tb.TypeAhead(list.GetXmlDataSource().GetRowCol(_33b,tb.GetDataFieldIndex()),tb.GetSearchTerm().length,tb.GetSearchTerm());
list.SetSelectedRow(_33b);
}
list.SetActiveRow(row);
}
if(e!=null&&_33b>-1&&list.InitialSearchOnce!=true){
list.Show();
list.ScrollIntoView(row,true);
}
tb.m_skipBlur=false;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.TypeAhead=TextBox_TypeAhead;
function TextBox_TypeAhead(txt){
var t=this.m_HTMLTagObject;
var x=xbGetCurPos(t);
if(txt.toLowerCase().indexOf(t.value.toLowerCase())!=0){
return;
}
this.SetValue(txt);
xbHighlight(t,x);
}
nitobi.combo.TextBox.prototype.OnMouseOver=TextBox_OnMouseOver;
function TextBox_OnMouseOver(_347){
try{
if(this.GetCombo().GetEnabled()){
if(this.GetHeight()!="100%"){
nitobi.html.Css.swapClass(this.GetHTMLContainerObject(),"ntb-combobox-text-dynamic","ntb-combobox-text-dynamic-over");
nitobi.html.Css.addClass(this.m_HTMLTagObject,"ntb-combobox-input-dynamic");
}
if(_347){
var b=this.GetCombo().GetButton();
if(null!=b){
b.OnMouseOver(null,false);
}
}
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.OnMouseOut=TextBox_OnMouseOut;
function TextBox_OnMouseOut(_349){
try{
if(this.GetCombo().GetEnabled()){
if(this.GetHeight()!="100%"){
nitobi.html.Css.swapClass(this.GetHTMLContainerObject(),"ntb-combobox-text-dynamic-over","ntb-combobox-text-dynamic");
nitobi.html.Css.removeClass(this.m_HTMLTagObject,"ntb-combobox-input-dynamic");
}
if(_349){
var b=this.GetCombo().GetButton();
if(null!=b){
b.OnMouseOut(null,false);
}
}
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.OnClick=TextBox_OnClick;
function TextBox_OnClick(){
try{
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.ToggleHidden=TextBox_ToggleHidden;
function TextBox_ToggleHidden(){
try{
this.m_ToggleHidden=true;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.ToggleShow=TextBox_ToggleShow;
function TextBox_ToggleShow(){
try{
this.m_ToggleShow=true;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.Render=TextBox_Render;
function TextBox_Render(){
try{
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetHTMLRenderString=TextBox_GetHTMLRenderString;
function TextBox_GetHTMLRenderString(){
try{
var c=this.GetCombo();
var _34c=c.GetId();
var _34d=this.GetValue().replace(/\'/g,"&#39;").replace(/\"/g,"&quot;");
var w=this.GetWidth();
var h=this.GetHeight();
var _350=c.mode=="smartlist";
var html="";
var _352;
_352=(null!=w&&""!=w?"width:"+w+";":"")+(null!=h&&""!=h?"height:"+h+";":"");
html+="<div id=\"EBAComboBoxTextContainer"+this.GetCombo().GetUniqueId()+"\" class=\"ntb-combobox-text-container ntb-combobox-text-dynamic\" style=\""+(this.hasButton?"border-right:0px solid white;":"")+(_350&&nitobi.browser.IE?"width:"+w+";":"")+"\">";
if(_350&&nitobi.browser.IE){
html+="<span style='"+_352+"'>";
_352="width:100%;height:"+h+";overflow-y:auto;";
}
html+="<"+(_350==true?"textarea":"input")+" id=\"EBAComboBoxText"+_34c+"\" name=\"EBAComboBoxText"+_34c+"\" type=\"TEXT\" class='"+this.GetCSSClassName()+"' contentEditable='"+this.GetEditable()+"' "+(this.GetEditable().toString().toLowerCase()=="true"?"":"readonly='true'")+" AUTOCOMPLETE='OFF' value='"+_34d+"'  "+"style=\""+_352+"\" "+"onblur='var combo=window.document.getElementById(\""+_34c+"\").object; if(!(combo.m_Over || combo.GetList().m_skipBlur)) window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnBlur(event)' "+"onkeyup='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnKeyOperation(event,0)' "+"onkeypress='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnKeyOperation(event,1)' "+"onkeydown='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnKeyOperation(event,2)' "+"onmouseover='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnMouseOver(true)' "+"onmouseout='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnMouseOut(true)' "+"onpaste='window.setTimeout(\"window.document.getElementById(\\\""+_34c+"\\\").object.GetTextBox().OnChanged()\",0)' "+"oninput='window.setTimeout(\"window.document.getElementById(\\\""+_34c+"\\\").object.GetTextBox().OnChanged()\",0)' "+"onfocus='window.document.getElementById(\""+_34c+"\").object.GetTextBox().OnFocus()' "+"tabindex='"+c.GetTabIndex()+"'>"+(_350==true?_34d:"")+"</"+(_350==true?"textarea>":"input>")+"<input id=\"EBAComboBoxTextValue"+_34c+"\" name=\""+_34c+"\" type=\"HIDDEN\" value=\""+_34d+"\">";
html+="</div>";
if(_350&&nitobi.browser.IE){
html+="</span>";
}
return html;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.Initialize=TextBox_Initialize;
function TextBox_Initialize(){
try{
this.m_ToggleHidden=false;
this.m_ToggleShow=false;
this.focused=false;
this.m_skipBlur=false;
this.m_skipFocusOnce=false;
this.prevKeyCode=-1;
this.skipKeyUp=false;
this.SetHTMLTagObject(document.getElementById("EBAComboBoxText"+this.GetCombo().GetId()));
this.m_TextValueTag=document.getElementById("EBAComboBoxTextValue"+this.GetCombo().GetId());
if(!this.GetCombo().GetEnabled()){
this.Disable();
}
this.m_userTag=null;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.Disable=TextBox_Disable;
function TextBox_Disable(){
nitobi.html.Css.swapClass(this.GetHTMLContainerObject(),"ntb-combobox-text-container","ntb-combobox-text-container-disabled");
nitobi.html.Css.addClass(this.m_HTMLTagObject,"ntb-combobox-input-disabled");
this.m_HTMLTagObject.disabled=true;
}
nitobi.combo.TextBox.prototype.Enable=TextBox_Enable;
function TextBox_Enable(){
nitobi.html.Css.swapClass(this.GetHTMLContainerObject(),"ntb-combobox-text-container-disabled","ntb-combobox-text-container");
nitobi.html.Css.removeClass(this.m_HTMLTagObject,"ntb-combobox-input-disabled");
this.m_HTMLTagObject.disabled=false;
}
nitobi.combo.TextBox.prototype.OnBlur=TextBox_OnBlur;
function TextBox_OnBlur(e){
try{
var _354=this.GetCombo();
var list=_354.GetList();
if(this.m_skipBlur||_354.m_Over){
return;
}
this.focused=false;
list.Hide();
eval(_354.GetOnBlurEvent());
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.OnFocus=TextBox_OnFocus;
function TextBox_OnFocus(){
try{
if(this.m_skipBlur||this.m_skipFocusOnce){
this.m_skipFocusOnce=false;
return;
}
this.focused=true;
var _356;
_356=this.GetCombo().GetList().IsVisible();
if(!_356||this.m_ToggleShow){
this.m_ToggleShow=false;
if(this.m_ToggleHidden){
this.m_ToggleHidden=false;
}else{
eval(this.GetCombo().GetOnFocusEvent());
}
}
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.SetOnEditKeyUpEvent=TextBox_SetOnEditKeyUpEvent;
function TextBox_SetOnEditKeyUpEvent(_357){
try{
this.m_OnEditKeyUpEvent=_357;
}
catch(err){
}
}
nitobi.combo.TextBox.prototype.GetOnEditKeyUpEvent=TextBox_GetOnEditKeyUpEvent;
function TextBox_GetOnEditKeyUpEvent(){
try{
return this.m_OnEditKeyUpEvent;
}
catch(err){
}
}
function TextBox_CancelBubble(e){
if(nitobi.browser.IE){
e.cancelBubble=true;
e.returnValue=false;
}else{
if(nitobi.browser.MOZ){
e.stopPropagation();
e.preventDefault();
}
}
}
nitobi.combo.TextBox.prototype.OnKeyOperation=TextBox_OnKeyOperation;
function TextBox_OnKeyOperation(e,_35a){
if(this.GetEditable()=="false"){
return;
}
e=e?e:window.event;
try{
var _35b=0;
var _35c=1;
var _35d=2;
var _35e=13;
var _35f=27;
var _360=9;
var _361=65;
var _362=90;
var _363=48;
var _364=57;
var _365=40;
var _366=38;
var _367=46;
var _368=8;
var _369=32;
var _36a=96;
var _36b=105;
var _36c=36;
var _36d=35;
var _36e=37;
var _36f=39;
var _370=112;
var _371=123;
var _372=16;
var _373=17;
var _374=18;
var _375=33;
var _376=34;
var t=this.m_HTMLTagObject;
var _378=this.GetCombo();
var list=_378.GetList();
var _37a=e.keyCode;
_378.SetEventObject(e);
var dfi=this.GetDataFieldIndex();
switch(_35a){
case (_35b):
if(_35e!=_37a&&_35f!=_37a&&_360!=_37a&&(_37a<_375||_37a>_365)&&(_37a<_370||_37a>_371)&&(_37a<_372||_37a>_374)){
if(_378.mode=="smartsearch"||_378.mode=="smartlist"||_378.mode=="filter"||_378.mode=="compact"){
list.GetXmlDataSource().m_Dirty=true;
}
this.OnChanged(e);
eval(this.GetOnEditKeyUpEvent());
}
if(_37a==_366||_37a==_365||_37a==_375||_37a==_376||_37a==_35e){
if(this.smartlistWA==true){
this.smartlistWA=false;
}else{
if(nitobi.browser.IE){
t.value=t.value;
}else{
xbPutCur(t,t.value.length);
}
}
}
if(_378.mode=="smartlist"&&_37a==_35e&&list.GetActiveRow()!=null){
this.SetValue(list.GetSelectedRowValues()[this.GetDataFieldIndex()],true);
list.SetActiveRow(null);
}
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(this.lio!=lio){
list.Hide();
}
this.lio=lio;
}
break;
case (_35d):
switch(_37a){
case (_35e):
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(lio!=this.lio){
list.Hide();
break;
}
}
this.m_skipBlur=true;
list.SetActiveRowAsSelected();
list.Hide();
t.focus();
eval(_378.GetOnSelectEvent());
TextBox_CancelBubble(e);
this.m_skipBlur=false;
break;
case (_360):
list.Hide();
eval(_378.GetOnTabEvent());
if(this.m_skipBlur||_378.m_Over){
this.m_skipBlur=false;
_378.m_Over=false;
}
list.SetActiveRowAsSelected();
eval(_378.GetOnSelectEvent());
break;
case (_35f):
list.Hide();
break;
case (_366):
if(this.Paging==true){
break;
}
var _37d;
_37d=list.IsVisible();
if(_378.mode=="smartlist"&&!_37d){
this.smartlistWA=true;
break;
}
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(lio!=this.lio){
list.Hide();
break;
}
}
this.m_skipBlur=true;
this.cursor=xbGetCurPos(t);
if(true==list.Move(EBAMoveAction_UP)){
t.focus();
this.SetValue(list.GetXmlDataSource().GetRowCol(list.GetRowIndex(list.GetActiveRow()),dfi));
}
this.m_skipBlur=false;
break;
case (_365):
if(this.Paging==true){
break;
}
var _37d;
_37d=list.IsVisible();
if(_378.mode=="smartlist"&&!_37d){
this.smartlistWA=true;
break;
}
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(lio!=this.lio){
list.Hide();
break;
}
}
this.m_skipBlur=true;
this.cursor=xbGetCurPos(t);
var r=list.GetActiveRow();
if(null!=r&&list.GetRowIndex(r)==list.GetXmlDataSource().GetNumberRows()-1&&true==list.GetAllowPaging()&&_378.mode=="default"){
list.SetActiveRow(null);
this.Paging=true;
list.OnGetNextPage(EBAScrollToNewBottom,true);
}else{
if(true==list.Move(EBAMoveAction_DOWN)){
t.focus();
this.SetValue(list.GetXmlDataSource().GetRowCol(list.GetRowIndex(list.GetActiveRow()),dfi));
}
}
this.m_skipBlur=false;
break;
case (_375):
if(this.Paging==true){
break;
}
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(lio!=this.lio){
list.Hide();
break;
}
}
this.m_skipBlur=true;
var b=nitobi.Browser;
var lb=list.GetSectionHTMLTagObject(EBAComboBoxListBody);
var _37d;
_37d=list.IsVisible();
if(_37d){
var r=list.GetActiveRow()||list.GetRow(0);
if(null!=r){
var idx=list.GetRowIndex(r);
while(0!=idx){
r=list.GetRow(--idx);
if(!b.IsObjectInView(r,lb)){
break;
}
}
b.ScrollIntoView(r,lb,false,true);
list.SetActiveRow(r);
this.SetValue(list.GetXmlDataSource().GetRowCol(idx,dfi));
}
}
this.m_skipBlur=false;
break;
case (_376):
if(this.Paging==true){
break;
}
if(_378.mode=="smartlist"){
var lio=t.value.lastIndexOf(_378.SmartListSeparator);
if(lio!=this.lio){
list.Hide();
break;
}
}
var _37d;
_37d=list.IsVisible();
if(!_37d){
if(_378.mode!="smartlist"){
list.Show();
}
}else{
this.m_skipBlur=true;
var b=nitobi.Browser;
var lb=list.GetSectionHTMLTagObject(EBAComboBoxListBody);
var r=list.GetActiveRow()||list.GetRow(0);
var idx=list.GetRowIndex(r);
var end=list.GetXmlDataSource().GetNumberRows()-1;
while(idx!=end){
r=list.GetRow(++idx);
if(!b.IsObjectInView(r,lb)){
break;
}
}
if(idx==end&&true==list.GetAllowPaging()&&_378.mode=="default"){
list.SetActiveRow(null);
this.Paging=true;
list.OnGetNextPage(EBAScrollToNewTop,true);
}else{
b.ScrollIntoView(r,lb,true,false);
list.SetActiveRow(r);
this.SetValue(list.GetXmlDataSource().GetRowCol(idx,dfi));
}
this.m_skipBlur=false;
}
break;
default:
}
break;
case (_35c):
if(_37a==_35e){
TextBox_CancelBubble(e);
}
break;
default:
}
_378.SetEventObject(null);
}
catch(err){
}
}
nitobi.prepare=function(){
ebagdl=0;
ebagd1=9999999999999;
s="var d = new Date().getTime();if ((d<"+ebagdl+") || (d>"+ebagd1+")) {alert('Evaluation period has expired.\\n\\nPlease notify your system administrator.\\n\\nPurchase Information:\\n       NITOBI SOFTWARE\\n\\n       www.nitobi.com\\n       sales@nitobi.com         \\n       Telephone: (604) 685-9287\\n       Fax: (604) 648-9090\\n       Toll-Free: 1-866-6EB-APPS\\n                      (1-866-632-2777)');}";
eval(s);
};
if(typeof (nitobi)=="undefined"){
nitobi={};
}
function xbDOM(){
}
nitobi.lang.defineNs("nitobi.browser");
if(nitobi.browser.MOZ){
Document.prototype.loadXML=_Document_loadXML;
Node.prototype.__defineGetter__("xml",_Node_getXML);
Document.prototype.readyState=0;
Document.prototype.__load__=Document.prototype.load;
Document.prototype.load=_Document_load;
Document.prototype.onreadystatechange=null;
Node.prototype._uniqueID=null;
Node.prototype.__defineGetter__("uniqueID",_Node_getUniqueID);
XMLDocument.prototype.transformNode=_XMLDocument_transformNode;
XMLDocument.prototype.transformNodeToObject=_XMLDocument_transformNodeToObject;
}
function _Document_loadXML(_383){
changeReadyState(this,1);
var p=new DOMParser();
var d=p.parseFromString(_383,"text/xml");
while(this.hasChildNodes()){
this.removeChild(this.lastChild);
}
for(var i=0;i<d.childNodes.length;i++){
this.appendChild(this.importNode(d.childNodes[i],true));
}
changeReadyState(this,4);
}
function _Node_getXML(){
return new XMLSerializer().serializeToString(this);
}
function _Document_load(_387){
changeReadyState(this,1);
try{
this.__load__(_387);
}
catch(e){
changeReadyState(this,4);
}
}
function changeReadyState(oDOM,_389){
oDOM.readyState=_389;
if(oDOM.onreadystatechange!=null&&(typeof oDOM.onreadystatechange)=="function"){
oDOM.onreadystatechange();
}
}
_Node_getUniqueID.i=1;
function _Node_getUniqueID(){
if(null==this._uniqueID){
this._uniqueID="mz__id"+_Node_getUniqueID.i++;
}
return this._uniqueID;
}
function EbaConstructValidXpathQuery(_38a,_38b){
try{
var _38c=_38a.match(/(\"|\')/g);
if(_38c!=null){
var _38d="concat(";
var _38e="";
var _38f;
for(var i=0;i<_38a.length;i++){
if(_38a.substr(i,1)=="\""){
_38f="&apos;";
}else{
_38f="&quot;";
}
_38d+=_38e+_38f+EbaXmlEncode(_38a.substr(i,1))+_38f;
_38e=",";
}
_38d+=_38e+"&apos;&apos;";
_38d+=")";
_38a=_38d;
}else{
var quot=(_38b?"\"":"");
_38a=quot+EbaXmlEncode(_38a)+quot;
}
return _38a;
}
catch(err){
}
}
function _XMLDocument_transformNode(_392){
var xs=new XMLSerializer();
var d=xbDOM.create();
this.transformNodeToObject(_392,d);
if(d.childNodes.length>0&&d.childNodes[0].tagName=="transformiix:result"){
return d.childNodes[0].textContent;
}
return nitobi.Browser.HTMLUnencode(xs.serializeToString(d));
}
function _XMLDocument_transformNodeToObject(_395,_396){
var p=new XSLTProcessor();
p.importStylesheet(_395);
var f=p.transformToFragment(this,_396);
while(_396.hasChildNodes()){
_396.removeChild(_396.firstChild);
}
if(_395.xml.match(/<xsl:output method=("text"|'text')/)){
var n=this.createElement("transformiix:result");
n.appendChild(f.childNodes[0]);
_396.appendChild(n);
return;
}
var d=xbDOM.create();
d.loadXML(f.xml);
f=d;
var cn=f.childNodes;
for(var i=0;i<cn.length;i++){
_396.appendChild(this.importNode(cn[i],true));
}
}
function EbaXmlEncode(str){
str=str.replace(/&/g,"&amp;");
str=str.replace(/'/g,"&apos;");
str=str.replace(/\"/g,"&quot;");
str=str.replace(/</g,"&lt;");
str=str.replace(/>/,"&gt;");
return str;
}
function XmlDataIslands(){
}
AX=["Msxml4.DOMDocument","Msxml3.DOMDocument","Msxml2.DOMDocument","Msxml.DOMDocument","Microsoft.XmlDom"];
xbDOM.create=xbDOM_create;
function xbDOM_create(_39e,_39f){
var d=null;
if(nitobi.browser.MOZ){
d=window.document.implementation.createDocument(_39e,_39f,null);
d.addEventListener("load",function(){
changeReadyState(d,4);
},false);
}else{
for(var i=0;!d&&i<AX.length;i++){
try{
d=new ActiveXObject(AX[i]);
}
catch(e){
}
}
if(_39f){
if(_39e){
d.loadXML("<a0:"+_39f+" xmlns:a0=\""+_39e+"\" />");
}else{
d.loadXML("<"+_39f+"/>");
}
}
}
return d;
}
function xbXMLHTTP(){
}
xbXMLHTTP.create=xbXMLHTTP_create;
function xbXMLHTTP_create(){
var x=null;
try{
x=new ActiveXObject("Msxml2.XMLHTTP");
}
catch(e){
try{
x=new ActiveXObject("Microsoft.XMLHTTP");
}
catch(oc){
x=null;
}
}
if(!x&&(typeof XMLHttpRequest)!="undefined"){
x=new XMLHttpRequest();
}
return x;
}
function xbGetCurPos(o){
if(o.createTextRange){
o.focus();
var r=document.selection.createRange().duplicate();
r.moveEnd("textedit",1);
return o.value.length-r.text.length;
}else{
if(o.setSelectionRange){
return o.selectionStart;
}
}
return -1;
}
function xbPutCur(o,x){
if(o.createTextRange){
o.focus();
var r=document.selection.createRange().duplicate();
r.move("character",0-o.value.length);
r.move("character",x);
r.select();
}else{
if(o.setSelectionRange){
o.setSelectionRange(x,x);
}
}
}
function xbHighlight(o,x){
if(o.createTextRange){
o.focus();
var r=document.selection.createRange().duplicate();
r.move("character",0-o.value.length);
r.move("character",x);
r.moveEnd("textedit",1);
r.select();
}else{
if(o.setSelectionRange){
o.setSelectionRange(x,o.value.length);
}
}
}
function xbClipXml(oXml,_3ac,_3ad,_3ae){
var xsl="<xsl:stylesheet version='1.0' xmlns:xsl='http://www.w3.org/1999/XSL/Transform'><xsl:template match='"+_3ac+"'><xsl:copy><xsl:copy-of select='@*'></xsl:copy-of><xsl:apply-templates select='"+_3ad+"'></xsl:apply-templates></xsl:copy></xsl:template><xsl:template match='"+_3ad+"'><xsl:choose><xsl:when test='position()&lt;="+_3ae+"'><xsl:copy-of select='.'></xsl:copy-of></xsl:when></xsl:choose></xsl:template></xsl:stylesheet>";
var x=xbDOM.create();
x.loadXML(xsl);
var newx=xbDOM.create();
oXml.transformNodeToObject(x,newx);
return newx;
}
if(!nitobi.browser.IE){
Document.prototype.createStyleSheet=function(){
var _3b2=this.createElement("style");
this.documentElement.childNodes[0].appendChild(_3b2);
return _3b2;
};
HTMLStyleElement.prototype.__defineSetter__("cssText",function(_3b3){
this.innerHTML=_3b3;
});
}
if(typeof (Eba)=="undefined"){
Eba={};
}
if(typeof (Eba.Dom)=="undefined"){
Eba.Dom={};
}
nitobi.Browser.ConvertXmlDataIsland=function(_3b4,_3b5){
if(null!=_3b4&&""!=_3b4){
var xmls=window.document.getElementById(_3b4);
if(null!=xmls){
var id=xmls.getAttribute("id");
var src=xmls.getAttribute("src");
var d=xbDOM.create();
if(null==src){
d.loadXML(this.EncodeAngleBracketsInTagAttributes(xmls.innerHTML.replace(/>\s+</g,"><"),_3b5));
}else{
d.async=false;
var _3ba=nitobi.Browser.LoadPageFromUrl(src,_3b5.GetHttpRequestMethod());
var _3bb=_3ba.indexOf("<?xml");
if(_3bb!=-1){
d.loadXML(_3ba.substr(_3bb));
}else{
d.loadXML(_3ba);
}
var d2=xbDOM.create();
d2.loadXML(this.EncodeAngleBracketsInTagAttributes(d.xml.replace(/>\s+</g,"><"),_3b5));
d=d2;
}
eval("window.document."+id+"=d;");
var p=(xmls.parentNode?xmls.parentNode:xmls.parentElement);
p.removeChild(xmls);
}
}
};
nitobi.lang.defineNs("nitobi.combo");
nitobi.combo.XmlDataSource=function(_3be,clip,_3c0,_3c1){
try{
this.combo=null;
this.m_Dirty=null;
this.m_LowerCaseXml=null;
if(nitobi.browser.MOZ){
this.m_LowerCaseXml=xbDOM.create();
}
if(_3be!=null){
this.combo=_3c1;
var x=(_3be?_3be.getAttribute("XmlId"):"");
this.SetXmlId(x);
var _3c3=document.getElementById(x);
if(nitobi.browser.MOZ||null==_3c3){
nitobi.Browser.ConvertXmlDataIsland(x,_3c1);
this.SetXmlObject(eval("window.document."+x),clip,_3c0);
}else{
this.SetXmlObject(_3c3);
}
this.SetLastPageSize(this.GetNumberRows());
this.m_Dirty=false;
}else{
this.m_Dirty=true;
this.SetLastPageSize(0);
this.SetNumberColumns(0);
}
}
catch(err){
}
};
nitobi.combo.XmlDataSource.prototype.GetXmlId=XmlDataSource_GetXmlId;
function XmlDataSource_GetXmlId(){
try{
return this.m_XmlId;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.SetXmlId=XmlDataSource_SetXmlId;
function XmlDataSource_SetXmlId(_3c4){
try{
this.m_XmlId=_3c4;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetXmlObject=XmlDataSource_GetXmlObject;
function XmlDataSource_GetXmlObject(){
try{
return this.m_XmlObject;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.SetXmlObject=XmlDataSource_SetXmlObject;
function XmlDataSource_SetXmlObject(_3c5,clip,_3c7){
try{
if(null==_3c5.documentElement){
return;
}
if(nitobi.browser.MOZ){
var d=xbDOM.create();
var xml=_3c5.xml.replace(/>\s+</g,"><");
d.loadXML(xml);
_3c5=d;
this.m_LowerCaseXml.loadXML(xml.toLowerCase());
}
if(clip==true){
_3c5=xbClipXml(_3c5,"root","e",_3c7);
}
this.m_XmlObject=_3c5;
this.SetLastPageSize(this.GetNumberRows());
var _3ca=_3c5.documentElement.getAttribute("fields");
if(null==_3ca){
}else{
var _3cb=_3ca.split("|");
this.SetColumnNames(_3cb);
this.SetNumberColumns(_3cb.length);
}
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetNumberRows=XmlDataSource_GetNumberRows;
function XmlDataSource_GetNumberRows(){
try{
var _3cc=this.GetXmlObject().selectNodes("//e").length;
return parseInt(_3cc);
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetLastPageSize=XmlDataSource_GetLastPageSize;
function XmlDataSource_GetLastPageSize(){
try{
return this.m_LastPageSize;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.SetLastPageSize=XmlDataSource_SetLastPageSize;
function XmlDataSource_SetLastPageSize(_3cd){
try{
this.m_LastPageSize=_3cd;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetNumberColumns=XmlDataSource_GetNumberColumns;
function XmlDataSource_GetNumberColumns(){
try{
return this.m_NumberColumns;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.SetNumberColumns=XmlDataSource_SetNumberColumns;
function XmlDataSource_SetNumberColumns(_3ce){
try{
this.m_NumberColumns=parseInt(_3ce);
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetColumnNames=XmlDataSource_GetColumnNames;
function XmlDataSource_GetColumnNames(){
try{
return this.m_ColumnNames;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.SetColumnNames=XmlDataSource_SetColumnNames;
function XmlDataSource_SetColumnNames(_3cf){
try{
this.m_ColumnNames=_3cf;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.Search=XmlDataSource_Search;
function XmlDataSource_Search(_3d0,_3d1,_3d2){
try{
_3d0=_3d0.toLowerCase();
_3d0=EbaConstructValidXpathQuery(_3d0,true);
var xsl;
var xsl;
if(nitobi.browser.IE){
xsl="<xsl:stylesheet version=\"1.0\" xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\" xmlns:msxsl=\"urn:schemas-microsoft-com:xslt\" xmlns:jstring=\"http://www.ebusiness-apps.com/comboxsl\"  extension-element-prefixes=\"msxsl\" exclude-result-prefixes=\"jstring\">";
}else{
xsl="<xsl:stylesheet xmlns:xsl=\"http://www.w3.org/1999/XSL/Transform\" version=\"1.0\"  >";
}
xsl+="<xsl:output method=\"text\" version=\"4.0\"/>";
if(nitobi.browser.IE){
xsl+="<msxsl:script language=\"javascript\" implements-prefix=\"jstring\">"+"<![CDATA["+"f"+"unction lowerCase(s) "+"{"+"\treturn s.toLowerCase();"+"}"+"]]>"+"</msxsl:script>";
}
xsl+="<xsl:template match=\"/\">"+"<xsl:apply-templates/>"+"</xsl:template>";
if(nitobi.browser.IE){
xsl+="<xsl:template match='//e["+(_3d2==true?"contains":"starts-with")+"(jstring:lowerCase(string(@"+String.fromCharCode(97+parseInt(_3d1))+")),"+_3d0+")][1]'>";
}else{
xsl+="<xsl:template match='//e["+(_3d2==true?"contains":"starts-with")+"(@"+String.fromCharCode(97+parseInt(_3d1))+","+_3d0+")][1]'>";
}
xsl+="<xsl:value-of select='position()-1' />"+"</xsl:template>"+"</xsl:stylesheet>";
var oXSL=xbDOM.create();
oXSL.loadXML(xsl);
var _3d5=oXSL.documentElement;
if((_3d5.tagName.toLowerCase()=="parsererror")||(_3d5.namespaceURI=="http://www.mozilla.org/newlayout/xml/parsererror.xml")){
parseError=new XMLSerializer().serializeToString(oXSL);
}
var _3d6;
if(nitobi.browser.IE){
_3d6=this.GetXmlObject();
}else{
_3d6=this.m_LowerCaseXml;
}
var _3d7=_3d6.transformNode(oXSL);
if(""==_3d7){
_3d7=-1;
}
return parseInt(_3d7);
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.AddPage=XmlDataSource_AddPage;
function XmlDataSource_AddPage(XML){
try{
var _3d9;
var _3da;
if(nitobi.browser.MOZ){
var _3db;
_3db=xbDOM.create();
_3db.loadXML(XML.toLowerCase());
_3da=_3db.selectNodes("//e");
_3d9=this.m_LowerCaseXml.documentElement;
}
var tmp=xbDOM.create();
tmp.loadXML(XML);
var _3dd=tmp.selectNodes("//e");
var root=this.GetXmlObject().documentElement;
this.SetLastPageSize(tmp.selectNodes("//e").length);
for(var i=0;i<_3dd.length;i++){
root.appendChild(_3dd[i]);
if(nitobi.browser.MOZ){
_3d9.appendChild(_3da[i]);
}
}
this.m_Dirty=false;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.Clear=XmlDataSource_Clear;
function XmlDataSource_Clear(){
try{
this.GetXmlObject().loadXML("<root/>");
if(nitobi.browser.MOZ){
this.m_LowerCaseXml.loadXML("<root/>");
}
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetRow=XmlDataSource_GetRow;
function XmlDataSource_GetRow(_3e0){
try{
_3e0=parseInt(_3e0);
var row=this.GetXmlObject().documentElement.childNodes.item(_3e0);
var _3e2=new Array;
for(var i=0;i<this.GetNumberColumns();i++){
_3e2[i]=row.getAttribute(String.fromCharCode(97+i));
}
return _3e2;
}
catch(err){
}
}
nitobi.combo.XmlDataSource.prototype.GetRowCol=XmlDataSource_GetRowCol;
function XmlDataSource_GetRowCol(Row,Col){
try{
var row=this.GetXmlObject().documentElement.childNodes.item(parseInt(Row));
var val=row.getAttribute(String.fromCharCode(97+parseInt(Col)));
return val;
}
catch(err){
return "";
}
}
nitobi.combo.XmlDataSource.prototype.GetColumnIndex=XmlDataSource_GetColumnIndex;
function XmlDataSource_GetColumnIndex(Name){
try{
if(Name==null){
return 0;
}
Name=Name.toLowerCase();
var _3e9=this.GetColumnNames();
if(_3e9!=null){
for(var i=0;i<_3e9.length;i++){
if(Name==_3e9[i].toLowerCase()){
return parseInt(i);
}
}
}
return -1;
}
catch(err){
}
}


