File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JavaFX and the fly likes JavaFX Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JavaFX
Bookmark "JavaFX "wonders"" Watch "JavaFX "wonders"" New topic
Author

JavaFX "wonders"

Jiri Goddard
Greenhorn

Joined: Aug 21, 2007
Posts: 21
Hello guys,

I'm trying to write a component that will fall apart after you click on it (I think the use case is clear ). Of course, it doesn't work properly. Who can help me?

FallIntoPieces.fx


Shatter.fx


First, repair the code so it compiles - uncomment the Group definition and make the onMouseClicked on Group - remove the "node."
Now the issues:
- although there's a code in both classes that is the same - the node.onMouseClicked handler, it compiles in first class, but not in the other one
- if i have my two components on stage and i click on them in the order i added them, it goes quite fine. if i do it vice versa, there's an artefact - i made the slices sequence visible for testing purposes.
- if you actually try to run the program, you spot another bug - after you click on component, the shatter effect appears at another place than are the mouse coordianates.

I played around with certain things for a long time. Now I think I don't see possible mistakes, that's why I came here.

Thanks

Oh, yes - don't mind the vector() function


http://dredwerkz.ic.cz
Jiri Goddard
Greenhorn

Joined: Aug 21, 2007
Posts: 21
answered here:
http://forums.sun.com/thread.jspa?threadID=5427483
 
Don't get me started about those stupid light bulbs.
 
subject: JavaFX "wonders"
 
Similar Threads
JSlider issue
Help with a chess program
Delay program until end TranslateTransition JavaFX
Grid Layout : Gap appears mysteriously in between cells.
JavaFx 1.3, image does not load well in imageView