Plugins/VcsPlugins/vcsPySvn/subversion.py

changeset 53
c3eb7cc1ff8b
parent 15
f6ccc31d6e72
child 55
b5c84934de9c
equal deleted inserted replaced
52:ba69827929ee 53:c3eb7cc1ff8b
14 import time 14 import time
15 15
16 from PyQt4.QtCore import * 16 from PyQt4.QtCore import *
17 from PyQt4.QtGui import * 17 from PyQt4.QtGui import *
18 18
19 from E4Gui.E4Application import e4App 19 from E4Gui.E4Application import e5App
20 20
21 from VCS.VersionControl import VersionControl 21 from VCS.VersionControl import VersionControl
22 22
23 import pysvn 23 import pysvn
24 24
875 names = name[:] 875 names = name[:]
876 else: 876 else:
877 names = [name] 877 names = [name]
878 for nam in names: 878 for nam in names:
879 if os.path.isfile(nam): 879 if os.path.isfile(nam):
880 editor = e4App().getObject("ViewManager").getOpenEditor(nam) 880 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
881 if editor and not editor.checkDirty() : 881 if editor and not editor.checkDirty() :
882 return 882 return
883 else: 883 else:
884 project = e4App().getObject("Project") 884 project = e5App().getObject("Project")
885 if nam == project.ppath and not project.saveAllScripts(): 885 if nam == project.ppath and not project.saveAllScripts():
886 return 886 return
887 self.diff = SvnDiffDialog(self) 887 self.diff = SvnDiffDialog(self)
888 self.diff.show() 888 self.diff.show()
889 QApplication.processEvents() 889 QApplication.processEvents()
1661 names = name[:] 1661 names = name[:]
1662 else: 1662 else:
1663 names = [name] 1663 names = [name]
1664 for nam in names: 1664 for nam in names:
1665 if os.path.isfile(nam): 1665 if os.path.isfile(nam):
1666 editor = e4App().getObject("ViewManager").getOpenEditor(nam) 1666 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
1667 if editor and not editor.checkDirty() : 1667 if editor and not editor.checkDirty() :
1668 return 1668 return
1669 else: 1669 else:
1670 project = e4App().getObject("Project") 1670 project = e5App().getObject("Project")
1671 if nam == project.ppath and not project.saveAllScripts(): 1671 if nam == project.ppath and not project.saveAllScripts():
1672 return 1672 return
1673 dlg = SvnRevisionSelectionDialog() 1673 dlg = SvnRevisionSelectionDialog()
1674 if dlg.exec_() == QDialog.Accepted: 1674 if dlg.exec_() == QDialog.Accepted:
1675 revisions = dlg.getRevisions() 1675 revisions = dlg.getRevisions()
1695 names = name[:] 1695 names = name[:]
1696 else: 1696 else:
1697 names = [name] 1697 names = [name]
1698 for nam in names: 1698 for nam in names:
1699 if os.path.isfile(nam): 1699 if os.path.isfile(nam):
1700 editor = e4App().getObject("ViewManager").getOpenEditor(nam) 1700 editor = e5App().getObject("ViewManager").getOpenEditor(nam)
1701 if editor and not editor.checkDirty() : 1701 if editor and not editor.checkDirty() :
1702 return 1702 return
1703 else: 1703 else:
1704 project = e4App().getObject("Project") 1704 project = e5App().getObject("Project")
1705 if nam == project.ppath and not project.saveAllScripts(): 1705 if nam == project.ppath and not project.saveAllScripts():
1706 return 1706 return
1707 1707
1708 dname = self.splitPath(names[0])[0] 1708 dname = self.splitPath(names[0])[0]
1709 1709

eric ide

mercurial