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 53680 - undo refactoring for renaming packages/files doesn't work
Summary: undo refactoring for renaming packages/files doesn't work
Status: CLOSED FIXED
Alias: None
Product: editor
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 4.x
Hardware: Other Other
: P2 blocker (vote)
Assignee: Martin Matula
URL:
Keywords:
: 52911 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-01-19 13:28 UTC by Pavel Rehak
Modified: 2007-04-03 18:02 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
thrown exception (3.10 KB, text/plain)
2005-01-19 13:28 UTC, Pavel Rehak
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Pavel Rehak 2005-01-19 13:28:37 UTC
Product Version       = NetBeans IDE Dev (Build 
200501181900)
 Operating System      = Windows XP version 5.1 
running on x86
 Java; VM; Vendor      = 1.5.0_02-ea; Java 
HotSpot(TM) Client VM 1.5.0_02-ea-b02; Sun 
Microsystems Inc.
 Java Home             = c:\Program 
Files\Java\jdk1.5.0_02\jre
---------------------------------------------
In source packages i have packages
abc.def.ghi.jkl with appropriate classes
(see http://beetle.czech/modules/refactoring/
promotion_d/testspecs/data/classes.zip)
and when i try rename /src/abc in files view to 
/src/aaa command goes smoothly through but 
refactoring->undo throws exception and package 
remains /src/aaa.
Comment 1 Pavel Rehak 2005-01-19 13:28:59 UTC
Created attachment 19781 [details]
thrown exception
Comment 2 Pavel Rehak 2005-01-19 13:41:25 UTC
Now i noticed it doesn't work neither for files :-(
(i'm trying to do it in Files view)
try rename a.java -> x.java, do refactoring,
and refactoring -> undo
all changes in x.java will be undone 
but file remains x.java (instead of a.java)
Comment 3 Jan Becicka 2005-01-19 14:02:08 UTC
Well, two issues described here:
1. Undo does not rename file back - this is known issue, which is
described in UI spec.
http://projects.netbeans.org/nonav/buildsys/j2se-project-ui-spec.html#Packages_and_Folders.
This is duplicate of issue 48676.
2. InvalidObjectException - this bug is valid and needs to be fixed.
Comment 4 Martin Matula 2005-01-20 14:27:24 UTC
Fixed.

Checking in src/org/netbeans/modules/javacore/scanning/JavaUpdater.java;
/cvs/java/javacore/src/org/netbeans/modules/javacore/scanning/JavaUpdater.java,v
 <--  JavaUpdater.java
new revision: 1.19; previous revision: 1.18
done
Comment 5 Martin Matula 2005-01-20 15:46:50 UTC
*** Issue 52911 has been marked as a duplicate of this issue. ***
Comment 6 Pavel Rehak 2005-04-04 14:50:37 UTC
Verified with build 200504031800.