# HG changeset patch # User Jan Kanis # Date 1400165958 -7200 # Node ID 344cd76f6fd2701a59ea92a85b2e6f92de5ac6f5 # Parent 2143f62809d06eeba56ec1b72dabb5dbce76df2a rename NCBI reference example diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example.html --- a/Blast output page example.html Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,2071 +0,0 @@ - - - - - - - - - - - - - - - -NCBI Blast:Nucleotide Sequence (16 letters) - - - - - - - - - - - - - - -
- - -
- - -
- -
- - - - - - - - - - - -
- - -
  • Your search parameters were adjusted to search for a short input sequence.

- Edit and Resubmit - -[Sign in above to save your search strategy] - - - -How to read this page -Blast report description - -
- - - - - -
- -
- -
-
- -
-
- - -

-
- -
-
-

Nucleotide Sequence (16 letters)

-
- - -
- -
-
-
-
-
RID
-
-PHWP1JNZ014 (Expires on 05-07 22:33 pm) -
-
-
-
-
Query ID
- -
lcl|59987
-
Description
-
None
-
Molecule type
-
nucleic acid
-
Query Length
-
16
-
-
- -
-
-
-
Database Name
-
pdb
-
Description
-
PDB nucleotide database
-
Program
-
BLASTN 2.2.29+
-
-
-
-
-
- -
-
- -
- - - -
- -
-
-
- - - - - - -
-
- -
-
- - - - -
-
- - - - - - -
-
- - - -
-
- -
-
- - - - - - - - - - -
- -
-

- -Alignments - - -

- -
-
-
-
-
- - - -GenBankGraphics - - - -Next -Previous -Descriptions - -
-
-
-
-Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Classic Post- Translocation State (post1, 50s Subunit) -
pdb|3J5A|A29034
-
-
-
- -
- - - - - - - - - - - - - -
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
- -
-
-
Query  1    CGTCCGTCGTGAAGAG  16
-            ||||||||||||||||
-Sbjct  961  CGTCCGTCGTGAAGAG  976
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
- -
-
-
Query  5     CGTCGTGA  12
-             ||||||||
-Sbjct  2591  CGTCGTGA  2598
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  7    TCGTGAA  13
-            |||||||
-Sbjct  839  TCGTGAA  845
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  9     GTGAAGA  15
-             |||||||
-Sbjct  2027  GTGAAGA  2033
-
-
-
-
-
-
-
- - - -GenBankGraphics - - - -Next -Previous -Descriptions - -
-
-
-
-Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre5b, 50s Subunit) -
pdb|3J58|A29034
-
-
-
- -
- - - - - - - - - - - - - -
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
- -
-
-
Query  1    CGTCCGTCGTGAAGAG  16
-            ||||||||||||||||
-Sbjct  961  CGTCCGTCGTGAAGAG  976
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
- -
-
-
Query  5     CGTCGTGA  12
-             ||||||||
-Sbjct  2591  CGTCGTGA  2598
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  7    TCGTGAA  13
-            |||||||
-Sbjct  839  TCGTGAA  845
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  9     GTGAAGA  15
-             |||||||
-Sbjct  2027  GTGAAGA  2033
-
-
-
-
-
-
-
- - - -GenBankGraphics - - - -Next -Previous -Descriptions - -
-
-
-
-Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre5a, 50s Subunit) -
pdb|3J56|A29034
-
-
-
- -
- - - - - - - - - - - - - -
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
- -
-
-
Query  1    CGTCCGTCGTGAAGAG  16
-            ||||||||||||||||
-Sbjct  961  CGTCCGTCGTGAAGAG  976
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
- -
-
-
Query  5     CGTCGTGA  12
-             ||||||||
-Sbjct  2591  CGTCGTGA  2598
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  7    TCGTGAA  13
-            |||||||
-Sbjct  839  TCGTGAA  845
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  9     GTGAAGA  15
-             |||||||
-Sbjct  2027  GTGAAGA  2033
-
-
-
-
-
-
-
- - - -GenBankGraphics - - - -Next -Previous -Descriptions - -
-
-
-
-Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre4, 50s Subunit) -
pdb|3J54|A29034
-
-
-
- -
- - - - - - - - - - - - - -
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
- -
-
-
Query  1    CGTCCGTCGTGAAGAG  16
-            ||||||||||||||||
-Sbjct  961  CGTCCGTCGTGAAGAG  976
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
- -
-
-
Query  5     CGTCGTGA  12
-             ||||||||
-Sbjct  2591  CGTCGTGA  2598
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  7    TCGTGAA  13
-            |||||||
-Sbjct  839  TCGTGAA  845
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  9     GTGAAGA  15
-             |||||||
-Sbjct  2027  GTGAAGA  2033
-
-
-
-
-
-
-
- - - -GenBankGraphics - - - -Next -Previous -Descriptions - -
-
-
-
-Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Classic Pre- Translocation State (pre1a, 50s Subunit) -
pdb|3J52|A29034
-
-
-
- -
- - - - - - - - - - - - - -
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
- -
-
-
Query  1    CGTCCGTCGTGAAGAG  16
-            ||||||||||||||||
-Sbjct  961  CGTCCGTCGTGAAGAG  976
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
- -
-
-
Query  5     CGTCGTGA  12
-             ||||||||
-Sbjct  2591  CGTCGTGA  2598
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  7    TCGTGAA  13
-            |||||||
-Sbjct  839  TCGTGAA  845
-
-
-
-
-
- - - - - - - - - - - - - -
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
- -
-
-
Query  9     GTGAAGA  15
-             |||||||
-Sbjct  2027  GTGAAGA  2033
-
-
-
-
-
-
-
- -
-
-
-
-
-
- -
-
- - - - -
-
-
- - - - - - - - - - - - - -
- -
- - - - -
- -
- - - -
-
- - - -
- - - - - - - - - - - - -
\ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/1.gif Binary file Blast output page example_files/1.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/2.gif Binary file Blast output page example_files/2.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/3.gif Binary file Blast output page example_files/3.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/5.gif Binary file Blast output page example_files/5.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/6.gif Binary file Blast output page example_files/6.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/9.gif Binary file Blast output page example_files/9.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/InstrumentPageStarterJS.js --- a/Blast output page example_files/InstrumentPageStarterJS.js Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,86 +0,0 @@ -(function(){if(typeof ncbi==="undefined")ncbi={};if(ncbi.sg)typeof console!=="undefined"&&console.error&&console.error("The logging JavaScript was added twice in the document. Please include it one time.");else{ncbi.sg=function(){};ncbi.sg.getInstance=function(){if(!ncbi.sg._instance)ncbi.sg._instance=new ncbi.sg;return ncbi.sg._instance};ncbi.sg._instance=null;ncbi.sg._version="26";(function(){var a=navigator.cookieEnabled?true:false;if(typeof navigator.cookieEnabled==="undefined"&&!a){document.cookie= -"testcookie";a=document.cookie.indexOf("testcookie")!==-1?true:false}ncbi.sg.isCookieEnabled=a})();ncbi.sg.appLogIgnore=["ncbi_sessionid","ncbi_clickdisabled"];ncbi.sg.prototype={init:function(){this.isProcessRunning=true;this._setUpMetaTagValues();this._setScrollingEnabled();if(this._cachedVals.ncbi_db&&this._cachedVals.ncbi_db.value.toLowerCase()=="pubmed"&&this._cachedVals.ncbi_report&&this._cachedVals.ncbi_report.value.toLowerCase()=="abstract"&&this._cachedVals.ncbi_resultcount&&this._cachedVals.ncbi_resultcount.value.toLowerCase()== -"1"||this._cachedVals.ncbi_db&&this._cachedVals.ncbi_db.value.toLowerCase()=="pmc"&&this._cachedVals.ncbi_report&&this._cachedVals.ncbi_report.value.toLowerCase()=="record"&&this._cachedVals.ncbi_type&&this._cachedVals.ncbi_type.value.toLowerCase()=="fulltext")ncbi.sg.isHoverEnabled=true;this._setUpPathParts();this._setUpCustomProps();this._addOnScrollListeners();this._send("init");this._scheduleDOMReadyPing();this._sendPrev();this._addPrintPing();this._setBeforeScrollDetails()},_vals:{},_cachedVals:{}, -_hasInitRun:false,_readyPinged:false,_pathParts:{part1:"",part2:"",part3:"",part4:""},_scheduleDOMReadyPing:function(){var a=this,b=function(){return typeof jQuery!=="undefined"&&typeof jQuery.ui!=="undefined"&&typeof jQuery.ui.jig!=="undefined"?typeof jQuery.ui.jig.version!=="undefined"&&jQuery.ui.jig.version?jQuery.ui.jig.version:"unknown":"unknown"},d=function(){var k={},j=jQuery.ui.jig._foundWidgets;for(var t in j)k["jigWidget_"+t]=j[t];k.jigVersion=b();return k},c=function(){if(!a._readyPinged){var k= -{};if(typeof jQuery!=="undefined"&&typeof jQuery.ui!=="undefined"&&typeof jQuery.ui.jig!=="undefined"&&typeof jQuery.ui.jig.scanned!=="undefined")if(jQuery.ui.jig.scanned){k=d();k.jsevent="domready";ncbi.sg._ping(k);a._readyPinged=true}else{if(typeof jQuery.ui.jig.scan!=="undefined"&&jQuery.ui.jig.scan){var j=jQuery.ui.jig.scan;jQuery.ui.jig.scan=function(){var t=j.apply(this,arguments);c();return t}}}else{k.jigVersion="nojig";k.jsevent="domready";ncbi.sg._ping(k);a._readyPinged=true}}};if(document.addEventListener){var e= -function(){document.removeEventListener("DOMContentLoaded",e,false);c()};document.addEventListener("DOMContentLoaded",e)}else if(document.attachEvent){var g=function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",g);c()}};document.attachEvent("onreadystatechange",g)}},_setScrollingEnabled:function(){try{ncbi.sg.isScrollingEnabled=false;var a=ncbi.sgAppsWithScrolling;if(typeof a!=="undefined")for(var b=0;b100&&this.ignoreLengthRestrictions.indexOf(a)===-1)b=b.substr(0,100);this._cachedVals[a]={sProp:a,value:b}}},getVal:function(a){return typeof this._cachedVals[a]!=="undefined"&&this._cachedVals[a]&&typeof this._cachedVals[a].value!=="undefined"? -this._cachedVals[a].value:null},removeAllEntries:function(){for(var a={},b=this.cachedNames.length,d=0;d0?":"+this._pathParts.part2:"",d=this._pathParts.part3.length>0?":"+this._pathParts.part3:"",c=this._pathParts.part4.length>0?":"+this._pathParts.part4:"";a={pagename:a+b+ -d,server:window.location.hostname,sitesect2:a+b,subsect3:a+b+d,subsect4:a+b+d+c,heir1:(a+b+d+c).replace(/:/g,"|")};for(var e in a)this.addEntry(e,a[e]);this._sessionIdCheck();this._staticPageCheck();this._prevHitCheck();this._browserConfigurationSettings();this._hashCheck()},_staticPageCheck:function(){this._cachedVals.ncbi_app&&this._cachedVals.ncbi_app.value.length>0||this.addEntry("ncbi_app","static");this._cachedVals.ncbi_pdid&&this._cachedVals.ncbi_pdid.value.length>0||this.addEntry("ncbi_pdid", -(document.title||"unknown").replace(/\s+/g,""))},_sessionIdCheck:function(){if(!(this._cachedVals.ncbi_sessionid&&this._cachedVals.ncbi_sessionid.value.length>0)){var a="";if(a.length===0){var b=this.getCookie("WebCubbyUser")||this.getCookie("WebEnv");if(b.length>0){b=unescape(b).split("@");if(b.length>1)a=b[b.length-1]}}if(a.length===0)a="NOSESSIONID";this.addEntry("ncbi_sessionid",a)}},getBrowserWidthHeight:function(){var a=this.getViewportWidth(),b=this.getViewportHeight();return{width:a,height:b}}, -_browserConfigurationSettings:function(){var a=this.getBrowserWidthHeight();this.addEntry("browserwidth",a.width);this.addEntry("browserheight",a.height);this.addEntry("screenwidth",screen.width);this.addEntry("screenheight",screen.height);this.addEntry("screenavailwidth",screen.availWidth);this.addEntry("screenavailheight",screen.availHeight);if(document&&document.body){var b=document.body.scrollWidth,d=document.body.scrollHeight,c=d>a.height?"true":"false";this.addEntry("canscroll_x",b>a.width? -"true":"false");this.addEntry("canscroll_y",c);this.addEntry("scrollwidth",b);this.addEntry("scrollheight",d)}if(screen.colorDepth)this.addEntry("colorDepth",screen.colorDepth);else screen.pixelDepth&&this.addEntry("colorDepth",screen.pixelDepth)},_hashCheck:function(){var a=window.location.hash;if(a){a=a.replace("#","");this.addEntry("urlhash",a)}(a=window.location.search.match(/[?&]campaign=([^&]*)/))&&this.addEntry("campaign",a[1])},_createPHID:function(){var a=this._cachedVals.ncbi_sessionid.value, -b=a.substr(0,15)+"9"+(new Date).getTime().toString(),d=a.length;b+=a.substr(d-(32-b.length),d);a={value:b};this.addEntry("ncbi_phid",b);return a},currentPageHitId:null,_prevHitCheck:function(){var a=this.getCookie("ncbi_prevPHID"),b=this._cachedVals.ncbi_phid;a.length>0&&this.addEntry("prev_phid",a);if(!b||!b.value||b.value.length===0)b=this._createPHID();this.currentPageHitId=b.value;var d=this;ncbi.sg._hasFocus&&d.setCookie("ncbi_prevPHID",b.value);var c=window.onfocus;window.onfocus=function(e){d.getCookie("ncbi_prevPHID")!== -b.value&&d.setCookie("ncbi_prevPHID",b.value);typeof c==="function"&&c(e)}},_setUpPathParts:function(){var a=this._cachedVals.ncbi_app,b=this._cachedVals.ncbi_db,d=this._cachedVals.ncbi_pdid,c=this._cachedVals.ncbi_pcid;this._pathParts.part1=a!==undefined?a.value:"";this._pathParts.part2=b!==undefined?b.value:"";this._pathParts.part3=d!==undefined?d.value:"";this._pathParts.part4=c!==undefined?c.value:""},getPerfStats:function(){var a=window.performance;if(!a)return{};var b=a.timing;if(b)b={dns:b.domainLookupEnd- -b.domainLookupStart,connect:b.connectEnd-b.connectStart,ttfb:b.responseStart-b.connectEnd,basePage:b.responseEnd-b.responseStart,frontEnd:b.loadEventStart-b.responseEnd};else return{};if(a=a.navigation){b.navType=a.type;b.redirectCount=a.redirectCount}return b},setPerfStats:function(a,b){var d=this.getPerfStats();for(var c in d){var e=d[c];if(e>=0){var g="jsperf_"+c;if(b)a[g]=e;else a.push(g+"="+e)}}},getExtraRenderStats:function(){var a={SELF_URL:encodeURIComponent(window.location.href)};if(typeof document!== -"undefined"&&typeof document.referrer!=="undefined")a.HTTP_REFERER=encodeURIComponent(document.referrer);return a},setExtraRenderStats:function(a){var b=this.getExtraRenderStats();for(var d in b)a.push(d+"="+b[d])},_send:function(a,b,d){if(typeof d==="undefined"||d===null)d=true;var c=[];if(a==="init"){c.push("jsevent=render");ncbi.sg.renderTime=new Date;if(typeof ncbi_startTime!=="undefined"){c.push("jsrendertime="+(ncbi.sg.renderTime-ncbi_startTime));ncbi.sg.loadTime&&c.push("jsloadtime="+(ncbi.sg.loadTime- -ncbi_startTime))}this.setPerfStats(c);this.setExtraRenderStats(c);c.push("cookieenabled="+(ncbi.sg.isCookieEnabled?"true":"false"))}for(var e in this._cachedVals)ncbi.sg.appLogIgnore.indexOf(e)===-1&&c.push(e+"="+encodeURIComponent(this._cachedVals[e].value));this._sendAl(c.join("&"),b,true,d);this._hasInitRun=true;var g=this;setTimeout(function(){g.isProcessRunning=false;g.runSGProcess()},300)},send:function(a,b){this._send(a,b,false)},_sendPrev:function(){var a=ncbi.sg.getInstance(),b=a.getCookie("clicknext"); -if(b){ncbi.sg._ping(b);a.setCookie("clicknext","")}if(b=a.getCookie("prevsearch")){ncbi.sg._ping(b);a.setCookie("prevsearch","")}if(b=a.getCookie("unloadnext")){ncbi.sg._ping(b);a.setCookie("unloadnext","")}},_sendAl:function(a,b,d,c){if(typeof c==="undefined"||c===null)c=true;if(a.indexOf("jseventms")===-1)a+="&jseventms="+ncbi.sg.getInstance().getMillisecondsSinceSunday();a.match(/jsevent=search/i)&&this._storeNext("prevsearch",a.replace(/jsevent=search(next)?/i,"jsevent=searchnext"),null,c);a+= -"&sgVersion="+ncbi.sg._version;if(a.indexOf("sgSource")===-1)a=this._setSgSource(a,c);c=window.location.port?":"+window.location.port:"";reqURL=typeof __ncbi_stat_url!=="undefined"?__ncbi_stat_url+"?"+a:window.location.protocol+"//"+window.location.hostname+c+"/stat?"+a;this.makeAjaxCall(reqURL,function(){typeof b==="function"&&b()},d)},sendAl:function(a,b,d){this._sendAl(a,b,d,false)},_processingQueue:[],isProcessRunning:false,addSGProcess:function(a){this._processingQueue.push(a)},getSGProcess:function(a){return this._processingQueue.shift(a)}, -runSGProcess:function(){if(this.isProcessRunning||this._processingQueue.length===0||!this._hasInitRun)return false;this.isProcessRunning=true;this.removeAllEntries();var a=this.getSGProcess();this._setUpCachedMetaTagValues(a.metadata);this.addEntry("jsevent",a.eventName);for(var b in a.props)this.addEntry(b,a.props[b]);this._send(a.eventName,a.callbackFnc);var d=this;setTimeout(function(){d.isProcessRunning=false;d.runSGProcess()},300)},noteEventData:function(a,b,d,c){this.addSGProcess({eventName:a, -props:b,metadata:d,callback:c});this.runSGProcess()},setCookie:function(a,b,d){if(window.sessionStorage)try{sessionStorage.setItem(a,b)}catch(c){}var e=new Date;d!==null&&e.setDate(e.getDate()+d);document.cookie=a+"="+escape(b)+(d===null?"":"; expires="+e.toGMTString())+"; domain="+escape(".nih.gov")+"; path=/"},_setSgSource:function(a,b){a+="&sgSource="+(b?"native":"api");return a},_storeNext:function(a,b,d,c){if(typeof c==="undefined"||c===null)c=true;b=this._setSgSource(b,c);this.setCookie(a,b, -d)},getCookie:function(a){var b;if(window.sessionStorage){try{b=sessionStorage.getItem(a)||""}catch(d){b=""}if(b.length>0)return b}if(document.cookie.length>0){b=document.cookie.indexOf(a+"=");if(b!==-1){b=b+a.length+1;a=document.cookie.indexOf(";",b);if(a===-1)a=document.cookie.length;return unescape(document.cookie.substring(b,a))}}return""},getTransport:function(){var a=null;if(window.XMLHttpRequest)try{a=new XMLHttpRequest;this.getTransport=function(){return new XMLHttpRequest}}catch(b){a=null}if(window.ActiveXObject&& -a===null)try{a=new ActiveXObject("Msxml2.XMLHTTP");this.getTransport=function(){return new ActiveXObject("Msxml2.XMLHTTP")}}catch(d){try{a=new ActiveXObject("Microsoft.XMLHTTP");this.getTransport=function(){return new ActiveXObject("Microsoft.XMLHTTP")}}catch(c){a=false}}if(a===null)this.getTransport=function(){return null};return this.getTransport()},makeAjaxCall:function(a,b,d){var c=this.getTransport();c._ncbi_skipOverride=true;c.open("GET",a,d);if(d)c.onreadystatechange=function(){c.readyState=== -4&&b(c)};ncbi.sg.lastPing=c;c.send(null);return c},scrollDetails:{maxScroll_x:0,maxScroll_y:0,currScroll_x:0,currScroll_y:0,hasScrolled:false},scrollEventDetails:{xTenths:0,yTenths:0,xMax:0,yMax:0},_getScrollXYPx:function(){return[window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0]},_getScrollXY:function(){var a=this.getViewportHeight(),b=this.getViewportWidth(),d=document.body.scrollHeight, -c=document.body.scrollWidth,e=this._getScrollXYPx(),g=Math.round(e[1]/a*10)/10;return{xRel:Math.round(e[0]/b*10)/10,yRel:g,viewportHeight:a,viewportWidth:b,pageHeight:d,pageWidth:c}},_addOnScrollListeners:function(){var a=window.onscroll,b=this;window.onscroll=function(){if(ncbi.sg.isScrollingEnabled){b._setScrollDetails();b.scrollDetails.hasScrolled=true;b._addScrollEvent()}else{b._setScrollDetails();b.scrollDetails.hasScrolled=true}if(typeof a==="function")return a()}},getViewportHeight:function(){return window.innerHeight? -window.innerHeight:document.documentElement&&document.documentElement.clientHeight?document.documentElement.clientHeight:document.body!==null?document.body.clientHeight:"NA"},getViewportWidth:function(){return window.innerWidth?window.innerWidth:document.documentElement&&document.documentElement.clientWidth?document.documentElement.clientWidth:document.body!==null?document.body.clientWidth:"NA"},_setScrollDetails:function(){this.scrollDetails.currScroll_y=window.pageYOffset||document.documentElement.scrollTop|| -document.body.scrollTop||0;this.scrollDetails.currScroll_x=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;this.getViewportWidth();this.getViewportHeight();if(this.scrollDetails.maxScroll_y0){e-=parseInt(a.scrollTop);d=true}if(a.scrollLeft&&a.scrollLeft>0){c-=parseInt(a.scrollLeft);b=true}if(a.offsetParent){b=this.findElementPos(a.offsetParent, -b,d);if(b==-1)return-1;c+=b[0];e+=b[1]}else if(a.ownerDocument){var g=a.ownerDocument.defaultView;if(!g&&a.ownerDocument.parentWindow)g=a.ownerDocument.parentWindow;if(g){var k=g.pageXOffset!==undefined?g.pageXOffset:(a.document.documentElement||a.document.body.parentNode||a.document.body).scrollLeft;a=g.pageYOffset!==undefined?g.pageYOffset:(a.document.documentElement||a.document.body.parentNode||a.document.body).scrollTop;if(!d&&a&&a>0)e-=parseInt(a);if(!b&&k&&k>0)c-=parseInt(k);if(g.frameElement){b= -this.findElementPos(g.frameElement);if(b==-1)return-1;c+=b[0];e+=b[1]}}}return[c,e]},addObjData:function(a,b){for(var d in b)a[d]=b[d]},getJoinedData:function(a){var b=[];for(var d in a)b.push(d+"="+encodeURIComponent(a[d]));return b.join("&")},addScrollHeadingData:function(a,b){var d=this.scrollEventDetails.headings;if(d){a["numHeadings."+this._scrollOrder+".scrollInfo"]=d.length;for(var c=0;c=0&&g<=A&&j+y>=0&&j<=B)if(this.isVisible(e)){w.visible=true;a.push(w)}}}return a},_setBeforeScrollDetails:function(a){this._lastScroll=a?a:null;a=this._getScrollXY();var b= -a.yRel;this.scrollEventDetails.xTenths=Math.round(a.xRel*10);this.scrollEventDetails.yTenths=Math.round(b*10);this.scrollEventDetails.xMax=Math.max(this.scrollEventDetails.xTenths,this.scrollEventDetails.xMax);this.scrollEventDetails.yMax=Math.max(this.scrollEventDetails.yTenths,this.scrollEventDetails.yMax);this.scrollEventDetails.headings=this.getVisibleHeadings()},getScrollDetails:function(a,b){if(!ncbi.sg.isScrollingEnabled){this._setScrollDetails();return this.scrollDetails}var d=this.scrollEventDetails; -d.tstamp=(new Date).getTime();var c=this._getScrollXY(),e=null;if(b||!this._lastScroll||d.tstamp-this._lastScroll>1E3){this._scrollOrder=this._scrollOrder!=undefined?this._scrollOrder+1:0;b="yTenths."+this._scrollOrder+".scrollInfo";e="xTenths."+this._scrollOrder+".scrollInfo";var g="maxXTenths."+this._scrollOrder+".scrollInfo",k="maxYTenths."+this._scrollOrder+".scrollInfo",j={};j["duration."+this._scrollOrder+".scrollInfo"]=this._lastScroll?d.tstamp-this._lastScroll:new Date-ncbi.sg.loadTime;j[e]= -this.scrollEventDetails.xTenths;j[b]=this.scrollEventDetails.yTenths;j[g]=this.scrollEventDetails.xMax;j[k]=this.scrollEventDetails.yMax;j["viewportHeight."+this._scrollOrder+".scrollInfo"]=c.viewportHeight;j["viewportWidth."+this._scrollOrder+".scrollInfo"]=c.viewportWidth;j["maxPossibleScrollTenthsY."+this._scrollOrder+".scrollInfo"]=Math.round((c.pageHeight/c.viewportHeight-1)*10);j["maxPossibleScrollTenthsX."+this._scrollOrder+".scrollInfo"]=Math.round((c.pageWidth/c.viewportWidth-1)*10);e=j= -this.addScrollHeadingData(j,a)}this._setBeforeScrollDetails(d.tstamp);return e},getScrollDetailsAr:function(a,b){var d=[];a=this.getScrollDetails(a,b);for(var c in a)d.push(c+"="+encodeURIComponent(a[c]));return d},addScrollDetailsAr:function(a,b,d){b=this.getScrollDetailsAr(b,d);for(d=0;d0)for(;y.length>0;)d(y.pop());var f={jsevent:"unload",ncbi_pingaction:"unload"};if(typeof ncbi_startTime!=="undefined"){f.ncbi_timeonpage=new Date-ncbi_startTime;if(typeof ncbi_onloadTime!=="undefined"&&ncbi_onloadTime)f.ncbi_onloadTime=ncbi_onloadTime-ncbi_startTime}var i=ncbi.sg.getInstance();i.setPerfStats(f,true);i.addScrollDetails(f, -1800-i.getJoinedData(f).length,true);if(!w){ncbi.sg._ping(f);var m="";for(var l in f)m+=l+"="+(l==="jsevent"?"unloadnext":f[l])+"&";m+="ncbi_phid="+i.currentPageHitId;i._storeNext("unloadnext",m,null)}w=true}function b(f){for(var i=y.length-1;i>=-1;i--)if(y[i]===f){y.slice(i,1);break}d(f)}function d(f,i){if(A.indexOf(f.tstamp)===-1){A.push(f.tstamp);B.push(f);c("click",f,i)}}function c(f,i,m,l){if(typeof l==="undefined"||l===null)l=true;var n=f==="click"?"link":"elem",h=i.link,o=i.evt,p=h.id||"", -x=h.name||"",F=h.sid||"",G=h.href||"",C=h.innerText||h.textContent||"";if(C.length>50)C=C.substr(0,50);var H=h.getAttribute?h.getAttribute("ref")||h.ref||"":"",I=h.className?h.className.replace(/^\s?/,"").replace(/\s?$/,"").split(/\s/g).join(",")||"":"";i=[];var D=[],z=h.parentNode;if(z)for(var r=0;r<6&&z!==null;r++){(parId=z.id)&&i.push(parId);if(parClassName=z.className)D=D.concat(parClassName.split(/\s/));z=z.parentNode}z=ncbi.sg.getInstance();r=z.currentPageHitId||"";var q=[];p.length>0&&q.push(n+ -"_id="+encodeURIComponent(p));x.length>0&&q.push(n+"_name="+encodeURIComponent(x));F.length>0&&q.push(n+"_sid="+encodeURIComponent(F));G.length>0&&q.push(n+"_href="+encodeURIComponent(G));C.length>0&&q.push(n+"_text="+encodeURIComponent(C));I.length>0&&q.push(n+"_class="+encodeURIComponent(I));r=z.getBrowserWidthHeight();r.width!==null&&q.push("browserwidth="+encodeURIComponent(r.width));r.height!==null&&q.push("browserheight="+encodeURIComponent(r.height));for(var E in o){r=o[E];r!==undefined&&q.push(E.toLowerCase()+ -"="+r.toString())}q.push("jsevent="+f);H.length>0&&q.push(H);if(typeof jQuery!=="undefined")if(h=jQuery(h).attr("sg")){h=h.split(/\}\s*,\s*\{/);for(r=0;r0)for(;m.length>0;)q.push(m.shift());i.length>0&&q.push("ancestorId="+i.join(","));D.length>0&&q.push("ancestorClassName="+D.join(",").replace(/\s+/g," ").replace(/(^\s|\s$)/g, -""));z.addScrollDetailsAr(q,1800-q.join("&").length,true);if(f==="click"){f=q.join("&").replace("jsevent=click","jsevent=clicknext");r=ncbi.sg.getInstance().currentPageHitId||"";f+="&ncbi_phid="+r;z._storeNext("clicknext",f,null,l)}ncbi.sg._ping(q,true,null,null,l)}function e(f){var i={};if(f){if(f.clientX||f.clientY){var m=ncbi.sg.getInstance()._getScrollXYPx();i.evt_coor_x=f.clientX+m[0];i.evt_coor_y=f.clientY+m[1]}else if(f.pageX||f.pageY){i.evt_coor_x=f.pageX;i.evt_coor_y=f.pageY}i.jseventms= -ncbi.sg.getInstance().getMillisecondsSinceSunday()}return i}function g(f,i,m,l,n){var h={},o=null,p=null;if(typeof i==="string"){o=i;p=m}else{h=e(i);o=m;p=l}if(p){i=typeof p;if(i==="string")p=[p];else if(i==="object"&&!(p instanceof Array)){i=[];for(var x in p)i.push(x+"="+p[x]);p=i}}c(o,{link:f,evt:h},p,n)}function k(f,i,m){var l=[];if(typeof i==="undefined")i=true;if(typeof f==="object"&&!(f instanceof Array))for(var n in f)l.push(n+"="+encodeURIComponent(f[n]));else if(typeof f==="string")l.push(f); -else l=f;f=ncbi.sg.getInstance().currentPageHitId||"";n=null;if(typeof ncbi.sg.loadTime!=="undefined")n=new Date-ncbi.sg.loadTime;var h=l.join("&");if(h.indexOf("jsevent=clicknext")!==-1||h.indexOf("jsevent=searchnext")!==-1||h.indexOf("jsevent=unloadnext")!==-1){f.length>0&&l.push("next_phid="+encodeURIComponent(f));n!==null&&l.push("next_ncbi_timesinceload="+n)}else{f.length>0&&l.push("ncbi_phid="+encodeURIComponent(f));n!==null&&l.push("ncbi_timesinceload="+n)}ncbi.sg.getInstance()._sendAl(l.join("&"), -null,i,m)}var j=window.onerror;window.onerror=function(f,i,m){if(!ncbi.sg.hasNotedErrorEvent){ncbi.sg.getInstance().noteEventData("jserror",{jserror:f,jserrorlocation:i,jserrorline:m,SELF_URL:window.location.href},["ncbi_sessionid","ncbi_phid"]);ncbi.sg.hasNotedErrorEvent=true;if(typeof j==="function")return j(f,i,m)}};var t=window.onbeforeunload;window.onbeforeunload=function(f){a();if(typeof t==="function")return t(f)};var y=[],A=[],B=[],w=false;ncbi.sg.sendElementEvent=function(f,i,m){c(f,i,m, -false)};ncbi.sg.clickTimers=[];if(typeof ncbi.sg.isClickEnabled==="undefined"){for(var v=document.getElementsByTagName("meta"),u=v.length-1,s=true;u>=0;){if(v[u].name.toLowerCase()==="ncbi_clickdisabled"){s=v[u].content.toLowerCase()==="false";break}u--}ncbi.sg.isClickEnabled=s}setClickEvent=function(){var f=function(h){return(h=typeof h.parentNode!=="undefined"?h.parentNode:null)?m(h)?h:f(h):false},i=function(h){h=h.target||h.srcElement;if(typeof h=="undefined"||h==null)return null;if(h.nodeType== -3)h=target.parentNode;m(h)||(h=f(h));return h},m=function(h){var o=typeof h.tagName!=="undefined"?h.tagName.toLowerCase():null,p=false,x=false;if(typeof jQuery!=="undefined")p=jQuery(h).is("button, input[type=button], input[type=submit], input[type=reset]");else if(o==="input"){h=inp.type;p=h=="button"||h=="submit"||h=="reset"}else p=o==="button"?true:false;p||(x=o=="a"||o=="area");return x?"link":p?"button":null},l=function(h,o,p,x){if(!(x&&x=="click"&&h.which&&h.which==3))if(!(!o||m(o)==null)){ncbi.sg.getInstance().setCookie("ncbi_prevPHID", -ncbi.sg.getInstance().currentPageHitId);h=e(h);h.iscontextmenu=x=="contextmenu"?"true":"false";o={evt:h,link:o,tstamp:(new Date).getTime(),floodTstamp:(new Date).getTime()};b(o);ncbi.sg.clickTimers&&window.clearTimeout(ncbi.sg.clickTimers);ncbi.sg.clickTimers=window.setTimeout(function(){ncbi.sg.clickTimers=null},300)}};if(window.addEventListener){window.addEventListener("click",function(h){l(h,i(h),[],"click")});window.addEventListener("contextmenu",function(h){l(h,i(h),[],"contextmenu")},false)}else if(window.attachEvent){document.attachEvent("onclick", -function(h){l(h,i(h),[],"click")});document.attachEvent("oncontextmenu",function(h){l(h,i(h),[],"contextmenu")},false)}if(Event.prototype.stopPropagation){var n=Event.prototype.stopPropagation;Event.prototype.stopPropagation=function(){var h=i(this);if(m(h)!=null)if(this.type=="click")l(this,h,[],"click");else this.type=="contextmenu"&&l(this,h,[],"contextmenu");return n.apply(this,arguments)}}};setClickEvent();ncbi.sg.scanLinks=function(){};ncbi.sg._ping=function(f,i,m,l,n){if(typeof n==="undefined"|| -n===null)n=true;typeof f==="undefined"||f===null||(typeof f==="object"&&f.nodeName!==undefined?g(f,i,m,l,n):k(f,i,n))};ncbi.sg.ping=function(f,i,m,l){ncbi.sg._ping(f,i,m,l,false)};ncbi.sg.loadTime=new Date})();if(!Array.prototype.indexOf)Array.prototype.indexOf=function(a,b){var d=this.length>>>0;b=Number(b)||0;b=b<0?Math.ceil(b):Math.floor(b);if(b<0)b+=d;for(;b0&&k.push("next_phid="+encodeURIComponent(c));j!==null&&k.push("next_ncbi_timesinceload="+ -j);ncbi.sg.getInstance()._sendAl(k.join("&"),null,e,g)},b=ncbi.sg.getInstance().getCookie("hovernext");if(b){a(b);ncbi.sg.getInstance().setCookie("hovernext","")}var d=function(c){var e={};if(c){if(c.clientX||c.clientY){var g=ncbi.sg.getInstance()._getScrollXYPx();e.evt_coor_x=c.clientX+g[0];e.evt_coor_y=c.clientY+g[1]}else if(c.pageX||c.pageY){e.evt_coor_x=c.pageX;e.evt_coor_y=c.pageY}e.jseventms=ncbi.sg.getInstance().getMillisecondsSinceSunday()}return e};jQuery(document).on("mousedown","a[ref*='itool=Abstract-nondef'], #disc_col a", -function(c){c=c.originalEvent;var e=d(c);jQuery(c.target);(new Date).getTime();(new Date).getTime();var g=jQuery(c.target),k=g.id||"",j=g.name||"",t=g.sid||"",y=g.href||"",A=g.innerText||g.textContent||"";if(A.length>50)A=A.substr(0,50);var B=g.getAttribute?g.getAttribute("ref")||g.ref||"":"",w=g.className?g.className.replace(/^\s?/,"").replace(/\s?$/,"").split(/\s/g).join(",")||"":"";c=[];var v=[],u=g.parentNode;if(u)for(var s=0;s<6&&u!==null;s++){(parId=u.id)&&c.push(parId);if(parClassName=u.className)v= -v.concat(parClassName.split(/\s/));u=u.parentNode}u=ncbi.sg.getInstance();var f=u.currentPageHitId||"";f=[];k.length>0&&f.push("link_id="+encodeURIComponent(k));j.length>0&&f.push("link_name="+encodeURIComponent(j));t.length>0&&f.push("link_sid="+encodeURIComponent(t));y.length>0&&f.push("link_href="+encodeURIComponent(y));A.length>0&&f.push("link_text="+encodeURIComponent(A));w.length>0&&f.push("link_class="+encodeURIComponent(w));s=u.getBrowserWidthHeight();s.width!==null&&f.push("browserwidth="+ -encodeURIComponent(s.width));s.height!==null&&f.push("browserheight="+encodeURIComponent(s.height));for(var i in e){s=e[i];s!==undefined&&f.push(i.toLowerCase()+"="+s.toString())}f.push("jsevent=hovernext");B.length>0&&f.push(B);if(typeof jQuery!=="undefined")if(e=jQuery(g).attr("sg")){e=e.split(/\}\s*,\s*\{/);for(s=0;s0&&f.push("ancestorId="+ -c.join(","));v.length>0&&f.push("ancestorClassName="+v.join(",").replace(/\s+/g," ").replace(/(^\s|\s$)/g,""));u.addScrollDetailsAr(f,1800-f.join("&").length,true);c=f.join("&");f=ncbi.sg.getInstance().currentPageHitId||"";c+="&ncbi_phid="+f;ncbi.sg.getInstance()._storeNext("hovernext",c,null)});jQuery(document).on("mouseup mousedown",function(c){!jQuery(c.target).is("a[ref*='itool=Abstract-nondef']")&&jQuery(c.target).parents("a[ref*='itool=Abstract-nondef']").length==0&&!jQuery(c.target).is("#disc_col a")&& -jQuery(c.target).parents("#disc_col a").length==0&&ncbi.sg.getInstance().setCookie("hovernext","")})}}); - -; -// This code creates window.console if it doesn't exist. -// It also creates stub functions for those functions that are missing in window.console. -// (Safari implements some but not all of the firebug window.console methods--this implements the rest.) -(function() { - var names = [ "log", "debug", "info", "warn", "error", "assert", "dir", "dirxml", "group", - "groupEnd", "time", "timeEnd", "count", "trace", "profile", "profileEnd" ]; - - if (typeof(console) === 'undefined' || typeof console === "function" ) { - //"typeof function" is needed see PP-769 - console = {}; - } - - for (var i = 0; i < names.length; ++i) { - if (typeof(console[names[i]]) === 'undefined') { - console[names[i]] = function() { return false; }; - } - } - ncbi.sg.getInstance().init(); -})(); diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/addOrg.jpg Binary file Blast output page example_files/addOrg.jpg has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/black.gif Binary file Blast output page example_files/black.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/blast.js --- a/Blast output page example_files/blast.js Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,308 +0,0 @@ - -function printfire() -{ - // Firefox - if (document.createEvent && window.dispatchEvent) { - printfire.args = arguments; - var ev = document.createEvent("Events"); - ev.initEvent("printfire", false, true); - window.dispatchEvent(ev); - } -} -//This functions handle setting defaults for protein or nulcleotide suite search page when -//one of blast program radio buttons is clicked - not used now -function AdjustMoreOptionsStyle() -{ - var optsEl = document.getElementById("moreopts"); - if(optsEl && optsEl.style.height != "0px") { - optsEl.style.height = optsEl.scrollHeight + "px"; - } -} - -//Strip (taxid:XXX) from organism list selection -//sgRunFunc="AdjustOrganism();" -function AdjustOrganism() -{ - var words = $("qorganism").value.split(" (taxid"); - $("qorganism").value = words[0]; -} - - -/* JS Common to all BLAST pages */ - - -function setResultsTarget() -{ - //var newWin = $("newwin"); - var newWin = this; - var searchFrm = $(newWin.getAttribute("form")); - if(newWin && newWin.checked == true) { - if(newWin.getAttribute("winType") == "random") { - searchFrm.target = "Blast_Results_for_" + Math.floor(Math.pow(10,10) *Math.random()); - } - else { - searchFrm.target = $("resPageTarget").value; - } - } - else { - searchFrm.target = ""; - } -} - -function diffFromDefault(elem) -{ - var currentVal = ""; - var ret = 0; - - if (!(elem)) return; - var defVal = elem.getAttribute("defVal"); //Default value - var elShowDiff = utils.getParent(elem); - if(!elem.type) {//div element for example - //Check if parent elem has "hide" class - if(utils.hasClass(utils.getParent(elem), "hide")) { - currentVal = "hide"; - } - else { - currentVal = "show"; - } - elShowDiff = elem; - } - else if(elem.type == "select-one") { - if(elem[elem.selectedIndex].value) currentVal = elem[elem.selectedIndex].value; - //If Default value is not specified - the first one in the selection list is the default - if (!defVal && elem[0].value) defVal = elem[0].value; - } - else if(elem.type == "select-multiple") { - currentVal = "";//for now - } - else if(elem.type == "checkbox") { - //alert("defVal1=" + elem.id + " " + defVal); - //var defVal = elem.defVal; //Default value - //alert("defVal2=" + defVal); - if(elem.checked == true) currentVal = "checked" - else currentVal = "unchecked"; - } - else { - currentVal = elem.value; - } - - - var numdiff = parseInt($("NUM_DIFFS").value,10); - var optsNumDiff = parseInt($("NUM_OPTS_DIFFS").value,10); - if(defVal != currentVal) { - if(!utils.hasClass(elShowDiff, "nondef")) { - utils.addClass(elShowDiff, "nondef"); - numdiff++; - if(utils.hasClass(elem,"opts")) optsNumDiff++; - } - ret = 1; - } - else { - if(utils.hasClass(elShowDiff, "nondef")) { - utils.removeClass(elShowDiff, "nondef"); - //alert("noDiff-" + elem.id); - if(numdiff != 0) numdiff--; - if(utils.hasClass(elem,"opts")) optsNumDiff--; - } - ret=0; - } - $("NUM_DIFFS").value = numdiff; - $("NUM_OPTS_DIFFS").value = optsNumDiff; - if(numdiff > 0) { - $("diffMes").style.display = "inline"; - } - else { - $("diffMes").style.display = "none"; - } - //alert(elem.id + " " + $("NUM_DIFFS").value); - return ret; -} - -function setDefalValue(elem) -{ - var currentVal; - var defVal = elem.getAttribute("defVal"); //Default value - if(elem.type == "select-one") { - //If Default value is not specified - the first one in the selection list is the default - if(!defVal) defVal = elem[0].value; - for(j=0; j < elem.options.length; j++) { - if(elem.options[j].value == defVal) { - elem.options[j].selected = true; - break; - } - } - } - else if(elem.type == "checkbox" || elem.type == "radio") { - if(!defVal) defVal = "checked"; - if(defVal == "checked") elem.checked = true - else elem.checked = false; - } - else { - if(!defVal) defVal = ""; - elem.value = defVal; - } - - var elShowDiff = utils.getParent(elem); - if(utils.hasClass(elShowDiff, "nondef")) { - utils.removeClass(elShowDiff, "nondef"); - } - //alert(elem.id + " " + $("NUM_DIFFS").value); -} - -function newResultsWinInit() { - jQuery("[class='newwin']").each(function(index) { - utils.addEvent(this, "click", setResultsTarget, false); - }); -} - -function resetOrganismSuggest(orgEntryElem) -{ - //suggestHint is in the hidden field used for SRA - var defaultMessage = ($("suggestHint")) ? $("suggestHint").value : "Enter organism name or id--completions will be suggested"; - var suggestHint = $("qorganism").getAttribute("suggestHint"); - if(suggestHint) defaultMessage = suggestHint; - if(orgEntryElem.value == "") { - orgEntryElem.value = defaultMessage; - } - if(orgEntryElem.value == defaultMessage) { - utils.addClass(orgEntryElem,"orgHint"); - } -} - -function setupOrganismSuggest(orgEntryElem) -{ - resetOrganismSuggest(orgEntryElem); - utils.addEvent(orgEntryElem, "focus", function() { - clearOrgSuggest(orgEntryElem); - }, false); -} - -function clearOrgSuggest(orgEntryElem) -{ - if(utils.hasClass(orgEntryElem,"orgHint")) { - orgEntryElem.value=""; - utils.removeClass(orgEntryElem,"orgHint"); - } -} - -function InitCustomButton(bn) -{ - utils.addEvent(bn, "mouseover", function() {this.src = this.getAttribute("mouseovImg");}, false); - utils.addEvent(bn, "mouseout", function() {this.src = this.getAttribute("mouseoutImg");}, false); - utils.addEvent(bn, "mousedown", function() {this.src = this.getAttribute("mousedownImg");}, false); - utils.addEvent(bn, "mouseup", function() {this.src = this.getAttribute("mouseupImg");}, false); -} - -function showHideElem(id,hide) -{ - if($(id)) { - if(hide) { - if(!utils.hasClass($(id),"hidden")) utils.addClass($(id), "hidden"); - } - else { - if(utils.hasClass($(id),"hidden")) utils.removeClass($(id), "hidden"); - } - } -} - -function resetOrganismControls(orgEntryElem) { - resetOrganismSuggest(orgEntryElem); - if ($("orgExcl")) $("orgExcl").checked = false; - utils.replaceInHtml("", $("orgs")); - if ($("frOrgs")) utils.replaceInHtml("", $("frOrgs")); - if ($("numOrg")) $("numOrg").value = 1; -} - -function AddOrgRow(e,orgName,exclName) { - e = e || window.event; - utils.preventDefault(e); - var checkedExclude = new Array(); - var orgDict = jQuery($($("qorganism"))).ncbiautocomplete("option","dictionary"); - orgDict = (!orgDict || orgDict == "") ? "taxids_sg" : orgDict; - var len = $("qorganism").getAttribute("size"); - - var newOrgFieldID = "qorganism" + $("numOrg").value; - var newOrgField = "
"; - if (exclName != "") { - newOrgField += "" + - "" + - ""; - } - newOrgField += "
"; - if (navigator.userAgent.match(/ie/i)) { - for (i = 1; i < $("numOrg").value; i++) { - if ($("orgExcl" + i)) checkedExclude[i] = $("orgExcl" + i).checked; - } - } - if (!navigator.userAgent.match(/firefox/i)) { - jQuery($($(orgs))).append(newOrgField,true); - } - else { - utils.insertInHtml(newOrgField, $("orgs")); - } - - if (navigator.userAgent.match(/ie/i)) { - for (i = 1; i < $("numOrg").value; i++) { - if ($("orgExcl" + i)) $("orgExcl" + i).checked = checkedExclude[i]; - } - } - setupOrganismSuggest($(newOrgFieldID)); - jQuery($($(newOrgFieldID))).ncbiautocomplete(); - $("numOrg").value++; -} - -function adjustOrgVal(orgEntryElem) -{ - //if (utils.hasClass($("searchForm").EQ_MENU, "orgHint")) $("searchForm").EQ_MENU.value = ""; - clearOrgSuggest(orgEntryElem); - if ($("numOrg")) { - for (i = 1; i < $("numOrg").value; i++) { - if ($("qorganism" + i)) { - clearOrgSuggest($("qorganism" + i)); - } - } - } -} - -function getUrlCompForEntryField(elem) { - var url = ""; - if (elem && elem.value != "") { - url = "&" + elem.name + "=" + escape(elem.value); - } - return url; -} - - -function getUrlCompForCheckedField(elem) { - var url = ""; - if (elem && elem.checked) { - url = "&" + elem.name + "=" + elem.value; - } - return url; - -} - -function getUrlCompForOptionsField(elem) { - var url = ""; - if (elem) { - url = "&" + elem.name + "=" + elem[elem.selectedIndex].value; - } - return url; -} - -function getUrlCompForMultiOptionsField(elem) { - var url = ""; - if (elem) { - for (i = 0; i < elem.options.length; i++) { - if (elem.options[i].selected) { - url += "&" + elem.name + "=" + elem.options[i].value; - } - } - } - return url; -} - - -utils.addEvent(window, 'load', newResultsWinInit, false); - diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/blastReq.css --- a/Blast output page example_files/blastReq.css Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,332 +0,0 @@ -#msgR .info { -background-color: #dfd; -padding: 4px; -border: solid 1px green; -color: green; -} - -dl.summary dt { -float: left; -width: 8em; -clear:left; -margin: 0; -text-align: right; -padding-right: 1em; -color: #666; -} - -dl.summary dd { -padding-left: 0.5em; -display: block; -margin-left: 7em !important; -margin: 0; -} -dl.summary dt, dl.summary dd { -margin-bottom: 0.5em; -} -a.help -{ -float:right; -font-size: 110%; -} - -dl.summary label { -display: inline; -} - -dl.summary tr th label { -padding: 0; -margin-right:0; -} -table.options { -border: solid 1px #ccc; -border-right: solid 1px #ccc; -} - -table.options td, -table.options td.frh { -font-size: 90%; -_font-size: 85%; -} - -table.options label.rb { -border-right: solid 1px #ccc; -margin-right: 0.5em; -padding-right: 2.0em; -} - -table.options tr td { -_font-size: 90%; -padding-left: 0.5em; -} - -table.options { -/*border-collapse: collapse;*/ -margin-left: 0; -padding-left: 0; -width: 62em; -} - -table.options td label { -font-size: 90%; -} - -table.options th label, -table.options td label { -margin-right: 0; -_position: relative; -_top: -0.1em; -} - -table.options tr.hdr td, -table.options tr.hdr th { -padding: 2px; -border: solid 1px #ccc; -background-color: #ddd; -} - -table.options td, table.options td.frh { -padding: 0.25em 0; -vertical-align: center; -} - -table.options th { -padding-right: 1em; -text-align: right; -padding-left: 1em; -} - -/* -*:focus{ -background-color: white !important; -} -*/ - -table.options select,table.options input, #graphic input{ -border: solid 1px #888; -padding: 1px; -} - -select { -font-size: 90%; -} - -select option { -padding-right: 0.5em; -} - -input.cb, table.options input.cb { -border: none; -} - -select { -margin-right:1em; -} - -table.options tr { -background-color: #eee; -} - -table.options tr.odd { -background-color: #e0e0e0; -} - -table.options th { - -background-color: white; -} - -table.options tr.paramSet td -{ - border-top: solid 2px white; -} - - - - -.resetAll -{ -font-weight: normal; -padding: 0.5em; -font-size: 90%; -margin-left:5em; -} - -.button { -background-color: #ccc; -padding: 0.25em 0.25em; -color: black; -border: outset 3px #eee; -_border: outset 3px #eee; -font-size: 90%; -_padding:0; -font-weight: bold; -height:25px; -_height:22px; -} - -.fbtn { -margin-bottom: 0.5em; -} - -.note { -font-size: 80%; -color: green; -background-color: #ffc; -margin-left: 2em; -padding: 3px; -} -.instr { - margin-left: 1em; - color: #666; -font-size: 90%; -} -.smaller { -font-size: 90%; -font-weight: normal; -} - -/* Results Page styles */ - -#ridRes -{ - background-color: #FC9; - padding:5px 5px; -} - - -span dd.hidden,dt.hidden,dd.hidden span -{ - display:none; -} - -dl.query .query, -dl.title .title, -dl.entrez .entrez, -dl.db .db -{ - display:block; -} - - -dl.entrez span.entrez -{ - display:inline; -} - -.hidden { -display: none; -} -.hide { -display: none; -} -.shown { -display: block; -} - - - -table.megaBlast tr.psiBlast, -table.blastn tr.psiBlast, -table.blastx tr.psiBlast, -table.tblastn tr.psiBlast, -table.tblastx tr.psiBlast, -table.discoMegablast tr.psiBlast -{ -display: none; -} - - -table.GlobalAln .xgl, -body.GlobalAln div.xgl, -body.GlobalAln dt.xgl, -body.GlobalAln dd.xgl, -body.GlobalAln span.xgl, -body.GlobalAln table.xgl -{ -display: none; -} - -.dispType -{ - /*background-color:White; - border:solid 1px black;*/ - border-top:solid 2px gray; - border-left:solid 2px gray; - font-size:90%; - padding-left:2px; - -} - -.newwin { -border: none; -} - -table.options .helplink -{ - font-weight:bold; - position:absolute; - right:0; -} - -div#query label -{ - display: inline; - font-weight:bold; - padding-right:1em; -} -#NEW_VIEW -{ - _margin-left:-2px; -} - - -table.blastp *.blastn, -table.psiBlast *.blastn, -table.phiBlast *.blastn, -table.blastx *.blastn, -table.tblastn *.blastn, -table.tblastx *.blastn -{ -display: none; -} - -#formatTable th.col1 { -width: 8em; -vertical-align: top; -} -/* -#formatTable .helplink span { -position: relative; -} -*/ -#org -{ - margin-top:2em; -} -#qorganism -{ - /*display:block;*/ -} -.fi -{ - position:relative; -} - -a#organismHelp -{ - margin-top:-1.5em; -} - -table.options tr.paramSet td.hd { -padding-right: 1em; -text-align: right; -padding-left: 1em; -background-color:White; -font-weight:bold; -border-top:none; -} -.oExcl -{ - margin-left:2px; -} diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/blastRes.css --- a/Blast output page example_files/blastRes.css Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,262 +0,0 @@ -a#refPage -{ - margin-left:3em; -} - -a.resLink -{ - margin-left:1em; - display:none; -} - -a.resLinkhidden -{ - display:none; -} - - -#cddResults -{ - float:right; - margin-top:-2em; - margin-right:1em; - color:#336699; - font-size:100%; -} - -#cddResults.showing { - background-image: url(images/down.gif); -} - - - -div.inlineDiv -{ - display:inline; -} - -span.reslink -{ - display:none; -} - -div.statPage *.statPage, -div.resPage *.resPage -{ - display:inline; -} - -div.resHeader *.hidden -{ - display:none; -} - -#cddInfo -{ - text-align:center; -} -#cddDesc -{ - font-weight:bold; -} -div#desctbl -{ -border: solid 1px #018aac; -/*min-width: 1000px;*/ -margin: none; -width: 100%; -background-color:White; -/*line-height:0; -_line-height:0;*/ -} - -table#descs -{ -font-family: Verdana, Sans-Serif; -font-size: 90%; -_font-size: 86%; -border-collapse: collapse; -/*min-width: 600px;*/ -width: 100%; -} - -table#descs th a { -text-decoration: none; -color: #00c; -} - -table#descs th a:visited { -color: #00c; -} - -table#descs th a:hover {position: relative; -text-decoration: underline; -} - -table#descs tr th.l, -table#descs tr td.l { -text-align: left; -} - -table#descs tr th.sp { -background-color: #def; -} - -table#descs tr th, -table#descs tr td { -text-align: center; -padding: 1px 4px; -} - -table#descs tr.first th { -padding-left:18px; -border-left: solid 1px #A0ceff; -border-top: solid 1px #A0ceff; -border-bottom: solid 1px #018aac; -border-right: solid 1px #018aac; -padding-right: 8px; -/*background-color: #01d5ff;*/ -background-color: #9cf; -/*font-size: 92%;*/ -white-space:normal; -line-height: 1.2em -} - - -table#descs td { -border: solid 1px #ccc; -border-width: 0px 1px; -white-space:nowrap; -overflow: hidden; -} - -.slink { -font-size: 90%; -font-weight: normal; -} - -table#descs tr.first th.sel { -background: #9cf url(images/up.gif) no-repeat center left; -padding-left: 18px; -padding-right: 18px; -} - -div.lim -{ -/*overflow: hidden;-this used to work in Firefox 2- comment for now and set the width */ -width: 35em; -display: inline-block; -height: 1.3em; -} - -table#descs tr:hover { -background-color: #def; -} - -pre -{ - font-size:110%; - _font-size:100%; - line-height:1; -} - -#msg -{ - white-space:normal; - border-color:#cccccc; - padding:0; - margin: 0; - margin-top:2px; -} -#msg li -{ - display:none; - padding:0; - margin: 0; - text-indent: 0; -} -#msg li.warning, #msg li.error ,#msg li.info -{ - display:block; -} - -#msg ul -{ - margin:0; - padding:0; -} - -table#statInfo -{ - border: solid 1px #ccc; - background-color: #eee; - width: 100%; -} - -table#statInfo tr.odd { -background-color: #e0e0e0; -} - -.READY, .UNKNOWN -{ - display:none; -} - -p.WAITING -{ - margin-top:1em; -} - -#frmPage -{ - margin-left:1em; -} - -span.Gene_PubMedLinks -{ - color: Green; font-weight: bold; -} - -ul.msg li p -{ - display:none; -} - -.msg li p.warning, .msg li p.error, .msg li p.success,.msg li p.info -{ - display:block; -} - -.mdlbox -{ - white-space:pre; - background-color:Transparent; - border:none; -} - -#blastErr -{ - white-space:normal; -} - - - -#RSIFrameNoRes,#RSIFrameDesc,#RSIFrameAln -{ - border:none; - width:519px; - height:35px; - margin:0px auto; -} - - -a.ui-ncbitoggler.hidden, a.ui-ncbitoggler-open.hidden -{ - display:none; -} - -.smn { - display: inline-block; - height: 16px; - width: 16px; -} diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/dynFormatRes.css --- a/Blast output page example_files/dynFormatRes.css Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,623 +0,0 @@ -/* style changes for redesign begin*/ -a.gbd -{ - text-decoration:none; -} - -tr.dflLnk td span -{ - font-size:78%; - display:none; - text-align:center; -} -a.dflSeq -{ - color:#369; - text-decoration:underline; - width:auto; -} -table.defln tr.dflLnk a -{ - margin-right:auto; - padding-left:0; -} - -.alnParLinks -{ - float:right; -} - -.alnSeqLinks -{ - float:right; - margin-right:1em; -} - - -.seqlinks select -{ - padding:0; -} - -.dlfRow div -{ - font-size:90%; -} - -.dlfRow -{ - display:inline; - font-size:110%; -} - -.dlfRow.hidden -{ - display:none; -} -.dlfRow label -{ - font-size:87%; - display:inline; - color:#606060; - font-weight:bold; -} - -.dlfRow span.r label -{ - padding-left:0.8em; -} - - -div.relInf -{ - font-family: Verdana, Sans-Serif; - font-size: 80%; - float:right; - width:21%; - border-top:solid 2px gray; - margin-top:-1em; - margin-right:3.5em; - left:3em; - max-width:25em; - padding-left:1em; - position:relative; - white-space:normal; -} - -div.relInf a -{ - padding-right:0.2em; -} - -.rlLink -{ - padding-left:0.2em; -} -.relInf label -{ - font-size:110%; - color:brown; - font-weight:bold; -} -div#content -{ - min-width:70em; -} - -.dflLnk a -{ - font-size:90%; -} -a.dflSeq -{ - width:auto; - font-weight:normal; -} - - -#cntDesc,#cntDesc_psiw -{ - margin-bottom:0.2em; - display:inline-block; - width:20em; -} -#cntDesc span,#cntDesc_psiw span -{ - margin-right:0.5em; -} - -#cntDesc a,#cntDesc input,#cntDesc_psiw a,#cntDesc_psiw input -{ - margin-left:0.5em; -} - -#cntSelNone,#cntShAll -{ - margin-left:0.2em; -} - -.toolsCtr -{ - color:Blue; -} - -table.ui-ncbigrid th span.slink a -{ - display:inline; - padding-right: 0; -} -table.ui-ncbigrid th.sp -{ - font-weight:bold; -} - -table.ui-ncbigrid th span.slink -{ - margin-left:0.2em; -} - -table.ui-ncbigrid td { - white-space:nowrap; -} -table.ui-ncbigrid td.c3 -{ - /*padding-left:0.8em;*/ -} -table.ui-ncbigrid caption -{ - font-size:0; - line-height:0; -} -#content h3.cap,#content h3.cap a.ui-ncbitoggler.ui-widget, #content h3.cap a.ui-ncbitoggler-open -{ - color:#4d4d4d; - text-align:left; - margin:0 0 0.5em 0; -} - -#content div.cap,#content div.cap a.ui-ncbitoggler.ui-widget, #content div.cap a.ui-ncbitoggler-open -{ - color:#4d4d4d; - text-align:left; - margin:0 0 0.5em 0; - letter-spacing:-1px; - font-size:110%; - font-weight:bold; -} - -#descriptions div.caption-exists { - margin: 0; -} - -/**********decrition toolbar styles *********/ - -div.cnf { - -moz-border-bottom-colors: none; - -moz-border-image: none; - -moz-border-left-colors: none; - -moz-border-right-colors: none; - -moz-border-top-colors: none; - background: url("images/cnf.png") repeat scroll 0 0 transparent; - border-style: solid none none; - border-width: 1px medium medium; - /*clear: left;*/ - height: 22px; - /*overflow: auto;*/ - width: 100%; -} - -ul.ui-ncbilocalnav li.has-child a.button_config { - background: url("/portal/portal3rc.fcgi/3493904/img/81796") no-repeat scroll right center transparent !important; - width: 22px; - height:22px; - margin-left:12em; -} - -#li-config -{ - float:right; - width:17em; -} -div#descTblCtrl ul.ui-ncbilocalnav li -{ - border-right:none; -} - - -.cfg -{ - font-size:90%; -} - - -.oneSeqAln .hsp label -{ - color:#606060; - font-size:95%; - padding-right:0.5em; -} - -.oneSeqAln pre -{ - margin-top:0.5em; -} - -.aln_feat label -{ - color: #606060; - font-size: 95%; - padding-right: 0.5em; -} -.oneSeqAln .dflLnk.aln_feat -{ - padding-bottom:1em; -} -div.oneSeqAln h4 -{ - border:none; - font-size:100%; - font-weight:normal; - letter-spacing:normal; - margin:0; -} - -.oneSeqAln .dflLnk -{ - width:56em; -} -.aln_feat a -{ - margin-left:1em; - display:block; -} -.dflLnk.aln_feat div -{ - /*display:inline-block; */ - margin-left:5em; - margin-top:-1em; -} -.aln_frame.shown -{ - display:block; -} -/*align params styles change */ - -table.alnParams -{ - border-left:none; - border-right:none; - margin-top:0.5em; - width:49em; -} - -table.alnParams th -{ - background-color:Transparent; - border:none; - text-align:left; -} - -table.alnParams td -{ - border:none; -} - - -.alnAll -{ - line-height:normal; - margin-top:1em; -} - -.alnAll div -{ - width:70%; -} - -/**new config staff begin**/ -.popDl -{ - display:none; -} -.popDl div -{ - margin-top:0.5em; -} -.popDl div.tl -{ - margin-top:0; - font-weight:bold; -} -a.button_config { - background: url("images/cnfButn.png") no-repeat scroll right center transparent !important; - width: 22px; - height:22px; - margin-left:12em; - float:right; -} - -a.toolsCtr,span.csLinks a -{ - margin-left:8px; - float:left; - cursor:pointer; -} - -a.toolsCtr[disabled] { - cursor: default; -} - - -a.toolsCtr SPAN -{ - color: #14376c; - /*line-height: 22px;*/ - padding-left: 15px; - background-repeat: no-repeat; - background-position:left center; -} - -a.toolsCtr[disabled] SPAN,a.toolsCtr[disabled] -{ - color:#C2C2C2; -} - -a.dnld span -{ - background-image: url("images/dndl.png"); -} - -a.dnld[disabled] span -{ - background-image: url("images/dndl_dsb.png"); -} - -a.dialog -{ - padding-right: 18px; - background:transparent url(images/dialog.png) no-repeat scroll right center; - text-decoration:none; -} - -a.dialog[disabled] { - background-image: url("images/dialog_dsb.png"); -} - - -a.alnNav span -{ - background-image: url("images/align_Normal.png"); -} - -a.alnNav -{ - text-decoration:none; -} - - -a.navNext span -{ - background-image: url("images/next_Normal.png"); -} - - -a.navNext[disabled] span -{ - background-image: url("images/next_Inactive.png"); -} - - -a.navPrev span -{ - background-image: url("images/prev_Normal.png"); -} - - -a.navPrev[disabled] span -{ - background-image: url("images/prev_Inactive.png"); -} - - -a.navBack span -{ - background-image: url("images/table_Normal.png"); -} - -.alnRn -{ - float:left; -} - - -/* styles to change per discusssion with Mark begin*/ -.dflLnk a -{ - padding-left:0; -} - - -table.ui-ncbigrid th { - padding-left:0.3em; - padding-right:0; - text-align:center; -} - -table.ui-ncbigrid td { - padding-left:0.4em; - padding-right:0.4em; - text-align:center; -} - -table.ui-ncbigrid td.c2,table.ui-ncbigrid td.c1 { - text-align:left; -} - -table.ui-ncbigrid td.c3{ - padding:0.363em 0.25em; -} - - -table.ui-ncbigrid th a { - padding-right: 5px; -} -table.ui-ncbigrid th.c0 -{ - width:25px; - padding:0; -} - -.dflnDth -{ - width:100%; -} -div.lim { - width: 14em; -} - -table.ui-ncbigrid th.c8,table.ui-ncbigrid th.c9 { - padding-right: 0.3em; -} -.c8,.c9 -{ - font-size:80%; -} - - -td.lim.l.c2,td.lim.l.c1 -{ - overflow:hidden; -} -a.spr -{ - border-right:none; -} - - -.psiInp -{ - margin-left:1em; - margin-top:0.5em; -} - - -.c8 input -{ - border:none; -} -table.ui-ncbigrid td.c8 -{ - padding-left:1.5em; -} - -tr.psi_new td -{ - background-color:#FFFF99; - border-top:solid 4px white; - border-spacing:3px; - border-collapse:collapse; - line-height:normal; -} -/* accessibility setting */ -tr.dflLnk td span.psiNw,tr.first th span,a.button_config span, a span.accsb,.dflLnk label.accsb -{ - display:inline; - position:absolute; - left:-9999px; -} - -div.tgl -{ - margin-top:-1em; -} -.shcl -{ - float:right; -} - -/* styles to change per discusssion with Mark end*/ - -.alnRn a -{ - padding-right:1em; -} -.alnAll .moreHsps -{ - font-family: Verdana, Sans-Serif; - font-size: 75%; - margin-top:-2.5em; - width:58%; -} -.erm -{ - background-color:#FFFFCC; - padding:0.5em; -} - -#debug,.ind,.alnMsgS .db,.erm .db -{ - display:none; -} - -.tmsAln label -{ - font-size:93%; - display:inline; - color:#606060; - font-weight:bold; -} -.alnAll .tmsAln, .tmsAln div -{ - width:100%; - margin-bottom:-1em; -} -.tmsAlnPar -{ - margin-top:-1em; -} -/*debug info styles begin */ - - -/* use those styles only in debug version - -.alnMsg -{ - border:solid 1px black; -} - -.alnMsgS.hidden,.alnMsgS .db -{ - display:block; -} - -.oneSeqAln -{ - border:1px solid #C8C8C8; -} - -#debug,tr.dflLnk td span.ind -{ - display:inline; -} -.c0 -{ - width:30px; -} -/*debug info styles end */ - - - -/**new config staff end**/ -/* -ul.ui-ncbilocalnav li, ul.ui-ncbilocalnav { - background-color: #F4F4F4; - background-image: -moz-linear-gradient(center top , #FFFFFF, #F4F4F4); -} -ul.ui-ncbilocalnav li { - border-right: 1px solid #C4C4C4; -} -*/ -/**********decrition toolbar styles end*********/ - - -/* style chenges for redesign end*/ diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/firefox-descriptions.css --- a/Blast output page example_files/firefox-descriptions.css Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -table.dbInfo caption { - -} \ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/format.js --- a/Blast output page example_files/format.js Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,270 +0,0 @@ - -function UpdateDisplayTypes(displayTypes) { - dispMenu = displayTypes.options; - for(i=0; i < dispMenu.length; i++) { - //if(!utils.hasClass(displayTypes,"psiBlast") && !utils.hasClass(displayTypes,"phiBlast") || - if($("stepNumber").value == "" || $("stepNumber").value < 2) { - if(dispMenu[i].value.indexOf("PSSM") != -1) { - dispMenu[i--] = null; - //break; - } - } - } -} - -function GetIndexByValue(selectElem,val) { - var idx = 0; - var opts = selectElem.options; - for(i=0; i < opts.length; i++) { - if(opts[i].value == val) { - idx = i; - break; - } - } - return idx; -} - -function resetAdvView(show) -{ - var advView = $("advView"); - if(show) { - if(utils.hasClass(advView, "hidden")) { - utils.removeClass(advView, "hidden"); - } - } - else { - utils.addClass(advView, "hidden"); - } -} - - -function ShowOrHide(hide,elem) -{ - if(hide) { - if(!utils.hasClass(elem, "hidden")) { - utils.addClass(elem, "hidden"); - } - } - else { - if(utils.hasClass(elem, "hidden")) { - utils.removeClass(elem, "hidden"); - } - } -} - -function UpdateFormatTypes(form) { - var selectedObjType = form.FORMAT_OBJECT[form.FORMAT_OBJECT.selectedIndex].value; - var hideAdvView = false; - bioseqFormatHide = true; - pssmFormatHide = true; - pssmScFormatHide = true; - formatTypeHide = true; - if (selectedObjType == "Alignment") { - formatObjectSelectedIndex = 0; //HTML - formatTypeHide = false; - hideAdvView = true; - } - if (selectedObjType == "PSSM") { - formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"Text"); - pssmFormatHide = false; - } - if (selectedObjType == "PSSM_Scoremat") { - formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"ASN.1"); - pssmScFormatHide = false; - } - else if (selectedObjType == "Bioseq") { - formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"ASN.1"); - bioseqFormatHide = false; - } - form.FORMAT_TYPE.selectedIndex = formatObjectSelectedIndex; - ShowOrHide(formatTypeHide,form.FORMAT_TYPE); - if ($("bioseqFormat")) { - ShowOrHide(bioseqFormatHide,$("bioseqFormat")); - $("bioseqFormat").readOnly=true; - } - if ($("pssmFormat")) { - ShowOrHide(pssmFormatHide,$("pssmFormat")); - $("pssmFormat").readOnly=true; - } - if ($("pssmScFormat")) { - ShowOrHide(pssmScFormatHide,$("pssmScFormat")); - $("pssmScFormat").readOnly=true; - } - resetAdvView(hideAdvView); -} - -function ResetForm() -{ - //var defValNodes = cssQuery(".reset"); - defValNodes = $("FormatForm").elements; - for(i=0; i < defValNodes.length; i++) { - if(utils.hasClass(defValNodes[i],"reset")) - setDefalValue(defValNodes[i]); - } - if ($("FormatForm").FORMAT_OBJECT.type == "select-one") { - UpdateFormatTypes($("FormatForm")); - UpdateDisplayTypes($("FormatForm").FORMAT_OBJECT); - } - if($("FormatForm").RUN_PSIBLAST.checked) setDefalValue($("FormatForm").I_THRESH) - else $("FormatForm").I_THRESH.value=""; - //resetOrganismSuggest($("FormatForm").FORMAT_ORGANISM); - resetOrganismControls($("FormatForm").FORMAT_ORGANISM); - //TO DO: add threshold -} - -function LimitByHitlistSize(list) -{ - var listBreak = false; - var optSel = false; - for(i=0; i < list.options.length; i++) { - var optVal = parseInt(list.options[i].value ,10); - var hitListSize = parseInt($("maxNumSeq").value ,10); - if(list.options[i].selected) optSel = true; - if(optVal >= hitListSize) { - if(!optSel) {list.options[i].selected = true;} - list.options.length = i + 1; - break; - } - } -} - -function AddFormatOrgField(e) { - AddOrgRow(e, "FORMAT_ORGANISM", "FORMAT_ORG_EXCLUDE"); -} - -function initSubmit() { - - -} - -function adjustFormatOptions() -{ - var alignView = $("FormatForm").ALIGNMENT_VIEW; - var formatType = $("FormatForm").FORMAT_TYPE; - var queryAnch = formatType[formatType.selectedIndex].value == "HTML" && (alignView[alignView.selectedIndex].value != "Pairwise" && alignView[alignView.selectedIndex].value != "PairwiseWithIdentities"); - var dynFormatQA = !$("FormatForm").OLD_VIEW.checked && queryAnch; - dynFormatPW = !$("FormatForm").OLD_VIEW.checked && formatType[formatType.selectedIndex].value == "HTML" && (alignView[alignView.selectedIndex].value == "Pairwise" || alignView[alignView.selectedIndex].value == "PairwiseWithIdentities"); - - UpdateDescriptions(dynFormatPW); - if (dynFormatPW) { - jQuery("#frmAln").addClass("hidden"); - if (!utils.hasClass($("shl"), "hidden")) jQuery("#shl").addClass("hidden"); //hide SHOW_LINKOUT - jQuery("#gts").addClass("hidden"); //hide GET_SEQUENCE - jQuery("#scf").removeClass("hidden");//show CDS_FEAT - $("FormatForm").SHOW_LINKOUT.checked = true; - } - else { - if(dynFormatQA) $("FRM_ALIGNMENTS").selectedIndex = $("FRM_DESCRIPTIONS").selectedIndex; - - jQuery("#frmAln").removeClass("hidden"); - if (dynFormatQA) { - if (!utils.hasClass($("shl"), "hidden")) jQuery("#shl").addClass("hidden"); //hide SHOW_LINKOUT - } - else { - jQuery("#shl").removeClass("hidden"); - } - if (queryAnch) { - jQuery("#scf").addClass("hidden"); //hide CDS_FEAT - } - else {//pairwise old_view=false - jQuery("#scf").removeClass("hidden"); //hide CDS_FEAT - } - jQuery("#gts").removeClass("hidden"); //GET_SEQUENCE - } - if ($("blastSpec").value == "VecScreen") { - adjustVecscreen(dynFormatPW); - } -} - -function adjustVecscreen(dynFormatPW) -{ - var dfltDescrInd = 0; //0 - var dfltDynDescrInd = 5; //1000 - var dfltAlnInd = 6; //1000 - if (dynFormatPW) { - utils.addClass($("lr"), "hidden"); - $("FRM_DESCRIPTIONS").selectedIndex = dfltDynDescrInd; - } - else { - utils.removeClass($("lr"), "hidden"); - $("FRM_DESCRIPTIONS").selectedIndex = dfltDescrInd; - } - $("FRM_ALIGNMENTS").selectedIndex = dfltAlnInd; -} - - -function UpdateDescriptions(removeZero) -{ - if (removeZero) { - dispMenu = $("FormatForm").DESCRIPTIONS; - dispMenu.remove(0); - } - else { - dispMenu = $("FormatForm").DESCRIPTIONS; - if (dispMenu.options[0].value != "0") { - if (navigator.userAgent.match(/ie/i)) { - dispMenu.add(new Option("0", "0"), 0); - } - else { - dispMenu.add(new Option("0", "0"), dispMenu[0]); - } - } - } -} - -function InitDynFormatOptions() -{ - if ($("OLD_VIEW")) { - utils.addEvent($("FormatForm").OLD_VIEW, "click", adjustFormatOptions, false); - utils.addEvent($("FormatForm").ALIGNMENT_VIEW,"change", adjustFormatOptions, false); - utils.addEvent($("FormatForm").FORMAT_TYPE, "change", adjustFormatOptions, false); - adjustFormatOptions(); - } -} - -function InitFormatPage() -{ - if ($("FormatForm").FORMAT_OBJECT.type == "select-one") { - UpdateDisplayTypes($("FormatForm").FORMAT_OBJECT); - UpdateFormatTypes($("FormatForm")); - list = $("FormatForm").FORMAT_OBJECT; - utils.addEvent(list, "change", function() { - UpdateFormatTypes($("FormatForm")); - }, - false); - } - utils.addEvent($("resetAll"), "click", ResetForm, false); - if($("maxNumSeq") != null) { - if($("maxNumSeq").value != "") { - LimitByHitlistSize($("FormatForm").DESCRIPTIONS); - LimitByHitlistSize($("FormatForm").ALIGNMENTS); - LimitByHitlistSize($("FormatForm").NUM_OVERVIEW); - } - } - setupOrganismSuggest($("FormatForm").FORMAT_ORGANISM); - utils.addEvent($("FormatForm"), "submit", function() { - adjustOrgVal($("FormatForm").FORMAT_ORGANISM);}, - false); - - if ($("addOrg")) utils.addEvent($("addOrg"), "click", AddFormatOrgField, false); - InitDynFormatOptions(); - /* add this code if decide image for View Report - var imgButtons = jQuery("[class='viewReport']"); - for (var i = 0; i < imgButtons.length; i++) { - var l = imgButtons[i]; - utils.addEvent(l, "click", function() {$("FormatForm").submit();}, false); - utils.addEvent(l, "mouseover", function() {l.src = l.getAttribute("mouseovImg");}, false); - utils.addEvent(l, "mouseout", function() {l.src = l.getAttribute("mouseoutImg");}, false); - utils.addEvent(l, "mousedown", function() {l.src = l.getAttribute("mousedownImg");}, false); - utils.addEvent(l, "mouseup", function() {l.src = l.getAttribute("mouseupImg");}, false); - } - */ -} - -utils.addEvent(window, 'load', InitFormatPage, false); - - - - - - diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/formatRes.js --- a/Blast output page example_files/formatRes.js Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1542 +0,0 @@ -// JScript source code -/*************************new code begin *******************************************************/ - -function getHiddenFieldVal(elemName) { - var val; - var elem = document.getElementsByName(elemName); - if (elem) { - val = (elem.length > 1) ? elem[0].value : elem.value; - } - return val; -} - -function getHiddenFieldParamString(elemName) { - var ret = ""; - var val = getHiddenFieldVal(elemName); - if (val) { - ret = "&" + elemName + "=" + val; - } - return ret; -} - -function elementInViewport(el) { - if (!el) return; - var rect = el.getBoundingClientRect(); - - var myWidth = 0, myHeight = 0; - if (typeof (window.innerWidth) == 'number') { - //Non-IE - myWidth = window.innerWidth; - myHeight = window.innerHeight; - } else if (document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) { - //IE 6+ in 'standards compliant mode' - myWidth = document.documentElement.clientWidth; - myHeight = document.documentElement.clientHeight; - } else if (document.body && (document.body.clientWidth || document.body.clientHeight)) { - //IE 4 compatible - myWidth = document.body.clientWidth; - myHeight = document.body.clientHeight; - } - //window.alert('Width = ' + myWidth); - //window.alert('Height = ' + myHeight); - - - //return (rect.top >= 0 && rect.left >= 0 && rect.bottom <= window.innerHeight && rect.right <= window.innerWidth) - //return (rect.top >= 0 && rect.left >= 0 && rect.bottom <= myHeight && rect.right <= myWidth) - return (rect.top >= 0 && rect.bottom <= myHeight); -} - -function DisplayAlignFromDescription(elem) { - var alignView = $("FormatForm").ALIGNMENT_VIEW; - if (alignView[alignView.selectedIndex].value == "Pairwise" || alignView[alignView.selectedIndex].value == "PairwiseWithIdentities") { - DisplayDynamicAlign(elem); - } - else { - location.href = "#" + elem.getAttribute("seqID"); - } -} - -// ind="" gi="" id="deflnDesc_gi" href="#AlnHdrgi">desc -//
-function DisplayDynamicAlign(elem) { - var currGi = elem.getAttribute("gi"); - var currInd = elem.getAttribute("ind"); - var stat = elem.getAttribute("stat"); - if (!currInd || !currGi) return; - - if (!stat || stat == "") { - //Get 4(5) aligns before currInd and 4(5) aligns after - ReadCurrentSeqAligns(currInd, 5); - } - else if (stat == "read") { - var indexes = getCurrIndexRange(currInd); - if (indexes) { - var msgID = "alnShow_" + indexes[0]; - location.href = "#" + msgID; - } - } - else { - //error status handling - } -} - - -function goToNextAlign(dtrID, next) { - var currInd = parseInt($(dtrID).getAttribute("ind")); - var rid = $("Rid").value; - nextInd = (next) ? currInd + 1 : currInd - 1; - - if ($("deflnDesc_" + nextInd)) { - currGi = $("deflnDesc_" + nextInd).getAttribute("seqID"); - scrollToGI = currGi; - if (!$("deflnDesc_" + nextInd).getAttribute("stat") || $("deflnDesc_" + nextInd).getAttribute("stat") == "") { - - if (!next) { - ReadPrevSeqAligns(currInd, 5, scrollToGI); - } - else { - //Use this indexes = wasAlignRead(nextInd); to determine insertAfterID in ReadNextAligns!!! - ReadNextSeqAligns(currInd, 5, scrollToGI); - } - - } - else { - location.href = "#" + scrollToGI; - } - } -} - -function goToDefLine(dtrID) { - if ($("psiInp")) { - var tbl = jQuery($(dtrID)).parents(".jig-ncbigrid"); //parent table - togglerID = PsiBelowThresh(tbl[0].id) ? "showDescB1" : "showDescG1"; - jQuery($(togglerID)).ncbitoggler("open"); - } -} - -/* -readAln.rid = rid; -readAln.startIndex = parseInt(currInd); -readAln.numSeq = parseInt(maxNumAligns); - -readAln.insertAfterID = insertAfterID; -readAln.seqList = giList; -readAln.scrollToSeqID = scrollToGI; -*/ -function ReadNextSeqAligns(currInd, maxNumAligns, scrollToGI) { - var lastDispIdx = 0; - var rid = $("Rid").value; - - var readAln = new Object(); - readAln.seqList = ""; //giList - readAln.rid = rid; - - currInd = parseInt(currInd); - - if (currInd != 0 && $("deflnDesc_" + currInd)) { - var par = utils.getParent($("aln_" + $("deflnDesc_" + currInd).getAttribute("seqID"))); //"alnShowReal_ - //alert(par.id); - if (par) par = utils.getParent(par); //"alnShow_ - //alert(par.id); - if (par) readAln.insertAfterID = par.id; - } - else { - readAln.insertAfterID = "alnStart"; - } - - - - readAln.startIndex = currInd + 1; - readAln.numSeq = maxNumAligns; - - checkIfAlnExceedsThreshold(readAln, currInd, maxNumAligns, "next"); - - readAln.scrollToSeqID = (scrollToGI && scrollToGI != "") ? scrollToGI : ""; - readAln.hspSort = 0; - ReadSeqAlignByIndex(readAln); -} - -function ReadPrevSeqAligns(currInd, maxNumAligns, scrollToGI) { - var lastDispIdx = 0; - var rid = $("Rid").value; - - var readAln = new Object(); - readAln.seqList = ""; //giList - readAln.rid = rid; - - currInd = parseInt(currInd); - - - //sets readAln.insertAfterID and returns lastDispIdx; - //Find the index of the previously displayed alignment - lastDispIdx = getPrevDisplyedAlignInfo(currInd, readAln); - - readAln.startIndex = (currInd - lastDispIdx > maxNumAligns) ? (currInd - maxNumAligns) : lastDispIdx + 1; - readAln.numSeq = currInd - readAln.startIndex; //stopIndex = currInd - - checkIfAlnExceedsThreshold(readAln, currInd, readAln.numSeq, "prev"); - - readAln.scrollToSeqID = (scrollToGI && scrollToGI != "") ? scrollToGI : $("deflnDesc_" + (currInd)).getAttribute("seqID"); - readAln.hspSort = 0; - ReadSeqAlignByIndex(readAln); -} - -//When descriptions is clicked - display maxNumAligns before currInd and maxNumAligns after currInd -function ReadCurrentSeqAligns(currInd, maxNumAligns) { - var rid = $("Rid").value; - var readAln = new Object(); - readAln.seqList = ""; //giList - readAln.rid = rid; - - currInd = parseInt(currInd); - - - //sets readAln.insertAfterID and returns lastDispIdx; - //Find the index of the previously displayed alignment - var lastDispIdx = getPrevDisplyedAlignInfo(currInd, readAln); - - //lastDispIdx = parseInt(lastDispIdx); - readAln.startIndex = (currInd - lastDispIdx > maxNumAligns) ? (currInd - maxNumAligns) : lastDispIdx + 1; - readAln.numSeq = parseInt(maxNumAligns * 2); - - checkIfAlnExceedsThreshold(readAln, currInd, maxNumAligns, "curr"); - - readAln.scrollToSeqID = $("deflnDesc_" + currInd).getAttribute("seqID"); - readAln.hspSort = 0; - ReadSeqAlignByIndex(readAln); - g_DisableAutoCheck = true; - location.href = "#alnShow_" + readAln.startIndex; -} - - - - -function setupDynHSPParams(readAln) -{ - var currSeqInd = readAln.startIndex; - hspNum = parseInt($("deflnDesc_" + currSeqInd).getAttribute("hsp")); - alnLen = parseInt($("deflnDesc_" + currSeqInd).getAttribute("len")); - var maxDispLen = parseInt($("maxDispAlnLen").value);//20000 - var minDispLen = parseInt($("minDispAlnLen").value);//2000 - if (alnLen > maxDispLen) { - var lenPerMatch = alnLen / hspNum; - readAln.AlignDbPageSize = (lenPerMatch > minDispLen) ? 1 : Math.floor(minDispLen / lenPerMatch); - readAln.AlignDbPageNum = 0; - $("deflnDesc_" + currSeqInd).setAttribute("dynHsps", readAln.AlignDbPageSize); - } -} - - - -function getCurrSeqsAlnLen(currSeqInd) -{ - var alnLen = 0; - if ($("deflnDesc_" + currSeqInd) && (!$("deflnDesc_" + currSeqInd).getAttribute("stat") || $("deflnDesc_" + currSeqInd).getAttribute("stat") == "")) { - alnLen = $("deflnDesc_" + currSeqInd).getAttribute("len"); - } - alnLen = (alnLen) ? parseInt(alnLen) : 0; - return alnLen; -} - -function checkTotalAlignLen(startIndex,stopIndex) -{ - var dispAlnLen = 0; - var maxDispLen = parseInt($("maxDispAlnLen").value); - for (var i = startIndex; i <= stopIndex; i++) { - alnLen = getCurrSeqsAlnLen(i); - if (alnLen == 0) break; - dispAlnLen += alnLen; - } - return dispAlnLen; -} -//Get total align length for seq currSeqInd and -//"curr" surrounding countSeqs seqs + current, "prev" - previous countSeqs seqs, "next" - next countSeqs seqs -function getTotalAlignLen(readAln, currSeqInd, countSeqs, dispType) -{ - var startIndex = readAln.startIndex; - var stopIndex = readAln.startIndex + readAln.numSeq - 1; - if (dispType == "curr") {//checks countSeqs before and countSeqs after current, including current - startIndex = Math.max(startIndex, currSeqInd - countSeqs); - stopIndex = Math.min(stopIndex, currSeqInd + countSeqs); - } - else if(dispType == "prev") { - startIndex = Math.max(startIndex, currSeqInd - 1 - countSeqs); - stopIndex = currSeqInd - 1; - } - else {//next - stopIndex = Math.min(stopIndex, currSeqInd + countSeqs + 1); - } - var totAlnLen = checkTotalAlignLen(startIndex,stopIndex); - return totAlnLen; -} - -function checkIfAlnExceedsThreshold(readAln,currSeqInd,maxNumAligns, dispType) -{ - var maxDispLen = parseInt($("maxDispAlnLen").value); - var totAlnLen = 0; - var exc = false; - for (var numSeq = 0; numSeq <= maxNumAligns; numSeq++) { - totAlnLen = getTotalAlignLen(readAln, currSeqInd, numSeq, dispType); - if(totAlnLen > maxDispLen) { - break; - } - } - if (totAlnLen > maxDispLen) { - if (numSeq != 0) numSeq--; - if (dispType == "curr") { - readAln.startIndex = Math.max(readAln.startIndex, currSeqInd - numSeq); - //prev + 1(curr) + next - readAln.numSeq = (currSeqInd - readAln.startIndex) + 1 + numSeq; - } - else if (dispType == "prev") { - readAln.startIndex = Math.max(readAln.startIndex, currSeqInd - 1 - numSeq); - readAln.numSeq = numSeq + 1; - } - else { //"next" - readAln.startIndex stays - readAln.numSeq = numSeq + 1; - } - - if (readAln.numSeq == 1 && $("useAlignDB") && $("useAlignDB").value == "true") { - setupDynHSPParams(readAln); - } - - exc = true; - } - return exc; -} - - -//readAln.startIndex, readAln.numSeq, readAln.scrollToSeqID,readAln.insertAfterID should be set -function ReadSeqAlignByIndex(readAln) { - var numAligns = 0; - for (var i = readAln.startIndex; i < readAln.startIndex + readAln.numSeq; i++) { - - if (!$("deflnDesc_" + i)) { - break; - } - if (!$("deflnDesc_" + i).getAttribute("stat") || $("deflnDesc_" + i).getAttribute("stat") == "") { - currGi = $("deflnDesc_" + i).getAttribute("seqFSTA"); - if (readAln.seqList != "") readAln.seqList += ","; - readAln.seqList += currGi; - numAligns++; - } - else { - break; - } - } - if (readAln.seqList != "") { - readAln.numSeq = parseInt(numAligns); - ReadSeqAlignForSeqList(readAln); - } -} - - -var g_DisplayeAlignsRanges = ""; //String in the format start1-stop1,start2-stop2... -//Find the range of indexes of displayed alignments for currAlnInd -//Returns array of 2 startIndex, stopIndex -function getCurrIndexRange(currAlinInd) { - var currRange; - var ranges = g_DisplayeAlignsRanges.split(","); - for (var i = 0; i < ranges.length; i++) { - var indexes = ranges[i].split("-"); - if (currAlinInd >= parseInt(indexes[0]) && currAlinInd <= parseInt(indexes[1])) { - currRange = indexes; - break; - } - } - return currRange; -} - - -//Find the index of the previous displayed alignment -function getPrevDisplyedAlignInfo(currInd, readAln) { - readAln.insertAfterID = "alnStart"; - lastDispIdx = 0; - for (var i = currInd - 1; i >= 1; i--) { - indexes = getCurrIndexRange(i); - if (indexes) { - lastDispIdx = indexes[1]; - readAln.insertAfterID = "alnShow_" + indexes[0]; - break; - } - } - return parseInt(lastDispIdx); -} - - -//setReadStatus -function setSeqAlnReadStatus(readAln, status) { - for (var i = readAln.startIndex; i < readAln.startIndex + readAln.numSeq; i++) { - if ($("deflnDesc_" + i)) { - jQuery($($("deflnDesc_" + i))).attr("stat", status); - if (status == "disp") { - g_MaxDisplayedIndex = (i > g_MaxDisplayedIndex) ? i : g_MaxDisplayedIndex; - } - } - } -} - -/* -readAln.rid = rid; -readAln.seqList = giList; -readAln.startIndex = parseInt(idx); -readAln.insertAfterID = insertAfterID; -readAln.numSeq = parseInt(numSeq); -readAln.scrollToSeqID = scrollToGI; -*/ -function SendReadSeqAlinRequest(readAln) { - blastUrl = "t2g.cgi"; - - var rp = new RemoteDataProvider(blastUrl); - - - rp.onSuccess = function(obj) { - if ($("alignView")) utils.removeClass($("alignView"), "hidden"); - - if ($("alnShow_" + readAln.startIndex)) { - var moreHspsLink = getNextHspsLink(readAln); - jQuery($($("alnShowReal_" + readAln.startIndex))).html(obj.responseText + moreHspsLink, { - 'widgets': ['ncbipopper', 'ncbitoggler'], - 'configs': { - 'ncbipopper': { hasArrow: true, arrowDirection: 'top' } - } - }); - setSeqAlnReadStatus(readAln, "disp"); - jQuery($("alnMsg_" + readAln.startIndex)).addClass("hidden"); - //Saves start and stop indexes of loaded alignments in global variables - saveIdxesForAutomaticLoad(readAln); - jQuery($($("alnShowReal_" + readAln.startIndex))).find(".alnHdr").each(function(index) { - var seqID = this.getAttribute("seqID"); - if(seqID) initAlignBatch(seqID); - }); - - } - - if (readAln.scrollToSeqID) { - location.href = "#" + readAln.scrollToSeqID; - } - - }; - rp.onError = function(obj) { - if ($("alignView")) utils.removeClass($("alignView"), "hidden"); - jQuery($("alnMsg_" + readAln.startIndex)).addClass("hidden"); - $("alnShowReal_" + readAln.startIndex).innerHTML = "
Error loading alignment ...requests:" + this.iActiveRequests + " status:" + obj.status + - "Try again<\a>
"; - } - var params = constructURLParams(readAln); - if (readAln.numSeq == 1) { - params += "&TOTAL_HSPS=" + $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); - } - params += "&SEQ_LIST_START=" + readAln.startIndex; - - var formatParams = constructFormatParams(); - params += formatParams; - - //alert(params); - rp.Request(params); -} - - -function constructURLParams(readAln) { - var params; - - if ($("useAlignDB") && $("useAlignDB").value == "true") { - - var alignDbParams = "&USE_ALIGNDB=true"; - var batchID = document.getElementsByName("ALIGNDB_BATCH_ID"); - if (batchID) { - alignDbParams += getHiddenFieldParamString("ALIGNDB_BATCH_ID"); - alignDbParams += getHiddenFieldParamString("ALIGNDB_MASTER_ALIAS"); - alignDbParams += getHiddenFieldParamString("ALIGNDB_CGI_HOST"); - alignDbParams += getHiddenFieldParamString("ALIGNDB_CGI_PATH"); - } - alignDbParams += "&ALIGN_SEQ_LIST=" + readAln.seqList; - alignDbParams += "&HSP_SORT=" + readAln.hspSort; - - if (readAln.hasOwnProperty("AlignDbPageNum")) { - alignDbParams += "&ALIGNDB_PAGE_NUM=" + readAln.AlignDbPageNum; - alignDbParams += "&ALIGNDB_PAGE_SIZE=" + readAln.AlignDbPageSize; - alignDbParams += "&HSP_START=" + readAln.AlignDbPageSize * readAln.AlignDbPageNum; - } - - params = "CMD=Get&RID=" + readAln.rid + "&OLD_BLAST=false&DESCRIPTIONS=0&NUM_OVERVIEW=0&DYNAMIC_FORMAT=on" + alignDbParams; - } - else { - params = "CMD=Get&RID=" + readAln.rid + "&OLD_BLAST=false&DESCRIPTIONS=0&NUM_OVERVIEW=0&GET_SEQUENCE=on&DYNAMIC_FORMAT=on&ALIGN_SEQ_LIST=" + readAln.seqList + "&HSP_SORT=" + readAln.hspSort; - } - if ($("phiPtInd")) { - params += "&PHI_PTTRN_INDEX=" + $("phiPtInd")[$("phiPtInd").selectedIndex].value; - } - return params; -} - -/* -readAln.rid = rid; -readAln.seqList = giList; -readAln.startIndex = parseInt(idx); -readAln.insertAfterID = insertAfterID; -readAln.numSeq = parseInt(numSeq); -readAln.scrollToSeqID = scrollToGI; -*/ -/*1. Draw div with id="alnShow_index" class ="alnMsg" with the message listing gis nad indexes -2. Insert another div with id="alnShowReal_index and class="alnMsgR" -3. For "alnShow_index" set atrr indexes="startInd-stopInd" -4. Set global g_MaxReadMessageIndex - max index of displayed seqalign ??? - check this -5. Add string "startInd-stopInd" to g_DisplayeAlignsRanges - comma separated indexes -6. Send read request -*/ - -function ReadSeqAlignForSeqList(readAln) { - var text = "
Loading alignment... for sequences " + readAln.seqList; - var stopIndex = readAln.startIndex + readAln.numSeq - 1; - var useAlignDB = ($("useAlignDB") && $("useAlignDB").value == "true") ? "AlignDB=on " : ""; - text += " " + useAlignDB + "Reading indexes " + readAln.startIndex + "-" + stopIndex + "
"; - text += "
"; - var debugControl = "
"; - if (!$("debug")) { - jQuery($($("descriptions"))).before(debugControl); - } - if (!$("alnShow_" + readAln.startIndex)) { - jQuery($($(readAln.insertAfterID))).after(text); - jQuery($($("alnShow_" + readAln.startIndex))).attr("indexes", readAln.startIndex + "-" + stopIndex); - jQuery($($("alnShow_" + readAln.startIndex))).attr("seqlist", readAln.seqList); - g_MaxReadMessageIndex = (readAln.startIndex > g_MaxReadMessageIndex) ? readAln.startIndex : g_MaxReadMessageIndex; - setSeqAlnReadStatus(readAln, "read"); - $("debug").innerHTML += ", " + useAlignDB + "Reading indexes " + readAln.startIndex + "-" + stopIndex; - - if (g_DisplayeAlignsRanges != "") g_DisplayeAlignsRanges += ","; - g_DisplayeAlignsRanges += readAln.startIndex + "-" + stopIndex; - - SendReadSeqAlinRequest(readAln); - } - else if ($("alnShowReal_" + readAln.startIndex).innerHTML.indexOf("Error") != -1) { - jQuery($("alnMsg_" + readAln.startIndex)).removeClass("hidden"); - jQuery($("erm_" + readAln.startIndex)).remove(); - SendReadSeqAlinRequest(readAln); - } -} - - -function ReSubmitReadSeqAligns(e,currInd) { - var rid = $("Rid").value; - if ($("alnShow_" + currInd)) { - var indexRange = jQuery($("alnShow_" + currInd)).attr("indexes"); - var range = indexRange.split("-"); - - - var readAln = new Object(); - readAln.seqList = ""; //giList - readAln.rid = rid; - readAln.seqList = jQuery($("alnShow_" + currInd)).attr("seqlist"); - readAln.startIndex = parseInt(range[0]); - readAln.numSeq = parseInt(range[1]) - parseInt(range[0]) + 1; - readAln.hspSort = 0; - ReadSeqAlignForSeqList(readAln); - utils.preventDefault(e); - } -} - - -var g_MaxReadMessageIndex = 0; //alnShow_idx with the message, deflnDesc_idx with stat="read" -var g_MaxDisplayedIndex = 0; //deflnDesc_idx with stat="disp" - last one in the set of N -var g_DisableAutoCheck = false; - -var g_autoStartIdx = new Array(); -var g_autoStopIdx = new Array(); - -function saveIdxesForAutomaticLoad(readAln) { - var stopIndex = readAln.startIndex + readAln.numSeq - 1; - g_autoStartIdx.push(readAln.startIndex); //1,20,25 - g_autoStopIdx.push(stopIndex); //4,24,29 - $("debug").innerHTML += ", displaying indexes " + readAln.startIndex + "-" + stopIndex; -} - -function getNextHspsLink(readAln) -{ - var moreHspsLink = "" - if (readAln.hasOwnProperty("AlignDbPageNum")) { - var nextPageNum = readAln.AlignDbPageNum + 1; - var currHspInd = readAln.AlignDbPageSize * nextPageNum; - var argstring = readAln.startIndex + "," + currHspInd; - var currGi = $("deflnDesc_" + readAln.startIndex).getAttribute("seqId"); - var accs = $("deflnDesc_" + readAln.startIndex).getAttribute("accs"); - var totalHsps = $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); - var prevHspInd = readAln.AlignDbPageSize * nextPageNum; - var segs = (prevHspInd + 1) + "-" + (prevHspInd + readAln.AlignDbPageSize); - var moreHspsID = "nxHsp" + currGi + "_" + (prevHspInd + 1); - - moreHspsLink = $("dynHspTmpl").innerHTML.replace("@moreHspsID@", moreHspsID); - moreHspsLink = moreHspsLink.replace(/@accs@/g, accs); - moreHspsLink = moreHspsLink.replace("@argstring@", argstring); - moreHspsLink = moreHspsLink.replace(/@segs@/g, segs); - moreHspsLink = moreHspsLink.replace("@totalHSP@", totalHsps); - moreHspsLink = moreHspsLink.replace(/@alignDbPageSize@/g, readAln.AlignDbPageSize); - moreHspsLink = moreHspsLink.replace("@aln_prev_num@", prevHspInd); - moreHspsLink = moreHspsLink.replace("@alnSeqGi@", currGi); - } - return moreHspsLink; -} - - -function ReadNextHSPSet(currSeqInd, currHSPNum) { - var readAln = new Object(); - - readAln.rid = $("Rid").value; - readAln.seqList = $("deflnDesc_" + currSeqInd).getAttribute("seqFSTA"); - readAln.gi = $("deflnDesc_" + currSeqInd).getAttribute("seqId"); - dynHsps = $("deflnDesc_" + currSeqInd).getAttribute("dynHsps"); - readAln.startIndex = currSeqInd; - readAln.numSeq = 1; - if (dynHsps) { - readAln.AlignDbPageNum = parseInt(currHSPNum) / parseInt(dynHsps); - readAln.AlignDbPageSize = parseInt(dynHsps); //number of HSps to retrieve - } - if (currHSPNum != 0) { - readAln.scrollToSeqID = "hsp" + +readAln.gi + "_" + (parseInt(currHSPNum) + 1); - readAln.insertAfterID = "ar_" + readAln.gi + "_" + currHSPNum; - } - var sortLink = $("sa_" + readAln.gi); - readAln.hspSort = (sortLink) ? parseInt(sortLink[sortLink.selectedIndex].value) : 0; - SendReadSeqAlinSortHSPRequest(readAln); -} - -function ReadNextHSPSetEvt(e, currSeqInd, currHSPNum) { - ReadNextHSPSet(currSeqInd, currHSPNum); - utils.preventDefault(e); -} - - - -function checkAutoAlignArray() { - var stop = false; - var start = false; - var currAlignViewPos = $("alignView").getBoundingClientRect().top; - if (currAlignViewPos < g_alignViewPos) {//scrolling down - g_alignViewPos = currAlignViewPos; - if (g_DisableAutoCheck) { - g_DisableAutoCheck = false; - return; - } - for (i = 0; i < g_autoStopIdx.length; i++) { - if (elementInViewport($("alnHdr_" + $("deflnDesc_" + g_autoStopIdx[i]).getAttribute("seqID")))) { - //alert("Reading more aligns scrolling down!"); - var nextInd = parseInt(g_autoStopIdx[i] + 1); - var currInd = g_autoStopIdx[i]; - if ($("deflnDesc_" + nextInd) && (!$("deflnDesc_" + nextInd).getAttribute("stat") || $("deflnDesc_" + nextInd).getAttribute("stat") == "")) { - ReadNextSeqAligns(currInd, 5); - stop = true; - break; - } - } - } - if (stop) g_autoStopIdx.splice(i, 1); //delete index from the array - } - else if (currAlignViewPos > g_alignViewPos) {//scrolling up - g_alignViewPos = currAlignViewPos; - //here maybe return if autoStop found!!! - /* commenting automic read when scroll up */ - for (i = 0; i < g_autoStartIdx.length; i++) { - if (elementInViewport($("alnHdr_" + $("deflnDesc_" + g_autoStartIdx[i]).getAttribute("seqID")))) { - //alert("Reading more aligns scrolling up!"); - var currInd = g_autoStartIdx[i]; - //Check for condition here if go there at all!!! Check if do the same thing as for ReadNext!!!! - if (currInd > 1) { - ReadPrevSeqAligns(currInd, 5); - start = true; - break; - } - } - } - if (start) g_autoStartIdx.splice(i, 1); - } - /*end of comment*/ -} - -var g_alignViewPos = 0; - -function checkAutoAlignLoad() { - - - checkAutoAlignArray(); - - if (jQuery($($(window))).scrollTop() + jQuery($($(window))).height() >= jQuery($($(document))).height() - 100) { - //alert("bottom!"); - - if ($("alnShowReal_" + g_MaxReadMessageIndex) && $("alnShowReal_" + g_MaxReadMessageIndex).innerHTML != "") { - //if(!$("alnShow_" + maxReadMessageIndex)) {//g_MaxReadMessageIndex - ReadNextSeqAligns(g_MaxDisplayedIndex, 5); - } - } -} - - -function GetPatternLocResults() -{ - form = $("results"); - if (!form.PHI_PTTRN_INDEX) { - var el = document.createElement("input"); - el.name = "PHI_PTTRN_INDEX"; - el.value = $("phiPtInd")[$("phiPtInd").selectedIndex].value; - form.appendChild(el); - } - else { - form.PHI_PTTRN_INDEX.value = $("phiPtInd")[$("phiPtInd").selectedIndex].value; - } - form.submit(); -} - -function goToNextHSP(elem, next) { - var par = jQuery(elem).parent(); //parent span with class="alnParLinks" - var parts = par[0].id.split("_"); //"hsp_hspnum "hsp207524544_2" - if (parts[0].indexOf("nxHsp") != -1) { - parts[0] = parts[0].replace("nxHsp", "hsp"); - } - nextID = (next) ? parts[0] + "_" + (parseInt(parts[1]) + 1) : parts[0] + "_" + (parseInt(parts[1]) - 1) - - gotoElem = jQuery($(nextID)); - if (gotoElem[0]) { - a = jQuery(gotoElem).offset(); - window.scroll(0, a.top); - } - - else { - retrieveNextHSP(parts[0],parts[1]); - } - -} - - -//parts[0]//hsp, parts[1] hspnum -function retrieveNextHSP(currLinkID, currHSPNum) -{ - var desLineID = currLinkID.replace("hsp", "dtr_"); //tr id - var currSeqInd, totalHsps; - jQuery($($(desLineID))).find(".deflnDesc").each(function(index) { - currSeqInd = parseInt(this.getAttribute("ind")); - totalHsps = parseInt(this.getAttribute("hsp")); - dynHsps = this.getAttribute("dynHsps"); - }); - currHSPNum = parseInt(currHSPNum); - if (currHSPNum < totalHsps && dynHsps) { - ReadNextHSPSet(currSeqInd, currHSPNum); - } -} -/********Adding those functions back to formatRes.js to identify Uncaught ReferenceError: getUrlCompForCheckedField is not defined error********************************/ -function getUrlCompForEntryField(elem) { - var url = ""; - if (elem && elem.value != "") { - url = "&" + elem.name + "=" + escape(elem.value); - } - return url; -} - - -function getUrlCompForCheckedField(elem) { - var url = ""; - if (elem && elem.checked) { - url = "&" + elem.name + "=" + elem.value; - } - return url; - -} - -function getUrlCompForOptionsField(elem) { - var url = ""; - if (elem) { - url = "&" + elem.name + "=" + elem[elem.selectedIndex].value; - } - return url; -} -/****************************************/ - -function constructFormatParams() { - var formatParams = ""; - - if ($("queryList")) { - formatParams += "&QUERY_INDEX=" + $("queryList")[$("queryList").selectedIndex].value; - } - - - formatParams += getUrlCompForCheckedField($("FormatForm").SHOW_LINKOUT); - formatParams += getUrlCompForCheckedField($("FormatForm").SHOW_CDS_FEATURE); - formatParams += getUrlCompForCheckedField($("FormatForm").NCBI_GI); - formatParams += getUrlCompForOptionsField($("FormatForm").ALIGNMENT_VIEW); - formatParams += getUrlCompForOptionsField($("FormatForm").MASK_CHAR); - formatParams += getUrlCompForOptionsField($("FormatForm").MASK_COLOR); - formatParams += getUrlCompForEntryField($("FormatForm").EXPECT_LOW); - formatParams += getUrlCompForEntryField($("FormatForm").EXPECT_HIGH); - formatParams += getUrlCompForEntryField($("FormatForm").PERC_IDENT_LOW); - formatParams += getUrlCompForEntryField($("FormatForm").PERC_IDENT_HIGH); - formatParams += getUrlCompForEntryField($("FormatForm").LINE_LENGTH); - - - formatParams += getHiddenFieldParamString("BUILD_NAME"); - - var serviceType = ""; - if ($("serviceType").value == "sra") { - serviceType = "sra"; - } - else if ($("clientType").value == "TMSmart_restricted") { - serviceType = "restricted"; - } - if (serviceType != "") { - formatParams += "&BOBJSRVC=" + serviceType; - } - if ($("currQuery").value != "") { - formatParams += "&CURR_QUERY_ID=" + $("currQuery").value; - } - - return formatParams; -} - -//readAln.seqList contains one gi only for this -function SendReadSeqAlinSortHSPRequest(readAln) { - blastUrl = "t2g.cgi"; - var rp = new RemoteDataProvider(blastUrl); - - - rp.onSuccess = function(obj) { - var moreHspsLink = (readAln.hasOwnProperty("AlignDbPageNum")) ? getNextHspsLink(readAln) : ""; - var alnHtml = obj.responseText + moreHspsLink; - initHSPRequest(readAln, obj.responseText + moreHspsLink,false); - if (readAln.scrollToSeqID) { - location.href = "#" + readAln.scrollToSeqID; - } - }; - rp.onError = function(obj) { - var currHspInd = (readAln.hasOwnProperty("AlignDbPageNum")) ? readAln.AlignDbPageSize * readAln.AlignDbPageNum : 0; - var msgID = "erm_" + readAln.gi + "_" + (currHspInd + 1); - if (!$(msgID)) { - var msg = "
"; - initHSPRequest(readAln, msg, true); - } - else { - var attNum = parseInt($(msgID).getAttribute("att")) + 1; - $(msgID).setAttribute("att", attNum); - jQuery($(msgID)).find(".attmt").each(function(index) { - jQuery(this).html(", attempt " + attNum); - }); - } - } - - var params = constructURLParams(readAln); - if (readAln.AlignDbPageSize) { - params += "&TOTAL_HSPS=" + $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); - } - params += "&SORT_ONE_ALN=on"; - var formatParams = constructFormatParams(); - - params += formatParams; - - //alert(params); - rp.Request(params); -} -function initHSPRequest(readAln, alnHtml, err) { - var currHspInd = (readAln.hasOwnProperty("AlignDbPageNum")) ? readAln.AlignDbPageSize * readAln.AlignDbPageNum : 0; - if (currHspInd != 0) { - readAln.insertAfterID = "ar_" + readAln.gi + "_" + currHspInd; - jQuery($(readAln.insertAfterID)).after(alnHtml); - moreHspsID = "nxHsp" + readAln.gi + "_" + (currHspInd + 1); - jQuery($(moreHspsID)).remove(); - if (!err) { - errMsgID = "erm_" + readAln.gi + "_" + (currHspInd + 1); - jQuery($(errMsgID)).remove(); - } - } - else { - jQuery($("alnAll_" + readAln.gi)).html(alnHtml); - } -} - -function SortHSPAlnSel(e, sortLink) {//example id="sa_207524544" - var readAln = new Object(); - - - var desLineID = sortLink.id.replace("sa", "dtr"); //tr id - var seqInd; - - jQuery($($(desLineID))).find(".deflnDesc").each(function(index) { - seqInd = this.getAttribute("ind"); - }); - - ReadNextHSPSet(parseInt(seqInd), 0); -} - - -function configDescriptions(e,btn,dlgId) -{ - var suffix = PsiBelowThresh(dlgId); - var colmnsInfId = "cfcDsInf" + suffix; - var tblID = "dscTable" + suffix; //"dscTable[_psiw]" - var showAllColId = "shcl" + suffix; - var chkBoxes = $C("checkbox", "type", $(dlgId), "input"); - if (!utils.hasClass(btn, "cnc")) $(colmnsInfId).value = ""; - for (i = 0; i < chkBoxes.length; i++) { - var check; - if (utils.hasClass(btn, "cnc")) {//cancel - if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) != -1 && !chkBoxes[i].checked) { - check = true; - } - else if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) == -1 && chkBoxes[i].checked) { - check = false; - } - } - else if (utils.hasClass(btn, "rdf") && !chkBoxes[i].checked) { - check = true; - } - if (typeof (check) != 'undefined') { - chkBoxes[i].checked = check; - showHideCol(tblID,parseInt(chkBoxes[i].value), !check); - } - if (!utils.hasClass(btn, "cnc")) { - if (chkBoxes[i].checked) { //OK - if ($(colmnsInfId).value != "") $(colmnsInfId).value += ","; - $(colmnsInfId).value += chkBoxes[i].value; - } - } - } - if ($(colmnsInfId).value != $(colmnsInfId).getAttribute("defval")) {//defval = "2,3,4,5,6,7,8" - jQuery($(showAllColId)).removeClass("hidden"); - } - else { - jQuery($(showAllColId)).addClass("hidden"); - } - - var chConfig = $("cfcDsSave").value != $(colmnsInfId).value; - - var cfds = document.getElementsByName("CONFIG_DESCR"); - if (cfds) { - for (i = 0; i < cfds.length; i++) { - cfds[i].value = $(colmnsInfId).value; - } - } - $("cfcDsSave").value = $(colmnsInfId).value; - if (chConfig) SaveConfigTable(); - jQuery(document.body).click(); - utils.preventDefault(e); -} - - - -function initDescConfig() -{ - initConfigColumns("dsConfig"); - if ($("psiw") && utils.hasClass($("psiw"), "shown")) { - initConfigColumns("dsConfig_psiw"); - } -} - - -function initConfigColumns(cnfDlgID) -{ - var suffix = PsiBelowThresh(cnfDlgID); - //cnfDlgID is "dsConfig[_psiw]" - var colmnsInfId = "cfcDsInf" + suffix; - var tblID = "dscTable" + suffix; //"dscTable[_psiw]" - var showAllColId = "shcl" + suffix; - - if (navigator.userAgent.match(/ie/i)) { - if ($("FormatForm").NCBI_GI.checked || $("serviceType").value == "sra") { - jQuery($(tblID)).find("th.c1").each(function(index) { - db = getHiddenFieldVal("DATABASE"); - var width = (db.match(/WGS/i) || db.match(/Whole_Genome_Shotgun_contigs/i)) ? "16em" : "14em"; - jQuery(this).css("width", width); - }); - } - } - - jQuery($(tblID)).find("tr.first").each(function(index) { - jQuery(this).find("a.dcs").each(function(index) { - jQuery(this).bind("click", function(e) { checkConfig(this); }); - }); - }); - - jQuery($(cnfDlgID)).find("button").each(function(index) { - jQuery(this).bind("click", function(e) { configDescriptions(e, this, cnfDlgID); }); - }); - - - jQuery($(cnfDlgID)).bind("click", function(e) { e.stopPropagation(); }); - - $(colmnsInfId).value = getHiddenFieldVal("CONFIG_DESCR"); - if ($(colmnsInfId).value == "" || $(colmnsInfId).value == "undefined") { - $(colmnsInfId).value = $(colmnsInfId).getAttribute("defval"); - } - if ($(colmnsInfId).value != $(colmnsInfId).getAttribute("defval")) {//defval = "2,3,4,5,6,7,8" - jQuery($(showAllColId)).removeClass("hidden"); - } - else { - jQuery($(showAllColId)).addClass("hidden"); - } - var chkBoxes = $C("checkbox", "type", $(cnfDlgID), "input") - for (i = 0; i < chkBoxes.length; i++) { - jQuery(chkBoxes[i]).bind("click", configColumn); - if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) != -1) { - chkBoxes[i].checked = true; - } - else { - //jQuery($(tblID)).ncbigrid("hideColumn", chkBoxes[i].value); - showHideCol($(tblID), chkBoxes[i].value, true); - } - } -} -function showAllCol(e,elem) -{ - var suffix = PsiBelowThresh(elem.id); - var rdf = "dscRsDf" + suffix; - jQuery($(rdf)).click();//click "restore defaults' - utils.preventDefault(e); -} - - -function configColumn() { - var suffix = PsiBelowThresh(this.id); - var tblID = "dscTable" + suffix; //"dscTable[_psiw]" - - cCls = "c" + this.value; - if (this.checked) {//show - showHideCol(tblID,parseInt(this.value), false); - } - else { - showHideCol(tblID,parseInt(this.value), true); - } -} - -function showHideCol(tblID, columnIndex, hide) { - - if ($("Transcr")) { - colHidden = utils.hasClass($("c" + columnIndex), "ui-ncbigrid-column-hidden"); - hide = hide && !colHidden; - show = !hide && colHidden; - } - else { - show = !hide; - } - if (hide) { - jQuery($(tblID)).ncbigrid("hideColumn", columnIndex); - } - else if (show) { - jQuery($(tblID)).ncbigrid("showColumn", columnIndex); - } - if ($("Transcr") && (hide || show) ) { - var colsp = parseInt($("Transcr").getAttribute("colspan")); - colsp = (hide) ? colsp - 1 : colsp + 1; - $("Transcr").setAttribute("colSpan", colsp); - if ($("GnmSeq")) $("GnmSeq").setAttribute("colSpan", colsp); - } -} - -function checkConfig(lnk) { - var cnfCol = "&CONFIG_DESCR=" + $("cfcDsSave").value; - lnk.href = lnk.href + cnfCol + "#sort_mark"; -} - -function DisplayAlignFromGraphics(seqID,e) //SeqID = gi if exists -{ - var dflLineLinks = $C(seqID, "gi", document, "a"); - for (i = 0; i < dflLineLinks.length; i++) { - jQuery(dflLineLinks[i]).click(); - break; - } - location.href = dflLineLinks[i].href; -} - - - -function initDescSelect() -{ - - jQuery("#cntDesc").find("a").each(function(index) { - jQuery(this).bind("click", configDescrSelect); - }); - jQuery("#cntSelN").click(); - jQuery("#descTblCtrl").find("a[view]").each(function(index) { - jQuery(this).bind("click", DisplaySelectedView); - }); - if ($("psiw") && utils.hasClass($("psiw"), "shown")) { - jQuery("#cntDesc_psiw").find("a").each(function(index) { - jQuery(this).bind("click", configDescrSelect); - }); - jQuery("#cntSelN_psiw").click(); - jQuery("#descTblCtrl_psiw").find("a[view]").each(function(index) { - jQuery(this).bind("click", DisplaySelectedView); - }); - } - - - //jQuery("#dsConfig").bind("click", function(e) { e.stopPropagation(); });?? - -} - -function DisplaySelectedView(e) { - if (this.getAttribute("view") == "graph") { //seqviewer - ViewSelectedSeqViewer(e,this); - } - else { - if (this.getAttribute("view") == "tree") { //seqviewer - $("scrWidth").value = screen.width; - $("scrHeight").value = screen.height; - } - ViewSelectedSeqsEx(e, this); - } -} - -function PsiBelowThresh(elemID) -{ - var suffix = ""; - if (elemID.indexOf("_psiw") != -1) { - suffix = "_psiw"; - } - return suffix; -} - -function ViewSelectedSeqsEx(e,elem) { - var sbmForm = elem.getAttribute("frm"); - var seqList = elem.getAttribute("seqList"); - - var cnfElem = utils.getParent(elem); //.cnf div - var suffix = PsiBelowThresh(cnfElem.id); - var tblID = "dscTable" + suffix; - - $(seqList).value = createSelseqString(tblID,true); - $(seqList).value = $(seqList).value.replace(/ti:/g, ""); //For traces - if ($(seqList).value.indexOf("dbSNP") != -1) { - $(seqList).value = $(seqList).value.replace(/dbSNP:rs/g, ""); //For snp - elem.href = $(sbmForm).action + $(seqList).value; - elem.target = "new"; - } - else { - $(sbmForm).submit(); - utils.preventDefault(e); - } -} - -function ViewSelectedSeqsTree(e) { - $("scrWidth").value = screen.width; - $("scrHeight").value = screen.height; -} - -function initSeqViewerGet(seqList) { - if (seqList.length >= 2000) { - seqList = seqList.substr(0,2000); - lastComma = seqList.lastIndexOf(","); - seqList = seqList.substr(0,lastComma); - } - $("seqViewParams").name = "RID"; - $("seqViewParams").value = $("ridParam").value + "[" + seqList + "]"; -} - -function ViewSelectedSeqViewer(e, elem) -{ - var cnfElem = utils.getParent(elem); //.cnf div - var suffix = PsiBelowThresh(cnfElem.id); - var tblID = "dscTable" + suffix; - - //change to false when new verison of seqVier is installed in production - var seqList = createSelseqString(tblID, false); - $("sbmtGraphics").action = $("seqViewUrl").value; - - var rp = new RemoteDataProvider("url2nc.cgi"); - rp.onSuccess = function(obj) { - var jsnResp = JSON.parse(obj.responseText); - ncid = jsnResp.ncid; - - if (ncid != "") { - $("seqViewParams").name = "rkey"; - $("seqViewParams").value = ncid; - } - else { - initSeqViewerGet(seqList); - } - $("sbmtGraphics").submit(); - }; - rp.onError = function(obj) { - initSeqViewerGet(seqList); - $("sbmtGraphics").submit(); - utils.preventDefault(e); - } - var params = $("ridParam").value + "[" + seqList + "]"; - rp.Request(params, "POST"); - utils.preventDefault(e); -} - -function configDescrSelect(e) { - var sel = this.getAttribute("sel"); - if (sel) { - var selNum = 0; - var check = (sel == "all") ? true : false; - - var suffix = PsiBelowThresh(this.id); - var tblID = "dscTable" + suffix; - var toolbarID = "descTblCtrl" + suffix; - var selElID = "slcNum" + suffix; - - jQuery($(tblID)).find("input[type='checkbox'].cb").each(function(index) { - jQuery(this)[0].checked = check; - if (check) selNum++; - }); - enableDescrLinks(selNum, toolbarID, selElID); - } - utils.preventDefault(e); -} - - - -function enableDescrLinks(selNum, toolbarID, selElID) { - jQuery($(toolbarID)).find("a[minSlct]").each(function(index) { - var minSelected = this.getAttribute("minSlct"); - minSelected = parseInt(minSelected); - if (selNum >= minSelected) { - this.removeAttribute("disabled"); - } - else { - this.setAttribute("disabled", "disabled"); - } - }); - $(selElID).innerHTML = selNum; -} - - - -function configDescrLinks(e, elem) -{ - - ncbi.sg.ping(elem, "click", elem.checked ? "checked=true" : "checked=false"); - var par = jQuery(elem).parents(".jig-ncbigrid");//parent table - if (par) { - var suffix = PsiBelowThresh(par[0].id); - var tblID = "dscTable" + suffix; - var toolbarID = "descTblCtrl" + suffix; - var selElID = "slcNum" + suffix; - - var currSelNum = parseInt($(selElID).innerHTML); - var selNum = elem.checked ? currSelNum + 1 : currSelNum - 1; - enableDescrLinks(selNum, toolbarID, selElID); - } -} -/***Download code begin****/ - -function initDownLoadPopup(dwnDialog) { - - jQuery(dwnDialog).find("button").each(function(index) { - jQuery(this).bind("click", execDownLoad); - }); - - jQuery(dwnDialog).bind("click", function(e) { e.stopPropagation(); }); -} - -function initDescDownLoad() { - initDownLoadPopup($("dsDownload")); - - if ($("psiw") && utils.hasClass($("psiw"), "shown")) { - initDownLoadPopup($("dsDownload_psiw")); - } -} - -function initAlignDownLoad(navObj) -{ - var seqID = navObj.seqID; - var dwnDialog = $("dlgDwnl_" + seqID); - jQuery(dwnDialog).find("button").each(function(index) { - jQuery(this).bind("click", execDownLoad); - }); - - var dwnFSTW = $("dwFST_" + seqID);//whole seq - var dwnFSTAl = $("dwFSTAl_" + seqID);//aligned regions - - if(dwnFSTW) dwnFSTW.setAttribute("seqfsta", navObj.currSeqID); - if(dwnFSTAl) dwnFSTAl.setAttribute("seqfsta", navObj.currSeqID); - - jQuery(dwnDialog).bind("click", function(e) { e.stopPropagation(); }); -} - - -function execDownLoad(e) { - if (!utils.hasClass(this, "cnc")) { - par = utils.getParent(this); - dwnDialog = utils.getParent(par); //parent dialog with popDl class - var descr = (this.id == "dw_cont" || this.id == "dw_cont_psiw") ? true : false; - jQuery(dwnDialog).find("input").each(function(index) { - if (this.checked) { - submitDownLoad(this, descr); - } - }); - } - jQuery(document.body).click(); - utils.preventDefault(e); -} - -function submitDownLoad(radioElem, descr) { - var toolURL = radioElem.getAttribute("url"); - if (toolURL) { - if (descr) { - var getGi = radioElem.getAttribute("getGi"); - getGi = (getGi) ? true : false; - - var tblID = "dscTable"; - var suffix = PsiBelowThresh(radioElem.id); - tblID += suffix; - - $("selDnSeqs").value = createSelseqString(tblID,getGi); - } - else { - var seqfsta = radioElem.getAttribute("seqfsta"); - $("selDnSeqs").value = (seqfsta) ? seqfsta : radioElem.getAttribute("getGi"); - } - var addParams = ""; - if (radioElem.getAttribute("addParam")) { - addParams = addDwnlParams(); - } - var submitName = radioElem.getAttribute("sbName") - $("selDnSeqs").name = (submitName) ? submitName : "ALIGN_SEQ_LIST"; - $("dwdlSubmit").action = toolURL + addParams; - $("dwdlSubmit").submit(); - } - else { - var sbFunction = radioElem.getAttribute("sbFunc"); - if (sbFunction) { - eval(sbFunction + "(radioElem, descr)"); - } - } -} - - -function initDownLoadFSTA(radioElem, descr) -{ - if (descr) { - - var tblID = "dscTable"; - var suffix = PsiBelowThresh(radioElem.id); - tblID += suffix; - - $("sbmtFASTA").ALIGN_SEQ_LIST.value = createSelseqString(tblID,false); - } - else { - $("sbmtFASTA").ALIGN_SEQ_LIST.value = radioElem.getAttribute("seqfsta"); - } - $("sbmtFASTA").DOWNLOAD_TYPE.value = radioElem.getAttribute("fstaDWType"); - - $("sbmtFASTA").DATABASE.value = getHiddenFieldVal("DATABASE"); - if ($("useAlignDB") && $("useAlignDB").value == "true") {//temp checkbox - var batchID = document.getElementsByName("ALIGNDB_BATCH_ID"); - if (batchID) { - $("sbmtFASTA").ALIGNDB_BATCH_ID.value = getHiddenFieldVal("ALIGNDB_BATCH_ID"); - $("sbmtFASTA").ALIGNDB_MASTER_ALIAS.value = getHiddenFieldVal("ALIGNDB_MASTER_ALIAS"); - $("sbmtFASTA").ALIGNDB_CGI_HOST.value = getHiddenFieldVal("ALIGNDB_CGI_HOST"); - $("sbmtFASTA").ALIGNDB_CGI_PATH.value = getHiddenFieldVal("ALIGNDB_CGI_PATH"); - } - } - $("sbmtFASTA").submit(); -} - -function createSelseqString(tblID,getGi) { - var selSeqs = ""; - jQuery($(tblID)).find("input[type='checkbox'].cb").each(function(index) { - if (jQuery(this)[0].checked) { - if (selSeqs != "") selSeqs += ","; - if (getGi) { - selSeqs += jQuery(this)[0].value; - } - else { - var linkID = jQuery(this)[0].id.replace("chk", "deflnDesc"); - selSeqs += $(linkID).getAttribute("seqFSTA"); - } - } - }); - return selSeqs; -} - -/***Download code end****/ - -/***Init navigation code begin **/ - -function initNavigation(navObj) { - initNextAlnLink(navObj, true); - initNextAlnLink(navObj, false); -} - - -function initNavInfo(navObj) { - var currInd = parseInt($("dtr_" + navObj.seqID).getAttribute("ind")); - nextInd = currInd + 1; - prevInd = currInd - 1; - - navObj.currSeqID = ""; - navObj.nextSeqID = ""; - navObj.prevSeqID = ""; - - if ($("deflnDesc_" + nextInd)) { - navObj.nextSeqID = $("deflnDesc_" + nextInd).getAttribute("accs"); - if(navObj.nextSeqID =="") navObj.nextSeqID = $("deflnDesc_" + nextInd).getAttribute("seqFSTA"); - } - if ($("deflnDesc_" + prevInd)) { - navObj.prevSeqID = $("deflnDesc_" + prevInd).getAttribute("accs"); - if (navObj.prevSeqID == "") navObj.prevSeqID = $("deflnDesc_" + prevInd).getAttribute("seqFSTA"); - } - if ($("deflnDesc_" + currInd)) { - navObj.currSeqID = $("deflnDesc_" + currInd).getAttribute("seqFSTA"); - } -} - - -function initNextAlnLink(navObj, next) { - - var nextLinkEl = (next) ? $("alnNxt_" + navObj.seqID) : $("alnPrv_" + navObj.seqID); - var nextSeqid = (next) ? navObj.nextSeqID : navObj.prevSeqID; - - if (nextLinkEl) { - if (nextSeqid != "") { - var text = (next) ? "next" : "previous"; - nextLinkEl.setAttribute("title", "Go to " + text + " alignment for " + nextSeqid); - } - else { - nextLinkEl.setAttribute("disabled", "disabled"); - } - } -} -function scan(link) { - var init = link.getAttribute("init"); - if (!init) { - ncbi.sg.scanLinks(link); - link.setAttribute("init","on"); - } -} - -function initWidth(seqID) { - var lineLengthElem = $("FormatForm").LINE_LENGTH; - var lineLength = parseInt(lineLengthElem[lineLengthElem.selectedIndex].value); - if (parseInt(lineLengthElem.getAttribute("defval")) == lineLength) return; - - var relWidth = (lineLength > 90) ? "12%" : "15%"; - var charWidth = (navigator.userAgent.match(/ie/i)) ? 8 : 7; - lineLength = (lineLength + parseInt(17)) * charWidth; - var width = lineLength + "px"; - jQuery($("alnAll_" + seqID)).find("div.dflLnk").each(function(index) { - jQuery(this).css("width", width); - }); - jQuery($("alnAll_" + seqID)).find("table.alnParams").each(function(index) { - jQuery(this).css("width", width); - }); - jQuery($("relInf_" + seqID)).css("width", relWidth); -} - - -/***Init navigation code end **/ -function initAlignBatch(seqID) -{ - var navObj = new Object(); - navObj.seqID = seqID; - initNavInfo(navObj); - - initAlignDownLoad(navObj); - initNavigation(navObj); - ncbi.sg.scanLinks($("alnNxt_" + seqID)); - ncbi.sg.scanLinks($("alnPrv_" + seqID)); - if ($("serviceType").value == "vecscreen") { - utils.addClass($("alnDsc_" + seqID), "hidden"); - } - ncbi.sg.scanLinks($("alnDwnld_" + seqID)); - jQuery($("csLinks_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); - jQuery($("relInf_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); - jQuery($("rng_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); - jQuery($("dln_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); - initWidth(seqID); -/* - jQuery($("alnHdr_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); - jQuery($("aln_" + seqID)).find("a").each(function(index) { - ncbi.sg.scanLinks(this); - }); -*/ -} - -function SaveConfigTable() { - blastUrl = "fmtsave.cgi"; - - - var rp = new RemoteDataProvider(blastUrl); - - - rp.onSuccess = function(obj) { - //alert("success"); - }; - rp.onError = function(obj) { - //alert("error"); - } - - var program = getHiddenFieldVal("PROGRAM"); - var rid = getHiddenFieldVal("RID"); - var blastSpec = getHiddenFieldVal("BLAST_SPEC"); - var params = "CMD=Get&RID=" + rid + "&ViewReport=on&PROGRAM=" + program + "&SAVE_INDV_FRM_OPTION=on&CONFIG_DESCR=" + $("cfcDsSave").value; - if(blastSpec) { - params += "&BLAST_SPEC=" + blastSpec; - } - rp.Request(params,"POST"); -} - -function removeRID() { - var rid = document.getElementsByName("RID"); - for (var i = 0; i <= rid.length; i++) { - jQuery(rid[i]).remove(); - } -} - -function initAdvancedView() -{ - if ($("dsConfig")) { - - var alnView = getHiddenFieldVal("ALIGNMENT_VIEW"); - if (alnView == "Pairwise" || alnView == "PairwiseWithIdentities") { - var rid = getHiddenFieldVal("RID"); - ReadNextSeqAligns(0, 5); - g_alignViewPos = $("alignView").getBoundingClientRect().top; - utils.addEvent(window, "scroll", checkAutoAlignLoad, false); - } - list = $("phiPtInd"); - if (list) { - utils.addEvent(list, "change", GetPatternLocResults, false); - } - initDescConfig(); - initDescSelect(); - initDescDownLoad(); - if ($("psiInp")) { - var nextIter = document.getElementsByName("NEXT_I"); - for (var i = 0; i < nextIter.length; i++) { - utils.addEvent(nextIter[i], "click", removeRID, false); - } - } - } -} - -//takes care of jQuery calls to elements that have dots in id like id= "SRA34456.3.4" -function initjQry() -{ - var oldCreate = jQuery.ui.ncbipopper.prototype._create; - jQuery.ui.ncbipopper.prototype._create = function() { - var destSelector = this.options.destSelector || this.options.sourceSelector || this.element.prop("hash"); - this.options.destSelector = destSelector.replace(/\./g, "\\."); - oldCreate.apply(this, arguments); - } -} -utils.addEvent(window, - "load", initAdvancedView, - false); - -initjQry() - -/* If user agent has "safari" in it, include safari-specific stylesheet. */ -if (navigator.userAgent.match(/ie/i)) { - document.write(""); -} -/*****************************new code end*********************************************************************/ diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/helix.gif Binary file Blast output page example_files/helix.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/jig.css --- a/Blast output page example_files/jig.css Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1 +0,0 @@ -.ui-helper-hidden{display:none;}.ui-helper-hidden-accessible{position:absolute;left:-99999999px;}.ui-helper-reset{margin:0;padding:0;border:0;outline:0;line-height:1.3;text-decoration:none;font-size:100%;list-style:none;}.ui-helper-clearfix:after{content:".";display:block;height:0;clear:both;visibility:hidden;}.ui-helper-clearfix{display:inline-block;}/* required comment for clearfix to work in Opera \*/ * html .ui-helper-clearfix{height:1%;}.ui-helper-clearfix{display:block;}/* end clearfix */ .ui-helper-zfix{width:100%;height:100%;top:0;left:0;position:absolute;opacity:0;filter:Alpha(Opacity=0);}.ui-state-disabled{cursor:default!important;}.ui-icon{display:block;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat;}.ui-widget-overlay{position:absolute;top:0;left:0;width:100%;height:100%;}.ui-widget{font-size:1.1em;}.ui-widget-content{border:1px solid #aaa;background:#fff url(images/ui-bg_flat_75_ffffff_40x100.png) 50% 50% repeat-x;color:#222;}.ui-widget-content a{color:#222;}.ui-widget-header{border:1px solid #aaa;background:#ccc url(images/ui-bg_highlight-soft_75_cccccc_1x100.png) 50% 50% repeat-x;color:#222;font-weight:bold;}.ui-widget-header a{color:#222;}.ui-state-default,.ui-widget-content .ui-state-default{border:1px solid #d3d3d3;background:#e6e6e6 url(images/ui-bg_glass_75_e6e6e6_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#555;}.ui-state-default a,.ui-state-default a:link,.ui-state-default a:visited{color:#555;text-decoration:none;}.ui-state-hover,.ui-widget-content .ui-state-hover,.ui-state-focus,.ui-widget-content .ui-state-focus{border:1px solid #999;background:#dadada url(images/ui-bg_glass_75_dadada_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#212121;}.ui-state-hover a,.ui-state-hover a:hover{color:#212121;text-decoration:none;}.ui-state-active,.ui-widget-content .ui-state-active{border:1px solid #aaa;background:#fff url(images/ui-bg_glass_65_ffffff_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#212121;}.ui-state-active a,.ui-state-active a:link,.ui-state-active a:visited{color:#212121;text-decoration:none;}.ui-state-highlight,.ui-widget-content .ui-state-highlight{border:1px solid #fcefa1;background:#fbf9ee url(images/ui-bg_glass_55_fbf9ee_1x400.png) 50% 50% repeat-x;color:#363636;}.ui-state-highlight a,.ui-widget-content .ui-state-highlight a{color:#363636;}.ui-state-error,.ui-widget-content .ui-state-error{border:1px solid #cd0a0a;background:#fef1ec url(images/ui-bg_glass_95_fef1ec_1x400.png) 50% 50% repeat-x;color:#cd0a0a;}.ui-state-error a,.ui-widget-content .ui-state-error a{color:#cd0a0a;}.ui-state-error-text,.ui-widget-content .ui-state-error-text{color:#cd0a0a;}.ui-priority-primary,.ui-widget-content .ui-priority-primary{font-weight:bold;}.ui-priority-secondary,.ui-widget-content .ui-priority-secondary{opacity:.7;filter:Alpha(Opacity=70);font-weight:normal;}.ui-state-disabled,.ui-widget-content .ui-state-disabled{opacity:.35;filter:Alpha(Opacity=35);background-image:none;}.ui-icon{width:16px;height:16px;background-image:url(images/ui-icons_222222_256x240.png);}.ui-widget-content .ui-icon{background-image:url(images/ui-icons_222222_256x240.png);}.ui-widget-header .ui-icon{background-image:url(images/ui-icons_222222_256x240.png);}.ui-state-default .ui-icon{background-image:url(images/ui-icons_888888_256x240.png);}.ui-state-hover .ui-icon,.ui-state-focus .ui-icon{background-image:url(images/ui-icons_454545_256x240.png);}.ui-state-active .ui-icon{background-image:url(images/ui-icons_454545_256x240.png);}.ui-state-highlight .ui-icon{background-image:url(images/ui-icons_2e83ff_256x240.png);}.ui-state-error .ui-icon,.ui-state-error-text .ui-icon{background-image:url(images/ui-icons_cd0a0a_256x240.png);}.ui-icon-carat-1-n{background-position:0 0;}.ui-icon-carat-1-ne{background-position:-16px 0;}.ui-icon-carat-1-e{background-position:-32px 0;}.ui-icon-carat-1-se{background-position:-48px 0;}.ui-icon-carat-1-s{background-position:-64px 0;}.ui-icon-carat-1-sw{background-position:-80px 0;}.ui-icon-carat-1-w{background-position:-96px 0;}.ui-icon-carat-1-nw{background-position:-112px 0;}.ui-icon-carat-2-n-s{background-position:-128px 0;}.ui-icon-carat-2-e-w{background-position:-144px 0;}.ui-icon-triangle-1-n{background-position:0 -16px;}.ui-icon-triangle-1-ne{background-position:-16px -16px;}.ui-icon-triangle-1-e{background-position:-32px -16px;}.ui-icon-triangle-1-se{background-position:-48px -16px;}.ui-icon-triangle-1-s{background-position:-64px -16px;}.ui-icon-triangle-1-sw{background-position:-80px -16px;}.ui-icon-triangle-1-w{background-position:-96px -16px;}.ui-icon-triangle-1-nw{background-position:-112px -16px;}.ui-icon-triangle-2-n-s{background-position:-128px -16px;}.ui-icon-triangle-2-e-w{background-position:-144px -16px;}.ui-icon-arrow-1-n{background-position:0 -32px;}.ui-icon-arrow-1-ne{background-position:-16px -32px;}.ui-icon-arrow-1-e{background-position:-32px -32px;}.ui-icon-arrow-1-se{background-position:-48px -32px;}.ui-icon-arrow-1-s{background-position:-64px -32px;}.ui-icon-arrow-1-sw{background-position:-80px -32px;}.ui-icon-arrow-1-w{background-position:-96px -32px;}.ui-icon-arrow-1-nw{background-position:-112px -32px;}.ui-icon-arrow-2-n-s{background-position:-128px -32px;}.ui-icon-arrow-2-ne-sw{background-position:-144px -32px;}.ui-icon-arrow-2-e-w{background-position:-160px -32px;}.ui-icon-arrow-2-se-nw{background-position:-176px -32px;}.ui-icon-arrowstop-1-n{background-position:-192px -32px;}.ui-icon-arrowstop-1-e{background-position:-208px -32px;}.ui-icon-arrowstop-1-s{background-position:-224px -32px;}.ui-icon-arrowstop-1-w{background-position:-240px -32px;}.ui-icon-arrowthick-1-n{background-position:0 -48px;}.ui-icon-arrowthick-1-ne{background-position:-16px -48px;}.ui-icon-arrowthick-1-e{background-position:-32px -48px;}.ui-icon-arrowthick-1-se{background-position:-48px -48px;}.ui-icon-arrowthick-1-s{background-position:-64px -48px;}.ui-icon-arrowthick-1-sw{background-position:-80px -48px;}.ui-icon-arrowthick-1-w{background-position:-96px -48px;}.ui-icon-arrowthick-1-nw{background-position:-112px -48px;}.ui-icon-arrowthick-2-n-s{background-position:-128px -48px;}.ui-icon-arrowthick-2-ne-sw{background-position:-144px -48px;}.ui-icon-arrowthick-2-e-w{background-position:-160px -48px;}.ui-icon-arrowthick-2-se-nw{background-position:-176px -48px;}.ui-icon-arrowthickstop-1-n{background-position:-192px -48px;}.ui-icon-arrowthickstop-1-e{background-position:-208px -48px;}.ui-icon-arrowthickstop-1-s{background-position:-224px -48px;}.ui-icon-arrowthickstop-1-w{background-position:-240px -48px;}.ui-icon-arrowreturnthick-1-w{background-position:0 -64px;}.ui-icon-arrowreturnthick-1-n{background-position:-16px -64px;}.ui-icon-arrowreturnthick-1-e{background-position:-32px -64px;}.ui-icon-arrowreturnthick-1-s{background-position:-48px -64px;}.ui-icon-arrowreturn-1-w{background-position:-64px -64px;}.ui-icon-arrowreturn-1-n{background-position:-80px -64px;}.ui-icon-arrowreturn-1-e{background-position:-96px -64px;}.ui-icon-arrowreturn-1-s{background-position:-112px -64px;}.ui-icon-arrowrefresh-1-w{background-position:-128px -64px;}.ui-icon-arrowrefresh-1-n{background-position:-144px -64px;}.ui-icon-arrowrefresh-1-e{background-position:-160px -64px;}.ui-icon-arrowrefresh-1-s{background-position:-176px -64px;}.ui-icon-arrow-4{background-position:0 -80px;}.ui-icon-arrow-4-diag{background-position:-16px -80px;}.ui-icon-extlink{background-position:-32px -80px;}.ui-icon-newwin{background-position:-48px -80px;}.ui-icon-refresh{background-position:-64px -80px;}.ui-icon-shuffle{background-position:-80px -80px;}.ui-icon-transfer-e-w{background-position:-96px -80px;}.ui-icon-transferthick-e-w{background-position:-112px -80px;}.ui-icon-folder-collapsed{background-position:0 -96px;}.ui-icon-folder-open{background-position:-16px -96px;}.ui-icon-document{background-position:-32px -96px;}.ui-icon-document-b{background-position:-48px -96px;}.ui-icon-note{background-position:-64px -96px;}.ui-icon-mail-closed{background-position:-80px -96px;}.ui-icon-mail-open{background-position:-96px -96px;}.ui-icon-suitcase{background-position:-112px -96px;}.ui-icon-comment{background-position:-128px -96px;}.ui-icon-person{background-position:-144px -96px;}.ui-icon-print{background-position:-160px -96px;}.ui-icon-trash{background-position:-176px -96px;}.ui-icon-locked{background-position:-192px -96px;}.ui-icon-unlocked{background-position:-208px -96px;}.ui-icon-bookmark{background-position:-224px -96px;}.ui-icon-tag{background-position:-240px -96px;}.ui-icon-home{background-position:0 -112px;}.ui-icon-flag{background-position:-16px -112px;}.ui-icon-calendar{background-position:-32px -112px;}.ui-icon-cart{background-position:-48px -112px;}.ui-icon-pencil{background-position:-64px -112px;}.ui-icon-clock{background-position:-80px -112px;}.ui-icon-disk{background-position:-96px -112px;}.ui-icon-calculator{background-position:-112px -112px;}.ui-icon-zoomin{background-position:-128px -112px;}.ui-icon-zoomout{background-position:-144px -112px;}.ui-icon-search{background-position:-160px -112px;}.ui-icon-wrench{background-position:-176px -112px;}.ui-icon-gear{background-position:-192px -112px;}.ui-icon-heart{background-position:-208px -112px;}.ui-icon-star{background-position:-224px -112px;}.ui-icon-link{background-position:-240px -112px;}.ui-icon-cancel{background-position:0 -128px;}.ui-icon-plus{background-position:-16px -128px;}.ui-icon-plusthick{background-position:-32px -128px;}.ui-icon-minus{background-position:-48px -128px;}.ui-icon-minusthick{background-position:-64px -128px;}.ui-icon-close{background-position:-80px -128px;}.ui-icon-closethick{background-position:-96px -128px;}.ui-icon-key{background-position:-112px -128px;}.ui-icon-lightbulb{background-position:-128px -128px;}.ui-icon-scissors{background-position:-144px -128px;}.ui-icon-clipboard{background-position:-160px -128px;}.ui-icon-copy{background-position:-176px -128px;}.ui-icon-contact{background-position:-192px -128px;}.ui-icon-image{background-position:-208px -128px;}.ui-icon-video{background-position:-224px -128px;}.ui-icon-script{background-position:-240px -128px;}.ui-icon-alert{background-position:0 -144px;}.ui-icon-info{background-position:-16px -144px;}.ui-icon-notice{background-position:-32px -144px;}.ui-icon-help{background-position:-48px -144px;}.ui-icon-check{background-position:-64px -144px;}.ui-icon-bullet{background-position:-80px -144px;}.ui-icon-radio-off{background-position:-96px -144px;}.ui-icon-radio-on{background-position:-112px -144px;}.ui-icon-pin-w{background-position:-128px -144px;}.ui-icon-pin-s{background-position:-144px -144px;}.ui-icon-play{background-position:0 -160px;}.ui-icon-pause{background-position:-16px -160px;}.ui-icon-seek-next{background-position:-32px -160px;}.ui-icon-seek-prev{background-position:-48px -160px;}.ui-icon-seek-end{background-position:-64px -160px;}.ui-icon-seek-start{background-position:-80px -160px;}.ui-icon-seek-first{background-position:-80px -160px;}.ui-icon-stop{background-position:-96px -160px;}.ui-icon-eject{background-position:-112px -160px;}.ui-icon-volume-off{background-position:-128px -160px;}.ui-icon-volume-on{background-position:-144px -160px;}.ui-icon-power{background-position:0 -176px;}.ui-icon-signal-diag{background-position:-16px -176px;}.ui-icon-signal{background-position:-32px -176px;}.ui-icon-battery-0{background-position:-48px -176px;}.ui-icon-battery-1{background-position:-64px -176px;}.ui-icon-battery-2{background-position:-80px -176px;}.ui-icon-battery-3{background-position:-96px -176px;}.ui-icon-circle-plus{background-position:0 -192px;}.ui-icon-circle-minus{background-position:-16px -192px;}.ui-icon-circle-close{background-position:-32px -192px;}.ui-icon-circle-triangle-e{background-position:-48px -192px;}.ui-icon-circle-triangle-s{background-position:-64px -192px;}.ui-icon-circle-triangle-w{background-position:-80px -192px;}.ui-icon-circle-triangle-n{background-position:-96px -192px;}.ui-icon-circle-arrow-e{background-position:-112px -192px;}.ui-icon-circle-arrow-s{background-position:-128px -192px;}.ui-icon-circle-arrow-w{background-position:-144px -192px;}.ui-icon-circle-arrow-n{background-position:-160px -192px;}.ui-icon-circle-zoomin{background-position:-176px -192px;}.ui-icon-circle-zoomout{background-position:-192px -192px;}.ui-icon-circle-check{background-position:-208px -192px;}.ui-icon-circlesmall-plus{background-position:0 -208px;}.ui-icon-circlesmall-minus{background-position:-16px -208px;}.ui-icon-circlesmall-close{background-position:-32px -208px;}.ui-icon-squaresmall-plus{background-position:-48px -208px;}.ui-icon-squaresmall-minus{background-position:-64px -208px;}.ui-icon-squaresmall-close{background-position:-80px -208px;}.ui-icon-grip-dotted-vertical{background-position:0 -224px;}.ui-icon-grip-dotted-horizontal{background-position:-16px -224px;}.ui-icon-grip-solid-vertical{background-position:-32px -224px;}.ui-icon-grip-solid-horizontal{background-position:-48px -224px;}.ui-icon-gripsmall-diagonal-se{background-position:-64px -224px;}.ui-icon-grip-diagonal-se{background-position:-80px -224px;}.ui-corner-tl{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;}.ui-corner-tr{-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;}.ui-corner-bl{-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;}.ui-corner-br{-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-top{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;}.ui-corner-bottom{-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-right{-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-left{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;}.ui-corner-all{-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px;}.ui-widget-overlay{background:#aaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x;opacity:.30;filter:Alpha(Opacity=30);}.ui-widget-shadow{margin:-8px 0 0 -8px;padding:8px;background:#aaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x;opacity:.30;filter:Alpha(Opacity=30);-moz-border-radius:8px;-webkit-border-radius:8px;border-radius:8px;}.ui-widget{font-family:arial,"sans-serif"!important;font-size:100%;}.ui-helper-reset{font-size:100%!important;}iframe.ui-ncbi-iframe-fix{position:absolute;top:0;left:0;height:200px;z-index:3000;display:block;filter:alpha(opacity=1);}#ui-datepicker-div{display:none;}.ui-widget-content a{color:#2F4A8B;}.ui-helper-hidden-accessible{left:-10000000px!important;}#jig-ncbi_requires_login iframe{border:none;} \ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 Blast output page example_files/jig.js --- a/Blast output page example_files/jig.js Thu May 15 16:53:04 2014 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,265 +0,0 @@ -(function(){function Ka(){var g=null,j=jQuery.cookie("WebCubbyUser");if(j)if(j.indexOf("logged-in=true")>-1)if(j=j.match(/my-name=([^;]+)/i))g=j[1];return g}function W(g){this.name=this.selector="";this.onPage=false;this.dependsOn=[];this.interactions=[];this.overrideDefaults={};this.addCss=function(){document.write('')};this.addJs=function(){document.write(' +NCBI Blast:Nucleotide Sequence (16 letters) + + + + + + + + + + + + + + +
+ + +
+ + +
+ +
+ + + + + + + + + + + +
+ + +
  • Your search parameters were adjusted to search for a short input sequence.

+ Edit and Resubmit + +[Sign in above to save your search strategy] + + + +How to read this page +Blast report description + +
+ + + + + +
+ +
+ +
+
+ +
+
+ + +

+
+ +
+
+

Nucleotide Sequence (16 letters)

+
+ + +
+ +
+
+
+
+
RID
+
+PHWP1JNZ014 (Expires on 05-07 22:33 pm) +
+
+
+
+
Query ID
+ +
lcl|59987
+
Description
+
None
+
Molecule type
+
nucleic acid
+
Query Length
+
16
+
+
+ +
+
+
+
Database Name
+
pdb
+
Description
+
PDB nucleotide database
+
Program
+
BLASTN 2.2.29+
+
+
+
+
+
+ +
+
+ +
+ + + +
+ +
+
+
+ + + + + + +
+
+ +
+
+ + + + +
+
+ + + + + + +
+
+ + + +
+
+ +
+
+ + + + + + + + + + +
+ +
+

+ +Alignments + + +

+ +
+
+
+
+
+ + + +GenBankGraphics + + + +Next +Previous +Descriptions + +
+
+
+
+Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Classic Post- Translocation State (post1, 50s Subunit) +
pdb|3J5A|A29034
+
+
+
+ +
+ + + + + + + + + + + + + +
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
+ +
+
+
Query  1    CGTCCGTCGTGAAGAG  16
+            ||||||||||||||||
+Sbjct  961  CGTCCGTCGTGAAGAG  976
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
+ +
+
+
Query  5     CGTCGTGA  12
+             ||||||||
+Sbjct  2591  CGTCGTGA  2598
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  7    TCGTGAA  13
+            |||||||
+Sbjct  839  TCGTGAA  845
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  9     GTGAAGA  15
+             |||||||
+Sbjct  2027  GTGAAGA  2033
+
+
+
+
+
+
+
+ + + +GenBankGraphics + + + +Next +Previous +Descriptions + +
+
+
+
+Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre5b, 50s Subunit) +
pdb|3J58|A29034
+
+
+
+ +
+ + + + + + + + + + + + + +
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
+ +
+
+
Query  1    CGTCCGTCGTGAAGAG  16
+            ||||||||||||||||
+Sbjct  961  CGTCCGTCGTGAAGAG  976
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
+ +
+
+
Query  5     CGTCGTGA  12
+             ||||||||
+Sbjct  2591  CGTCGTGA  2598
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  7    TCGTGAA  13
+            |||||||
+Sbjct  839  TCGTGAA  845
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  9     GTGAAGA  15
+             |||||||
+Sbjct  2027  GTGAAGA  2033
+
+
+
+
+
+
+
+ + + +GenBankGraphics + + + +Next +Previous +Descriptions + +
+
+
+
+Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre5a, 50s Subunit) +
pdb|3J56|A29034
+
+
+
+ +
+ + + + + + + + + + + + + +
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
+ +
+
+
Query  1    CGTCCGTCGTGAAGAG  16
+            ||||||||||||||||
+Sbjct  961  CGTCCGTCGTGAAGAG  976
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
+ +
+
+
Query  5     CGTCGTGA  12
+             ||||||||
+Sbjct  2591  CGTCGTGA  2598
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  7    TCGTGAA  13
+            |||||||
+Sbjct  839  TCGTGAA  845
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  9     GTGAAGA  15
+             |||||||
+Sbjct  2027  GTGAAGA  2033
+
+
+
+
+
+
+
+ + + +GenBankGraphics + + + +Next +Previous +Descriptions + +
+
+
+
+Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Hybrid Pre- Translocation State (pre4, 50s Subunit) +
pdb|3J54|A29034
+
+
+
+ +
+ + + + + + + + + + + + + +
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
+ +
+
+
Query  1    CGTCCGTCGTGAAGAG  16
+            ||||||||||||||||
+Sbjct  961  CGTCCGTCGTGAAGAG  976
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
+ +
+
+
Query  5     CGTCGTGA  12
+             ||||||||
+Sbjct  2591  CGTCGTGA  2598
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  7    TCGTGAA  13
+            |||||||
+Sbjct  839  TCGTGAA  845
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  9     GTGAAGA  15
+             |||||||
+Sbjct  2027  GTGAAGA  2033
+
+
+
+
+
+
+
+ + + +GenBankGraphics + + + +Next +Previous +Descriptions + +
+
+
+
+Chain A, E. Coli 70s-fmetval-trnaval-trnafmet Complex In Classic Pre- Translocation State (pre1a, 50s Subunit) +
pdb|3J52|A29034
+
+
+
+ +
+ + + + + + + + + + + + + +
Alignment statistics for match #1
ScoreExpectIdentitiesGapsStrandFrame
32.2 bits(16)8e-04()16/16(100%)0/16(0%)Plus/Plus
+ +
+
+
Query  1    CGTCCGTCGTGAAGAG  16
+            ||||||||||||||||
+Sbjct  961  CGTCCGTCGTGAAGAG  976
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #2
ScoreExpectIdentitiesGapsStrandFrame
16.4 bits(8) 47()8/8(100%)0/8(0%)Plus/Plus
+ +
+
+
Query  5     CGTCGTGA  12
+             ||||||||
+Sbjct  2591  CGTCGTGA  2598
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #3
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  7    TCGTGAA  13
+            |||||||
+Sbjct  839  TCGTGAA  845
+
+
+
+
+
+ + + + + + + + + + + + + +
Alignment statistics for match #4
ScoreExpectIdentitiesGapsStrandFrame
14.4 bits(7) 186()7/7(100%)0/7(0%)Plus/Plus
+ +
+
+
Query  9     GTGAAGA  15
+             |||||||
+Sbjct  2027  GTGAAGA  2033
+
+
+
+
+
+
+
+ +
+
+
+
+
+
+ +
+
+ + + + +
+
+
+ + + + + + + + + + + + + +
+ +
+ + + + +
+ +
+ + + +
+
+ + + +
+ + + + + + + + + + + + + \ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/1.gif Binary file NCBI Blast reference example_files/1.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/2.gif Binary file NCBI Blast reference example_files/2.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/3.gif Binary file NCBI Blast reference example_files/3.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/5.gif Binary file NCBI Blast reference example_files/5.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/6.gif Binary file NCBI Blast reference example_files/6.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/9.gif Binary file NCBI Blast reference example_files/9.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/InstrumentPageStarterJS.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/InstrumentPageStarterJS.js Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,86 @@ +(function(){if(typeof ncbi==="undefined")ncbi={};if(ncbi.sg)typeof console!=="undefined"&&console.error&&console.error("The logging JavaScript was added twice in the document. Please include it one time.");else{ncbi.sg=function(){};ncbi.sg.getInstance=function(){if(!ncbi.sg._instance)ncbi.sg._instance=new ncbi.sg;return ncbi.sg._instance};ncbi.sg._instance=null;ncbi.sg._version="26";(function(){var a=navigator.cookieEnabled?true:false;if(typeof navigator.cookieEnabled==="undefined"&&!a){document.cookie= +"testcookie";a=document.cookie.indexOf("testcookie")!==-1?true:false}ncbi.sg.isCookieEnabled=a})();ncbi.sg.appLogIgnore=["ncbi_sessionid","ncbi_clickdisabled"];ncbi.sg.prototype={init:function(){this.isProcessRunning=true;this._setUpMetaTagValues();this._setScrollingEnabled();if(this._cachedVals.ncbi_db&&this._cachedVals.ncbi_db.value.toLowerCase()=="pubmed"&&this._cachedVals.ncbi_report&&this._cachedVals.ncbi_report.value.toLowerCase()=="abstract"&&this._cachedVals.ncbi_resultcount&&this._cachedVals.ncbi_resultcount.value.toLowerCase()== +"1"||this._cachedVals.ncbi_db&&this._cachedVals.ncbi_db.value.toLowerCase()=="pmc"&&this._cachedVals.ncbi_report&&this._cachedVals.ncbi_report.value.toLowerCase()=="record"&&this._cachedVals.ncbi_type&&this._cachedVals.ncbi_type.value.toLowerCase()=="fulltext")ncbi.sg.isHoverEnabled=true;this._setUpPathParts();this._setUpCustomProps();this._addOnScrollListeners();this._send("init");this._scheduleDOMReadyPing();this._sendPrev();this._addPrintPing();this._setBeforeScrollDetails()},_vals:{},_cachedVals:{}, +_hasInitRun:false,_readyPinged:false,_pathParts:{part1:"",part2:"",part3:"",part4:""},_scheduleDOMReadyPing:function(){var a=this,b=function(){return typeof jQuery!=="undefined"&&typeof jQuery.ui!=="undefined"&&typeof jQuery.ui.jig!=="undefined"?typeof jQuery.ui.jig.version!=="undefined"&&jQuery.ui.jig.version?jQuery.ui.jig.version:"unknown":"unknown"},d=function(){var k={},j=jQuery.ui.jig._foundWidgets;for(var t in j)k["jigWidget_"+t]=j[t];k.jigVersion=b();return k},c=function(){if(!a._readyPinged){var k= +{};if(typeof jQuery!=="undefined"&&typeof jQuery.ui!=="undefined"&&typeof jQuery.ui.jig!=="undefined"&&typeof jQuery.ui.jig.scanned!=="undefined")if(jQuery.ui.jig.scanned){k=d();k.jsevent="domready";ncbi.sg._ping(k);a._readyPinged=true}else{if(typeof jQuery.ui.jig.scan!=="undefined"&&jQuery.ui.jig.scan){var j=jQuery.ui.jig.scan;jQuery.ui.jig.scan=function(){var t=j.apply(this,arguments);c();return t}}}else{k.jigVersion="nojig";k.jsevent="domready";ncbi.sg._ping(k);a._readyPinged=true}}};if(document.addEventListener){var e= +function(){document.removeEventListener("DOMContentLoaded",e,false);c()};document.addEventListener("DOMContentLoaded",e)}else if(document.attachEvent){var g=function(){if(document.readyState==="complete"){document.detachEvent("onreadystatechange",g);c()}};document.attachEvent("onreadystatechange",g)}},_setScrollingEnabled:function(){try{ncbi.sg.isScrollingEnabled=false;var a=ncbi.sgAppsWithScrolling;if(typeof a!=="undefined")for(var b=0;b100&&this.ignoreLengthRestrictions.indexOf(a)===-1)b=b.substr(0,100);this._cachedVals[a]={sProp:a,value:b}}},getVal:function(a){return typeof this._cachedVals[a]!=="undefined"&&this._cachedVals[a]&&typeof this._cachedVals[a].value!=="undefined"? +this._cachedVals[a].value:null},removeAllEntries:function(){for(var a={},b=this.cachedNames.length,d=0;d0?":"+this._pathParts.part2:"",d=this._pathParts.part3.length>0?":"+this._pathParts.part3:"",c=this._pathParts.part4.length>0?":"+this._pathParts.part4:"";a={pagename:a+b+ +d,server:window.location.hostname,sitesect2:a+b,subsect3:a+b+d,subsect4:a+b+d+c,heir1:(a+b+d+c).replace(/:/g,"|")};for(var e in a)this.addEntry(e,a[e]);this._sessionIdCheck();this._staticPageCheck();this._prevHitCheck();this._browserConfigurationSettings();this._hashCheck()},_staticPageCheck:function(){this._cachedVals.ncbi_app&&this._cachedVals.ncbi_app.value.length>0||this.addEntry("ncbi_app","static");this._cachedVals.ncbi_pdid&&this._cachedVals.ncbi_pdid.value.length>0||this.addEntry("ncbi_pdid", +(document.title||"unknown").replace(/\s+/g,""))},_sessionIdCheck:function(){if(!(this._cachedVals.ncbi_sessionid&&this._cachedVals.ncbi_sessionid.value.length>0)){var a="";if(a.length===0){var b=this.getCookie("WebCubbyUser")||this.getCookie("WebEnv");if(b.length>0){b=unescape(b).split("@");if(b.length>1)a=b[b.length-1]}}if(a.length===0)a="NOSESSIONID";this.addEntry("ncbi_sessionid",a)}},getBrowserWidthHeight:function(){var a=this.getViewportWidth(),b=this.getViewportHeight();return{width:a,height:b}}, +_browserConfigurationSettings:function(){var a=this.getBrowserWidthHeight();this.addEntry("browserwidth",a.width);this.addEntry("browserheight",a.height);this.addEntry("screenwidth",screen.width);this.addEntry("screenheight",screen.height);this.addEntry("screenavailwidth",screen.availWidth);this.addEntry("screenavailheight",screen.availHeight);if(document&&document.body){var b=document.body.scrollWidth,d=document.body.scrollHeight,c=d>a.height?"true":"false";this.addEntry("canscroll_x",b>a.width? +"true":"false");this.addEntry("canscroll_y",c);this.addEntry("scrollwidth",b);this.addEntry("scrollheight",d)}if(screen.colorDepth)this.addEntry("colorDepth",screen.colorDepth);else screen.pixelDepth&&this.addEntry("colorDepth",screen.pixelDepth)},_hashCheck:function(){var a=window.location.hash;if(a){a=a.replace("#","");this.addEntry("urlhash",a)}(a=window.location.search.match(/[?&]campaign=([^&]*)/))&&this.addEntry("campaign",a[1])},_createPHID:function(){var a=this._cachedVals.ncbi_sessionid.value, +b=a.substr(0,15)+"9"+(new Date).getTime().toString(),d=a.length;b+=a.substr(d-(32-b.length),d);a={value:b};this.addEntry("ncbi_phid",b);return a},currentPageHitId:null,_prevHitCheck:function(){var a=this.getCookie("ncbi_prevPHID"),b=this._cachedVals.ncbi_phid;a.length>0&&this.addEntry("prev_phid",a);if(!b||!b.value||b.value.length===0)b=this._createPHID();this.currentPageHitId=b.value;var d=this;ncbi.sg._hasFocus&&d.setCookie("ncbi_prevPHID",b.value);var c=window.onfocus;window.onfocus=function(e){d.getCookie("ncbi_prevPHID")!== +b.value&&d.setCookie("ncbi_prevPHID",b.value);typeof c==="function"&&c(e)}},_setUpPathParts:function(){var a=this._cachedVals.ncbi_app,b=this._cachedVals.ncbi_db,d=this._cachedVals.ncbi_pdid,c=this._cachedVals.ncbi_pcid;this._pathParts.part1=a!==undefined?a.value:"";this._pathParts.part2=b!==undefined?b.value:"";this._pathParts.part3=d!==undefined?d.value:"";this._pathParts.part4=c!==undefined?c.value:""},getPerfStats:function(){var a=window.performance;if(!a)return{};var b=a.timing;if(b)b={dns:b.domainLookupEnd- +b.domainLookupStart,connect:b.connectEnd-b.connectStart,ttfb:b.responseStart-b.connectEnd,basePage:b.responseEnd-b.responseStart,frontEnd:b.loadEventStart-b.responseEnd};else return{};if(a=a.navigation){b.navType=a.type;b.redirectCount=a.redirectCount}return b},setPerfStats:function(a,b){var d=this.getPerfStats();for(var c in d){var e=d[c];if(e>=0){var g="jsperf_"+c;if(b)a[g]=e;else a.push(g+"="+e)}}},getExtraRenderStats:function(){var a={SELF_URL:encodeURIComponent(window.location.href)};if(typeof document!== +"undefined"&&typeof document.referrer!=="undefined")a.HTTP_REFERER=encodeURIComponent(document.referrer);return a},setExtraRenderStats:function(a){var b=this.getExtraRenderStats();for(var d in b)a.push(d+"="+b[d])},_send:function(a,b,d){if(typeof d==="undefined"||d===null)d=true;var c=[];if(a==="init"){c.push("jsevent=render");ncbi.sg.renderTime=new Date;if(typeof ncbi_startTime!=="undefined"){c.push("jsrendertime="+(ncbi.sg.renderTime-ncbi_startTime));ncbi.sg.loadTime&&c.push("jsloadtime="+(ncbi.sg.loadTime- +ncbi_startTime))}this.setPerfStats(c);this.setExtraRenderStats(c);c.push("cookieenabled="+(ncbi.sg.isCookieEnabled?"true":"false"))}for(var e in this._cachedVals)ncbi.sg.appLogIgnore.indexOf(e)===-1&&c.push(e+"="+encodeURIComponent(this._cachedVals[e].value));this._sendAl(c.join("&"),b,true,d);this._hasInitRun=true;var g=this;setTimeout(function(){g.isProcessRunning=false;g.runSGProcess()},300)},send:function(a,b){this._send(a,b,false)},_sendPrev:function(){var a=ncbi.sg.getInstance(),b=a.getCookie("clicknext"); +if(b){ncbi.sg._ping(b);a.setCookie("clicknext","")}if(b=a.getCookie("prevsearch")){ncbi.sg._ping(b);a.setCookie("prevsearch","")}if(b=a.getCookie("unloadnext")){ncbi.sg._ping(b);a.setCookie("unloadnext","")}},_sendAl:function(a,b,d,c){if(typeof c==="undefined"||c===null)c=true;if(a.indexOf("jseventms")===-1)a+="&jseventms="+ncbi.sg.getInstance().getMillisecondsSinceSunday();a.match(/jsevent=search/i)&&this._storeNext("prevsearch",a.replace(/jsevent=search(next)?/i,"jsevent=searchnext"),null,c);a+= +"&sgVersion="+ncbi.sg._version;if(a.indexOf("sgSource")===-1)a=this._setSgSource(a,c);c=window.location.port?":"+window.location.port:"";reqURL=typeof __ncbi_stat_url!=="undefined"?__ncbi_stat_url+"?"+a:window.location.protocol+"//"+window.location.hostname+c+"/stat?"+a;this.makeAjaxCall(reqURL,function(){typeof b==="function"&&b()},d)},sendAl:function(a,b,d){this._sendAl(a,b,d,false)},_processingQueue:[],isProcessRunning:false,addSGProcess:function(a){this._processingQueue.push(a)},getSGProcess:function(a){return this._processingQueue.shift(a)}, +runSGProcess:function(){if(this.isProcessRunning||this._processingQueue.length===0||!this._hasInitRun)return false;this.isProcessRunning=true;this.removeAllEntries();var a=this.getSGProcess();this._setUpCachedMetaTagValues(a.metadata);this.addEntry("jsevent",a.eventName);for(var b in a.props)this.addEntry(b,a.props[b]);this._send(a.eventName,a.callbackFnc);var d=this;setTimeout(function(){d.isProcessRunning=false;d.runSGProcess()},300)},noteEventData:function(a,b,d,c){this.addSGProcess({eventName:a, +props:b,metadata:d,callback:c});this.runSGProcess()},setCookie:function(a,b,d){if(window.sessionStorage)try{sessionStorage.setItem(a,b)}catch(c){}var e=new Date;d!==null&&e.setDate(e.getDate()+d);document.cookie=a+"="+escape(b)+(d===null?"":"; expires="+e.toGMTString())+"; domain="+escape(".nih.gov")+"; path=/"},_setSgSource:function(a,b){a+="&sgSource="+(b?"native":"api");return a},_storeNext:function(a,b,d,c){if(typeof c==="undefined"||c===null)c=true;b=this._setSgSource(b,c);this.setCookie(a,b, +d)},getCookie:function(a){var b;if(window.sessionStorage){try{b=sessionStorage.getItem(a)||""}catch(d){b=""}if(b.length>0)return b}if(document.cookie.length>0){b=document.cookie.indexOf(a+"=");if(b!==-1){b=b+a.length+1;a=document.cookie.indexOf(";",b);if(a===-1)a=document.cookie.length;return unescape(document.cookie.substring(b,a))}}return""},getTransport:function(){var a=null;if(window.XMLHttpRequest)try{a=new XMLHttpRequest;this.getTransport=function(){return new XMLHttpRequest}}catch(b){a=null}if(window.ActiveXObject&& +a===null)try{a=new ActiveXObject("Msxml2.XMLHTTP");this.getTransport=function(){return new ActiveXObject("Msxml2.XMLHTTP")}}catch(d){try{a=new ActiveXObject("Microsoft.XMLHTTP");this.getTransport=function(){return new ActiveXObject("Microsoft.XMLHTTP")}}catch(c){a=false}}if(a===null)this.getTransport=function(){return null};return this.getTransport()},makeAjaxCall:function(a,b,d){var c=this.getTransport();c._ncbi_skipOverride=true;c.open("GET",a,d);if(d)c.onreadystatechange=function(){c.readyState=== +4&&b(c)};ncbi.sg.lastPing=c;c.send(null);return c},scrollDetails:{maxScroll_x:0,maxScroll_y:0,currScroll_x:0,currScroll_y:0,hasScrolled:false},scrollEventDetails:{xTenths:0,yTenths:0,xMax:0,yMax:0},_getScrollXYPx:function(){return[window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0,window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0]},_getScrollXY:function(){var a=this.getViewportHeight(),b=this.getViewportWidth(),d=document.body.scrollHeight, +c=document.body.scrollWidth,e=this._getScrollXYPx(),g=Math.round(e[1]/a*10)/10;return{xRel:Math.round(e[0]/b*10)/10,yRel:g,viewportHeight:a,viewportWidth:b,pageHeight:d,pageWidth:c}},_addOnScrollListeners:function(){var a=window.onscroll,b=this;window.onscroll=function(){if(ncbi.sg.isScrollingEnabled){b._setScrollDetails();b.scrollDetails.hasScrolled=true;b._addScrollEvent()}else{b._setScrollDetails();b.scrollDetails.hasScrolled=true}if(typeof a==="function")return a()}},getViewportHeight:function(){return window.innerHeight? +window.innerHeight:document.documentElement&&document.documentElement.clientHeight?document.documentElement.clientHeight:document.body!==null?document.body.clientHeight:"NA"},getViewportWidth:function(){return window.innerWidth?window.innerWidth:document.documentElement&&document.documentElement.clientWidth?document.documentElement.clientWidth:document.body!==null?document.body.clientWidth:"NA"},_setScrollDetails:function(){this.scrollDetails.currScroll_y=window.pageYOffset||document.documentElement.scrollTop|| +document.body.scrollTop||0;this.scrollDetails.currScroll_x=window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0;this.getViewportWidth();this.getViewportHeight();if(this.scrollDetails.maxScroll_y0){e-=parseInt(a.scrollTop);d=true}if(a.scrollLeft&&a.scrollLeft>0){c-=parseInt(a.scrollLeft);b=true}if(a.offsetParent){b=this.findElementPos(a.offsetParent, +b,d);if(b==-1)return-1;c+=b[0];e+=b[1]}else if(a.ownerDocument){var g=a.ownerDocument.defaultView;if(!g&&a.ownerDocument.parentWindow)g=a.ownerDocument.parentWindow;if(g){var k=g.pageXOffset!==undefined?g.pageXOffset:(a.document.documentElement||a.document.body.parentNode||a.document.body).scrollLeft;a=g.pageYOffset!==undefined?g.pageYOffset:(a.document.documentElement||a.document.body.parentNode||a.document.body).scrollTop;if(!d&&a&&a>0)e-=parseInt(a);if(!b&&k&&k>0)c-=parseInt(k);if(g.frameElement){b= +this.findElementPos(g.frameElement);if(b==-1)return-1;c+=b[0];e+=b[1]}}}return[c,e]},addObjData:function(a,b){for(var d in b)a[d]=b[d]},getJoinedData:function(a){var b=[];for(var d in a)b.push(d+"="+encodeURIComponent(a[d]));return b.join("&")},addScrollHeadingData:function(a,b){var d=this.scrollEventDetails.headings;if(d){a["numHeadings."+this._scrollOrder+".scrollInfo"]=d.length;for(var c=0;c=0&&g<=A&&j+y>=0&&j<=B)if(this.isVisible(e)){w.visible=true;a.push(w)}}}return a},_setBeforeScrollDetails:function(a){this._lastScroll=a?a:null;a=this._getScrollXY();var b= +a.yRel;this.scrollEventDetails.xTenths=Math.round(a.xRel*10);this.scrollEventDetails.yTenths=Math.round(b*10);this.scrollEventDetails.xMax=Math.max(this.scrollEventDetails.xTenths,this.scrollEventDetails.xMax);this.scrollEventDetails.yMax=Math.max(this.scrollEventDetails.yTenths,this.scrollEventDetails.yMax);this.scrollEventDetails.headings=this.getVisibleHeadings()},getScrollDetails:function(a,b){if(!ncbi.sg.isScrollingEnabled){this._setScrollDetails();return this.scrollDetails}var d=this.scrollEventDetails; +d.tstamp=(new Date).getTime();var c=this._getScrollXY(),e=null;if(b||!this._lastScroll||d.tstamp-this._lastScroll>1E3){this._scrollOrder=this._scrollOrder!=undefined?this._scrollOrder+1:0;b="yTenths."+this._scrollOrder+".scrollInfo";e="xTenths."+this._scrollOrder+".scrollInfo";var g="maxXTenths."+this._scrollOrder+".scrollInfo",k="maxYTenths."+this._scrollOrder+".scrollInfo",j={};j["duration."+this._scrollOrder+".scrollInfo"]=this._lastScroll?d.tstamp-this._lastScroll:new Date-ncbi.sg.loadTime;j[e]= +this.scrollEventDetails.xTenths;j[b]=this.scrollEventDetails.yTenths;j[g]=this.scrollEventDetails.xMax;j[k]=this.scrollEventDetails.yMax;j["viewportHeight."+this._scrollOrder+".scrollInfo"]=c.viewportHeight;j["viewportWidth."+this._scrollOrder+".scrollInfo"]=c.viewportWidth;j["maxPossibleScrollTenthsY."+this._scrollOrder+".scrollInfo"]=Math.round((c.pageHeight/c.viewportHeight-1)*10);j["maxPossibleScrollTenthsX."+this._scrollOrder+".scrollInfo"]=Math.round((c.pageWidth/c.viewportWidth-1)*10);e=j= +this.addScrollHeadingData(j,a)}this._setBeforeScrollDetails(d.tstamp);return e},getScrollDetailsAr:function(a,b){var d=[];a=this.getScrollDetails(a,b);for(var c in a)d.push(c+"="+encodeURIComponent(a[c]));return d},addScrollDetailsAr:function(a,b,d){b=this.getScrollDetailsAr(b,d);for(d=0;d0)for(;y.length>0;)d(y.pop());var f={jsevent:"unload",ncbi_pingaction:"unload"};if(typeof ncbi_startTime!=="undefined"){f.ncbi_timeonpage=new Date-ncbi_startTime;if(typeof ncbi_onloadTime!=="undefined"&&ncbi_onloadTime)f.ncbi_onloadTime=ncbi_onloadTime-ncbi_startTime}var i=ncbi.sg.getInstance();i.setPerfStats(f,true);i.addScrollDetails(f, +1800-i.getJoinedData(f).length,true);if(!w){ncbi.sg._ping(f);var m="";for(var l in f)m+=l+"="+(l==="jsevent"?"unloadnext":f[l])+"&";m+="ncbi_phid="+i.currentPageHitId;i._storeNext("unloadnext",m,null)}w=true}function b(f){for(var i=y.length-1;i>=-1;i--)if(y[i]===f){y.slice(i,1);break}d(f)}function d(f,i){if(A.indexOf(f.tstamp)===-1){A.push(f.tstamp);B.push(f);c("click",f,i)}}function c(f,i,m,l){if(typeof l==="undefined"||l===null)l=true;var n=f==="click"?"link":"elem",h=i.link,o=i.evt,p=h.id||"", +x=h.name||"",F=h.sid||"",G=h.href||"",C=h.innerText||h.textContent||"";if(C.length>50)C=C.substr(0,50);var H=h.getAttribute?h.getAttribute("ref")||h.ref||"":"",I=h.className?h.className.replace(/^\s?/,"").replace(/\s?$/,"").split(/\s/g).join(",")||"":"";i=[];var D=[],z=h.parentNode;if(z)for(var r=0;r<6&&z!==null;r++){(parId=z.id)&&i.push(parId);if(parClassName=z.className)D=D.concat(parClassName.split(/\s/));z=z.parentNode}z=ncbi.sg.getInstance();r=z.currentPageHitId||"";var q=[];p.length>0&&q.push(n+ +"_id="+encodeURIComponent(p));x.length>0&&q.push(n+"_name="+encodeURIComponent(x));F.length>0&&q.push(n+"_sid="+encodeURIComponent(F));G.length>0&&q.push(n+"_href="+encodeURIComponent(G));C.length>0&&q.push(n+"_text="+encodeURIComponent(C));I.length>0&&q.push(n+"_class="+encodeURIComponent(I));r=z.getBrowserWidthHeight();r.width!==null&&q.push("browserwidth="+encodeURIComponent(r.width));r.height!==null&&q.push("browserheight="+encodeURIComponent(r.height));for(var E in o){r=o[E];r!==undefined&&q.push(E.toLowerCase()+ +"="+r.toString())}q.push("jsevent="+f);H.length>0&&q.push(H);if(typeof jQuery!=="undefined")if(h=jQuery(h).attr("sg")){h=h.split(/\}\s*,\s*\{/);for(r=0;r0)for(;m.length>0;)q.push(m.shift());i.length>0&&q.push("ancestorId="+i.join(","));D.length>0&&q.push("ancestorClassName="+D.join(",").replace(/\s+/g," ").replace(/(^\s|\s$)/g, +""));z.addScrollDetailsAr(q,1800-q.join("&").length,true);if(f==="click"){f=q.join("&").replace("jsevent=click","jsevent=clicknext");r=ncbi.sg.getInstance().currentPageHitId||"";f+="&ncbi_phid="+r;z._storeNext("clicknext",f,null,l)}ncbi.sg._ping(q,true,null,null,l)}function e(f){var i={};if(f){if(f.clientX||f.clientY){var m=ncbi.sg.getInstance()._getScrollXYPx();i.evt_coor_x=f.clientX+m[0];i.evt_coor_y=f.clientY+m[1]}else if(f.pageX||f.pageY){i.evt_coor_x=f.pageX;i.evt_coor_y=f.pageY}i.jseventms= +ncbi.sg.getInstance().getMillisecondsSinceSunday()}return i}function g(f,i,m,l,n){var h={},o=null,p=null;if(typeof i==="string"){o=i;p=m}else{h=e(i);o=m;p=l}if(p){i=typeof p;if(i==="string")p=[p];else if(i==="object"&&!(p instanceof Array)){i=[];for(var x in p)i.push(x+"="+p[x]);p=i}}c(o,{link:f,evt:h},p,n)}function k(f,i,m){var l=[];if(typeof i==="undefined")i=true;if(typeof f==="object"&&!(f instanceof Array))for(var n in f)l.push(n+"="+encodeURIComponent(f[n]));else if(typeof f==="string")l.push(f); +else l=f;f=ncbi.sg.getInstance().currentPageHitId||"";n=null;if(typeof ncbi.sg.loadTime!=="undefined")n=new Date-ncbi.sg.loadTime;var h=l.join("&");if(h.indexOf("jsevent=clicknext")!==-1||h.indexOf("jsevent=searchnext")!==-1||h.indexOf("jsevent=unloadnext")!==-1){f.length>0&&l.push("next_phid="+encodeURIComponent(f));n!==null&&l.push("next_ncbi_timesinceload="+n)}else{f.length>0&&l.push("ncbi_phid="+encodeURIComponent(f));n!==null&&l.push("ncbi_timesinceload="+n)}ncbi.sg.getInstance()._sendAl(l.join("&"), +null,i,m)}var j=window.onerror;window.onerror=function(f,i,m){if(!ncbi.sg.hasNotedErrorEvent){ncbi.sg.getInstance().noteEventData("jserror",{jserror:f,jserrorlocation:i,jserrorline:m,SELF_URL:window.location.href},["ncbi_sessionid","ncbi_phid"]);ncbi.sg.hasNotedErrorEvent=true;if(typeof j==="function")return j(f,i,m)}};var t=window.onbeforeunload;window.onbeforeunload=function(f){a();if(typeof t==="function")return t(f)};var y=[],A=[],B=[],w=false;ncbi.sg.sendElementEvent=function(f,i,m){c(f,i,m, +false)};ncbi.sg.clickTimers=[];if(typeof ncbi.sg.isClickEnabled==="undefined"){for(var v=document.getElementsByTagName("meta"),u=v.length-1,s=true;u>=0;){if(v[u].name.toLowerCase()==="ncbi_clickdisabled"){s=v[u].content.toLowerCase()==="false";break}u--}ncbi.sg.isClickEnabled=s}setClickEvent=function(){var f=function(h){return(h=typeof h.parentNode!=="undefined"?h.parentNode:null)?m(h)?h:f(h):false},i=function(h){h=h.target||h.srcElement;if(typeof h=="undefined"||h==null)return null;if(h.nodeType== +3)h=target.parentNode;m(h)||(h=f(h));return h},m=function(h){var o=typeof h.tagName!=="undefined"?h.tagName.toLowerCase():null,p=false,x=false;if(typeof jQuery!=="undefined")p=jQuery(h).is("button, input[type=button], input[type=submit], input[type=reset]");else if(o==="input"){h=inp.type;p=h=="button"||h=="submit"||h=="reset"}else p=o==="button"?true:false;p||(x=o=="a"||o=="area");return x?"link":p?"button":null},l=function(h,o,p,x){if(!(x&&x=="click"&&h.which&&h.which==3))if(!(!o||m(o)==null)){ncbi.sg.getInstance().setCookie("ncbi_prevPHID", +ncbi.sg.getInstance().currentPageHitId);h=e(h);h.iscontextmenu=x=="contextmenu"?"true":"false";o={evt:h,link:o,tstamp:(new Date).getTime(),floodTstamp:(new Date).getTime()};b(o);ncbi.sg.clickTimers&&window.clearTimeout(ncbi.sg.clickTimers);ncbi.sg.clickTimers=window.setTimeout(function(){ncbi.sg.clickTimers=null},300)}};if(window.addEventListener){window.addEventListener("click",function(h){l(h,i(h),[],"click")});window.addEventListener("contextmenu",function(h){l(h,i(h),[],"contextmenu")},false)}else if(window.attachEvent){document.attachEvent("onclick", +function(h){l(h,i(h),[],"click")});document.attachEvent("oncontextmenu",function(h){l(h,i(h),[],"contextmenu")},false)}if(Event.prototype.stopPropagation){var n=Event.prototype.stopPropagation;Event.prototype.stopPropagation=function(){var h=i(this);if(m(h)!=null)if(this.type=="click")l(this,h,[],"click");else this.type=="contextmenu"&&l(this,h,[],"contextmenu");return n.apply(this,arguments)}}};setClickEvent();ncbi.sg.scanLinks=function(){};ncbi.sg._ping=function(f,i,m,l,n){if(typeof n==="undefined"|| +n===null)n=true;typeof f==="undefined"||f===null||(typeof f==="object"&&f.nodeName!==undefined?g(f,i,m,l,n):k(f,i,n))};ncbi.sg.ping=function(f,i,m,l){ncbi.sg._ping(f,i,m,l,false)};ncbi.sg.loadTime=new Date})();if(!Array.prototype.indexOf)Array.prototype.indexOf=function(a,b){var d=this.length>>>0;b=Number(b)||0;b=b<0?Math.ceil(b):Math.floor(b);if(b<0)b+=d;for(;b0&&k.push("next_phid="+encodeURIComponent(c));j!==null&&k.push("next_ncbi_timesinceload="+ +j);ncbi.sg.getInstance()._sendAl(k.join("&"),null,e,g)},b=ncbi.sg.getInstance().getCookie("hovernext");if(b){a(b);ncbi.sg.getInstance().setCookie("hovernext","")}var d=function(c){var e={};if(c){if(c.clientX||c.clientY){var g=ncbi.sg.getInstance()._getScrollXYPx();e.evt_coor_x=c.clientX+g[0];e.evt_coor_y=c.clientY+g[1]}else if(c.pageX||c.pageY){e.evt_coor_x=c.pageX;e.evt_coor_y=c.pageY}e.jseventms=ncbi.sg.getInstance().getMillisecondsSinceSunday()}return e};jQuery(document).on("mousedown","a[ref*='itool=Abstract-nondef'], #disc_col a", +function(c){c=c.originalEvent;var e=d(c);jQuery(c.target);(new Date).getTime();(new Date).getTime();var g=jQuery(c.target),k=g.id||"",j=g.name||"",t=g.sid||"",y=g.href||"",A=g.innerText||g.textContent||"";if(A.length>50)A=A.substr(0,50);var B=g.getAttribute?g.getAttribute("ref")||g.ref||"":"",w=g.className?g.className.replace(/^\s?/,"").replace(/\s?$/,"").split(/\s/g).join(",")||"":"";c=[];var v=[],u=g.parentNode;if(u)for(var s=0;s<6&&u!==null;s++){(parId=u.id)&&c.push(parId);if(parClassName=u.className)v= +v.concat(parClassName.split(/\s/));u=u.parentNode}u=ncbi.sg.getInstance();var f=u.currentPageHitId||"";f=[];k.length>0&&f.push("link_id="+encodeURIComponent(k));j.length>0&&f.push("link_name="+encodeURIComponent(j));t.length>0&&f.push("link_sid="+encodeURIComponent(t));y.length>0&&f.push("link_href="+encodeURIComponent(y));A.length>0&&f.push("link_text="+encodeURIComponent(A));w.length>0&&f.push("link_class="+encodeURIComponent(w));s=u.getBrowserWidthHeight();s.width!==null&&f.push("browserwidth="+ +encodeURIComponent(s.width));s.height!==null&&f.push("browserheight="+encodeURIComponent(s.height));for(var i in e){s=e[i];s!==undefined&&f.push(i.toLowerCase()+"="+s.toString())}f.push("jsevent=hovernext");B.length>0&&f.push(B);if(typeof jQuery!=="undefined")if(e=jQuery(g).attr("sg")){e=e.split(/\}\s*,\s*\{/);for(s=0;s0&&f.push("ancestorId="+ +c.join(","));v.length>0&&f.push("ancestorClassName="+v.join(",").replace(/\s+/g," ").replace(/(^\s|\s$)/g,""));u.addScrollDetailsAr(f,1800-f.join("&").length,true);c=f.join("&");f=ncbi.sg.getInstance().currentPageHitId||"";c+="&ncbi_phid="+f;ncbi.sg.getInstance()._storeNext("hovernext",c,null)});jQuery(document).on("mouseup mousedown",function(c){!jQuery(c.target).is("a[ref*='itool=Abstract-nondef']")&&jQuery(c.target).parents("a[ref*='itool=Abstract-nondef']").length==0&&!jQuery(c.target).is("#disc_col a")&& +jQuery(c.target).parents("#disc_col a").length==0&&ncbi.sg.getInstance().setCookie("hovernext","")})}}); + +; +// This code creates window.console if it doesn't exist. +// It also creates stub functions for those functions that are missing in window.console. +// (Safari implements some but not all of the firebug window.console methods--this implements the rest.) +(function() { + var names = [ "log", "debug", "info", "warn", "error", "assert", "dir", "dirxml", "group", + "groupEnd", "time", "timeEnd", "count", "trace", "profile", "profileEnd" ]; + + if (typeof(console) === 'undefined' || typeof console === "function" ) { + //"typeof function" is needed see PP-769 + console = {}; + } + + for (var i = 0; i < names.length; ++i) { + if (typeof(console[names[i]]) === 'undefined') { + console[names[i]] = function() { return false; }; + } + } + ncbi.sg.getInstance().init(); +})(); diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/addOrg.jpg Binary file NCBI Blast reference example_files/addOrg.jpg has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/black.gif Binary file NCBI Blast reference example_files/black.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/blast.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/blast.js Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,308 @@ + +function printfire() +{ + // Firefox + if (document.createEvent && window.dispatchEvent) { + printfire.args = arguments; + var ev = document.createEvent("Events"); + ev.initEvent("printfire", false, true); + window.dispatchEvent(ev); + } +} +//This functions handle setting defaults for protein or nulcleotide suite search page when +//one of blast program radio buttons is clicked - not used now +function AdjustMoreOptionsStyle() +{ + var optsEl = document.getElementById("moreopts"); + if(optsEl && optsEl.style.height != "0px") { + optsEl.style.height = optsEl.scrollHeight + "px"; + } +} + +//Strip (taxid:XXX) from organism list selection +//sgRunFunc="AdjustOrganism();" +function AdjustOrganism() +{ + var words = $("qorganism").value.split(" (taxid"); + $("qorganism").value = words[0]; +} + + +/* JS Common to all BLAST pages */ + + +function setResultsTarget() +{ + //var newWin = $("newwin"); + var newWin = this; + var searchFrm = $(newWin.getAttribute("form")); + if(newWin && newWin.checked == true) { + if(newWin.getAttribute("winType") == "random") { + searchFrm.target = "Blast_Results_for_" + Math.floor(Math.pow(10,10) *Math.random()); + } + else { + searchFrm.target = $("resPageTarget").value; + } + } + else { + searchFrm.target = ""; + } +} + +function diffFromDefault(elem) +{ + var currentVal = ""; + var ret = 0; + + if (!(elem)) return; + var defVal = elem.getAttribute("defVal"); //Default value + var elShowDiff = utils.getParent(elem); + if(!elem.type) {//div element for example + //Check if parent elem has "hide" class + if(utils.hasClass(utils.getParent(elem), "hide")) { + currentVal = "hide"; + } + else { + currentVal = "show"; + } + elShowDiff = elem; + } + else if(elem.type == "select-one") { + if(elem[elem.selectedIndex].value) currentVal = elem[elem.selectedIndex].value; + //If Default value is not specified - the first one in the selection list is the default + if (!defVal && elem[0].value) defVal = elem[0].value; + } + else if(elem.type == "select-multiple") { + currentVal = "";//for now + } + else if(elem.type == "checkbox") { + //alert("defVal1=" + elem.id + " " + defVal); + //var defVal = elem.defVal; //Default value + //alert("defVal2=" + defVal); + if(elem.checked == true) currentVal = "checked" + else currentVal = "unchecked"; + } + else { + currentVal = elem.value; + } + + + var numdiff = parseInt($("NUM_DIFFS").value,10); + var optsNumDiff = parseInt($("NUM_OPTS_DIFFS").value,10); + if(defVal != currentVal) { + if(!utils.hasClass(elShowDiff, "nondef")) { + utils.addClass(elShowDiff, "nondef"); + numdiff++; + if(utils.hasClass(elem,"opts")) optsNumDiff++; + } + ret = 1; + } + else { + if(utils.hasClass(elShowDiff, "nondef")) { + utils.removeClass(elShowDiff, "nondef"); + //alert("noDiff-" + elem.id); + if(numdiff != 0) numdiff--; + if(utils.hasClass(elem,"opts")) optsNumDiff--; + } + ret=0; + } + $("NUM_DIFFS").value = numdiff; + $("NUM_OPTS_DIFFS").value = optsNumDiff; + if(numdiff > 0) { + $("diffMes").style.display = "inline"; + } + else { + $("diffMes").style.display = "none"; + } + //alert(elem.id + " " + $("NUM_DIFFS").value); + return ret; +} + +function setDefalValue(elem) +{ + var currentVal; + var defVal = elem.getAttribute("defVal"); //Default value + if(elem.type == "select-one") { + //If Default value is not specified - the first one in the selection list is the default + if(!defVal) defVal = elem[0].value; + for(j=0; j < elem.options.length; j++) { + if(elem.options[j].value == defVal) { + elem.options[j].selected = true; + break; + } + } + } + else if(elem.type == "checkbox" || elem.type == "radio") { + if(!defVal) defVal = "checked"; + if(defVal == "checked") elem.checked = true + else elem.checked = false; + } + else { + if(!defVal) defVal = ""; + elem.value = defVal; + } + + var elShowDiff = utils.getParent(elem); + if(utils.hasClass(elShowDiff, "nondef")) { + utils.removeClass(elShowDiff, "nondef"); + } + //alert(elem.id + " " + $("NUM_DIFFS").value); +} + +function newResultsWinInit() { + jQuery("[class='newwin']").each(function(index) { + utils.addEvent(this, "click", setResultsTarget, false); + }); +} + +function resetOrganismSuggest(orgEntryElem) +{ + //suggestHint is in the hidden field used for SRA + var defaultMessage = ($("suggestHint")) ? $("suggestHint").value : "Enter organism name or id--completions will be suggested"; + var suggestHint = $("qorganism").getAttribute("suggestHint"); + if(suggestHint) defaultMessage = suggestHint; + if(orgEntryElem.value == "") { + orgEntryElem.value = defaultMessage; + } + if(orgEntryElem.value == defaultMessage) { + utils.addClass(orgEntryElem,"orgHint"); + } +} + +function setupOrganismSuggest(orgEntryElem) +{ + resetOrganismSuggest(orgEntryElem); + utils.addEvent(orgEntryElem, "focus", function() { + clearOrgSuggest(orgEntryElem); + }, false); +} + +function clearOrgSuggest(orgEntryElem) +{ + if(utils.hasClass(orgEntryElem,"orgHint")) { + orgEntryElem.value=""; + utils.removeClass(orgEntryElem,"orgHint"); + } +} + +function InitCustomButton(bn) +{ + utils.addEvent(bn, "mouseover", function() {this.src = this.getAttribute("mouseovImg");}, false); + utils.addEvent(bn, "mouseout", function() {this.src = this.getAttribute("mouseoutImg");}, false); + utils.addEvent(bn, "mousedown", function() {this.src = this.getAttribute("mousedownImg");}, false); + utils.addEvent(bn, "mouseup", function() {this.src = this.getAttribute("mouseupImg");}, false); +} + +function showHideElem(id,hide) +{ + if($(id)) { + if(hide) { + if(!utils.hasClass($(id),"hidden")) utils.addClass($(id), "hidden"); + } + else { + if(utils.hasClass($(id),"hidden")) utils.removeClass($(id), "hidden"); + } + } +} + +function resetOrganismControls(orgEntryElem) { + resetOrganismSuggest(orgEntryElem); + if ($("orgExcl")) $("orgExcl").checked = false; + utils.replaceInHtml("", $("orgs")); + if ($("frOrgs")) utils.replaceInHtml("", $("frOrgs")); + if ($("numOrg")) $("numOrg").value = 1; +} + +function AddOrgRow(e,orgName,exclName) { + e = e || window.event; + utils.preventDefault(e); + var checkedExclude = new Array(); + var orgDict = jQuery($($("qorganism"))).ncbiautocomplete("option","dictionary"); + orgDict = (!orgDict || orgDict == "") ? "taxids_sg" : orgDict; + var len = $("qorganism").getAttribute("size"); + + var newOrgFieldID = "qorganism" + $("numOrg").value; + var newOrgField = "
"; + if (exclName != "") { + newOrgField += "" + + "" + + ""; + } + newOrgField += "
"; + if (navigator.userAgent.match(/ie/i)) { + for (i = 1; i < $("numOrg").value; i++) { + if ($("orgExcl" + i)) checkedExclude[i] = $("orgExcl" + i).checked; + } + } + if (!navigator.userAgent.match(/firefox/i)) { + jQuery($($(orgs))).append(newOrgField,true); + } + else { + utils.insertInHtml(newOrgField, $("orgs")); + } + + if (navigator.userAgent.match(/ie/i)) { + for (i = 1; i < $("numOrg").value; i++) { + if ($("orgExcl" + i)) $("orgExcl" + i).checked = checkedExclude[i]; + } + } + setupOrganismSuggest($(newOrgFieldID)); + jQuery($($(newOrgFieldID))).ncbiautocomplete(); + $("numOrg").value++; +} + +function adjustOrgVal(orgEntryElem) +{ + //if (utils.hasClass($("searchForm").EQ_MENU, "orgHint")) $("searchForm").EQ_MENU.value = ""; + clearOrgSuggest(orgEntryElem); + if ($("numOrg")) { + for (i = 1; i < $("numOrg").value; i++) { + if ($("qorganism" + i)) { + clearOrgSuggest($("qorganism" + i)); + } + } + } +} + +function getUrlCompForEntryField(elem) { + var url = ""; + if (elem && elem.value != "") { + url = "&" + elem.name + "=" + escape(elem.value); + } + return url; +} + + +function getUrlCompForCheckedField(elem) { + var url = ""; + if (elem && elem.checked) { + url = "&" + elem.name + "=" + elem.value; + } + return url; + +} + +function getUrlCompForOptionsField(elem) { + var url = ""; + if (elem) { + url = "&" + elem.name + "=" + elem[elem.selectedIndex].value; + } + return url; +} + +function getUrlCompForMultiOptionsField(elem) { + var url = ""; + if (elem) { + for (i = 0; i < elem.options.length; i++) { + if (elem.options[i].selected) { + url += "&" + elem.name + "=" + elem.options[i].value; + } + } + } + return url; +} + + +utils.addEvent(window, 'load', newResultsWinInit, false); + diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/blastReq.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/blastReq.css Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,332 @@ +#msgR .info { +background-color: #dfd; +padding: 4px; +border: solid 1px green; +color: green; +} + +dl.summary dt { +float: left; +width: 8em; +clear:left; +margin: 0; +text-align: right; +padding-right: 1em; +color: #666; +} + +dl.summary dd { +padding-left: 0.5em; +display: block; +margin-left: 7em !important; +margin: 0; +} +dl.summary dt, dl.summary dd { +margin-bottom: 0.5em; +} +a.help +{ +float:right; +font-size: 110%; +} + +dl.summary label { +display: inline; +} + +dl.summary tr th label { +padding: 0; +margin-right:0; +} +table.options { +border: solid 1px #ccc; +border-right: solid 1px #ccc; +} + +table.options td, +table.options td.frh { +font-size: 90%; +_font-size: 85%; +} + +table.options label.rb { +border-right: solid 1px #ccc; +margin-right: 0.5em; +padding-right: 2.0em; +} + +table.options tr td { +_font-size: 90%; +padding-left: 0.5em; +} + +table.options { +/*border-collapse: collapse;*/ +margin-left: 0; +padding-left: 0; +width: 62em; +} + +table.options td label { +font-size: 90%; +} + +table.options th label, +table.options td label { +margin-right: 0; +_position: relative; +_top: -0.1em; +} + +table.options tr.hdr td, +table.options tr.hdr th { +padding: 2px; +border: solid 1px #ccc; +background-color: #ddd; +} + +table.options td, table.options td.frh { +padding: 0.25em 0; +vertical-align: center; +} + +table.options th { +padding-right: 1em; +text-align: right; +padding-left: 1em; +} + +/* +*:focus{ +background-color: white !important; +} +*/ + +table.options select,table.options input, #graphic input{ +border: solid 1px #888; +padding: 1px; +} + +select { +font-size: 90%; +} + +select option { +padding-right: 0.5em; +} + +input.cb, table.options input.cb { +border: none; +} + +select { +margin-right:1em; +} + +table.options tr { +background-color: #eee; +} + +table.options tr.odd { +background-color: #e0e0e0; +} + +table.options th { + +background-color: white; +} + +table.options tr.paramSet td +{ + border-top: solid 2px white; +} + + + + +.resetAll +{ +font-weight: normal; +padding: 0.5em; +font-size: 90%; +margin-left:5em; +} + +.button { +background-color: #ccc; +padding: 0.25em 0.25em; +color: black; +border: outset 3px #eee; +_border: outset 3px #eee; +font-size: 90%; +_padding:0; +font-weight: bold; +height:25px; +_height:22px; +} + +.fbtn { +margin-bottom: 0.5em; +} + +.note { +font-size: 80%; +color: green; +background-color: #ffc; +margin-left: 2em; +padding: 3px; +} +.instr { + margin-left: 1em; + color: #666; +font-size: 90%; +} +.smaller { +font-size: 90%; +font-weight: normal; +} + +/* Results Page styles */ + +#ridRes +{ + background-color: #FC9; + padding:5px 5px; +} + + +span dd.hidden,dt.hidden,dd.hidden span +{ + display:none; +} + +dl.query .query, +dl.title .title, +dl.entrez .entrez, +dl.db .db +{ + display:block; +} + + +dl.entrez span.entrez +{ + display:inline; +} + +.hidden { +display: none; +} +.hide { +display: none; +} +.shown { +display: block; +} + + + +table.megaBlast tr.psiBlast, +table.blastn tr.psiBlast, +table.blastx tr.psiBlast, +table.tblastn tr.psiBlast, +table.tblastx tr.psiBlast, +table.discoMegablast tr.psiBlast +{ +display: none; +} + + +table.GlobalAln .xgl, +body.GlobalAln div.xgl, +body.GlobalAln dt.xgl, +body.GlobalAln dd.xgl, +body.GlobalAln span.xgl, +body.GlobalAln table.xgl +{ +display: none; +} + +.dispType +{ + /*background-color:White; + border:solid 1px black;*/ + border-top:solid 2px gray; + border-left:solid 2px gray; + font-size:90%; + padding-left:2px; + +} + +.newwin { +border: none; +} + +table.options .helplink +{ + font-weight:bold; + position:absolute; + right:0; +} + +div#query label +{ + display: inline; + font-weight:bold; + padding-right:1em; +} +#NEW_VIEW +{ + _margin-left:-2px; +} + + +table.blastp *.blastn, +table.psiBlast *.blastn, +table.phiBlast *.blastn, +table.blastx *.blastn, +table.tblastn *.blastn, +table.tblastx *.blastn +{ +display: none; +} + +#formatTable th.col1 { +width: 8em; +vertical-align: top; +} +/* +#formatTable .helplink span { +position: relative; +} +*/ +#org +{ + margin-top:2em; +} +#qorganism +{ + /*display:block;*/ +} +.fi +{ + position:relative; +} + +a#organismHelp +{ + margin-top:-1.5em; +} + +table.options tr.paramSet td.hd { +padding-right: 1em; +text-align: right; +padding-left: 1em; +background-color:White; +font-weight:bold; +border-top:none; +} +.oExcl +{ + margin-left:2px; +} diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/blastRes.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/blastRes.css Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,262 @@ +a#refPage +{ + margin-left:3em; +} + +a.resLink +{ + margin-left:1em; + display:none; +} + +a.resLinkhidden +{ + display:none; +} + + +#cddResults +{ + float:right; + margin-top:-2em; + margin-right:1em; + color:#336699; + font-size:100%; +} + +#cddResults.showing { + background-image: url(images/down.gif); +} + + + +div.inlineDiv +{ + display:inline; +} + +span.reslink +{ + display:none; +} + +div.statPage *.statPage, +div.resPage *.resPage +{ + display:inline; +} + +div.resHeader *.hidden +{ + display:none; +} + +#cddInfo +{ + text-align:center; +} +#cddDesc +{ + font-weight:bold; +} +div#desctbl +{ +border: solid 1px #018aac; +/*min-width: 1000px;*/ +margin: none; +width: 100%; +background-color:White; +/*line-height:0; +_line-height:0;*/ +} + +table#descs +{ +font-family: Verdana, Sans-Serif; +font-size: 90%; +_font-size: 86%; +border-collapse: collapse; +/*min-width: 600px;*/ +width: 100%; +} + +table#descs th a { +text-decoration: none; +color: #00c; +} + +table#descs th a:visited { +color: #00c; +} + +table#descs th a:hover {position: relative; +text-decoration: underline; +} + +table#descs tr th.l, +table#descs tr td.l { +text-align: left; +} + +table#descs tr th.sp { +background-color: #def; +} + +table#descs tr th, +table#descs tr td { +text-align: center; +padding: 1px 4px; +} + +table#descs tr.first th { +padding-left:18px; +border-left: solid 1px #A0ceff; +border-top: solid 1px #A0ceff; +border-bottom: solid 1px #018aac; +border-right: solid 1px #018aac; +padding-right: 8px; +/*background-color: #01d5ff;*/ +background-color: #9cf; +/*font-size: 92%;*/ +white-space:normal; +line-height: 1.2em +} + + +table#descs td { +border: solid 1px #ccc; +border-width: 0px 1px; +white-space:nowrap; +overflow: hidden; +} + +.slink { +font-size: 90%; +font-weight: normal; +} + +table#descs tr.first th.sel { +background: #9cf url(images/up.gif) no-repeat center left; +padding-left: 18px; +padding-right: 18px; +} + +div.lim +{ +/*overflow: hidden;-this used to work in Firefox 2- comment for now and set the width */ +width: 35em; +display: inline-block; +height: 1.3em; +} + +table#descs tr:hover { +background-color: #def; +} + +pre +{ + font-size:110%; + _font-size:100%; + line-height:1; +} + +#msg +{ + white-space:normal; + border-color:#cccccc; + padding:0; + margin: 0; + margin-top:2px; +} +#msg li +{ + display:none; + padding:0; + margin: 0; + text-indent: 0; +} +#msg li.warning, #msg li.error ,#msg li.info +{ + display:block; +} + +#msg ul +{ + margin:0; + padding:0; +} + +table#statInfo +{ + border: solid 1px #ccc; + background-color: #eee; + width: 100%; +} + +table#statInfo tr.odd { +background-color: #e0e0e0; +} + +.READY, .UNKNOWN +{ + display:none; +} + +p.WAITING +{ + margin-top:1em; +} + +#frmPage +{ + margin-left:1em; +} + +span.Gene_PubMedLinks +{ + color: Green; font-weight: bold; +} + +ul.msg li p +{ + display:none; +} + +.msg li p.warning, .msg li p.error, .msg li p.success,.msg li p.info +{ + display:block; +} + +.mdlbox +{ + white-space:pre; + background-color:Transparent; + border:none; +} + +#blastErr +{ + white-space:normal; +} + + + +#RSIFrameNoRes,#RSIFrameDesc,#RSIFrameAln +{ + border:none; + width:519px; + height:35px; + margin:0px auto; +} + + +a.ui-ncbitoggler.hidden, a.ui-ncbitoggler-open.hidden +{ + display:none; +} + +.smn { + display: inline-block; + height: 16px; + width: 16px; +} diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/dynFormatRes.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/dynFormatRes.css Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,623 @@ +/* style changes for redesign begin*/ +a.gbd +{ + text-decoration:none; +} + +tr.dflLnk td span +{ + font-size:78%; + display:none; + text-align:center; +} +a.dflSeq +{ + color:#369; + text-decoration:underline; + width:auto; +} +table.defln tr.dflLnk a +{ + margin-right:auto; + padding-left:0; +} + +.alnParLinks +{ + float:right; +} + +.alnSeqLinks +{ + float:right; + margin-right:1em; +} + + +.seqlinks select +{ + padding:0; +} + +.dlfRow div +{ + font-size:90%; +} + +.dlfRow +{ + display:inline; + font-size:110%; +} + +.dlfRow.hidden +{ + display:none; +} +.dlfRow label +{ + font-size:87%; + display:inline; + color:#606060; + font-weight:bold; +} + +.dlfRow span.r label +{ + padding-left:0.8em; +} + + +div.relInf +{ + font-family: Verdana, Sans-Serif; + font-size: 80%; + float:right; + width:21%; + border-top:solid 2px gray; + margin-top:-1em; + margin-right:3.5em; + left:3em; + max-width:25em; + padding-left:1em; + position:relative; + white-space:normal; +} + +div.relInf a +{ + padding-right:0.2em; +} + +.rlLink +{ + padding-left:0.2em; +} +.relInf label +{ + font-size:110%; + color:brown; + font-weight:bold; +} +div#content +{ + min-width:70em; +} + +.dflLnk a +{ + font-size:90%; +} +a.dflSeq +{ + width:auto; + font-weight:normal; +} + + +#cntDesc,#cntDesc_psiw +{ + margin-bottom:0.2em; + display:inline-block; + width:20em; +} +#cntDesc span,#cntDesc_psiw span +{ + margin-right:0.5em; +} + +#cntDesc a,#cntDesc input,#cntDesc_psiw a,#cntDesc_psiw input +{ + margin-left:0.5em; +} + +#cntSelNone,#cntShAll +{ + margin-left:0.2em; +} + +.toolsCtr +{ + color:Blue; +} + +table.ui-ncbigrid th span.slink a +{ + display:inline; + padding-right: 0; +} +table.ui-ncbigrid th.sp +{ + font-weight:bold; +} + +table.ui-ncbigrid th span.slink +{ + margin-left:0.2em; +} + +table.ui-ncbigrid td { + white-space:nowrap; +} +table.ui-ncbigrid td.c3 +{ + /*padding-left:0.8em;*/ +} +table.ui-ncbigrid caption +{ + font-size:0; + line-height:0; +} +#content h3.cap,#content h3.cap a.ui-ncbitoggler.ui-widget, #content h3.cap a.ui-ncbitoggler-open +{ + color:#4d4d4d; + text-align:left; + margin:0 0 0.5em 0; +} + +#content div.cap,#content div.cap a.ui-ncbitoggler.ui-widget, #content div.cap a.ui-ncbitoggler-open +{ + color:#4d4d4d; + text-align:left; + margin:0 0 0.5em 0; + letter-spacing:-1px; + font-size:110%; + font-weight:bold; +} + +#descriptions div.caption-exists { + margin: 0; +} + +/**********decrition toolbar styles *********/ + +div.cnf { + -moz-border-bottom-colors: none; + -moz-border-image: none; + -moz-border-left-colors: none; + -moz-border-right-colors: none; + -moz-border-top-colors: none; + background: url("images/cnf.png") repeat scroll 0 0 transparent; + border-style: solid none none; + border-width: 1px medium medium; + /*clear: left;*/ + height: 22px; + /*overflow: auto;*/ + width: 100%; +} + +ul.ui-ncbilocalnav li.has-child a.button_config { + background: url("/portal/portal3rc.fcgi/3493904/img/81796") no-repeat scroll right center transparent !important; + width: 22px; + height:22px; + margin-left:12em; +} + +#li-config +{ + float:right; + width:17em; +} +div#descTblCtrl ul.ui-ncbilocalnav li +{ + border-right:none; +} + + +.cfg +{ + font-size:90%; +} + + +.oneSeqAln .hsp label +{ + color:#606060; + font-size:95%; + padding-right:0.5em; +} + +.oneSeqAln pre +{ + margin-top:0.5em; +} + +.aln_feat label +{ + color: #606060; + font-size: 95%; + padding-right: 0.5em; +} +.oneSeqAln .dflLnk.aln_feat +{ + padding-bottom:1em; +} +div.oneSeqAln h4 +{ + border:none; + font-size:100%; + font-weight:normal; + letter-spacing:normal; + margin:0; +} + +.oneSeqAln .dflLnk +{ + width:56em; +} +.aln_feat a +{ + margin-left:1em; + display:block; +} +.dflLnk.aln_feat div +{ + /*display:inline-block; */ + margin-left:5em; + margin-top:-1em; +} +.aln_frame.shown +{ + display:block; +} +/*align params styles change */ + +table.alnParams +{ + border-left:none; + border-right:none; + margin-top:0.5em; + width:49em; +} + +table.alnParams th +{ + background-color:Transparent; + border:none; + text-align:left; +} + +table.alnParams td +{ + border:none; +} + + +.alnAll +{ + line-height:normal; + margin-top:1em; +} + +.alnAll div +{ + width:70%; +} + +/**new config staff begin**/ +.popDl +{ + display:none; +} +.popDl div +{ + margin-top:0.5em; +} +.popDl div.tl +{ + margin-top:0; + font-weight:bold; +} +a.button_config { + background: url("images/cnfButn.png") no-repeat scroll right center transparent !important; + width: 22px; + height:22px; + margin-left:12em; + float:right; +} + +a.toolsCtr,span.csLinks a +{ + margin-left:8px; + float:left; + cursor:pointer; +} + +a.toolsCtr[disabled] { + cursor: default; +} + + +a.toolsCtr SPAN +{ + color: #14376c; + /*line-height: 22px;*/ + padding-left: 15px; + background-repeat: no-repeat; + background-position:left center; +} + +a.toolsCtr[disabled] SPAN,a.toolsCtr[disabled] +{ + color:#C2C2C2; +} + +a.dnld span +{ + background-image: url("images/dndl.png"); +} + +a.dnld[disabled] span +{ + background-image: url("images/dndl_dsb.png"); +} + +a.dialog +{ + padding-right: 18px; + background:transparent url(images/dialog.png) no-repeat scroll right center; + text-decoration:none; +} + +a.dialog[disabled] { + background-image: url("images/dialog_dsb.png"); +} + + +a.alnNav span +{ + background-image: url("images/align_Normal.png"); +} + +a.alnNav +{ + text-decoration:none; +} + + +a.navNext span +{ + background-image: url("images/next_Normal.png"); +} + + +a.navNext[disabled] span +{ + background-image: url("images/next_Inactive.png"); +} + + +a.navPrev span +{ + background-image: url("images/prev_Normal.png"); +} + + +a.navPrev[disabled] span +{ + background-image: url("images/prev_Inactive.png"); +} + + +a.navBack span +{ + background-image: url("images/table_Normal.png"); +} + +.alnRn +{ + float:left; +} + + +/* styles to change per discusssion with Mark begin*/ +.dflLnk a +{ + padding-left:0; +} + + +table.ui-ncbigrid th { + padding-left:0.3em; + padding-right:0; + text-align:center; +} + +table.ui-ncbigrid td { + padding-left:0.4em; + padding-right:0.4em; + text-align:center; +} + +table.ui-ncbigrid td.c2,table.ui-ncbigrid td.c1 { + text-align:left; +} + +table.ui-ncbigrid td.c3{ + padding:0.363em 0.25em; +} + + +table.ui-ncbigrid th a { + padding-right: 5px; +} +table.ui-ncbigrid th.c0 +{ + width:25px; + padding:0; +} + +.dflnDth +{ + width:100%; +} +div.lim { + width: 14em; +} + +table.ui-ncbigrid th.c8,table.ui-ncbigrid th.c9 { + padding-right: 0.3em; +} +.c8,.c9 +{ + font-size:80%; +} + + +td.lim.l.c2,td.lim.l.c1 +{ + overflow:hidden; +} +a.spr +{ + border-right:none; +} + + +.psiInp +{ + margin-left:1em; + margin-top:0.5em; +} + + +.c8 input +{ + border:none; +} +table.ui-ncbigrid td.c8 +{ + padding-left:1.5em; +} + +tr.psi_new td +{ + background-color:#FFFF99; + border-top:solid 4px white; + border-spacing:3px; + border-collapse:collapse; + line-height:normal; +} +/* accessibility setting */ +tr.dflLnk td span.psiNw,tr.first th span,a.button_config span, a span.accsb,.dflLnk label.accsb +{ + display:inline; + position:absolute; + left:-9999px; +} + +div.tgl +{ + margin-top:-1em; +} +.shcl +{ + float:right; +} + +/* styles to change per discusssion with Mark end*/ + +.alnRn a +{ + padding-right:1em; +} +.alnAll .moreHsps +{ + font-family: Verdana, Sans-Serif; + font-size: 75%; + margin-top:-2.5em; + width:58%; +} +.erm +{ + background-color:#FFFFCC; + padding:0.5em; +} + +#debug,.ind,.alnMsgS .db,.erm .db +{ + display:none; +} + +.tmsAln label +{ + font-size:93%; + display:inline; + color:#606060; + font-weight:bold; +} +.alnAll .tmsAln, .tmsAln div +{ + width:100%; + margin-bottom:-1em; +} +.tmsAlnPar +{ + margin-top:-1em; +} +/*debug info styles begin */ + + +/* use those styles only in debug version + +.alnMsg +{ + border:solid 1px black; +} + +.alnMsgS.hidden,.alnMsgS .db +{ + display:block; +} + +.oneSeqAln +{ + border:1px solid #C8C8C8; +} + +#debug,tr.dflLnk td span.ind +{ + display:inline; +} +.c0 +{ + width:30px; +} +/*debug info styles end */ + + + +/**new config staff end**/ +/* +ul.ui-ncbilocalnav li, ul.ui-ncbilocalnav { + background-color: #F4F4F4; + background-image: -moz-linear-gradient(center top , #FFFFFF, #F4F4F4); +} +ul.ui-ncbilocalnav li { + border-right: 1px solid #C4C4C4; +} +*/ +/**********decrition toolbar styles end*********/ + + +/* style chenges for redesign end*/ diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/firefox-descriptions.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/firefox-descriptions.css Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,3 @@ +table.dbInfo caption { + +} \ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/format.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/format.js Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,270 @@ + +function UpdateDisplayTypes(displayTypes) { + dispMenu = displayTypes.options; + for(i=0; i < dispMenu.length; i++) { + //if(!utils.hasClass(displayTypes,"psiBlast") && !utils.hasClass(displayTypes,"phiBlast") || + if($("stepNumber").value == "" || $("stepNumber").value < 2) { + if(dispMenu[i].value.indexOf("PSSM") != -1) { + dispMenu[i--] = null; + //break; + } + } + } +} + +function GetIndexByValue(selectElem,val) { + var idx = 0; + var opts = selectElem.options; + for(i=0; i < opts.length; i++) { + if(opts[i].value == val) { + idx = i; + break; + } + } + return idx; +} + +function resetAdvView(show) +{ + var advView = $("advView"); + if(show) { + if(utils.hasClass(advView, "hidden")) { + utils.removeClass(advView, "hidden"); + } + } + else { + utils.addClass(advView, "hidden"); + } +} + + +function ShowOrHide(hide,elem) +{ + if(hide) { + if(!utils.hasClass(elem, "hidden")) { + utils.addClass(elem, "hidden"); + } + } + else { + if(utils.hasClass(elem, "hidden")) { + utils.removeClass(elem, "hidden"); + } + } +} + +function UpdateFormatTypes(form) { + var selectedObjType = form.FORMAT_OBJECT[form.FORMAT_OBJECT.selectedIndex].value; + var hideAdvView = false; + bioseqFormatHide = true; + pssmFormatHide = true; + pssmScFormatHide = true; + formatTypeHide = true; + if (selectedObjType == "Alignment") { + formatObjectSelectedIndex = 0; //HTML + formatTypeHide = false; + hideAdvView = true; + } + if (selectedObjType == "PSSM") { + formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"Text"); + pssmFormatHide = false; + } + if (selectedObjType == "PSSM_Scoremat") { + formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"ASN.1"); + pssmScFormatHide = false; + } + else if (selectedObjType == "Bioseq") { + formatObjectSelectedIndex = GetIndexByValue(form.FORMAT_TYPE,"ASN.1"); + bioseqFormatHide = false; + } + form.FORMAT_TYPE.selectedIndex = formatObjectSelectedIndex; + ShowOrHide(formatTypeHide,form.FORMAT_TYPE); + if ($("bioseqFormat")) { + ShowOrHide(bioseqFormatHide,$("bioseqFormat")); + $("bioseqFormat").readOnly=true; + } + if ($("pssmFormat")) { + ShowOrHide(pssmFormatHide,$("pssmFormat")); + $("pssmFormat").readOnly=true; + } + if ($("pssmScFormat")) { + ShowOrHide(pssmScFormatHide,$("pssmScFormat")); + $("pssmScFormat").readOnly=true; + } + resetAdvView(hideAdvView); +} + +function ResetForm() +{ + //var defValNodes = cssQuery(".reset"); + defValNodes = $("FormatForm").elements; + for(i=0; i < defValNodes.length; i++) { + if(utils.hasClass(defValNodes[i],"reset")) + setDefalValue(defValNodes[i]); + } + if ($("FormatForm").FORMAT_OBJECT.type == "select-one") { + UpdateFormatTypes($("FormatForm")); + UpdateDisplayTypes($("FormatForm").FORMAT_OBJECT); + } + if($("FormatForm").RUN_PSIBLAST.checked) setDefalValue($("FormatForm").I_THRESH) + else $("FormatForm").I_THRESH.value=""; + //resetOrganismSuggest($("FormatForm").FORMAT_ORGANISM); + resetOrganismControls($("FormatForm").FORMAT_ORGANISM); + //TO DO: add threshold +} + +function LimitByHitlistSize(list) +{ + var listBreak = false; + var optSel = false; + for(i=0; i < list.options.length; i++) { + var optVal = parseInt(list.options[i].value ,10); + var hitListSize = parseInt($("maxNumSeq").value ,10); + if(list.options[i].selected) optSel = true; + if(optVal >= hitListSize) { + if(!optSel) {list.options[i].selected = true;} + list.options.length = i + 1; + break; + } + } +} + +function AddFormatOrgField(e) { + AddOrgRow(e, "FORMAT_ORGANISM", "FORMAT_ORG_EXCLUDE"); +} + +function initSubmit() { + + +} + +function adjustFormatOptions() +{ + var alignView = $("FormatForm").ALIGNMENT_VIEW; + var formatType = $("FormatForm").FORMAT_TYPE; + var queryAnch = formatType[formatType.selectedIndex].value == "HTML" && (alignView[alignView.selectedIndex].value != "Pairwise" && alignView[alignView.selectedIndex].value != "PairwiseWithIdentities"); + var dynFormatQA = !$("FormatForm").OLD_VIEW.checked && queryAnch; + dynFormatPW = !$("FormatForm").OLD_VIEW.checked && formatType[formatType.selectedIndex].value == "HTML" && (alignView[alignView.selectedIndex].value == "Pairwise" || alignView[alignView.selectedIndex].value == "PairwiseWithIdentities"); + + UpdateDescriptions(dynFormatPW); + if (dynFormatPW) { + jQuery("#frmAln").addClass("hidden"); + if (!utils.hasClass($("shl"), "hidden")) jQuery("#shl").addClass("hidden"); //hide SHOW_LINKOUT + jQuery("#gts").addClass("hidden"); //hide GET_SEQUENCE + jQuery("#scf").removeClass("hidden");//show CDS_FEAT + $("FormatForm").SHOW_LINKOUT.checked = true; + } + else { + if(dynFormatQA) $("FRM_ALIGNMENTS").selectedIndex = $("FRM_DESCRIPTIONS").selectedIndex; + + jQuery("#frmAln").removeClass("hidden"); + if (dynFormatQA) { + if (!utils.hasClass($("shl"), "hidden")) jQuery("#shl").addClass("hidden"); //hide SHOW_LINKOUT + } + else { + jQuery("#shl").removeClass("hidden"); + } + if (queryAnch) { + jQuery("#scf").addClass("hidden"); //hide CDS_FEAT + } + else {//pairwise old_view=false + jQuery("#scf").removeClass("hidden"); //hide CDS_FEAT + } + jQuery("#gts").removeClass("hidden"); //GET_SEQUENCE + } + if ($("blastSpec").value == "VecScreen") { + adjustVecscreen(dynFormatPW); + } +} + +function adjustVecscreen(dynFormatPW) +{ + var dfltDescrInd = 0; //0 + var dfltDynDescrInd = 5; //1000 + var dfltAlnInd = 6; //1000 + if (dynFormatPW) { + utils.addClass($("lr"), "hidden"); + $("FRM_DESCRIPTIONS").selectedIndex = dfltDynDescrInd; + } + else { + utils.removeClass($("lr"), "hidden"); + $("FRM_DESCRIPTIONS").selectedIndex = dfltDescrInd; + } + $("FRM_ALIGNMENTS").selectedIndex = dfltAlnInd; +} + + +function UpdateDescriptions(removeZero) +{ + if (removeZero) { + dispMenu = $("FormatForm").DESCRIPTIONS; + dispMenu.remove(0); + } + else { + dispMenu = $("FormatForm").DESCRIPTIONS; + if (dispMenu.options[0].value != "0") { + if (navigator.userAgent.match(/ie/i)) { + dispMenu.add(new Option("0", "0"), 0); + } + else { + dispMenu.add(new Option("0", "0"), dispMenu[0]); + } + } + } +} + +function InitDynFormatOptions() +{ + if ($("OLD_VIEW")) { + utils.addEvent($("FormatForm").OLD_VIEW, "click", adjustFormatOptions, false); + utils.addEvent($("FormatForm").ALIGNMENT_VIEW,"change", adjustFormatOptions, false); + utils.addEvent($("FormatForm").FORMAT_TYPE, "change", adjustFormatOptions, false); + adjustFormatOptions(); + } +} + +function InitFormatPage() +{ + if ($("FormatForm").FORMAT_OBJECT.type == "select-one") { + UpdateDisplayTypes($("FormatForm").FORMAT_OBJECT); + UpdateFormatTypes($("FormatForm")); + list = $("FormatForm").FORMAT_OBJECT; + utils.addEvent(list, "change", function() { + UpdateFormatTypes($("FormatForm")); + }, + false); + } + utils.addEvent($("resetAll"), "click", ResetForm, false); + if($("maxNumSeq") != null) { + if($("maxNumSeq").value != "") { + LimitByHitlistSize($("FormatForm").DESCRIPTIONS); + LimitByHitlistSize($("FormatForm").ALIGNMENTS); + LimitByHitlistSize($("FormatForm").NUM_OVERVIEW); + } + } + setupOrganismSuggest($("FormatForm").FORMAT_ORGANISM); + utils.addEvent($("FormatForm"), "submit", function() { + adjustOrgVal($("FormatForm").FORMAT_ORGANISM);}, + false); + + if ($("addOrg")) utils.addEvent($("addOrg"), "click", AddFormatOrgField, false); + InitDynFormatOptions(); + /* add this code if decide image for View Report + var imgButtons = jQuery("[class='viewReport']"); + for (var i = 0; i < imgButtons.length; i++) { + var l = imgButtons[i]; + utils.addEvent(l, "click", function() {$("FormatForm").submit();}, false); + utils.addEvent(l, "mouseover", function() {l.src = l.getAttribute("mouseovImg");}, false); + utils.addEvent(l, "mouseout", function() {l.src = l.getAttribute("mouseoutImg");}, false); + utils.addEvent(l, "mousedown", function() {l.src = l.getAttribute("mousedownImg");}, false); + utils.addEvent(l, "mouseup", function() {l.src = l.getAttribute("mouseupImg");}, false); + } + */ +} + +utils.addEvent(window, 'load', InitFormatPage, false); + + + + + + diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/formatRes.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/formatRes.js Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,1542 @@ +// JScript source code +/*************************new code begin *******************************************************/ + +function getHiddenFieldVal(elemName) { + var val; + var elem = document.getElementsByName(elemName); + if (elem) { + val = (elem.length > 1) ? elem[0].value : elem.value; + } + return val; +} + +function getHiddenFieldParamString(elemName) { + var ret = ""; + var val = getHiddenFieldVal(elemName); + if (val) { + ret = "&" + elemName + "=" + val; + } + return ret; +} + +function elementInViewport(el) { + if (!el) return; + var rect = el.getBoundingClientRect(); + + var myWidth = 0, myHeight = 0; + if (typeof (window.innerWidth) == 'number') { + //Non-IE + myWidth = window.innerWidth; + myHeight = window.innerHeight; + } else if (document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) { + //IE 6+ in 'standards compliant mode' + myWidth = document.documentElement.clientWidth; + myHeight = document.documentElement.clientHeight; + } else if (document.body && (document.body.clientWidth || document.body.clientHeight)) { + //IE 4 compatible + myWidth = document.body.clientWidth; + myHeight = document.body.clientHeight; + } + //window.alert('Width = ' + myWidth); + //window.alert('Height = ' + myHeight); + + + //return (rect.top >= 0 && rect.left >= 0 && rect.bottom <= window.innerHeight && rect.right <= window.innerWidth) + //return (rect.top >= 0 && rect.left >= 0 && rect.bottom <= myHeight && rect.right <= myWidth) + return (rect.top >= 0 && rect.bottom <= myHeight); +} + +function DisplayAlignFromDescription(elem) { + var alignView = $("FormatForm").ALIGNMENT_VIEW; + if (alignView[alignView.selectedIndex].value == "Pairwise" || alignView[alignView.selectedIndex].value == "PairwiseWithIdentities") { + DisplayDynamicAlign(elem); + } + else { + location.href = "#" + elem.getAttribute("seqID"); + } +} + +// ind="" gi="" id="deflnDesc_gi" href="#AlnHdrgi">desc +//
+function DisplayDynamicAlign(elem) { + var currGi = elem.getAttribute("gi"); + var currInd = elem.getAttribute("ind"); + var stat = elem.getAttribute("stat"); + if (!currInd || !currGi) return; + + if (!stat || stat == "") { + //Get 4(5) aligns before currInd and 4(5) aligns after + ReadCurrentSeqAligns(currInd, 5); + } + else if (stat == "read") { + var indexes = getCurrIndexRange(currInd); + if (indexes) { + var msgID = "alnShow_" + indexes[0]; + location.href = "#" + msgID; + } + } + else { + //error status handling + } +} + + +function goToNextAlign(dtrID, next) { + var currInd = parseInt($(dtrID).getAttribute("ind")); + var rid = $("Rid").value; + nextInd = (next) ? currInd + 1 : currInd - 1; + + if ($("deflnDesc_" + nextInd)) { + currGi = $("deflnDesc_" + nextInd).getAttribute("seqID"); + scrollToGI = currGi; + if (!$("deflnDesc_" + nextInd).getAttribute("stat") || $("deflnDesc_" + nextInd).getAttribute("stat") == "") { + + if (!next) { + ReadPrevSeqAligns(currInd, 5, scrollToGI); + } + else { + //Use this indexes = wasAlignRead(nextInd); to determine insertAfterID in ReadNextAligns!!! + ReadNextSeqAligns(currInd, 5, scrollToGI); + } + + } + else { + location.href = "#" + scrollToGI; + } + } +} + +function goToDefLine(dtrID) { + if ($("psiInp")) { + var tbl = jQuery($(dtrID)).parents(".jig-ncbigrid"); //parent table + togglerID = PsiBelowThresh(tbl[0].id) ? "showDescB1" : "showDescG1"; + jQuery($(togglerID)).ncbitoggler("open"); + } +} + +/* +readAln.rid = rid; +readAln.startIndex = parseInt(currInd); +readAln.numSeq = parseInt(maxNumAligns); + +readAln.insertAfterID = insertAfterID; +readAln.seqList = giList; +readAln.scrollToSeqID = scrollToGI; +*/ +function ReadNextSeqAligns(currInd, maxNumAligns, scrollToGI) { + var lastDispIdx = 0; + var rid = $("Rid").value; + + var readAln = new Object(); + readAln.seqList = ""; //giList + readAln.rid = rid; + + currInd = parseInt(currInd); + + if (currInd != 0 && $("deflnDesc_" + currInd)) { + var par = utils.getParent($("aln_" + $("deflnDesc_" + currInd).getAttribute("seqID"))); //"alnShowReal_ + //alert(par.id); + if (par) par = utils.getParent(par); //"alnShow_ + //alert(par.id); + if (par) readAln.insertAfterID = par.id; + } + else { + readAln.insertAfterID = "alnStart"; + } + + + + readAln.startIndex = currInd + 1; + readAln.numSeq = maxNumAligns; + + checkIfAlnExceedsThreshold(readAln, currInd, maxNumAligns, "next"); + + readAln.scrollToSeqID = (scrollToGI && scrollToGI != "") ? scrollToGI : ""; + readAln.hspSort = 0; + ReadSeqAlignByIndex(readAln); +} + +function ReadPrevSeqAligns(currInd, maxNumAligns, scrollToGI) { + var lastDispIdx = 0; + var rid = $("Rid").value; + + var readAln = new Object(); + readAln.seqList = ""; //giList + readAln.rid = rid; + + currInd = parseInt(currInd); + + + //sets readAln.insertAfterID and returns lastDispIdx; + //Find the index of the previously displayed alignment + lastDispIdx = getPrevDisplyedAlignInfo(currInd, readAln); + + readAln.startIndex = (currInd - lastDispIdx > maxNumAligns) ? (currInd - maxNumAligns) : lastDispIdx + 1; + readAln.numSeq = currInd - readAln.startIndex; //stopIndex = currInd + + checkIfAlnExceedsThreshold(readAln, currInd, readAln.numSeq, "prev"); + + readAln.scrollToSeqID = (scrollToGI && scrollToGI != "") ? scrollToGI : $("deflnDesc_" + (currInd)).getAttribute("seqID"); + readAln.hspSort = 0; + ReadSeqAlignByIndex(readAln); +} + +//When descriptions is clicked - display maxNumAligns before currInd and maxNumAligns after currInd +function ReadCurrentSeqAligns(currInd, maxNumAligns) { + var rid = $("Rid").value; + var readAln = new Object(); + readAln.seqList = ""; //giList + readAln.rid = rid; + + currInd = parseInt(currInd); + + + //sets readAln.insertAfterID and returns lastDispIdx; + //Find the index of the previously displayed alignment + var lastDispIdx = getPrevDisplyedAlignInfo(currInd, readAln); + + //lastDispIdx = parseInt(lastDispIdx); + readAln.startIndex = (currInd - lastDispIdx > maxNumAligns) ? (currInd - maxNumAligns) : lastDispIdx + 1; + readAln.numSeq = parseInt(maxNumAligns * 2); + + checkIfAlnExceedsThreshold(readAln, currInd, maxNumAligns, "curr"); + + readAln.scrollToSeqID = $("deflnDesc_" + currInd).getAttribute("seqID"); + readAln.hspSort = 0; + ReadSeqAlignByIndex(readAln); + g_DisableAutoCheck = true; + location.href = "#alnShow_" + readAln.startIndex; +} + + + + +function setupDynHSPParams(readAln) +{ + var currSeqInd = readAln.startIndex; + hspNum = parseInt($("deflnDesc_" + currSeqInd).getAttribute("hsp")); + alnLen = parseInt($("deflnDesc_" + currSeqInd).getAttribute("len")); + var maxDispLen = parseInt($("maxDispAlnLen").value);//20000 + var minDispLen = parseInt($("minDispAlnLen").value);//2000 + if (alnLen > maxDispLen) { + var lenPerMatch = alnLen / hspNum; + readAln.AlignDbPageSize = (lenPerMatch > minDispLen) ? 1 : Math.floor(minDispLen / lenPerMatch); + readAln.AlignDbPageNum = 0; + $("deflnDesc_" + currSeqInd).setAttribute("dynHsps", readAln.AlignDbPageSize); + } +} + + + +function getCurrSeqsAlnLen(currSeqInd) +{ + var alnLen = 0; + if ($("deflnDesc_" + currSeqInd) && (!$("deflnDesc_" + currSeqInd).getAttribute("stat") || $("deflnDesc_" + currSeqInd).getAttribute("stat") == "")) { + alnLen = $("deflnDesc_" + currSeqInd).getAttribute("len"); + } + alnLen = (alnLen) ? parseInt(alnLen) : 0; + return alnLen; +} + +function checkTotalAlignLen(startIndex,stopIndex) +{ + var dispAlnLen = 0; + var maxDispLen = parseInt($("maxDispAlnLen").value); + for (var i = startIndex; i <= stopIndex; i++) { + alnLen = getCurrSeqsAlnLen(i); + if (alnLen == 0) break; + dispAlnLen += alnLen; + } + return dispAlnLen; +} +//Get total align length for seq currSeqInd and +//"curr" surrounding countSeqs seqs + current, "prev" - previous countSeqs seqs, "next" - next countSeqs seqs +function getTotalAlignLen(readAln, currSeqInd, countSeqs, dispType) +{ + var startIndex = readAln.startIndex; + var stopIndex = readAln.startIndex + readAln.numSeq - 1; + if (dispType == "curr") {//checks countSeqs before and countSeqs after current, including current + startIndex = Math.max(startIndex, currSeqInd - countSeqs); + stopIndex = Math.min(stopIndex, currSeqInd + countSeqs); + } + else if(dispType == "prev") { + startIndex = Math.max(startIndex, currSeqInd - 1 - countSeqs); + stopIndex = currSeqInd - 1; + } + else {//next + stopIndex = Math.min(stopIndex, currSeqInd + countSeqs + 1); + } + var totAlnLen = checkTotalAlignLen(startIndex,stopIndex); + return totAlnLen; +} + +function checkIfAlnExceedsThreshold(readAln,currSeqInd,maxNumAligns, dispType) +{ + var maxDispLen = parseInt($("maxDispAlnLen").value); + var totAlnLen = 0; + var exc = false; + for (var numSeq = 0; numSeq <= maxNumAligns; numSeq++) { + totAlnLen = getTotalAlignLen(readAln, currSeqInd, numSeq, dispType); + if(totAlnLen > maxDispLen) { + break; + } + } + if (totAlnLen > maxDispLen) { + if (numSeq != 0) numSeq--; + if (dispType == "curr") { + readAln.startIndex = Math.max(readAln.startIndex, currSeqInd - numSeq); + //prev + 1(curr) + next + readAln.numSeq = (currSeqInd - readAln.startIndex) + 1 + numSeq; + } + else if (dispType == "prev") { + readAln.startIndex = Math.max(readAln.startIndex, currSeqInd - 1 - numSeq); + readAln.numSeq = numSeq + 1; + } + else { //"next" - readAln.startIndex stays + readAln.numSeq = numSeq + 1; + } + + if (readAln.numSeq == 1 && $("useAlignDB") && $("useAlignDB").value == "true") { + setupDynHSPParams(readAln); + } + + exc = true; + } + return exc; +} + + +//readAln.startIndex, readAln.numSeq, readAln.scrollToSeqID,readAln.insertAfterID should be set +function ReadSeqAlignByIndex(readAln) { + var numAligns = 0; + for (var i = readAln.startIndex; i < readAln.startIndex + readAln.numSeq; i++) { + + if (!$("deflnDesc_" + i)) { + break; + } + if (!$("deflnDesc_" + i).getAttribute("stat") || $("deflnDesc_" + i).getAttribute("stat") == "") { + currGi = $("deflnDesc_" + i).getAttribute("seqFSTA"); + if (readAln.seqList != "") readAln.seqList += ","; + readAln.seqList += currGi; + numAligns++; + } + else { + break; + } + } + if (readAln.seqList != "") { + readAln.numSeq = parseInt(numAligns); + ReadSeqAlignForSeqList(readAln); + } +} + + +var g_DisplayeAlignsRanges = ""; //String in the format start1-stop1,start2-stop2... +//Find the range of indexes of displayed alignments for currAlnInd +//Returns array of 2 startIndex, stopIndex +function getCurrIndexRange(currAlinInd) { + var currRange; + var ranges = g_DisplayeAlignsRanges.split(","); + for (var i = 0; i < ranges.length; i++) { + var indexes = ranges[i].split("-"); + if (currAlinInd >= parseInt(indexes[0]) && currAlinInd <= parseInt(indexes[1])) { + currRange = indexes; + break; + } + } + return currRange; +} + + +//Find the index of the previous displayed alignment +function getPrevDisplyedAlignInfo(currInd, readAln) { + readAln.insertAfterID = "alnStart"; + lastDispIdx = 0; + for (var i = currInd - 1; i >= 1; i--) { + indexes = getCurrIndexRange(i); + if (indexes) { + lastDispIdx = indexes[1]; + readAln.insertAfterID = "alnShow_" + indexes[0]; + break; + } + } + return parseInt(lastDispIdx); +} + + +//setReadStatus +function setSeqAlnReadStatus(readAln, status) { + for (var i = readAln.startIndex; i < readAln.startIndex + readAln.numSeq; i++) { + if ($("deflnDesc_" + i)) { + jQuery($($("deflnDesc_" + i))).attr("stat", status); + if (status == "disp") { + g_MaxDisplayedIndex = (i > g_MaxDisplayedIndex) ? i : g_MaxDisplayedIndex; + } + } + } +} + +/* +readAln.rid = rid; +readAln.seqList = giList; +readAln.startIndex = parseInt(idx); +readAln.insertAfterID = insertAfterID; +readAln.numSeq = parseInt(numSeq); +readAln.scrollToSeqID = scrollToGI; +*/ +function SendReadSeqAlinRequest(readAln) { + blastUrl = "t2g.cgi"; + + var rp = new RemoteDataProvider(blastUrl); + + + rp.onSuccess = function(obj) { + if ($("alignView")) utils.removeClass($("alignView"), "hidden"); + + if ($("alnShow_" + readAln.startIndex)) { + var moreHspsLink = getNextHspsLink(readAln); + jQuery($($("alnShowReal_" + readAln.startIndex))).html(obj.responseText + moreHspsLink, { + 'widgets': ['ncbipopper', 'ncbitoggler'], + 'configs': { + 'ncbipopper': { hasArrow: true, arrowDirection: 'top' } + } + }); + setSeqAlnReadStatus(readAln, "disp"); + jQuery($("alnMsg_" + readAln.startIndex)).addClass("hidden"); + //Saves start and stop indexes of loaded alignments in global variables + saveIdxesForAutomaticLoad(readAln); + jQuery($($("alnShowReal_" + readAln.startIndex))).find(".alnHdr").each(function(index) { + var seqID = this.getAttribute("seqID"); + if(seqID) initAlignBatch(seqID); + }); + + } + + if (readAln.scrollToSeqID) { + location.href = "#" + readAln.scrollToSeqID; + } + + }; + rp.onError = function(obj) { + if ($("alignView")) utils.removeClass($("alignView"), "hidden"); + jQuery($("alnMsg_" + readAln.startIndex)).addClass("hidden"); + $("alnShowReal_" + readAln.startIndex).innerHTML = "
Error loading alignment ...requests:" + this.iActiveRequests + " status:" + obj.status + + "Try again<\a>
"; + } + var params = constructURLParams(readAln); + if (readAln.numSeq == 1) { + params += "&TOTAL_HSPS=" + $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); + } + params += "&SEQ_LIST_START=" + readAln.startIndex; + + var formatParams = constructFormatParams(); + params += formatParams; + + //alert(params); + rp.Request(params); +} + + +function constructURLParams(readAln) { + var params; + + if ($("useAlignDB") && $("useAlignDB").value == "true") { + + var alignDbParams = "&USE_ALIGNDB=true"; + var batchID = document.getElementsByName("ALIGNDB_BATCH_ID"); + if (batchID) { + alignDbParams += getHiddenFieldParamString("ALIGNDB_BATCH_ID"); + alignDbParams += getHiddenFieldParamString("ALIGNDB_MASTER_ALIAS"); + alignDbParams += getHiddenFieldParamString("ALIGNDB_CGI_HOST"); + alignDbParams += getHiddenFieldParamString("ALIGNDB_CGI_PATH"); + } + alignDbParams += "&ALIGN_SEQ_LIST=" + readAln.seqList; + alignDbParams += "&HSP_SORT=" + readAln.hspSort; + + if (readAln.hasOwnProperty("AlignDbPageNum")) { + alignDbParams += "&ALIGNDB_PAGE_NUM=" + readAln.AlignDbPageNum; + alignDbParams += "&ALIGNDB_PAGE_SIZE=" + readAln.AlignDbPageSize; + alignDbParams += "&HSP_START=" + readAln.AlignDbPageSize * readAln.AlignDbPageNum; + } + + params = "CMD=Get&RID=" + readAln.rid + "&OLD_BLAST=false&DESCRIPTIONS=0&NUM_OVERVIEW=0&DYNAMIC_FORMAT=on" + alignDbParams; + } + else { + params = "CMD=Get&RID=" + readAln.rid + "&OLD_BLAST=false&DESCRIPTIONS=0&NUM_OVERVIEW=0&GET_SEQUENCE=on&DYNAMIC_FORMAT=on&ALIGN_SEQ_LIST=" + readAln.seqList + "&HSP_SORT=" + readAln.hspSort; + } + if ($("phiPtInd")) { + params += "&PHI_PTTRN_INDEX=" + $("phiPtInd")[$("phiPtInd").selectedIndex].value; + } + return params; +} + +/* +readAln.rid = rid; +readAln.seqList = giList; +readAln.startIndex = parseInt(idx); +readAln.insertAfterID = insertAfterID; +readAln.numSeq = parseInt(numSeq); +readAln.scrollToSeqID = scrollToGI; +*/ +/*1. Draw div with id="alnShow_index" class ="alnMsg" with the message listing gis nad indexes +2. Insert another div with id="alnShowReal_index and class="alnMsgR" +3. For "alnShow_index" set atrr indexes="startInd-stopInd" +4. Set global g_MaxReadMessageIndex - max index of displayed seqalign ??? - check this +5. Add string "startInd-stopInd" to g_DisplayeAlignsRanges - comma separated indexes +6. Send read request +*/ + +function ReadSeqAlignForSeqList(readAln) { + var text = "
Loading alignment... for sequences " + readAln.seqList; + var stopIndex = readAln.startIndex + readAln.numSeq - 1; + var useAlignDB = ($("useAlignDB") && $("useAlignDB").value == "true") ? "AlignDB=on " : ""; + text += " " + useAlignDB + "Reading indexes " + readAln.startIndex + "-" + stopIndex + "
"; + text += "
"; + var debugControl = "
"; + if (!$("debug")) { + jQuery($($("descriptions"))).before(debugControl); + } + if (!$("alnShow_" + readAln.startIndex)) { + jQuery($($(readAln.insertAfterID))).after(text); + jQuery($($("alnShow_" + readAln.startIndex))).attr("indexes", readAln.startIndex + "-" + stopIndex); + jQuery($($("alnShow_" + readAln.startIndex))).attr("seqlist", readAln.seqList); + g_MaxReadMessageIndex = (readAln.startIndex > g_MaxReadMessageIndex) ? readAln.startIndex : g_MaxReadMessageIndex; + setSeqAlnReadStatus(readAln, "read"); + $("debug").innerHTML += ", " + useAlignDB + "Reading indexes " + readAln.startIndex + "-" + stopIndex; + + if (g_DisplayeAlignsRanges != "") g_DisplayeAlignsRanges += ","; + g_DisplayeAlignsRanges += readAln.startIndex + "-" + stopIndex; + + SendReadSeqAlinRequest(readAln); + } + else if ($("alnShowReal_" + readAln.startIndex).innerHTML.indexOf("Error") != -1) { + jQuery($("alnMsg_" + readAln.startIndex)).removeClass("hidden"); + jQuery($("erm_" + readAln.startIndex)).remove(); + SendReadSeqAlinRequest(readAln); + } +} + + +function ReSubmitReadSeqAligns(e,currInd) { + var rid = $("Rid").value; + if ($("alnShow_" + currInd)) { + var indexRange = jQuery($("alnShow_" + currInd)).attr("indexes"); + var range = indexRange.split("-"); + + + var readAln = new Object(); + readAln.seqList = ""; //giList + readAln.rid = rid; + readAln.seqList = jQuery($("alnShow_" + currInd)).attr("seqlist"); + readAln.startIndex = parseInt(range[0]); + readAln.numSeq = parseInt(range[1]) - parseInt(range[0]) + 1; + readAln.hspSort = 0; + ReadSeqAlignForSeqList(readAln); + utils.preventDefault(e); + } +} + + +var g_MaxReadMessageIndex = 0; //alnShow_idx with the message, deflnDesc_idx with stat="read" +var g_MaxDisplayedIndex = 0; //deflnDesc_idx with stat="disp" - last one in the set of N +var g_DisableAutoCheck = false; + +var g_autoStartIdx = new Array(); +var g_autoStopIdx = new Array(); + +function saveIdxesForAutomaticLoad(readAln) { + var stopIndex = readAln.startIndex + readAln.numSeq - 1; + g_autoStartIdx.push(readAln.startIndex); //1,20,25 + g_autoStopIdx.push(stopIndex); //4,24,29 + $("debug").innerHTML += ", displaying indexes " + readAln.startIndex + "-" + stopIndex; +} + +function getNextHspsLink(readAln) +{ + var moreHspsLink = "" + if (readAln.hasOwnProperty("AlignDbPageNum")) { + var nextPageNum = readAln.AlignDbPageNum + 1; + var currHspInd = readAln.AlignDbPageSize * nextPageNum; + var argstring = readAln.startIndex + "," + currHspInd; + var currGi = $("deflnDesc_" + readAln.startIndex).getAttribute("seqId"); + var accs = $("deflnDesc_" + readAln.startIndex).getAttribute("accs"); + var totalHsps = $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); + var prevHspInd = readAln.AlignDbPageSize * nextPageNum; + var segs = (prevHspInd + 1) + "-" + (prevHspInd + readAln.AlignDbPageSize); + var moreHspsID = "nxHsp" + currGi + "_" + (prevHspInd + 1); + + moreHspsLink = $("dynHspTmpl").innerHTML.replace("@moreHspsID@", moreHspsID); + moreHspsLink = moreHspsLink.replace(/@accs@/g, accs); + moreHspsLink = moreHspsLink.replace("@argstring@", argstring); + moreHspsLink = moreHspsLink.replace(/@segs@/g, segs); + moreHspsLink = moreHspsLink.replace("@totalHSP@", totalHsps); + moreHspsLink = moreHspsLink.replace(/@alignDbPageSize@/g, readAln.AlignDbPageSize); + moreHspsLink = moreHspsLink.replace("@aln_prev_num@", prevHspInd); + moreHspsLink = moreHspsLink.replace("@alnSeqGi@", currGi); + } + return moreHspsLink; +} + + +function ReadNextHSPSet(currSeqInd, currHSPNum) { + var readAln = new Object(); + + readAln.rid = $("Rid").value; + readAln.seqList = $("deflnDesc_" + currSeqInd).getAttribute("seqFSTA"); + readAln.gi = $("deflnDesc_" + currSeqInd).getAttribute("seqId"); + dynHsps = $("deflnDesc_" + currSeqInd).getAttribute("dynHsps"); + readAln.startIndex = currSeqInd; + readAln.numSeq = 1; + if (dynHsps) { + readAln.AlignDbPageNum = parseInt(currHSPNum) / parseInt(dynHsps); + readAln.AlignDbPageSize = parseInt(dynHsps); //number of HSps to retrieve + } + if (currHSPNum != 0) { + readAln.scrollToSeqID = "hsp" + +readAln.gi + "_" + (parseInt(currHSPNum) + 1); + readAln.insertAfterID = "ar_" + readAln.gi + "_" + currHSPNum; + } + var sortLink = $("sa_" + readAln.gi); + readAln.hspSort = (sortLink) ? parseInt(sortLink[sortLink.selectedIndex].value) : 0; + SendReadSeqAlinSortHSPRequest(readAln); +} + +function ReadNextHSPSetEvt(e, currSeqInd, currHSPNum) { + ReadNextHSPSet(currSeqInd, currHSPNum); + utils.preventDefault(e); +} + + + +function checkAutoAlignArray() { + var stop = false; + var start = false; + var currAlignViewPos = $("alignView").getBoundingClientRect().top; + if (currAlignViewPos < g_alignViewPos) {//scrolling down + g_alignViewPos = currAlignViewPos; + if (g_DisableAutoCheck) { + g_DisableAutoCheck = false; + return; + } + for (i = 0; i < g_autoStopIdx.length; i++) { + if (elementInViewport($("alnHdr_" + $("deflnDesc_" + g_autoStopIdx[i]).getAttribute("seqID")))) { + //alert("Reading more aligns scrolling down!"); + var nextInd = parseInt(g_autoStopIdx[i] + 1); + var currInd = g_autoStopIdx[i]; + if ($("deflnDesc_" + nextInd) && (!$("deflnDesc_" + nextInd).getAttribute("stat") || $("deflnDesc_" + nextInd).getAttribute("stat") == "")) { + ReadNextSeqAligns(currInd, 5); + stop = true; + break; + } + } + } + if (stop) g_autoStopIdx.splice(i, 1); //delete index from the array + } + else if (currAlignViewPos > g_alignViewPos) {//scrolling up + g_alignViewPos = currAlignViewPos; + //here maybe return if autoStop found!!! + /* commenting automic read when scroll up */ + for (i = 0; i < g_autoStartIdx.length; i++) { + if (elementInViewport($("alnHdr_" + $("deflnDesc_" + g_autoStartIdx[i]).getAttribute("seqID")))) { + //alert("Reading more aligns scrolling up!"); + var currInd = g_autoStartIdx[i]; + //Check for condition here if go there at all!!! Check if do the same thing as for ReadNext!!!! + if (currInd > 1) { + ReadPrevSeqAligns(currInd, 5); + start = true; + break; + } + } + } + if (start) g_autoStartIdx.splice(i, 1); + } + /*end of comment*/ +} + +var g_alignViewPos = 0; + +function checkAutoAlignLoad() { + + + checkAutoAlignArray(); + + if (jQuery($($(window))).scrollTop() + jQuery($($(window))).height() >= jQuery($($(document))).height() - 100) { + //alert("bottom!"); + + if ($("alnShowReal_" + g_MaxReadMessageIndex) && $("alnShowReal_" + g_MaxReadMessageIndex).innerHTML != "") { + //if(!$("alnShow_" + maxReadMessageIndex)) {//g_MaxReadMessageIndex + ReadNextSeqAligns(g_MaxDisplayedIndex, 5); + } + } +} + + +function GetPatternLocResults() +{ + form = $("results"); + if (!form.PHI_PTTRN_INDEX) { + var el = document.createElement("input"); + el.name = "PHI_PTTRN_INDEX"; + el.value = $("phiPtInd")[$("phiPtInd").selectedIndex].value; + form.appendChild(el); + } + else { + form.PHI_PTTRN_INDEX.value = $("phiPtInd")[$("phiPtInd").selectedIndex].value; + } + form.submit(); +} + +function goToNextHSP(elem, next) { + var par = jQuery(elem).parent(); //parent span with class="alnParLinks" + var parts = par[0].id.split("_"); //"hsp_hspnum "hsp207524544_2" + if (parts[0].indexOf("nxHsp") != -1) { + parts[0] = parts[0].replace("nxHsp", "hsp"); + } + nextID = (next) ? parts[0] + "_" + (parseInt(parts[1]) + 1) : parts[0] + "_" + (parseInt(parts[1]) - 1) + + gotoElem = jQuery($(nextID)); + if (gotoElem[0]) { + a = jQuery(gotoElem).offset(); + window.scroll(0, a.top); + } + + else { + retrieveNextHSP(parts[0],parts[1]); + } + +} + + +//parts[0]//hsp, parts[1] hspnum +function retrieveNextHSP(currLinkID, currHSPNum) +{ + var desLineID = currLinkID.replace("hsp", "dtr_"); //tr id + var currSeqInd, totalHsps; + jQuery($($(desLineID))).find(".deflnDesc").each(function(index) { + currSeqInd = parseInt(this.getAttribute("ind")); + totalHsps = parseInt(this.getAttribute("hsp")); + dynHsps = this.getAttribute("dynHsps"); + }); + currHSPNum = parseInt(currHSPNum); + if (currHSPNum < totalHsps && dynHsps) { + ReadNextHSPSet(currSeqInd, currHSPNum); + } +} +/********Adding those functions back to formatRes.js to identify Uncaught ReferenceError: getUrlCompForCheckedField is not defined error********************************/ +function getUrlCompForEntryField(elem) { + var url = ""; + if (elem && elem.value != "") { + url = "&" + elem.name + "=" + escape(elem.value); + } + return url; +} + + +function getUrlCompForCheckedField(elem) { + var url = ""; + if (elem && elem.checked) { + url = "&" + elem.name + "=" + elem.value; + } + return url; + +} + +function getUrlCompForOptionsField(elem) { + var url = ""; + if (elem) { + url = "&" + elem.name + "=" + elem[elem.selectedIndex].value; + } + return url; +} +/****************************************/ + +function constructFormatParams() { + var formatParams = ""; + + if ($("queryList")) { + formatParams += "&QUERY_INDEX=" + $("queryList")[$("queryList").selectedIndex].value; + } + + + formatParams += getUrlCompForCheckedField($("FormatForm").SHOW_LINKOUT); + formatParams += getUrlCompForCheckedField($("FormatForm").SHOW_CDS_FEATURE); + formatParams += getUrlCompForCheckedField($("FormatForm").NCBI_GI); + formatParams += getUrlCompForOptionsField($("FormatForm").ALIGNMENT_VIEW); + formatParams += getUrlCompForOptionsField($("FormatForm").MASK_CHAR); + formatParams += getUrlCompForOptionsField($("FormatForm").MASK_COLOR); + formatParams += getUrlCompForEntryField($("FormatForm").EXPECT_LOW); + formatParams += getUrlCompForEntryField($("FormatForm").EXPECT_HIGH); + formatParams += getUrlCompForEntryField($("FormatForm").PERC_IDENT_LOW); + formatParams += getUrlCompForEntryField($("FormatForm").PERC_IDENT_HIGH); + formatParams += getUrlCompForEntryField($("FormatForm").LINE_LENGTH); + + + formatParams += getHiddenFieldParamString("BUILD_NAME"); + + var serviceType = ""; + if ($("serviceType").value == "sra") { + serviceType = "sra"; + } + else if ($("clientType").value == "TMSmart_restricted") { + serviceType = "restricted"; + } + if (serviceType != "") { + formatParams += "&BOBJSRVC=" + serviceType; + } + if ($("currQuery").value != "") { + formatParams += "&CURR_QUERY_ID=" + $("currQuery").value; + } + + return formatParams; +} + +//readAln.seqList contains one gi only for this +function SendReadSeqAlinSortHSPRequest(readAln) { + blastUrl = "t2g.cgi"; + var rp = new RemoteDataProvider(blastUrl); + + + rp.onSuccess = function(obj) { + var moreHspsLink = (readAln.hasOwnProperty("AlignDbPageNum")) ? getNextHspsLink(readAln) : ""; + var alnHtml = obj.responseText + moreHspsLink; + initHSPRequest(readAln, obj.responseText + moreHspsLink,false); + if (readAln.scrollToSeqID) { + location.href = "#" + readAln.scrollToSeqID; + } + }; + rp.onError = function(obj) { + var currHspInd = (readAln.hasOwnProperty("AlignDbPageNum")) ? readAln.AlignDbPageSize * readAln.AlignDbPageNum : 0; + var msgID = "erm_" + readAln.gi + "_" + (currHspInd + 1); + if (!$(msgID)) { + var msg = "
"; + initHSPRequest(readAln, msg, true); + } + else { + var attNum = parseInt($(msgID).getAttribute("att")) + 1; + $(msgID).setAttribute("att", attNum); + jQuery($(msgID)).find(".attmt").each(function(index) { + jQuery(this).html(", attempt " + attNum); + }); + } + } + + var params = constructURLParams(readAln); + if (readAln.AlignDbPageSize) { + params += "&TOTAL_HSPS=" + $("deflnDesc_" + readAln.startIndex).getAttribute("hsp"); + } + params += "&SORT_ONE_ALN=on"; + var formatParams = constructFormatParams(); + + params += formatParams; + + //alert(params); + rp.Request(params); +} +function initHSPRequest(readAln, alnHtml, err) { + var currHspInd = (readAln.hasOwnProperty("AlignDbPageNum")) ? readAln.AlignDbPageSize * readAln.AlignDbPageNum : 0; + if (currHspInd != 0) { + readAln.insertAfterID = "ar_" + readAln.gi + "_" + currHspInd; + jQuery($(readAln.insertAfterID)).after(alnHtml); + moreHspsID = "nxHsp" + readAln.gi + "_" + (currHspInd + 1); + jQuery($(moreHspsID)).remove(); + if (!err) { + errMsgID = "erm_" + readAln.gi + "_" + (currHspInd + 1); + jQuery($(errMsgID)).remove(); + } + } + else { + jQuery($("alnAll_" + readAln.gi)).html(alnHtml); + } +} + +function SortHSPAlnSel(e, sortLink) {//example id="sa_207524544" + var readAln = new Object(); + + + var desLineID = sortLink.id.replace("sa", "dtr"); //tr id + var seqInd; + + jQuery($($(desLineID))).find(".deflnDesc").each(function(index) { + seqInd = this.getAttribute("ind"); + }); + + ReadNextHSPSet(parseInt(seqInd), 0); +} + + +function configDescriptions(e,btn,dlgId) +{ + var suffix = PsiBelowThresh(dlgId); + var colmnsInfId = "cfcDsInf" + suffix; + var tblID = "dscTable" + suffix; //"dscTable[_psiw]" + var showAllColId = "shcl" + suffix; + var chkBoxes = $C("checkbox", "type", $(dlgId), "input"); + if (!utils.hasClass(btn, "cnc")) $(colmnsInfId).value = ""; + for (i = 0; i < chkBoxes.length; i++) { + var check; + if (utils.hasClass(btn, "cnc")) {//cancel + if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) != -1 && !chkBoxes[i].checked) { + check = true; + } + else if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) == -1 && chkBoxes[i].checked) { + check = false; + } + } + else if (utils.hasClass(btn, "rdf") && !chkBoxes[i].checked) { + check = true; + } + if (typeof (check) != 'undefined') { + chkBoxes[i].checked = check; + showHideCol(tblID,parseInt(chkBoxes[i].value), !check); + } + if (!utils.hasClass(btn, "cnc")) { + if (chkBoxes[i].checked) { //OK + if ($(colmnsInfId).value != "") $(colmnsInfId).value += ","; + $(colmnsInfId).value += chkBoxes[i].value; + } + } + } + if ($(colmnsInfId).value != $(colmnsInfId).getAttribute("defval")) {//defval = "2,3,4,5,6,7,8" + jQuery($(showAllColId)).removeClass("hidden"); + } + else { + jQuery($(showAllColId)).addClass("hidden"); + } + + var chConfig = $("cfcDsSave").value != $(colmnsInfId).value; + + var cfds = document.getElementsByName("CONFIG_DESCR"); + if (cfds) { + for (i = 0; i < cfds.length; i++) { + cfds[i].value = $(colmnsInfId).value; + } + } + $("cfcDsSave").value = $(colmnsInfId).value; + if (chConfig) SaveConfigTable(); + jQuery(document.body).click(); + utils.preventDefault(e); +} + + + +function initDescConfig() +{ + initConfigColumns("dsConfig"); + if ($("psiw") && utils.hasClass($("psiw"), "shown")) { + initConfigColumns("dsConfig_psiw"); + } +} + + +function initConfigColumns(cnfDlgID) +{ + var suffix = PsiBelowThresh(cnfDlgID); + //cnfDlgID is "dsConfig[_psiw]" + var colmnsInfId = "cfcDsInf" + suffix; + var tblID = "dscTable" + suffix; //"dscTable[_psiw]" + var showAllColId = "shcl" + suffix; + + if (navigator.userAgent.match(/ie/i)) { + if ($("FormatForm").NCBI_GI.checked || $("serviceType").value == "sra") { + jQuery($(tblID)).find("th.c1").each(function(index) { + db = getHiddenFieldVal("DATABASE"); + var width = (db.match(/WGS/i) || db.match(/Whole_Genome_Shotgun_contigs/i)) ? "16em" : "14em"; + jQuery(this).css("width", width); + }); + } + } + + jQuery($(tblID)).find("tr.first").each(function(index) { + jQuery(this).find("a.dcs").each(function(index) { + jQuery(this).bind("click", function(e) { checkConfig(this); }); + }); + }); + + jQuery($(cnfDlgID)).find("button").each(function(index) { + jQuery(this).bind("click", function(e) { configDescriptions(e, this, cnfDlgID); }); + }); + + + jQuery($(cnfDlgID)).bind("click", function(e) { e.stopPropagation(); }); + + $(colmnsInfId).value = getHiddenFieldVal("CONFIG_DESCR"); + if ($(colmnsInfId).value == "" || $(colmnsInfId).value == "undefined") { + $(colmnsInfId).value = $(colmnsInfId).getAttribute("defval"); + } + if ($(colmnsInfId).value != $(colmnsInfId).getAttribute("defval")) {//defval = "2,3,4,5,6,7,8" + jQuery($(showAllColId)).removeClass("hidden"); + } + else { + jQuery($(showAllColId)).addClass("hidden"); + } + var chkBoxes = $C("checkbox", "type", $(cnfDlgID), "input") + for (i = 0; i < chkBoxes.length; i++) { + jQuery(chkBoxes[i]).bind("click", configColumn); + if ($(colmnsInfId).value.indexOf(chkBoxes[i].value) != -1) { + chkBoxes[i].checked = true; + } + else { + //jQuery($(tblID)).ncbigrid("hideColumn", chkBoxes[i].value); + showHideCol($(tblID), chkBoxes[i].value, true); + } + } +} +function showAllCol(e,elem) +{ + var suffix = PsiBelowThresh(elem.id); + var rdf = "dscRsDf" + suffix; + jQuery($(rdf)).click();//click "restore defaults' + utils.preventDefault(e); +} + + +function configColumn() { + var suffix = PsiBelowThresh(this.id); + var tblID = "dscTable" + suffix; //"dscTable[_psiw]" + + cCls = "c" + this.value; + if (this.checked) {//show + showHideCol(tblID,parseInt(this.value), false); + } + else { + showHideCol(tblID,parseInt(this.value), true); + } +} + +function showHideCol(tblID, columnIndex, hide) { + + if ($("Transcr")) { + colHidden = utils.hasClass($("c" + columnIndex), "ui-ncbigrid-column-hidden"); + hide = hide && !colHidden; + show = !hide && colHidden; + } + else { + show = !hide; + } + if (hide) { + jQuery($(tblID)).ncbigrid("hideColumn", columnIndex); + } + else if (show) { + jQuery($(tblID)).ncbigrid("showColumn", columnIndex); + } + if ($("Transcr") && (hide || show) ) { + var colsp = parseInt($("Transcr").getAttribute("colspan")); + colsp = (hide) ? colsp - 1 : colsp + 1; + $("Transcr").setAttribute("colSpan", colsp); + if ($("GnmSeq")) $("GnmSeq").setAttribute("colSpan", colsp); + } +} + +function checkConfig(lnk) { + var cnfCol = "&CONFIG_DESCR=" + $("cfcDsSave").value; + lnk.href = lnk.href + cnfCol + "#sort_mark"; +} + +function DisplayAlignFromGraphics(seqID,e) //SeqID = gi if exists +{ + var dflLineLinks = $C(seqID, "gi", document, "a"); + for (i = 0; i < dflLineLinks.length; i++) { + jQuery(dflLineLinks[i]).click(); + break; + } + location.href = dflLineLinks[i].href; +} + + + +function initDescSelect() +{ + + jQuery("#cntDesc").find("a").each(function(index) { + jQuery(this).bind("click", configDescrSelect); + }); + jQuery("#cntSelN").click(); + jQuery("#descTblCtrl").find("a[view]").each(function(index) { + jQuery(this).bind("click", DisplaySelectedView); + }); + if ($("psiw") && utils.hasClass($("psiw"), "shown")) { + jQuery("#cntDesc_psiw").find("a").each(function(index) { + jQuery(this).bind("click", configDescrSelect); + }); + jQuery("#cntSelN_psiw").click(); + jQuery("#descTblCtrl_psiw").find("a[view]").each(function(index) { + jQuery(this).bind("click", DisplaySelectedView); + }); + } + + + //jQuery("#dsConfig").bind("click", function(e) { e.stopPropagation(); });?? + +} + +function DisplaySelectedView(e) { + if (this.getAttribute("view") == "graph") { //seqviewer + ViewSelectedSeqViewer(e,this); + } + else { + if (this.getAttribute("view") == "tree") { //seqviewer + $("scrWidth").value = screen.width; + $("scrHeight").value = screen.height; + } + ViewSelectedSeqsEx(e, this); + } +} + +function PsiBelowThresh(elemID) +{ + var suffix = ""; + if (elemID.indexOf("_psiw") != -1) { + suffix = "_psiw"; + } + return suffix; +} + +function ViewSelectedSeqsEx(e,elem) { + var sbmForm = elem.getAttribute("frm"); + var seqList = elem.getAttribute("seqList"); + + var cnfElem = utils.getParent(elem); //.cnf div + var suffix = PsiBelowThresh(cnfElem.id); + var tblID = "dscTable" + suffix; + + $(seqList).value = createSelseqString(tblID,true); + $(seqList).value = $(seqList).value.replace(/ti:/g, ""); //For traces + if ($(seqList).value.indexOf("dbSNP") != -1) { + $(seqList).value = $(seqList).value.replace(/dbSNP:rs/g, ""); //For snp + elem.href = $(sbmForm).action + $(seqList).value; + elem.target = "new"; + } + else { + $(sbmForm).submit(); + utils.preventDefault(e); + } +} + +function ViewSelectedSeqsTree(e) { + $("scrWidth").value = screen.width; + $("scrHeight").value = screen.height; +} + +function initSeqViewerGet(seqList) { + if (seqList.length >= 2000) { + seqList = seqList.substr(0,2000); + lastComma = seqList.lastIndexOf(","); + seqList = seqList.substr(0,lastComma); + } + $("seqViewParams").name = "RID"; + $("seqViewParams").value = $("ridParam").value + "[" + seqList + "]"; +} + +function ViewSelectedSeqViewer(e, elem) +{ + var cnfElem = utils.getParent(elem); //.cnf div + var suffix = PsiBelowThresh(cnfElem.id); + var tblID = "dscTable" + suffix; + + //change to false when new verison of seqVier is installed in production + var seqList = createSelseqString(tblID, false); + $("sbmtGraphics").action = $("seqViewUrl").value; + + var rp = new RemoteDataProvider("url2nc.cgi"); + rp.onSuccess = function(obj) { + var jsnResp = JSON.parse(obj.responseText); + ncid = jsnResp.ncid; + + if (ncid != "") { + $("seqViewParams").name = "rkey"; + $("seqViewParams").value = ncid; + } + else { + initSeqViewerGet(seqList); + } + $("sbmtGraphics").submit(); + }; + rp.onError = function(obj) { + initSeqViewerGet(seqList); + $("sbmtGraphics").submit(); + utils.preventDefault(e); + } + var params = $("ridParam").value + "[" + seqList + "]"; + rp.Request(params, "POST"); + utils.preventDefault(e); +} + +function configDescrSelect(e) { + var sel = this.getAttribute("sel"); + if (sel) { + var selNum = 0; + var check = (sel == "all") ? true : false; + + var suffix = PsiBelowThresh(this.id); + var tblID = "dscTable" + suffix; + var toolbarID = "descTblCtrl" + suffix; + var selElID = "slcNum" + suffix; + + jQuery($(tblID)).find("input[type='checkbox'].cb").each(function(index) { + jQuery(this)[0].checked = check; + if (check) selNum++; + }); + enableDescrLinks(selNum, toolbarID, selElID); + } + utils.preventDefault(e); +} + + + +function enableDescrLinks(selNum, toolbarID, selElID) { + jQuery($(toolbarID)).find("a[minSlct]").each(function(index) { + var minSelected = this.getAttribute("minSlct"); + minSelected = parseInt(minSelected); + if (selNum >= minSelected) { + this.removeAttribute("disabled"); + } + else { + this.setAttribute("disabled", "disabled"); + } + }); + $(selElID).innerHTML = selNum; +} + + + +function configDescrLinks(e, elem) +{ + + ncbi.sg.ping(elem, "click", elem.checked ? "checked=true" : "checked=false"); + var par = jQuery(elem).parents(".jig-ncbigrid");//parent table + if (par) { + var suffix = PsiBelowThresh(par[0].id); + var tblID = "dscTable" + suffix; + var toolbarID = "descTblCtrl" + suffix; + var selElID = "slcNum" + suffix; + + var currSelNum = parseInt($(selElID).innerHTML); + var selNum = elem.checked ? currSelNum + 1 : currSelNum - 1; + enableDescrLinks(selNum, toolbarID, selElID); + } +} +/***Download code begin****/ + +function initDownLoadPopup(dwnDialog) { + + jQuery(dwnDialog).find("button").each(function(index) { + jQuery(this).bind("click", execDownLoad); + }); + + jQuery(dwnDialog).bind("click", function(e) { e.stopPropagation(); }); +} + +function initDescDownLoad() { + initDownLoadPopup($("dsDownload")); + + if ($("psiw") && utils.hasClass($("psiw"), "shown")) { + initDownLoadPopup($("dsDownload_psiw")); + } +} + +function initAlignDownLoad(navObj) +{ + var seqID = navObj.seqID; + var dwnDialog = $("dlgDwnl_" + seqID); + jQuery(dwnDialog).find("button").each(function(index) { + jQuery(this).bind("click", execDownLoad); + }); + + var dwnFSTW = $("dwFST_" + seqID);//whole seq + var dwnFSTAl = $("dwFSTAl_" + seqID);//aligned regions + + if(dwnFSTW) dwnFSTW.setAttribute("seqfsta", navObj.currSeqID); + if(dwnFSTAl) dwnFSTAl.setAttribute("seqfsta", navObj.currSeqID); + + jQuery(dwnDialog).bind("click", function(e) { e.stopPropagation(); }); +} + + +function execDownLoad(e) { + if (!utils.hasClass(this, "cnc")) { + par = utils.getParent(this); + dwnDialog = utils.getParent(par); //parent dialog with popDl class + var descr = (this.id == "dw_cont" || this.id == "dw_cont_psiw") ? true : false; + jQuery(dwnDialog).find("input").each(function(index) { + if (this.checked) { + submitDownLoad(this, descr); + } + }); + } + jQuery(document.body).click(); + utils.preventDefault(e); +} + +function submitDownLoad(radioElem, descr) { + var toolURL = radioElem.getAttribute("url"); + if (toolURL) { + if (descr) { + var getGi = radioElem.getAttribute("getGi"); + getGi = (getGi) ? true : false; + + var tblID = "dscTable"; + var suffix = PsiBelowThresh(radioElem.id); + tblID += suffix; + + $("selDnSeqs").value = createSelseqString(tblID,getGi); + } + else { + var seqfsta = radioElem.getAttribute("seqfsta"); + $("selDnSeqs").value = (seqfsta) ? seqfsta : radioElem.getAttribute("getGi"); + } + var addParams = ""; + if (radioElem.getAttribute("addParam")) { + addParams = addDwnlParams(); + } + var submitName = radioElem.getAttribute("sbName") + $("selDnSeqs").name = (submitName) ? submitName : "ALIGN_SEQ_LIST"; + $("dwdlSubmit").action = toolURL + addParams; + $("dwdlSubmit").submit(); + } + else { + var sbFunction = radioElem.getAttribute("sbFunc"); + if (sbFunction) { + eval(sbFunction + "(radioElem, descr)"); + } + } +} + + +function initDownLoadFSTA(radioElem, descr) +{ + if (descr) { + + var tblID = "dscTable"; + var suffix = PsiBelowThresh(radioElem.id); + tblID += suffix; + + $("sbmtFASTA").ALIGN_SEQ_LIST.value = createSelseqString(tblID,false); + } + else { + $("sbmtFASTA").ALIGN_SEQ_LIST.value = radioElem.getAttribute("seqfsta"); + } + $("sbmtFASTA").DOWNLOAD_TYPE.value = radioElem.getAttribute("fstaDWType"); + + $("sbmtFASTA").DATABASE.value = getHiddenFieldVal("DATABASE"); + if ($("useAlignDB") && $("useAlignDB").value == "true") {//temp checkbox + var batchID = document.getElementsByName("ALIGNDB_BATCH_ID"); + if (batchID) { + $("sbmtFASTA").ALIGNDB_BATCH_ID.value = getHiddenFieldVal("ALIGNDB_BATCH_ID"); + $("sbmtFASTA").ALIGNDB_MASTER_ALIAS.value = getHiddenFieldVal("ALIGNDB_MASTER_ALIAS"); + $("sbmtFASTA").ALIGNDB_CGI_HOST.value = getHiddenFieldVal("ALIGNDB_CGI_HOST"); + $("sbmtFASTA").ALIGNDB_CGI_PATH.value = getHiddenFieldVal("ALIGNDB_CGI_PATH"); + } + } + $("sbmtFASTA").submit(); +} + +function createSelseqString(tblID,getGi) { + var selSeqs = ""; + jQuery($(tblID)).find("input[type='checkbox'].cb").each(function(index) { + if (jQuery(this)[0].checked) { + if (selSeqs != "") selSeqs += ","; + if (getGi) { + selSeqs += jQuery(this)[0].value; + } + else { + var linkID = jQuery(this)[0].id.replace("chk", "deflnDesc"); + selSeqs += $(linkID).getAttribute("seqFSTA"); + } + } + }); + return selSeqs; +} + +/***Download code end****/ + +/***Init navigation code begin **/ + +function initNavigation(navObj) { + initNextAlnLink(navObj, true); + initNextAlnLink(navObj, false); +} + + +function initNavInfo(navObj) { + var currInd = parseInt($("dtr_" + navObj.seqID).getAttribute("ind")); + nextInd = currInd + 1; + prevInd = currInd - 1; + + navObj.currSeqID = ""; + navObj.nextSeqID = ""; + navObj.prevSeqID = ""; + + if ($("deflnDesc_" + nextInd)) { + navObj.nextSeqID = $("deflnDesc_" + nextInd).getAttribute("accs"); + if(navObj.nextSeqID =="") navObj.nextSeqID = $("deflnDesc_" + nextInd).getAttribute("seqFSTA"); + } + if ($("deflnDesc_" + prevInd)) { + navObj.prevSeqID = $("deflnDesc_" + prevInd).getAttribute("accs"); + if (navObj.prevSeqID == "") navObj.prevSeqID = $("deflnDesc_" + prevInd).getAttribute("seqFSTA"); + } + if ($("deflnDesc_" + currInd)) { + navObj.currSeqID = $("deflnDesc_" + currInd).getAttribute("seqFSTA"); + } +} + + +function initNextAlnLink(navObj, next) { + + var nextLinkEl = (next) ? $("alnNxt_" + navObj.seqID) : $("alnPrv_" + navObj.seqID); + var nextSeqid = (next) ? navObj.nextSeqID : navObj.prevSeqID; + + if (nextLinkEl) { + if (nextSeqid != "") { + var text = (next) ? "next" : "previous"; + nextLinkEl.setAttribute("title", "Go to " + text + " alignment for " + nextSeqid); + } + else { + nextLinkEl.setAttribute("disabled", "disabled"); + } + } +} +function scan(link) { + var init = link.getAttribute("init"); + if (!init) { + ncbi.sg.scanLinks(link); + link.setAttribute("init","on"); + } +} + +function initWidth(seqID) { + var lineLengthElem = $("FormatForm").LINE_LENGTH; + var lineLength = parseInt(lineLengthElem[lineLengthElem.selectedIndex].value); + if (parseInt(lineLengthElem.getAttribute("defval")) == lineLength) return; + + var relWidth = (lineLength > 90) ? "12%" : "15%"; + var charWidth = (navigator.userAgent.match(/ie/i)) ? 8 : 7; + lineLength = (lineLength + parseInt(17)) * charWidth; + var width = lineLength + "px"; + jQuery($("alnAll_" + seqID)).find("div.dflLnk").each(function(index) { + jQuery(this).css("width", width); + }); + jQuery($("alnAll_" + seqID)).find("table.alnParams").each(function(index) { + jQuery(this).css("width", width); + }); + jQuery($("relInf_" + seqID)).css("width", relWidth); +} + + +/***Init navigation code end **/ +function initAlignBatch(seqID) +{ + var navObj = new Object(); + navObj.seqID = seqID; + initNavInfo(navObj); + + initAlignDownLoad(navObj); + initNavigation(navObj); + ncbi.sg.scanLinks($("alnNxt_" + seqID)); + ncbi.sg.scanLinks($("alnPrv_" + seqID)); + if ($("serviceType").value == "vecscreen") { + utils.addClass($("alnDsc_" + seqID), "hidden"); + } + ncbi.sg.scanLinks($("alnDwnld_" + seqID)); + jQuery($("csLinks_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); + jQuery($("relInf_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); + jQuery($("rng_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); + jQuery($("dln_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); + initWidth(seqID); +/* + jQuery($("alnHdr_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); + jQuery($("aln_" + seqID)).find("a").each(function(index) { + ncbi.sg.scanLinks(this); + }); +*/ +} + +function SaveConfigTable() { + blastUrl = "fmtsave.cgi"; + + + var rp = new RemoteDataProvider(blastUrl); + + + rp.onSuccess = function(obj) { + //alert("success"); + }; + rp.onError = function(obj) { + //alert("error"); + } + + var program = getHiddenFieldVal("PROGRAM"); + var rid = getHiddenFieldVal("RID"); + var blastSpec = getHiddenFieldVal("BLAST_SPEC"); + var params = "CMD=Get&RID=" + rid + "&ViewReport=on&PROGRAM=" + program + "&SAVE_INDV_FRM_OPTION=on&CONFIG_DESCR=" + $("cfcDsSave").value; + if(blastSpec) { + params += "&BLAST_SPEC=" + blastSpec; + } + rp.Request(params,"POST"); +} + +function removeRID() { + var rid = document.getElementsByName("RID"); + for (var i = 0; i <= rid.length; i++) { + jQuery(rid[i]).remove(); + } +} + +function initAdvancedView() +{ + if ($("dsConfig")) { + + var alnView = getHiddenFieldVal("ALIGNMENT_VIEW"); + if (alnView == "Pairwise" || alnView == "PairwiseWithIdentities") { + var rid = getHiddenFieldVal("RID"); + ReadNextSeqAligns(0, 5); + g_alignViewPos = $("alignView").getBoundingClientRect().top; + utils.addEvent(window, "scroll", checkAutoAlignLoad, false); + } + list = $("phiPtInd"); + if (list) { + utils.addEvent(list, "change", GetPatternLocResults, false); + } + initDescConfig(); + initDescSelect(); + initDescDownLoad(); + if ($("psiInp")) { + var nextIter = document.getElementsByName("NEXT_I"); + for (var i = 0; i < nextIter.length; i++) { + utils.addEvent(nextIter[i], "click", removeRID, false); + } + } + } +} + +//takes care of jQuery calls to elements that have dots in id like id= "SRA34456.3.4" +function initjQry() +{ + var oldCreate = jQuery.ui.ncbipopper.prototype._create; + jQuery.ui.ncbipopper.prototype._create = function() { + var destSelector = this.options.destSelector || this.options.sourceSelector || this.element.prop("hash"); + this.options.destSelector = destSelector.replace(/\./g, "\\."); + oldCreate.apply(this, arguments); + } +} +utils.addEvent(window, + "load", initAdvancedView, + false); + +initjQry() + +/* If user agent has "safari" in it, include safari-specific stylesheet. */ +if (navigator.userAgent.match(/ie/i)) { + document.write(""); +} +/*****************************new code end*********************************************************************/ diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/helix.gif Binary file NCBI Blast reference example_files/helix.gif has changed diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/jig.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/jig.css Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,1 @@ +.ui-helper-hidden{display:none;}.ui-helper-hidden-accessible{position:absolute;left:-99999999px;}.ui-helper-reset{margin:0;padding:0;border:0;outline:0;line-height:1.3;text-decoration:none;font-size:100%;list-style:none;}.ui-helper-clearfix:after{content:".";display:block;height:0;clear:both;visibility:hidden;}.ui-helper-clearfix{display:inline-block;}/* required comment for clearfix to work in Opera \*/ * html .ui-helper-clearfix{height:1%;}.ui-helper-clearfix{display:block;}/* end clearfix */ .ui-helper-zfix{width:100%;height:100%;top:0;left:0;position:absolute;opacity:0;filter:Alpha(Opacity=0);}.ui-state-disabled{cursor:default!important;}.ui-icon{display:block;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat;}.ui-widget-overlay{position:absolute;top:0;left:0;width:100%;height:100%;}.ui-widget{font-size:1.1em;}.ui-widget-content{border:1px solid #aaa;background:#fff url(images/ui-bg_flat_75_ffffff_40x100.png) 50% 50% repeat-x;color:#222;}.ui-widget-content a{color:#222;}.ui-widget-header{border:1px solid #aaa;background:#ccc url(images/ui-bg_highlight-soft_75_cccccc_1x100.png) 50% 50% repeat-x;color:#222;font-weight:bold;}.ui-widget-header a{color:#222;}.ui-state-default,.ui-widget-content .ui-state-default{border:1px solid #d3d3d3;background:#e6e6e6 url(images/ui-bg_glass_75_e6e6e6_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#555;}.ui-state-default a,.ui-state-default a:link,.ui-state-default a:visited{color:#555;text-decoration:none;}.ui-state-hover,.ui-widget-content .ui-state-hover,.ui-state-focus,.ui-widget-content .ui-state-focus{border:1px solid #999;background:#dadada url(images/ui-bg_glass_75_dadada_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#212121;}.ui-state-hover a,.ui-state-hover a:hover{color:#212121;text-decoration:none;}.ui-state-active,.ui-widget-content .ui-state-active{border:1px solid #aaa;background:#fff url(images/ui-bg_glass_65_ffffff_1x400.png) 50% 50% repeat-x;font-weight:normal;color:#212121;}.ui-state-active a,.ui-state-active a:link,.ui-state-active a:visited{color:#212121;text-decoration:none;}.ui-state-highlight,.ui-widget-content .ui-state-highlight{border:1px solid #fcefa1;background:#fbf9ee url(images/ui-bg_glass_55_fbf9ee_1x400.png) 50% 50% repeat-x;color:#363636;}.ui-state-highlight a,.ui-widget-content .ui-state-highlight a{color:#363636;}.ui-state-error,.ui-widget-content .ui-state-error{border:1px solid #cd0a0a;background:#fef1ec url(images/ui-bg_glass_95_fef1ec_1x400.png) 50% 50% repeat-x;color:#cd0a0a;}.ui-state-error a,.ui-widget-content .ui-state-error a{color:#cd0a0a;}.ui-state-error-text,.ui-widget-content .ui-state-error-text{color:#cd0a0a;}.ui-priority-primary,.ui-widget-content .ui-priority-primary{font-weight:bold;}.ui-priority-secondary,.ui-widget-content .ui-priority-secondary{opacity:.7;filter:Alpha(Opacity=70);font-weight:normal;}.ui-state-disabled,.ui-widget-content .ui-state-disabled{opacity:.35;filter:Alpha(Opacity=35);background-image:none;}.ui-icon{width:16px;height:16px;background-image:url(images/ui-icons_222222_256x240.png);}.ui-widget-content .ui-icon{background-image:url(images/ui-icons_222222_256x240.png);}.ui-widget-header .ui-icon{background-image:url(images/ui-icons_222222_256x240.png);}.ui-state-default .ui-icon{background-image:url(images/ui-icons_888888_256x240.png);}.ui-state-hover .ui-icon,.ui-state-focus .ui-icon{background-image:url(images/ui-icons_454545_256x240.png);}.ui-state-active .ui-icon{background-image:url(images/ui-icons_454545_256x240.png);}.ui-state-highlight .ui-icon{background-image:url(images/ui-icons_2e83ff_256x240.png);}.ui-state-error .ui-icon,.ui-state-error-text .ui-icon{background-image:url(images/ui-icons_cd0a0a_256x240.png);}.ui-icon-carat-1-n{background-position:0 0;}.ui-icon-carat-1-ne{background-position:-16px 0;}.ui-icon-carat-1-e{background-position:-32px 0;}.ui-icon-carat-1-se{background-position:-48px 0;}.ui-icon-carat-1-s{background-position:-64px 0;}.ui-icon-carat-1-sw{background-position:-80px 0;}.ui-icon-carat-1-w{background-position:-96px 0;}.ui-icon-carat-1-nw{background-position:-112px 0;}.ui-icon-carat-2-n-s{background-position:-128px 0;}.ui-icon-carat-2-e-w{background-position:-144px 0;}.ui-icon-triangle-1-n{background-position:0 -16px;}.ui-icon-triangle-1-ne{background-position:-16px -16px;}.ui-icon-triangle-1-e{background-position:-32px -16px;}.ui-icon-triangle-1-se{background-position:-48px -16px;}.ui-icon-triangle-1-s{background-position:-64px -16px;}.ui-icon-triangle-1-sw{background-position:-80px -16px;}.ui-icon-triangle-1-w{background-position:-96px -16px;}.ui-icon-triangle-1-nw{background-position:-112px -16px;}.ui-icon-triangle-2-n-s{background-position:-128px -16px;}.ui-icon-triangle-2-e-w{background-position:-144px -16px;}.ui-icon-arrow-1-n{background-position:0 -32px;}.ui-icon-arrow-1-ne{background-position:-16px -32px;}.ui-icon-arrow-1-e{background-position:-32px -32px;}.ui-icon-arrow-1-se{background-position:-48px -32px;}.ui-icon-arrow-1-s{background-position:-64px -32px;}.ui-icon-arrow-1-sw{background-position:-80px -32px;}.ui-icon-arrow-1-w{background-position:-96px -32px;}.ui-icon-arrow-1-nw{background-position:-112px -32px;}.ui-icon-arrow-2-n-s{background-position:-128px -32px;}.ui-icon-arrow-2-ne-sw{background-position:-144px -32px;}.ui-icon-arrow-2-e-w{background-position:-160px -32px;}.ui-icon-arrow-2-se-nw{background-position:-176px -32px;}.ui-icon-arrowstop-1-n{background-position:-192px -32px;}.ui-icon-arrowstop-1-e{background-position:-208px -32px;}.ui-icon-arrowstop-1-s{background-position:-224px -32px;}.ui-icon-arrowstop-1-w{background-position:-240px -32px;}.ui-icon-arrowthick-1-n{background-position:0 -48px;}.ui-icon-arrowthick-1-ne{background-position:-16px -48px;}.ui-icon-arrowthick-1-e{background-position:-32px -48px;}.ui-icon-arrowthick-1-se{background-position:-48px -48px;}.ui-icon-arrowthick-1-s{background-position:-64px -48px;}.ui-icon-arrowthick-1-sw{background-position:-80px -48px;}.ui-icon-arrowthick-1-w{background-position:-96px -48px;}.ui-icon-arrowthick-1-nw{background-position:-112px -48px;}.ui-icon-arrowthick-2-n-s{background-position:-128px -48px;}.ui-icon-arrowthick-2-ne-sw{background-position:-144px -48px;}.ui-icon-arrowthick-2-e-w{background-position:-160px -48px;}.ui-icon-arrowthick-2-se-nw{background-position:-176px -48px;}.ui-icon-arrowthickstop-1-n{background-position:-192px -48px;}.ui-icon-arrowthickstop-1-e{background-position:-208px -48px;}.ui-icon-arrowthickstop-1-s{background-position:-224px -48px;}.ui-icon-arrowthickstop-1-w{background-position:-240px -48px;}.ui-icon-arrowreturnthick-1-w{background-position:0 -64px;}.ui-icon-arrowreturnthick-1-n{background-position:-16px -64px;}.ui-icon-arrowreturnthick-1-e{background-position:-32px -64px;}.ui-icon-arrowreturnthick-1-s{background-position:-48px -64px;}.ui-icon-arrowreturn-1-w{background-position:-64px -64px;}.ui-icon-arrowreturn-1-n{background-position:-80px -64px;}.ui-icon-arrowreturn-1-e{background-position:-96px -64px;}.ui-icon-arrowreturn-1-s{background-position:-112px -64px;}.ui-icon-arrowrefresh-1-w{background-position:-128px -64px;}.ui-icon-arrowrefresh-1-n{background-position:-144px -64px;}.ui-icon-arrowrefresh-1-e{background-position:-160px -64px;}.ui-icon-arrowrefresh-1-s{background-position:-176px -64px;}.ui-icon-arrow-4{background-position:0 -80px;}.ui-icon-arrow-4-diag{background-position:-16px -80px;}.ui-icon-extlink{background-position:-32px -80px;}.ui-icon-newwin{background-position:-48px -80px;}.ui-icon-refresh{background-position:-64px -80px;}.ui-icon-shuffle{background-position:-80px -80px;}.ui-icon-transfer-e-w{background-position:-96px -80px;}.ui-icon-transferthick-e-w{background-position:-112px -80px;}.ui-icon-folder-collapsed{background-position:0 -96px;}.ui-icon-folder-open{background-position:-16px -96px;}.ui-icon-document{background-position:-32px -96px;}.ui-icon-document-b{background-position:-48px -96px;}.ui-icon-note{background-position:-64px -96px;}.ui-icon-mail-closed{background-position:-80px -96px;}.ui-icon-mail-open{background-position:-96px -96px;}.ui-icon-suitcase{background-position:-112px -96px;}.ui-icon-comment{background-position:-128px -96px;}.ui-icon-person{background-position:-144px -96px;}.ui-icon-print{background-position:-160px -96px;}.ui-icon-trash{background-position:-176px -96px;}.ui-icon-locked{background-position:-192px -96px;}.ui-icon-unlocked{background-position:-208px -96px;}.ui-icon-bookmark{background-position:-224px -96px;}.ui-icon-tag{background-position:-240px -96px;}.ui-icon-home{background-position:0 -112px;}.ui-icon-flag{background-position:-16px -112px;}.ui-icon-calendar{background-position:-32px -112px;}.ui-icon-cart{background-position:-48px -112px;}.ui-icon-pencil{background-position:-64px -112px;}.ui-icon-clock{background-position:-80px -112px;}.ui-icon-disk{background-position:-96px -112px;}.ui-icon-calculator{background-position:-112px -112px;}.ui-icon-zoomin{background-position:-128px -112px;}.ui-icon-zoomout{background-position:-144px -112px;}.ui-icon-search{background-position:-160px -112px;}.ui-icon-wrench{background-position:-176px -112px;}.ui-icon-gear{background-position:-192px -112px;}.ui-icon-heart{background-position:-208px -112px;}.ui-icon-star{background-position:-224px -112px;}.ui-icon-link{background-position:-240px -112px;}.ui-icon-cancel{background-position:0 -128px;}.ui-icon-plus{background-position:-16px -128px;}.ui-icon-plusthick{background-position:-32px -128px;}.ui-icon-minus{background-position:-48px -128px;}.ui-icon-minusthick{background-position:-64px -128px;}.ui-icon-close{background-position:-80px -128px;}.ui-icon-closethick{background-position:-96px -128px;}.ui-icon-key{background-position:-112px -128px;}.ui-icon-lightbulb{background-position:-128px -128px;}.ui-icon-scissors{background-position:-144px -128px;}.ui-icon-clipboard{background-position:-160px -128px;}.ui-icon-copy{background-position:-176px -128px;}.ui-icon-contact{background-position:-192px -128px;}.ui-icon-image{background-position:-208px -128px;}.ui-icon-video{background-position:-224px -128px;}.ui-icon-script{background-position:-240px -128px;}.ui-icon-alert{background-position:0 -144px;}.ui-icon-info{background-position:-16px -144px;}.ui-icon-notice{background-position:-32px -144px;}.ui-icon-help{background-position:-48px -144px;}.ui-icon-check{background-position:-64px -144px;}.ui-icon-bullet{background-position:-80px -144px;}.ui-icon-radio-off{background-position:-96px -144px;}.ui-icon-radio-on{background-position:-112px -144px;}.ui-icon-pin-w{background-position:-128px -144px;}.ui-icon-pin-s{background-position:-144px -144px;}.ui-icon-play{background-position:0 -160px;}.ui-icon-pause{background-position:-16px -160px;}.ui-icon-seek-next{background-position:-32px -160px;}.ui-icon-seek-prev{background-position:-48px -160px;}.ui-icon-seek-end{background-position:-64px -160px;}.ui-icon-seek-start{background-position:-80px -160px;}.ui-icon-seek-first{background-position:-80px -160px;}.ui-icon-stop{background-position:-96px -160px;}.ui-icon-eject{background-position:-112px -160px;}.ui-icon-volume-off{background-position:-128px -160px;}.ui-icon-volume-on{background-position:-144px -160px;}.ui-icon-power{background-position:0 -176px;}.ui-icon-signal-diag{background-position:-16px -176px;}.ui-icon-signal{background-position:-32px -176px;}.ui-icon-battery-0{background-position:-48px -176px;}.ui-icon-battery-1{background-position:-64px -176px;}.ui-icon-battery-2{background-position:-80px -176px;}.ui-icon-battery-3{background-position:-96px -176px;}.ui-icon-circle-plus{background-position:0 -192px;}.ui-icon-circle-minus{background-position:-16px -192px;}.ui-icon-circle-close{background-position:-32px -192px;}.ui-icon-circle-triangle-e{background-position:-48px -192px;}.ui-icon-circle-triangle-s{background-position:-64px -192px;}.ui-icon-circle-triangle-w{background-position:-80px -192px;}.ui-icon-circle-triangle-n{background-position:-96px -192px;}.ui-icon-circle-arrow-e{background-position:-112px -192px;}.ui-icon-circle-arrow-s{background-position:-128px -192px;}.ui-icon-circle-arrow-w{background-position:-144px -192px;}.ui-icon-circle-arrow-n{background-position:-160px -192px;}.ui-icon-circle-zoomin{background-position:-176px -192px;}.ui-icon-circle-zoomout{background-position:-192px -192px;}.ui-icon-circle-check{background-position:-208px -192px;}.ui-icon-circlesmall-plus{background-position:0 -208px;}.ui-icon-circlesmall-minus{background-position:-16px -208px;}.ui-icon-circlesmall-close{background-position:-32px -208px;}.ui-icon-squaresmall-plus{background-position:-48px -208px;}.ui-icon-squaresmall-minus{background-position:-64px -208px;}.ui-icon-squaresmall-close{background-position:-80px -208px;}.ui-icon-grip-dotted-vertical{background-position:0 -224px;}.ui-icon-grip-dotted-horizontal{background-position:-16px -224px;}.ui-icon-grip-solid-vertical{background-position:-32px -224px;}.ui-icon-grip-solid-horizontal{background-position:-48px -224px;}.ui-icon-gripsmall-diagonal-se{background-position:-64px -224px;}.ui-icon-grip-diagonal-se{background-position:-80px -224px;}.ui-corner-tl{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;}.ui-corner-tr{-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;}.ui-corner-bl{-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;}.ui-corner-br{-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-top{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;}.ui-corner-bottom{-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-right{-moz-border-radius-topright:4px;-webkit-border-top-right-radius:4px;border-top-right-radius:4px;-moz-border-radius-bottomright:4px;-webkit-border-bottom-right-radius:4px;border-bottom-right-radius:4px;}.ui-corner-left{-moz-border-radius-topleft:4px;-webkit-border-top-left-radius:4px;border-top-left-radius:4px;-moz-border-radius-bottomleft:4px;-webkit-border-bottom-left-radius:4px;border-bottom-left-radius:4px;}.ui-corner-all{-moz-border-radius:4px;-webkit-border-radius:4px;border-radius:4px;}.ui-widget-overlay{background:#aaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x;opacity:.30;filter:Alpha(Opacity=30);}.ui-widget-shadow{margin:-8px 0 0 -8px;padding:8px;background:#aaa url(images/ui-bg_flat_0_aaaaaa_40x100.png) 50% 50% repeat-x;opacity:.30;filter:Alpha(Opacity=30);-moz-border-radius:8px;-webkit-border-radius:8px;border-radius:8px;}.ui-widget{font-family:arial,"sans-serif"!important;font-size:100%;}.ui-helper-reset{font-size:100%!important;}iframe.ui-ncbi-iframe-fix{position:absolute;top:0;left:0;height:200px;z-index:3000;display:block;filter:alpha(opacity=1);}#ui-datepicker-div{display:none;}.ui-widget-content a{color:#2F4A8B;}.ui-helper-hidden-accessible{left:-10000000px!important;}#jig-ncbi_requires_login iframe{border:none;} \ No newline at end of file diff -r 2143f62809d0 -r 344cd76f6fd2 NCBI Blast reference example_files/jig.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/NCBI Blast reference example_files/jig.js Thu May 15 16:59:18 2014 +0200 @@ -0,0 +1,265 @@ +(function(){function Ka(){var g=null,j=jQuery.cookie("WebCubbyUser");if(j)if(j.indexOf("logged-in=true")>-1)if(j=j.match(/my-name=([^;]+)/i))g=j[1];return g}function W(g){this.name=this.selector="";this.onPage=false;this.dependsOn=[];this.interactions=[];this.overrideDefaults={};this.addCss=function(){document.write('')};this.addJs=function(){document.write('