Bug 2480 - Excluded resources are still available in preview and debugger
authorEugene Ostroukhov <eugeneo@symbian.org>
Tue, 01 Jun 2010 11:21:52 -0700
changeset 343 945945f2458d
parent 342 f62d2a36bc43
child 344 0f103d99721b
Bug 2480 - Excluded resources are still available in preview and debugger
org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/handlers/WorkspaceResourceProvider.java
--- a/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/handlers/WorkspaceResourceProvider.java	Tue Jun 01 11:09:05 2010 -0700
+++ b/org.symbian.tools.wrttools.previewer/src/org/symbian/tools/wrttools/previewer/http/handlers/WorkspaceResourceProvider.java	Tue Jun 01 11:21:52 2010 -0700
@@ -27,6 +27,7 @@
 import org.eclipse.core.runtime.CoreException;
 import org.eclipse.core.runtime.IPath;
 import org.json.simple.JSONObject;
+import org.symbian.tools.wrttools.util.ProjectUtils;
 
 public class WorkspaceResourceProvider implements IResourceProvider {
     public String[] getPaths() {
@@ -36,7 +37,7 @@
     public InputStream getResourceStream(IProject project, IPath resource, Map<String, String[]> parameters)
             throws IOException, CoreException {
         IFile file = project.getFile(resource);
-        if (file.isAccessible()) {
+        if (file.isAccessible() && !ProjectUtils.isExcluded(file)) {
             return file.getContents();
         } else {
             return null;