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.
Summary: | Renaming variable with "refactor" doesn't alter code within a GUI form | ||
---|---|---|---|
Product: | guibuilder | Reporter: | aquaglow |
Component: | Code | Assignee: | issues@guibuilder <issues> |
Status: | NEW --- | ||
Severity: | normal | CC: | MackSix |
Priority: | P3 | ||
Version: | 6.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
aquaglow
2011-01-14 14:19:43 UTC
This works ok for me in: Product Version: NetBeans IDE Dev (Build 201111030600) Java: 1.7.0_01; Java HotSpot(TM) Client VM 21.1-b02 System: Windows Vista version 6.0 running on x86; Cp1252; en_US (nb) This issue is still valid.
> This works ok for me ...
It works when the renamed variable is in the form. It doesn't work when it is in another Java class.
The root of the problem seems to be in RefactoringPluginFactoryImpl.createInstance(). It ignores all renames of class elements outside form files - it performs explicit RefactoringInfo.isJavaFileOfForm(primaryFile) check.
This issue gets fixed when this check is commented out, but such a change also means much higher involvement of GUI Builder's refactoring plugin in rename refactorings. So, it is a risky change because it is not clear whether other parts of form.refactoring module can handle renames in non-form files correctly.
Hence, I am postponing this change to post-NB 7.1 builds.
|