Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic links without HeadShape show up as PointerArrow after save. (Read 2885 times)
Blue
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 9
Joined: Jun 11th, 2014
links without HeadShape show up as PointerArrow after save.
Jun 23rd, 2014 at 1:13pm
Print Post  
I'm using Diagramming for ASP.NET, V5.0.5

When i'm using link.setHeadShape(null) clientside it works as expected and removes the head shape from the link.

When the map is saved serverside and reloaded, the same link shows up as having a PointerArrow. The clientside model seems to get this shape automatically if the headshape is null serverside.

When I view the map after it's saved using imagemap mode instead the arrow head is not visible.

Any fix for this?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: links without HeadShape show up as PointerArrow after save.
Reply #1 - Jun 24th, 2014 at 9:15am
Print Post  
Call this from body.onload handler as work-around:

Code
Select All
function onLoad()
{
	var linkFromJson = MindFusion.Diagramming.DiagramLink.prototype.fromJson;
	MindFusion.Diagramming.DiagramLink.prototype.fromJson = function(json) {
		linkFromJson.apply(this, [json]);
		if (!json.headShape)
			this.setHeadShape(null);
	}
} 



I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Blue
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 9
Joined: Jun 11th, 2014
Re: links without HeadShape show up as PointerArrow after save.
Reply #2 - Jun 24th, 2014 at 4:17pm
Print Post  
Hi, thanks again! Yes the following works.

Code (Javascript)
Select All
// Fixes empty link Head Shapes showing up as having arrows
Sys.Application.add_load(function () {
    var linkFromJson = window.MindFusion.Diagramming.DiagramLink.prototype.fromJson;

    window.MindFusion.Diagramming.DiagramLink.prototype.fromJson = function (json) {
        linkFromJson.apply(this, [json]);
        if (!json.headShape)
            this.setHeadShape(null);
    }
});
 



I got some other small issues that probably should be fixed. Should I send you a PM or post them in the forums?
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: links without HeadShape show up as PointerArrow after save.
Reply #3 - Jun 25th, 2014 at 7:07am
Print Post  
Quote:
Should I send you a PM or post them in the forums?


As you wish.
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint