How to change the cursor back to default

Hi,

I created a Picture object and set its property ‘cursor’ to ‘pointer’, then I added a function to handle user’s clicking on the picture. What it did is to destroy the diagram where the picture was located and inserted some nodes to the DOM in the current page. I could see the cursor become a pointer when the mouse was over the picture and the function did what I was expected when I clicked the picture. However I found out the cursor seemed not reset back to the “default” shape. Can someone tell me
what GoJS does to the DOM when I set the cursor to ‘pointer’ and how can I reset the cursor back?

Thanks.

When a mouse-over finds a GraphObject whose GraphObject.cursor property is not an empty string, it sets the Diagram.currentCursor to that value. If there is no GraphObject, or if no GraphObject has a cursor value, it sets Diagram.currentCursor to the empty string, which causes the Diagram.defaultCursor to be used.

So I think you just need to set myDiagram.currentCursor = "";

It does the trick. Thanks for the quick response.