mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-01 14:15:23 +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
|
||||
Fix for Bug 66053 - externalized string in cview
|
||||
|
||||
|
|
|
@ -125,42 +125,42 @@ public class BaseCElementContentProvider implements ITreeContentProvider {
|
|||
return NO_CHILDREN;
|
||||
|
||||
try {
|
||||
if (element instanceof ICModel) {
|
||||
return getCProjects((ICModel)element);
|
||||
} else if (element instanceof ICProject ) {
|
||||
return getSourceRoots((ICProject)element);
|
||||
} else if (element instanceof ICContainer) {
|
||||
return getCResources((ICContainer)element);
|
||||
} else if (element instanceof IBinaryContainer) {
|
||||
return NO_CHILDREN; // we deal with this in the CVIewContentProvider
|
||||
} else if (element instanceof IArchiveContainer) {
|
||||
return NO_CHILDREN; // we deal with this in the CViewContentProvider
|
||||
} else if (element instanceof ITranslationUnit) {
|
||||
// if we want to get the chidren of a translation unit
|
||||
if (fProvideMembers) {
|
||||
// if we want to use the working copy of it
|
||||
if(fProvideWorkingCopy){
|
||||
// if it is not already a working copy
|
||||
if(!(element instanceof IWorkingCopy)){
|
||||
// if it has a valid working copy
|
||||
ITranslationUnit tu = (ITranslationUnit)element;
|
||||
IWorkingCopy copy = tu.findSharedWorkingCopy(CUIPlugin.getDefault().getBufferFactory());
|
||||
if(copy != null) {
|
||||
return ((IParent)copy).getChildren();
|
||||
if (element instanceof ICModel) {
|
||||
return getCProjects((ICModel)element);
|
||||
} else if (element instanceof ICProject ) {
|
||||
return getSourceRoots((ICProject)element);
|
||||
} else if (element instanceof ICContainer) {
|
||||
return getCResources((ICContainer)element);
|
||||
} else if (element instanceof IBinaryContainer) {
|
||||
return NO_CHILDREN; // we deal with this in the CVIewContentProvider
|
||||
} else if (element instanceof IArchiveContainer) {
|
||||
return NO_CHILDREN; // we deal with this in the CViewContentProvider
|
||||
} else if (element instanceof ITranslationUnit) {
|
||||
// if we want to get the chidren of a translation unit
|
||||
if (fProvideMembers) {
|
||||
// if we want to use the working copy of it
|
||||
if(fProvideWorkingCopy){
|
||||
// if it is not already a working copy
|
||||
if(!(element instanceof IWorkingCopy)){
|
||||
// if it has a valid working copy
|
||||
ITranslationUnit tu = (ITranslationUnit)element;
|
||||
IWorkingCopy copy = tu.findSharedWorkingCopy(CUIPlugin.getDefault().getBufferFactory());
|
||||
if(copy != null) {
|
||||
return ((IParent)copy).getChildren();
|
||||
}
|
||||
}
|
||||
}
|
||||
return ((IParent)element).getChildren();
|
||||
}
|
||||
} 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);
|
||||
}
|
||||
} 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) {
|
||||
CUIPlugin.getDefault().log(e);
|
||||
//CUIPlugin.getDefault().log(e);
|
||||
return NO_CHILDREN;
|
||||
}
|
||||
return NO_CHILDREN;
|
||||
|
|
Loading…
Add table
Reference in a new issue