[Pydev-cvs] org.python.pydev/src/org/python/pydev/plugin/nature PythonNature.java,1.13,1.14
Brought to you by:
fabioz
From: Fabio Z. <fa...@us...> - 2005-09-13 01:35:40
|
Update of /cvsroot/pydev/org.python.pydev/src/org/python/pydev/plugin/nature In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12763/src/org/python/pydev/plugin/nature Modified Files: PythonNature.java Log Message: Index: PythonNature.java =================================================================== RCS file: /cvsroot/pydev/org.python.pydev/src/org/python/pydev/plugin/nature/PythonNature.java,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** PythonNature.java 13 Aug 2005 18:10:18 -0000 1.13 --- PythonNature.java 13 Sep 2005 01:35:33 -0000 1.14 *************** *** 14,17 **** --- 14,18 ---- import java.io.InputStream; import java.io.ObjectInputStream; + import java.util.List; import org.eclipse.core.resources.ICommand; *************** *** 36,40 **** --- 37,43 ---- import org.python.pydev.editor.codecompletion.revisited.ASTManager; import org.python.pydev.editor.codecompletion.revisited.ICodeCompletionASTManager; + import org.python.pydev.extension.ExtensionHelper; import org.python.pydev.plugin.PydevPlugin; + import org.python.pydev.ui.interpreters.IInterpreterObserver; import org.python.pydev.utils.JobProgressComunicator; *************** *** 209,212 **** --- 212,216 ---- */ private void init() { + final PythonNature nature = this; if (initialized == false) { initialized = true; *************** *** 230,233 **** --- 234,242 ---- }else{ astManager.setProject(getProject()); // this is the project related to it + + List<IInterpreterObserver> participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); + for (IInterpreterObserver observer : participants) { + observer.notifyNatureRecreated(nature, monitor); + } } return Status.OK_STATUS; *************** *** 270,273 **** --- 279,283 ---- */ public void rebuildPath(final String paths) { + final PythonNature nature = this; Job myJob = new Job("Pydev code completion: rebuilding modules") { *************** *** 278,281 **** --- 288,297 ---- astManager.setProject(getProject()); astManager.changePythonPath(paths, project, new JobProgressComunicator(monitor, "Rebuilding modules", 500, this)); + + List<IInterpreterObserver> participants = ExtensionHelper.getParticipants(ExtensionHelper.PYDEV_INTERPRETER_OBSERVER); + for (IInterpreterObserver observer : participants) { + observer.notifyProjectPythonpathRestored(nature, monitor); + } + saveAstManager(false); |