This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Product Version: NetBeans IDE Dev (Build 201402190001) Java: 1.8.0; Java HotSpot(TM) 64-Bit Server VM 25.0-b69 Runtime: Java(TM) SE Runtime Environment 1.8.0-b129 System: Windows 7 version 6.1 running on amd64; Cp1252; en_CA (nb) Make Controller action on an fxml file that includes another fxml file will remove the @FXML annotation from the existing field in the controller for both the Node and the controller class. E.g. Given and FXML file containing: <fx:include fx:id="myPanel" source="some_other.fxml" /> and a controller for that fxml file containing: @FXML private Parent myPanel; @FXML private AnotherController myPanelController; After invoking "Make Controller" the controller code looks like: private Parent myPanel; private AnotherController myPanelController;
See also Bug 241839 which is a DIFFERENT, yet related, anomaly.
Yes, fx:include is not supported in the @FXML binding analysis, AFAIK.
Fixed in jet-main#32249f0a276f
Hi Svata, Regarding Comment #2, if that is the case, what is the Fix to be tested in Comment #3? Best regards,
I included the fx:include in fx:id simple indexing pass. It will be noted, so potentially @FXML bound variable will not be discarded (as the .fxml reference to the field is now recognized). However the scanner does not traverse the includes (for performance reasons and simplicity), so generator is not able to generate such a @FXML variable for you. Possible future enhancements include: * determine the type of the fx:included object, generate bound field * process the closure of fx:includes, generate complete model (feel free to file such enhancements, if you find them useful).
What version has this been fixed on? It is still happening for me in 8.0.2
Sorry for the inconvenience. 8.0.2 was released on 28 November 2014. So the patch didn't make the cut in time for 8.0.2, but has been fixed in Development (see Svata's comment above) and should be in NetBeans IDE 8.1. If this is problematic for you, you *might* consider trying a development release from http://bits.netbeans.org/download/trunk/nightly/latest/