Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Link Event is not working (linkClicked) (Read 3222 times)
Freizeitsoldat
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: May 10th, 2009
Link Event is not working (linkClicked)
Oct 16th, 2009 at 11:25am
Print Post  
Hello Stoyan,

i just bought JDiagram with Sourcecode. I want to use a JavaScript if a Link is clicked. I used <param name="LinkClicked" value="linkClicked"> for the applet.

But the linkClicked function is not called. Even an alert("xxx") does not apear. Is there something i have to activate, to use Link events?

(My other Topic about Java 1.5 - 1.6 compability is solved - we donīt use Java 1.5 anymore...)

Thank you,
Alex
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Link Event is not working (linkClicked)
Reply #1 - Oct 16th, 2009 at 12:51pm
Print Post  
Does your linkClicked function take two parameters? The first parameter should be the sender object , and the second one - the event object.
  
Back to top
 
IP Logged
 
Freizeitsoldat
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 19
Joined: May 10th, 2009
Re: Link Event is not working (linkClicked)
Reply #2 - Oct 17th, 2009 at 10:45am
Print Post  
Sure, i have the linkClicked(sender, event) function in JavaScript. The function has the same parameters like nodeClicked or nodeDoubleClicked.

nodeClicked and nodeDoubleClicked are working fine! linkCreation(sender, event) is also working. But i need a function for clicking onto the links.

There is no error in the error console and no error in the java console. The JavaScript function is not called (i checked it with alert("hahaha")Wink.

Alex
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Link Event is not working (linkClicked)
Reply #3 - Oct 18th, 2009 at 1:54pm
Print Post  
Is it only the event not being raised, or you can't select the links too? If there are some nodes behind the links, try setting the HitTestPriority property to ZOrder: diagram.setHitTestPriority(HitTestPriority.ZOrder);

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


I love YaBB 1G - SP1!

Posts: 19
Joined: May 10th, 2009
Re: Link Event is not working (linkClicked)
Reply #4 - Oct 19th, 2009 at 9:00am
Print Post  
Thank you, it works with HitTestPriority!
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint