Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 353091

Summary: [M2x IDE Integration] org.eclipse.sphinx.xtendxpand.ui.groups.TemplateGroup#loadTemplate(IFile) method return null if template file is under a folder not a PackageJavaElement
Product: [Automotive] Sphinx Reporter: Idrissa Dieng <idydieng>
Component: CoreAssignee: Idrissa Dieng <idydieng>
Status: CLOSED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: stephaneberle9
Version: 0.7.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Idrissa Dieng CLA 2011-07-26 06:07:17 EDT
The org.eclipse.sphinx.xtendxpand.ui.groups.TemplateGroup#loadTemplate(IFile) method return null if template file is under a folder not a PackageJavaElement.

The root cause is:

 - The org.eclipse.sphinx.xtendxpand.ui.groups.TemplateGroup#loadTemplate(IFile) method use org.eclipse.xtend.shared.ui.core.IXtendXpandProject#findXtendXpandResource(IStorage) and the last one call org.eclipse.xtend.shared.ui.core.internal.JDTUtil#findXtendXpandResourceID(IJavaProject, IStorage).

- The org.eclipse.xtend.shared.ui.core.internal.JDTUtil#findXtendXpandResourceID(IJavaProject, IStorage) return null as ResourceID because folders are JavaElement
Comment 1 Idrissa Dieng CLA 2011-07-26 16:55:50 EDT

*** This bug has been marked as a duplicate of bug 341921 ***
Comment 2 Idrissa Dieng CLA 2011-07-26 16:56:36 EDT
proposed patch in #Bug 341921 resolve this problem.