src/eric7/Plugins/VcsPlugins/vcsMercurial/hg.py

branch
eric7
changeset 9413
80c06d472826
parent 9318
a47b5c46be3f
child 9421
989ee2535d59
equal deleted inserted replaced
9412:45e7bb09c120 9413:80c06d472826
13 import pathlib 13 import pathlib
14 14
15 from PyQt6.QtCore import pyqtSignal, QFileSystemWatcher, QCoreApplication 15 from PyQt6.QtCore import pyqtSignal, QFileSystemWatcher, QCoreApplication
16 from PyQt6.QtWidgets import QApplication, QDialog, QInputDialog 16 from PyQt6.QtWidgets import QApplication, QDialog, QInputDialog
17 17
18 from EricWidgets.EricApplication import ericApp 18 from eric7.EricWidgets.EricApplication import ericApp
19 from EricWidgets import EricMessageBox, EricFileDialog 19 from eric7.EricWidgets import EricMessageBox, EricFileDialog
20 20
21 from QScintilla.MiniEditor import MiniEditor 21 from eric7.QScintilla.MiniEditor import MiniEditor
22 22
23 from VCS.VersionControl import VersionControl 23 from eric7.VCS.VersionControl import VersionControl
24 from VCS.RepositoryInfoDialog import VcsRepositoryInfoDialog 24 from eric7.VCS.RepositoryInfoDialog import VcsRepositoryInfoDialog
25 25
26 from .HgDialog import HgDialog 26 from .HgDialog import HgDialog
27 from .HgClient import HgClient 27 from .HgClient import HgClient
28 28
29 import Preferences 29 from eric7 import Preferences, Utilities
30 import Utilities
31 30
32 31
33 class Hg(VersionControl): 32 class Hg(VersionControl):
34 """ 33 """
35 Class implementing the version control systems interface to Mercurial. 34 Class implementing the version control systems interface to Mercurial.
909 names = [name] 908 names = [name]
910 909
911 project = ericApp().getObject("Project") 910 project = ericApp().getObject("Project")
912 names = [project.getRelativePath(nam) for nam in names] 911 names = [project.getRelativePath(nam) for nam in names]
913 if names[0]: 912 if names[0]:
914 from UI.DeleteFilesConfirmationDialog import DeleteFilesConfirmationDialog 913 from eric7.UI.DeleteFilesConfirmationDialog import (
914 DeleteFilesConfirmationDialog,
915 )
915 916
916 dlg = DeleteFilesConfirmationDialog( 917 dlg = DeleteFilesConfirmationDialog(
917 self.parent(), 918 self.parent(),
918 self.tr("Revert changes"), 919 self.tr("Revert changes"),
919 self.tr( 920 self.tr(
1002 names = [name] 1003 names = [name]
1003 1004
1004 project = ericApp().getObject("Project") 1005 project = ericApp().getObject("Project")
1005 names = [project.getRelativePath(nam) for nam in names] 1006 names = [project.getRelativePath(nam) for nam in names]
1006 if names[0]: 1007 if names[0]:
1007 from UI.DeleteFilesConfirmationDialog import DeleteFilesConfirmationDialog 1008 from eric7.UI.DeleteFilesConfirmationDialog import (
1009 DeleteFilesConfirmationDialog,
1010 )
1008 1011
1009 dlg = DeleteFilesConfirmationDialog( 1012 dlg = DeleteFilesConfirmationDialog(
1010 self.parent(), 1013 self.parent(),
1011 self.tr("Re-Merge"), 1014 self.tr("Re-Merge"),
1012 self.tr( 1015 self.tr(
1613 ), 1616 ),
1614 ) 1617 )
1615 return 1618 return
1616 1619
1617 if self.sbsDiff is None: 1620 if self.sbsDiff is None:
1618 from UI.CompareDialog import CompareDialog 1621 from eric7.UI.CompareDialog import CompareDialog
1619 1622
1620 self.sbsDiff = CompareDialog() 1623 self.sbsDiff = CompareDialog()
1621 self.sbsDiff.show() 1624 self.sbsDiff.show()
1622 self.sbsDiff.raise_() 1625 self.sbsDiff.raise_()
1623 self.sbsDiff.compare(output1, output2, name1, name2) 1626 self.sbsDiff.compare(output1, output2, name1, name2)

eric ide

mercurial