Community
Participate
Working Groups
1. Create a class Test.java 2. Compile the class (if autobuild is off) 3. From the Navigator open Test.class ==> class file editor shows corresponding source 4. Change Test.java and save it ==> the class file viewer shows old Java source There are two cases here 1) auto-build is on ==> class file viewer should show new source 2) auto-build is off ==> class file viewer should be cleared and contain something like: "Corresponding source has changed but not compiled - the source for the class file can not be displayed" Once the Java file is compiled the source should be shown again NOTES: EG (12.09.2001 15:49:59) not convinced that we should show the source at all in this case. Mapping a source file for a class file makes sense in the binary JAR scenario but not in the generated class file scenario. Proposal, don't show the source for class files in the output folder.
moved to 'active'
No you get an dialog if you reactivate the class file editor telling you that the file has changed on disk. If you reload it you see the new source. Best would be if the class file editor would do this without asking since there is no way that a user could change the content using the editor. But the current implementation is consistent.
Still exists but is very unlikely in a normal usage scenario.
Dirk, when I test it I have three cases (tested against R2.0) 1) using source folders (auto-build on or off) [ok]: ==> dialog says it can't be shown since it is not on the build path 2) using project as source folder and auto-build off: ==> nothing happens if I change the .java file however if I close the .class file and reopen it the new content of the .java file is shown. Isn't this wrong: the .class file is still the old one since it hasn't been built 3) using project as source folder and auto-build on: ==> I get an error when I say Yes to the reload dialog (see attached .log) Giving the fact that there are errors written to the log I reopened the bug.
Created attachment 1791 [details] .log
Fix available in builds > N20030228