1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-04-29 19:45:01 +02:00

Bug Fixing

This commit is contained in:
Hoda Amer 2004-07-15 18:11:23 +00:00
parent 634e93d450
commit 143ff15904
2 changed files with 9 additions and 2 deletions

View file

@ -1,3 +1,6 @@
2004-07-15 Hoda Amer
Fix for PR 68500: [Outline View] After doing a rename of a class, the outline viewer does not display the new name (just the old name)
2004-07-09 Hoda Amer 2004-07-09 Hoda Amer
Fix for PR 69510 : [C++ Class Wizard] error message in C++ Class Wizard if invoke Class Wizard from existing C++ class in C/C++ Project View Fix for PR 69510 : [C++ Class Wizard] error message in C++ Class Wizard if invoke Class Wizard from existing C++ class in C/C++ Project View

View file

@ -619,19 +619,23 @@ public class RenameElementProcessor extends RenameProcessor implements IReferenc
parent = parent.getParent(); parent = parent.getParent();
level++; level++;
} }
// now we are at the first folder or project container
// get siblings at level = level // get siblings at level = level
Set parentsSet = new HashSet(); Set parentsSet = new HashSet();
Set childrenSet = new HashSet(); Set childrenSet = new HashSet();
ICElement[] pr =((IParent)parent).getChildren(); ICElement[] pr =((IParent)parent).getChildren();
// add all translation unit children but not subfolders
for (int i =0; i < pr.length; i++){ for (int i =0; i < pr.length; i++){
parentsSet.add(pr[i]); if(!(pr[i] instanceof ICContainer))
parentsSet.add(pr[i]);
} }
// compare to elements in added translation units.
int currentLevel = 1; int currentLevel = 1;
while (currentLevel < level) { while (currentLevel < level) {
Iterator itr = parentsSet.iterator(); Iterator itr = parentsSet.iterator();
while (itr.hasNext()){ while (itr.hasNext()){
Object o = itr.next(); Object o = itr.next();
if((o instanceof ISourceManipulation) || (o instanceof ICContainer)){ if(o instanceof ISourceManipulation) {
ICElement p = (ICElement)o; ICElement p = (ICElement)o;
if(p instanceof IParent){ if(p instanceof IParent){
ICElement[] ch = ((IParent)p).getChildren(); ICElement[] ch = ((IParent)p).getChildren();