Moving an input pin inside a Comment region creates ghost link

Hey hey hello,

This is on 7.2-19

Let’s say you have a process node with an input pin exposed. Moving the whole thing (the node + its pin) inside a Comment region will create a ghost link that throws some exception in the console when selected :

Exception here for reference:

NullReferenceException: "Object reference not set to an instance of an object."
    StackTrace:
        VL.Lang.View.CanvasView+InsertNodeIntoLinkHandler { public virtual VL.Core.Viewer.IMouseEventHandler MouseUp(VL.Core.Viewer.VMouseEventArgs arg) { ... } } 
        VL.Lang.View.CanvasView+CanvasDecisionMouseHandler { private VL.Core.Viewer.IMouseEventHandler DoubleClickMethod(VL.Core.Viewer.VMouseEventArgs firstClick, VL.Core.Viewer.VMouseEventArgs click) { ... } } 
        VL.Lang.View.CanvasView+CanvasDecisionMouseHandler+<>c__DisplayClass35_0 { internal VL.Core.Viewer.IMouseEventHandler <SelectDownMouseHandler>b__2(VL.Core.Viewer.VMouseEventArgs click) { ... } } 
        VL.Core.Viewer.Handler+<>c__DisplayClass18_0 { internal VL.Core.Viewer.IMouseEventHandler <OnDoubleClick>b__0(VL.Core.Viewer.VMouseEventArgs down) { ... } } 
        VL.Core.Viewer.Handler+ParallelMouseHandler { public virtual VL.Core.Viewer.IMouseEventHandler MouseDown(VL.Core.Viewer.VMouseEventArgs arg) { ... } } 
        VL.Lang.View.CanvasView+CanvasDecisionMouseHandler { public virtual VL.Core.Viewer.IMouseEventHandler MouseDown(VL.Core.Viewer.VMouseEventArgs arg) { ... } } 
        VL.Lang.View.CanvasView { private void HandleMouseDown(object sender, VL.Core.Viewer.VMouseEventArgs e) { ... } } 
        VL.GraphicalEditor.Skia.GraphEditor { protected virtual void OnMouseDown(System.Windows.Forms.MouseEventArgs e) { ... } } 
        System.Windows.Forms.Control { private void WmMouseDown(System.Windows.Forms.Message& m, System.Windows.Forms.MouseButtons button, int clicks) { ... } } 
        System.Windows.Forms.Control { protected virtual void WndProc(System.Windows.Forms.Message& m) { ... } } 
        VL.GraphicalEditor.Skia.GraphEditor { protected virtual void WndProc(System.Windows.Forms.Message& m) { ... } } 

After that, the region is “broken” and it’s not possible to move it or move the node inside of it. It can still be deleted though.

Of course this only happens by “mistake”, but I would expect the UI to catch that more gracefully :-)

Thanks!

seb

1 Like

Related :Allow pins in Comment regions

Right, after all allowing pins in Comment regions makes sense.