How to reorder automatically generated methods in Netbeans?

二次信任 提交于 2019-12-10 04:13:34

问题


When using Netbeans' features for generating event handlers from a GUI, for example, while the body of the generated methods are editable, I cannot find a way to change the order of the generated methods within the code of a class.

Cutting for cutting and pasting is not allowed with generated code.

How instead might I do this?

Thank you very much!


回答1:


You can't do that in Netbeans. It's not really a priority because you can use the Navigator instead.

If you really want to move those blocks, open the Java file with an other editor (Gedit, Notepad...) and re-order the blocks here.

You can also remove the //GEN-FIRST and //GEN-LAST to make them editable in Netbeans.



来源:https://stackoverflow.com/questions/11009940/how-to-reorder-automatically-generated-methods-in-netbeans

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!