-
Enhancement
-
Resolution: Won't Fix
-
P4
-
fx2.0
-
None
The method setTranslateX is declared final. This means I cannot override the method to take special action when the position of my node changes. I have several places where a node needs to update itself when the user or my program moves it arround. For instance i have a node which has an anchor point which is centered on the screen. When the node is moved, I need to relocate the anchor point to ensure it is still centered on screen. One obvious way of doing this is by overriding setTranslateX as follows
void setTranslateX(double x) {
super(setTranslateX);
//then do what is necessary
//...
}
If there is no special reason why setTranslateX is final, I suggest declaring it non-final.
void setTranslateX(double x) {
super(setTranslateX);
//then do what is necessary
//...
}
If there is no special reason why setTranslateX is final, I suggest declaring it non-final.