icn3d 3.25.10 → 3.25.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/icn3d.js CHANGED
@@ -32289,7 +32289,7 @@ class Alternate {
32289
32289
  ic.impostorCls.clearImpostors();
32290
32290
 
32291
32291
  // show membranes
32292
- if(ic.bOpm) {
32292
+ if(ic.bOpm && !me.cfg.chainalign) {
32293
32293
  //if(window.dialog && window.dialog.hasClass('ui-dialog-content')) window.dialog.dialog( "close" );
32294
32294
 
32295
32295
  let html = me.utilsCls.getMemDesc();
@@ -41362,6 +41362,10 @@ class ShowAnno {
41362
41362
  }
41363
41363
  }
41364
41364
  getColorhexFromBlosum62(resA, resB) { let ic = this.icn3d, me = ic.icn3dui;
41365
+ let color = '333333';
41366
+
41367
+ if(!resA || !resB) return color;
41368
+
41365
41369
  resA = resA.toUpperCase();
41366
41370
  resB = resB.toUpperCase();
41367
41371
 
@@ -41371,7 +41375,7 @@ class ShowAnno {
41371
41375
  if(matrixValue === undefined) return '333333';
41372
41376
  // range and color: blue for -4 ~ 0, red for 0 ~ 11
41373
41377
  // max value 221 to avoid white
41374
- let color = '333333';
41378
+
41375
41379
  if(matrixValue > 0) {
41376
41380
  let c = 221 - parseInt(matrixValue / 11.0 * 221);
41377
41381
  let cStr =(c < 10) ? '0' + c.toString(16) : c.toString(16);
@@ -42029,7 +42033,9 @@ class ShowSeq {
42029
42033
  for(let il = strandArray.length, i = il - 1; i >= 0; --i) {
42030
42034
  if(strandArray[i].endRefnum - strandArray[i].startRefnum + 1 < 3) { // remove the strand
42031
42035
  if(i != il - 1) { // modify
42032
- strandArray[i + 1].loopResCnt += strandArray[i].loopResCnt + strandArray[i].endRefnum - strandArray[i].startRefnum + 1;
42036
+ // strandArray[i + 1].loopResCnt += strandArray[i].loopResCnt + strandArray[i].endRefnum - strandArray[i].startRefnum + 1;
42037
+
42038
+ strandArray[i + 1].loopResCnt += strandArray[i].loopResCnt + parseInt(strandArray[i].endResi) - parseInt(strandArray[i].startResi) + 1;
42033
42039
  }
42034
42040
 
42035
42041
  strandArray.splice(i, 1);
@@ -51858,7 +51864,7 @@ class ParserUtils {
51858
51864
  if(rmsd) {
51859
51865
  me.htmlCls.clickMenuCls.setLogCmd("realignment RMSD: " + rmsd.toPrecision(4), false);
51860
51866
  let html = "<br><b>Realignment RMSD</b>: " + rmsd.toPrecision(4) + " &#8491;<br><br>";
51861
- if(ic.bAfMem) {
51867
+ if(ic.bAfMem && !me.cfg.chainalign) {
51862
51868
  //if(window.dialog && window.dialog.hasClass('ui-dialog-content')) window.dialog.dialog( "close" );
51863
51869
  html += me.utilsCls.getMemDesc();
51864
51870
  }
@@ -62547,18 +62553,35 @@ class Scap {
62547
62553
  }
62548
62554
  }
62549
62555
 
62550
- adjust2DWidth(id) { let ic = this.icn3d, me = ic.icn3dui;
62551
- let halfWidth = 125;
62556
+ adjust2DWidth(id) { let ic = this.icn3d; ic.icn3dui;
62552
62557
  id = ic.pre + id;
62553
-
62558
+ /*
62554
62559
  let height =($("#" + ic.pre + 'dl_selectannotations').hasClass("ui-dialog-content")) ? $("#" + ic.pre + 'dl_selectannotations').dialog( "option", "height") : me.htmlCls.HEIGHT;
62555
62560
  let width =($("#" + ic.pre + 'dl_selectannotations').hasClass("ui-dialog-content")) ? halfWidth * 2 : me.htmlCls.WIDTH * 0.5;
62556
62561
 
62557
62562
  $("#" + id).dialog( "option", "width", width );
62558
62563
  $("#" + id).dialog( "option", "height", height);
62559
- let position = { my: "left-" + halfWidth + " top+" + me.htmlCls.MENU_HEIGHT, at: "right top", of: "#" + ic.pre + "viewer", collision: "none" };
62564
+ let position = { my: "left-" + halfWidth + " top+" + me.htmlCls.MENU_HEIGHT, at: "right top", of: "#" + ic.pre + "viewer", collision: "none" }
62560
62565
 
62561
- $("#" + id).dialog( "option", "position", position );
62566
+ $("#" + id).dialog( "option", "position", position );
62567
+ */
62568
+
62569
+ let width, height, top;
62570
+
62571
+ if($("#" + ic.pre + 'dl_selectannotations').hasClass("ui-dialog-content")) {
62572
+ width = $("#" + ic.pre + 'dl_selectannotations').dialog( "option", "width");
62573
+ height = $("#" + ic.pre + 'dl_selectannotations').dialog( "option", "height") * 0.5;
62574
+ top = height;
62575
+
62576
+ $("#" + ic.pre + "dl_selectannotations").dialog( "option", "height", height);
62577
+
62578
+ $("#" + id).dialog( "option", "width", width );
62579
+ $("#" + id).dialog( "option", "height", height);
62580
+
62581
+ let position = { my: "left top", at: "right top+" + top, of: "#" + ic.pre + "viewer", collision: "none" };
62582
+
62583
+ $("#" + id).dialog( "option", "position", position );
62584
+ }
62562
62585
  }
62563
62586
 
62564
62587
  async retrieveScap(snp, bInteraction, bPdb) { let ic = this.icn3d, me = ic.icn3dui;