Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Flashing Rectangles While Dragging Node (Read 2794 times)
alukes
Junior Member
**
Offline


I love YaBB 1G - SP1!

Posts: 61
Joined: Jul 1st, 2011
Flashing Rectangles While Dragging Node
Sep 18th, 2016 at 11:13pm
Print Post  
The Mindfusion overview example works fine with no unwanted flashing rectangles, but my project produces flashing rectangles while dragging. When I stop dragging the unwanted rectangles are no longer visible .What should I look for? What other information do you need?

this is how the diagram is configured. The Browser is Safari.

function diagramSetUp() {
     diagram.setRouteLinks(true);
     diagram.setRoundedLinks(true);
     diagram.setLinkCrossings(MindFusion.Diagramming.LinkCrossings.Arc);
     diagram.setAlignToGrid(true);
     diagram.setDynamicLinks(false);
     diagram.setLinkHeadShapeSize(2);
     diagram.setBehavior(Behavior.DrawLinks);
     Diagram.LinkTextStyle = MindFusion.Diagramming.LinkTextStyle.OverLongestSegment;
     // add the listeners
     diagram.addEventListener(Events.nodeDeleting, onNodeDeleting);
     diagram.addEventListener(Events.nodeDeleted, onNodeDeleted);
     diagram.addEventListener(Events.nodeCreated, onNodeCreated);
     diagram.addEventListener(Events.linkCreating, onLinkCreating);
     diagram.addEventListener(Events.linkCreated, onLinkCreated);
     diagram.addEventListener(Events.linkDeleted, onLinkDeleted);
     diagram.addEventListener(Events.nodeClicked, onNodeClicked);
     diagram.addEventListener(Events.nodeDoubleClicked, onNodeDoubleClicked);
}

$(document).ready(
           function()
           // function createDiagram()
           {
// create a Diagram component that wraps the "diagram" canvas
                 diagram = Diagram.create($("#diagram")[0]);
                 createAnchorPoints();
                 diagramSetUp();

                 // create a NodeListView component that wraps the "nodeList" canvas
                 var nodeList = MindFusion.Diagramming.NodeListView
                             .create($("#nodeList")[0]);
                 nodeList.setTargetView($("diagram")[0]);
                 initNodeList(nodeList, diagram);

                 // create an Overview component that wraps the "overview" canvas
                 var overview = MindFusion.Diagramming.Overview
                             .create($("#overview")[0]);
                 overview.setDiagram(diagram);

                 // create an ZoomControl component that wraps the "zoomer" canvas
                 var zoomer = MindFusion.Controls.ZoomControl
                             .create($("#zoomer")[0]);
                 zoomer.setTarget(diagram);
});


Thanks

« Last Edit: Sep 19th, 2016 at 4:38am by alukes »  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Flashing Rectangles While Dragging Node
Reply #1 - Sep 19th, 2016 at 6:58am
Print Post  
I can see the Overview control flashing while the diagram auto-resizes if you drag a node towards its edge. Is that what you mean, or you are getting flashing rectangles inside the diagram canvas?
  
Back to top
 
IP Logged
 
alukes
Junior Member
**
Offline


I love YaBB 1G - SP1!

Posts: 61
Joined: Jul 1st, 2011
Re: Flashing Rectangles While Dragging Node
Reply #2 - Sep 19th, 2016 at 1:12pm
Print Post  
getting flashing rectangles inside the diagram canvas even when the dragged node is not near an edge.
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Flashing Rectangles While Dragging Node
Reply #3 - Sep 19th, 2016 at 2:18pm
Print Post  
I could not reproduce by adding only diagramSetUp() to our overview demo, trying it both on various Windows browsers and on OSX Safari. Please check if my version shows rectangles on your system -
http://mindfusion.eu/demos/jsdiagram/OverviewTest.html

If it doesn't, that might be related to code in your event handlers or createAnchorPoints method - please post them too. If it does show the glitch, please let me know what OSX and Safari versions you are using.

Regards,
Slavcho
Mindfusion
  
Back to top
 
IP Logged
 
alukes
Junior Member
**
Offline


I love YaBB 1G - SP1!

Posts: 61
Joined: Jul 1st, 2011
Re: Flashing Rectangles While Dragging Node
Reply #4 - Sep 20th, 2016 at 3:09am
Print Post  
I commented out all addEventHandlers, and it worked correctly. Added them back in and it still works as it should.

I don't know what caused the problem. I will continue to watch it. 

Maybe keep this post open for a few days, then delete it if I can't replicate the problem? I will delete if if I can.

Thanks
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint