From: Cezary Czaplewski Date: Wed, 11 Apr 2018 18:00:09 +0000 (+0200) Subject: trajectory NGLview corrections X-Git-Url: http://mmka.chem.univ.gda.pl/gitweb/?a=commitdiff_plain;h=1af6414b7ff3204ff78cf1a0debaa14c0e79f154;p=django_unres.git trajectory NGLview corrections --- diff --git a/django_simple/todo/templates/details.html b/django_simple/todo/templates/details.html index d32f9fe..ba9425c 100644 --- a/django_simple/todo/templates/details.html +++ b/django_simple/todo/templates/details.html @@ -466,7 +466,7 @@ Created {{ task.created_date }}
  • -0 frame +1 frame
    @@ -1213,6 +1213,7 @@ window.addEventListener("resize", o.addRepresentation( "licorice",{ color: "residueindex",colorScale:["blue","cyan", "green", "yellow","orange", "red"] }); + o.setPosition([0, 0, 100]); o.autoView(); o.addTrajectory(); }); @@ -1238,7 +1239,7 @@ window.addEventListener("resize", isRunning = true; trajComp.signals.frameChanged.add(function(){ - var fnum=trajComp.trajectory.currentFrame; + var fnum=trajComp.trajectory.currentFrame+1; clipRange.value = fnum; clipRange_val.innerHTML = numberWithCommas(parseInt(clipRange.value*1)); }); @@ -1253,7 +1254,7 @@ window.addEventListener("resize", var clipRange_val = document.getElementById( "clipRange_val" ); clipRange.oninput = function( e ){ var trajComp = stage.getComponentsByName("unres_md").list[0].trajList[0]; - trajComp.setFrame(e.target.value) + trajComp.setFrame(e.target.value-1) clipRange_val.innerHTML = numberWithCommas(parseInt(e.target.value*1)); }; diff --git a/django_simple/todo/templates/details1.html b/django_simple/todo/templates/details1.html index 9bb24f7..4abd64d 100644 --- a/django_simple/todo/templates/details1.html +++ b/django_simple/todo/templates/details1.html @@ -455,7 +455,7 @@ Created {{ task.created_date }}
  • -0 frame +1 frame
    @@ -1208,6 +1208,7 @@ window.addEventListener("resize", o.addRepresentation( "licorice",{ color: "residueindex",colorScale:["blue","cyan", "green", "yellow","orange", "red"] }); + o.setPosition([0, 0, 100]); o.autoView(); o.addTrajectory(); }); @@ -1233,7 +1234,7 @@ window.addEventListener("resize", isRunning = true; trajComp.signals.frameChanged.add(function(){ - var fnum=trajComp.trajectory.currentFrame; + var fnum=trajComp.trajectory.currentFrame+1; clipRange.value = fnum; clipRange_val.innerHTML = numberWithCommas(parseInt(clipRange.value*1)); }); @@ -1248,7 +1249,7 @@ window.addEventListener("resize", var clipRange_val = document.getElementById( "clipRange_val" ); clipRange.oninput = function( e ){ var trajComp = stage.getComponentsByName("unres_md").list[0].trajList[0]; - trajComp.setFrame(e.target.value) + trajComp.setFrame(e.target.value-1) clipRange_val.innerHTML = numberWithCommas(parseInt(e.target.value*1)); };