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: | Java Bean: setDoubleBuffered() Methods Not Copied When Form is Copied | ||
---|---|---|---|
Product: | guibuilder | Reporter: | MackSix |
Component: | Code | Assignee: | issues@guibuilder <issues> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P4 | ||
Version: | 7.1 | ||
Hardware: | PC | ||
OS: | Windows Vista | ||
Issue Type: | DEFECT | Exception Reporter: | |
Attachments: | Project that exhibits the error. |
Description
MackSix
2011-10-25 05:53:48 UTC
Product Version: NetBeans IDE Dev (Build 201110240600) 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) In fact, it is not necessary to copy the form. It is sufficient to close it, reopen it and do some unrelated change that forces regeneration of the source code. The resulting code (with only one setDoubleBuffered() method) is correct because the default value of doubleBuffered property of all the mentioned components (except JLocaleChooser) is true. Hence, only JLocaleChooser requires this statement to be generated. On the other hand, the initial state is incorrect. When the other (i.e., not JLocalChooser) components are added then Properties window incorrectly shows that the default value of their doubleBuffered property is false. This is caused by the lazy initialization of default values of the properties and by the fact that we set doubleBuffered property to false during painting of the component being added. We have to restore the original value of this property when the component is added. Fixed. Modified file: http://hg.netbeans.org/jet-main/rev/4de8f78971b5 |