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.

Bug 34930 - Rename form with 1 inner class causes problem
Summary: Rename form with 1 inner class causes problem
Alias: None
Product: guibuilder
Classification: Unclassified
Component: Code (show other bugs)
Version: 3.x
Hardware: PC Windows ME/2000
: P3 blocker (vote)
Assignee: issues@guibuilder
Depends on: 27180
  Show dependency tree
Reported: 2003-07-14 16:43 UTC by _ viendu
Modified: 2005-07-11 13:17 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Note You need to log in before you can comment on or make changes to this bug.
Description _ viendu 2003-07-14 16:43:50 UTC
When rename a form, all generated codes would
automatically be updated (renamed).  You only need
to rename stuffs that you write.  That is the case
when you have your settings set to generate
anonymous class for events.  But if you choose 1
inner class to handle all of the events, it will
not rename the class in generated event  code.  So
you cannot change them either (it's uneditable
code).  The trick is to change the preference
back, and rename, and change preference back again.
Comment 1 Tomas Pavek 2003-07-22 16:37:40 UTC
Theoretically, name of the form class can be generated in more places,
not only in the inner event dispatcher class. Ideally, the form should
be regenerated when renamed. But this is hardly possible if the form
is closed. In such case, the form should be regenerated on opening -
but how to know it was renamed before, so it needs regeneration? We
should not force regeneration everytime the form opens just because
this possibility. So maybe ignore this case (don't care about renaming
closed forms)?
Comment 2 Tomas Pavek 2003-07-23 11:23:45 UTC
Fixed in trunk. Only the case the form is opened.

Different fix is needed for proj40_prototype (depends on issue 27180).
Comment 3 Marek Grummich 2005-07-11 13:17:59 UTC