mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-28 19:35:36 +02:00
Fix for PR 66186.
Remove the log() print not necessary and users thinks something went wrong. * src/org/eclipse/cdt/internal/ui/BaseCElementContentProvider.java
This commit is contained in:
parent
c013ff1910
commit
5e8a965b20
2 changed files with 37 additions and 30 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
2004-06-08 Alain Magloire
|
||||||
|
|
||||||
|
Fix for PR 66186.
|
||||||
|
Remove the log() print not necessary
|
||||||
|
and users thinks something went wrong.
|
||||||
|
* src/org/eclipse/cdt/internal/ui/BaseCElementContentProvider.java
|
||||||
|
|
||||||
2004-06-07 Tanya Wolff
|
2004-06-07 Tanya Wolff
|
||||||
Fix for Bug 66053 - externalized string in cview
|
Fix for Bug 66053 - externalized string in cview
|
||||||
|
|
||||||
|
|
|
@ -125,42 +125,42 @@ public class BaseCElementContentProvider implements ITreeContentProvider {
|
||||||
return NO_CHILDREN;
|
return NO_CHILDREN;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if (element instanceof ICModel) {
|
if (element instanceof ICModel) {
|
||||||
return getCProjects((ICModel)element);
|
return getCProjects((ICModel)element);
|
||||||
} else if (element instanceof ICProject ) {
|
} else if (element instanceof ICProject ) {
|
||||||
return getSourceRoots((ICProject)element);
|
return getSourceRoots((ICProject)element);
|
||||||
} else if (element instanceof ICContainer) {
|
} else if (element instanceof ICContainer) {
|
||||||
return getCResources((ICContainer)element);
|
return getCResources((ICContainer)element);
|
||||||
} else if (element instanceof IBinaryContainer) {
|
} else if (element instanceof IBinaryContainer) {
|
||||||
return NO_CHILDREN; // we deal with this in the CVIewContentProvider
|
return NO_CHILDREN; // we deal with this in the CVIewContentProvider
|
||||||
} else if (element instanceof IArchiveContainer) {
|
} else if (element instanceof IArchiveContainer) {
|
||||||
return NO_CHILDREN; // we deal with this in the CViewContentProvider
|
return NO_CHILDREN; // we deal with this in the CViewContentProvider
|
||||||
} else if (element instanceof ITranslationUnit) {
|
} else if (element instanceof ITranslationUnit) {
|
||||||
// if we want to get the chidren of a translation unit
|
// if we want to get the chidren of a translation unit
|
||||||
if (fProvideMembers) {
|
if (fProvideMembers) {
|
||||||
// if we want to use the working copy of it
|
// if we want to use the working copy of it
|
||||||
if(fProvideWorkingCopy){
|
if(fProvideWorkingCopy){
|
||||||
// if it is not already a working copy
|
// if it is not already a working copy
|
||||||
if(!(element instanceof IWorkingCopy)){
|
if(!(element instanceof IWorkingCopy)){
|
||||||
// if it has a valid working copy
|
// if it has a valid working copy
|
||||||
ITranslationUnit tu = (ITranslationUnit)element;
|
ITranslationUnit tu = (ITranslationUnit)element;
|
||||||
IWorkingCopy copy = tu.findSharedWorkingCopy(CUIPlugin.getDefault().getBufferFactory());
|
IWorkingCopy copy = tu.findSharedWorkingCopy(CUIPlugin.getDefault().getBufferFactory());
|
||||||
if(copy != null) {
|
if(copy != null) {
|
||||||
return ((IParent)copy).getChildren();
|
return ((IParent)copy).getChildren();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
return ((IParent)element).getChildren();
|
||||||
}
|
}
|
||||||
|
} else if (element instanceof IParent) {
|
||||||
return ((IParent)element).getChildren();
|
return ((IParent)element).getChildren();
|
||||||
|
} else if (element instanceof IProject) {
|
||||||
|
return getResources((IProject)element);
|
||||||
|
} else if (element instanceof IFolder) {
|
||||||
|
return getResources((IFolder)element);
|
||||||
}
|
}
|
||||||
} else if (element instanceof IParent) {
|
|
||||||
return ((IParent)element).getChildren();
|
|
||||||
} else if (element instanceof IProject) {
|
|
||||||
return getResources((IProject)element);
|
|
||||||
} else if (element instanceof IFolder) {
|
|
||||||
return getResources((IFolder)element);
|
|
||||||
}
|
|
||||||
} catch (CModelException e) {
|
} catch (CModelException e) {
|
||||||
CUIPlugin.getDefault().log(e);
|
//CUIPlugin.getDefault().log(e);
|
||||||
return NO_CHILDREN;
|
return NO_CHILDREN;
|
||||||
}
|
}
|
||||||
return NO_CHILDREN;
|
return NO_CHILDREN;
|
||||||
|
|
Loading…
Add table
Reference in a new issue