Skip to content

Commit

Permalink
turn off requestAnimationframe before viewing a new object
Browse files Browse the repository at this point in the history
  • Loading branch information
bernhard-42 committed Sep 4, 2024
1 parent 7ecc3f0 commit 7b1ac97
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions resources/webview.html
Original file line number Diff line number Diff line change
Expand Up @@ -356,6 +356,12 @@
console.log("displayOptions", displayOptions);
}

// Turn of animation loop of last viewer
if (viewer != null) {
viewer.hasAnimationLoop = false;
viewer.continueAnimation = false;
}

const container = document.getElementById("cad_viewer");
container.innerHTML = ""
viewer = new Viewer(container, displayOptions, nc, null);
Expand Down

0 comments on commit 7b1ac97

Please sign in to comment.