In the heapremovePRO exercise (see for example http://algoviz.org/OpenDSA/dev/OpenDSA/AV/Binary/heapremovePRO.html), consider as the first step to (mistakenly) decrement the heap. For this exercise, "undo" is the default mechanism for dealing with user mistakes. Since the user action was to decrement the heap, the tree is displayed with one node and one edge removed. "Undo" then tries to reset the tree to its original state. What I see on the screen is first a flicker where the node and edge are redrawn correctly, then the popup message appears. Next, when I dismiss the popup, the tree is REDRAWN INCORRECTLY with the edge missing.
This is all happening automatically under JSAV control by the "undo" mode. So I don't think that there is anything incorrect about the exercise code, nor any way for the exercise to catch and work around the display error.
In the heapremovePRO exercise (see for example http://algoviz.org/OpenDSA/dev/OpenDSA/AV/Binary/heapremovePRO.html), consider as the first step to (mistakenly) decrement the heap. For this exercise, "undo" is the default mechanism for dealing with user mistakes. Since the user action was to decrement the heap, the tree is displayed with one node and one edge removed. "Undo" then tries to reset the tree to its original state. What I see on the screen is first a flicker where the node and edge are redrawn correctly, then the popup message appears. Next, when I dismiss the popup, the tree is REDRAWN INCORRECTLY with the edge missing.
This is all happening automatically under JSAV control by the "undo" mode. So I don't think that there is anything incorrect about the exercise code, nor any way for the exercise to catch and work around the display error.