Fixed "textEditor==null" bug
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpeclipse / resourcesview / PHPProject.java
index 859733a..e903be5 100644 (file)
@@ -8,18 +8,16 @@ import java.util.List;
 
 import javax.xml.parsers.SAXParserFactory;
 
+import net.sourceforge.phpeclipse.LoadPathEntry;
+import net.sourceforge.phpeclipse.PHPeclipsePlugin;
+
 import org.eclipse.core.resources.IFile;
 import org.eclipse.core.resources.IProject;
 import org.eclipse.core.resources.IProjectNature;
 import org.eclipse.core.resources.IResource;
 import org.eclipse.core.runtime.CoreException;
 import org.eclipse.core.runtime.IPath;
-import org.eclipse.core.runtime.IStatus;
 import org.eclipse.core.runtime.Path;
-import org.eclipse.core.runtime.Status;
-import net.sourceforge.phpeclipse.LoadPathEntry;
-import net.sourceforge.phpeclipse.PHPeclipsePlugin;
-
 import org.xml.sax.Attributes;
 import org.xml.sax.ContentHandler;
 import org.xml.sax.InputSource;
@@ -28,7 +26,7 @@ import org.xml.sax.SAXException;
 import org.xml.sax.XMLReader;
 
 public class PHPProject implements IProjectNature, PHPElement {
-       protected IProject project;
+       protected IProject fProject;
        protected List loadPathEntries;
        protected boolean scratched;
 
@@ -39,7 +37,7 @@ public class PHPProject implements IProjectNature, PHPElement {
        public void deconfigure() throws CoreException {}
 
        public IProject getProject() {
-               return project;
+               return fProject;
        }
 
        protected IProject getProject(String name) {
@@ -47,7 +45,7 @@ public class PHPProject implements IProjectNature, PHPElement {
        }
 
        public void setProject(IProject aProject) {
-               project = aProject;
+               fProject = aProject;
        }
 
        public void addLoadPathEntry(IProject anotherPHPProject) {
@@ -139,7 +137,7 @@ public class PHPProject implements IProjectNature, PHPElement {
        }
 
        protected IFile getLoadPathEntriesFile() {
-               return project.getFile(".loadpath");
+               return fProject.getFile(".loadpath");
        }
 
        public void save() throws CoreException {
@@ -169,8 +167,9 @@ public class PHPProject implements IProjectNature, PHPElement {
                buffer.append("</loadpath>");
                return buffer.toString();
        }
+       
        public IResource getUnderlyingResource() {
-               return project;
+               return fProject;
        }
 
 }