Project/Project.py

changeset 2318
3a3ee7cc2ad6
parent 2302
f29e9405c851
child 2319
116c547dedce
equal deleted inserted replaced
2317:ac7ffbf5b36b 2318:3a3ee7cc2ad6
2249 (vcsSystemOverride is not None and \ 2249 (vcsSystemOverride is not None and \
2250 len(self.pudata["VCSOVERRIDE"]) == 0): 2250 len(self.pudata["VCSOVERRIDE"]) == 0):
2251 # stop the VCS monitor thread and shutdown VCS 2251 # stop the VCS monitor thread and shutdown VCS
2252 if self.vcs is not None: 2252 if self.vcs is not None:
2253 self.vcs.stopStatusMonitor() 2253 self.vcs.stopStatusMonitor()
2254 self.vcs.vcsStatusMonitorData.disconnect(self.__model.changeVCSStates) 2254 ## self.vcs.vcsStatusMonitorData.disconnect(self.__model.changeVCSStates)
2255 self.vcs.vcsStatusMonitorStatus.disconnect(self.__statusMonitorStatus) 2255 ## self.vcs.vcsStatusMonitorStatus.disconnect(self.__statusMonitorStatus)
2256 self.vcs.vcsShutdown() 2256 self.vcs.vcsShutdown()
2257 self.vcs.deleteLater()
2257 self.vcs = None 2258 self.vcs = None
2258 e5App().getObject("PluginManager").deactivateVcsPlugins() 2259 e5App().getObject("PluginManager").deactivateVcsPlugins()
2259 # reinit VCS 2260 # reinit VCS
2260 self.vcs = self.initVCS() 2261 self.vcs = self.initVCS()
2261 # start the VCS monitor thread 2262 # start the VCS monitor thread
2612 return False 2613 return False
2613 2614
2614 # stop the VCS monitor thread 2615 # stop the VCS monitor thread
2615 if self.vcs is not None: 2616 if self.vcs is not None:
2616 self.vcs.stopStatusMonitor() 2617 self.vcs.stopStatusMonitor()
2617 try: 2618 ## try:
2618 self.vcs.vcsStatusMonitorData.disconnect( 2619 ## self.vcs.vcsStatusMonitorData.disconnect(
2619 self.__model.changeVCSStates) 2620 ## self.__model.changeVCSStates)
2620 except TypeError: 2621 ## except TypeError:
2621 pass 2622 ## pass
2622 try: 2623 ## try:
2623 self.vcs.vcsStatusMonitorStatus.disconnect( 2624 ## self.vcs.vcsStatusMonitorStatus.disconnect(
2624 self.__statusMonitorStatus) 2625 ## self.__statusMonitorStatus)
2625 except TypeError: 2626 ## except TypeError:
2626 pass 2627 ## pass
2627 2628
2628 # now save the tasks 2629 # now save the tasks
2629 if not noSave: 2630 if not noSave:
2630 self.writeTasks() 2631 self.writeTasks()
2631 self.ui.taskViewer.clearProjectTasks() 2632 self.ui.taskViewer.clearProjectTasks()
2632 self.ui.taskViewer.setProjectOpen(False) 2633 self.ui.taskViewer.setProjectOpen(False)
2633 2634
2634 # now shutdown the vcs interface 2635 # now shutdown the vcs interface
2635 if self.vcs: 2636 if self.vcs:
2636 self.vcs.vcsShutdown() 2637 self.vcs.vcsShutdown()
2638 self.vcs.deleteLater()
2637 self.vcs = None 2639 self.vcs = None
2638 e5App().getObject("PluginManager").deactivateVcsPlugins() 2640 e5App().getObject("PluginManager").deactivateVcsPlugins()
2639 2641
2640 # now close all project related windows 2642 # now close all project related windows
2641 self.__closeAllWindows() 2643 self.__closeAllWindows()

eric ide

mercurial