/* Copyright 2010: Thomson Reuters Global Resources. All Rights Reserved. Proprietary and Confidential information of TRGR. Disclosure, Use or Reproduction without the written authorization of TRGR is prohibited. */
function getWestlawFrameReference(strWestlawFrameName){var objWestlawFrameReference=null;if(strWestlawFrameName.toLowerCase()=="_top"){objWestlawFrameReference=window.top}else{var topFrame=getTopWestlawFrame();objWestlawFrameReference=findWestlawFrameReference(topFrame,strWestlawFrameName)}return objWestlawFrameReference}function getTopWestlawFrame(){try{var frameName=getFNFromURL(document.location.href);if(frameName&&unescape(frameName.toLowerCase())!="_top"){return getFrameFromWindow(frameName,window)}}catch(err){}try{if(top.name){return top}}catch(err){return getFrameFromWindow(getFNFromURL(document.location.href),window)}return top}function getFrameFromWindow(strWestlawFrameName,startingWindow){if(startingWindow.name.toLowerCase()==strWestlawFrameName){return startingWindow}try{if(startingWindow.parent.name.toLowerCase()=="_top"){return window.top}}catch(err){return startingWindow}return getFrameFromWindow(strWestlawFrameName,startingWindow.parent)}function findWestlawFrameReference(currentwindow,strWestlawFrameName){topFrame=getTopWestlawFrame();var retval=topFrame;if(currentwindow.name){if(currentwindow.name.toLowerCase()==strWestlawFrameName.toLowerCase()){retval=currentwindow;return retval}}for(var x=currentwindow.length-1;x>=0;x--){retval=findWestlawFrameReference(currentwindow.frames[x],strWestlawFrameName);if(retval!=topFrame){return retval}}return retval}function resetObjWestlawFrameReference(){objWestlawFrameReference=null}function getFNFromURL(strURL){var strFN=GetUrlParm("fn",strURL);if(strFN==""){strFN="_top"}return strFN}function GetUrlParm(name,url){if(url==null||url==undefined){url=window.location.href}name=name.replace(/[\[]/,"\\[").replace(/[\]]/,"\\]");var regexS="[\\?&]"+name+"=([^&#]*)";var regex=new RegExp(regexS,"i");var results=regex.exec(url);if(results==null){return""}else{return results[1]}}function GetTagToPrintItems(){var topFrame=getTopWestlawFrame();return GetTagToPrintItemsRecursive(topFrame)}function GetTagToPrintItemsRecursive(frame){try{if(frame==null||frame==undefined){return""}if(frame.GetTagToPrintSelectedItemsInternal!=null&&frame.GetTagToPrintSelectedItemsInternal!=undefined){var selectedItems=frame.GetTagToPrintSelectedItemsInternal();if(selectedItems!=""){return selectedItems}}var innerFrames=frame.frames;var iframes=frame.document!=null?frame.document.getElementsByTagName("iframe"):[];if(iframes!=null&&iframes.length>0){innerFrames=[];for(var i=0;i<iframes.length;++i){try{innerFrames[innerFrames.length]=iframes[i].contentWindow}catch(e){}}}for(var i=0;i<innerFrames.length;++i){var selectedItems=GetTagToPrintItemsRecursive(innerFrames[i]);if(selectedItems!=""){return selectedItems}}}catch(e){}return""}if(typeof(Sys)!=="undefined"){Sys.Application.notifyScriptLoaded()};
