Extending a Group Node


If I extend the Group node using this syntax :

    function MyGroup() {
    go.Diagram.inherit(MyGroup, go.Group);

Then the drag functionality seems to go wrong. If I attempt to drag a group, the contained nodes move but not the containing group. All other functionality seems to be okay (select, resize etc).

Is this by design?

I’m sorry. At the current time you cannot subclass any GraphObject, including Group.

It is unfortunate that there is such limited support for “classes” in JavaScript.
That is why we have added a bunch of properties whose values are functions (not “methods”).
Those functional properties greatly help reduce the need for subclassing.

What methods of Group did you want to override?

Thanks Walter,

I think I you had already told me that. My memory is going - it must be my age.