Quantcast
Channel: GoJS - Northwoods Software
Viewing all articles
Browse latest Browse all 7069

`setFromKeyForLinkData` sets the `from` property to `undefined`

$
0
0

@Jany wrote:

With GoJS 1.7.5 in Chromium.

Sometimes, when calling setFromKeyForLinkData, a single call will set from to undefined instead of the string I provide, and if I call the same method with the same parameters a second time, it does what I ask for. Why is that? Am I missing something? How to make sure that the first call sets the property correctly every time?

Here is my debug code:

        var newFrom = ...;
        console.log('Before 1st call', link.from, newFrom);
        diagram.model.setFromKeyForLinkData(link, newFrom);
        console.log('After 1st call', link.from, newFrom);
        diagram.model.setFromKeyForLinkData(link, newFrom);
        console.log('After 2nd call', link.from, newFrom);

Here is what I observe in chromium's console:

Thanks in advance,

Jany Belluz

Posts: 5

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 7069

Trending Articles