eric6/Plugins/VcsPlugins/vcsMercurial/QueuesExtension/HgQueuesHeaderDialog.py

changeset 7971
ff2971513d6d
parent 7923
91e843545d9a
child 8143
2c730d5fd177
equal deleted inserted replaced
7970:c4ee8a81584c 7971:ff2971513d6d
4 # 4 #
5 5
6 """ 6 """
7 Module implementing a dialog to show the commit message of the current patch. 7 Module implementing a dialog to show the commit message of the current patch.
8 """ 8 """
9
10 import os
11 9
12 from PyQt5.QtCore import Qt, QCoreApplication 10 from PyQt5.QtCore import Qt, QCoreApplication
13 from PyQt5.QtWidgets import QDialog, QDialogButtonBox 11 from PyQt5.QtWidgets import QDialog, QDialogButtonBox
14 12
15 from .Ui_HgQueuesHeaderDialog import Ui_HgQueuesHeaderDialog 13 from .Ui_HgQueuesHeaderDialog import Ui_HgQueuesHeaderDialog
50 if self.__hgClient.isExecuting(): 48 if self.__hgClient.isExecuting():
51 self.__hgClient.cancel() 49 self.__hgClient.cancel()
52 50
53 e.accept() 51 e.accept()
54 52
55 def start(self, path): 53 def start(self):
56 """ 54 """
57 Public slot to start the list command. 55 Public slot to start the list command.
58
59 @param path name of directory to be listed (string)
60 """ 56 """
61 self.activateWindow() 57 self.activateWindow()
62
63 dname, fname = self.vcs.splitPath(path)
64
65 # find the root of the repo
66 repodir = dname
67 while not os.path.isdir(os.path.join(repodir, self.vcs.adminDir)):
68 repodir = os.path.dirname(repodir)
69 if os.path.splitdrive(repodir)[1] == os.sep:
70 return
71 58
72 args = self.vcs.initCommand("qheader") 59 args = self.vcs.initCommand("qheader")
73 60
74 out, err = self.__hgClient.runcommand( 61 out, err = self.__hgClient.runcommand(
75 args, output=self.__showOutput, error=self.__showError) 62 args, output=self.__showOutput, error=self.__showError)

eric ide

mercurial