I recently noticed another weird behaviour in Designer using the Eclipse-function to rename a Java class.
When using this function, you will instantly notice another problem with the menu entries increasing every time you open it - but this is another story.
tl;dr
Here is a litte demo video
How to reproduce
To reproduce this, do the following:
Create a new blank database, create 2 classes “FirstClass” and “SecondClass”. Use “FirstClass” in “SecondClass”. Rename the “FistClass” by using right mouse click on the class and then “Refactor, Rename” (always use the last entry/entries in this menu, the others won’t do anything). Now rename the class to whatever you want, .e.g. “BetterFirstClass”. It also “works” just moving it to another package, but for simplicity we only rename it now.
Then, in “SecondClass”, make a change and save it. The editor and the whole IDE will tell you about the error that “BetterFirstClass” cannot be resolved. Hm...
Executing a “Project, Clean” solves this problem for now (because there is none) until you change and save the class(es) that use the renamed one again.
I created an ODP to check the metadata files because they are responsible in most cases. Not this time, everything looks ok.
Solution / Workaround
There is only one solution I am aware of: instead of renaming/moving the existing class, copy the content from the existing to the clipboard or elsewhere so you don’t lose it. Do the refactoring as usual and ignore the problem for now. This is only for the classes that use this class to be adapted. Then, delete the renamed class. Close the application as this name seems to be cached (see the video). Re-open the application and re-create the “new” class as usual. Copy over the content you preserved into the new class and save everything. As a result you should be able to alter everything else without this problem.
Did you experience this, too? I have seen this with different versions of 12.0.x. If you know the reason and/or how to solve this in a better way, please let us know.