--- a/src/eric7/Plugins/VcsPlugins/vcsSubversion/subversion.py Fri Oct 25 09:47:48 2024 +0200 +++ b/src/eric7/Plugins/VcsPlugins/vcsSubversion/subversion.py Fri Oct 25 17:58:59 2024 +0200 @@ -331,7 +331,10 @@ QProcess(), "svn", args, os.path.join(tmpDir, project) ) else: - dia = SvnDialog(self.tr("Importing project into Subversion repository")) + dia = SvnDialog( + self.tr("Importing project into Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args, os.path.join(tmpDir, project)) if res: dia.exec() @@ -399,7 +402,10 @@ if noDialog: return self.startSynchronizedProcess(QProcess(), "svn", args) else: - dia = SvnDialog(self.tr("Checking project out of Subversion repository")) + dia = SvnDialog( + self.tr("Checking project out of Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args) if res: dia.exec() @@ -456,7 +462,10 @@ args.append(self.__svnURL(svnUrl)) args.append(projectDir) - dia = SvnDialog(self.tr("Exporting project from Subversion repository")) + dia = SvnDialog( + self.tr("Exporting project from Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args) if res: dia.exec() @@ -579,7 +588,10 @@ if noDialog: self.startSynchronizedProcess(QProcess(), "svn", args, dname) else: - dia = SvnDialog(self.tr("Commiting changes to Subversion repository")) + dia = SvnDialog( + self.tr("Commiting changes to Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args, dname) if res: dia.exec() @@ -654,7 +666,10 @@ self.startSynchronizedProcess(QProcess(), "svn", args, dname) res = False else: - dia = SvnDialog(self.tr("Synchronizing with the Subversion repository")) + dia = SvnDialog( + self.tr("Synchronizing with the Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args, dname, True) if res: dia.exec() @@ -756,7 +771,8 @@ self.startSynchronizedProcess(QProcess(), "svn", args, wdir) else: dia = SvnDialog( - self.tr("Adding files/directories to the Subversion repository") + self.tr("Adding files/directories to the Subversion repository"), + parent=self.__ui, ) res = dia.startProcess(args, wdir) if res: @@ -849,7 +865,10 @@ else: args.append(path) - dia = SvnDialog(self.tr("Adding directory trees to the Subversion repository")) + dia = SvnDialog( + self.tr("Adding directory trees to the Subversion repository"), + parent=self.__ui, + ) res = dia.startProcess(args, dname) if res: dia.exec() @@ -886,7 +905,8 @@ res = self.startSynchronizedProcess(QProcess(), "svn", args) else: dia = SvnDialog( - self.tr("Removing files/directories from the Subversion repository") + self.tr("Removing files/directories from the Subversion repository"), + parent=self.__ui, ) res = dia.startProcess(args) if res: @@ -925,7 +945,7 @@ force = True accepted = True else: - dlg = SvnCopyDialog(name, None, True, force) + dlg = SvnCopyDialog(name, parent=self.__ui, move=True, force=force) accepted = dlg.exec() == QDialog.DialogCode.Accepted if accepted: target, force = dlg.getData() @@ -950,7 +970,7 @@ if noDialog: res = self.startSynchronizedProcess(QProcess(), "svn", args) else: - dia = SvnDialog(self.tr("Moving {0}").format(name)) + dia = SvnDialog(self.tr("Moving {0}").format(name), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -1045,7 +1065,10 @@ None if self.otherData["standardLayout"] else self.svnNormalizeURL(reposURL) ) dlg = SvnTagDialog( - self.allTagsBranchesList, url, self.otherData["standardLayout"] + self.allTagsBranchesList, + url, + self.otherData["standardLayout"], + parent=self.__ui, ) if dlg.exec() == QDialog.DialogCode.Accepted: tag, tagOp = dlg.getParameters() @@ -1096,7 +1119,8 @@ args.append(url) dia = SvnDialog( - self.tr("Tagging {0} in the Subversion repository").format(name) + self.tr("Tagging {0} in the Subversion repository").format(name), + parent=self.__ui, ) res = dia.startProcess(args) if res: @@ -1147,7 +1171,7 @@ ), ) if yes: - dia = SvnDialog(self.tr("Reverting changes")) + dia = SvnDialog(self.tr("Reverting changes"), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -1197,7 +1221,10 @@ None if self.otherData["standardLayout"] else self.svnNormalizeURL(reposURL) ) dlg = SvnSwitchDialog( - self.allTagsBranchesList, url, self.otherData["standardLayout"] + self.allTagsBranchesList, + url, + self.otherData["standardLayout"], + parent=self.__ui, ) if dlg.exec() == QDialog.DialogCode.Accepted: tag, tagType = dlg.getParameters() @@ -1243,7 +1270,7 @@ args.append(url) args.append(name) - dia = SvnDialog(self.tr("Switching to {0}").format(tn)) + dia = SvnDialog(self.tr("Switching to {0}").format(tn), parent=self.__ui) res = dia.startProcess(args, setLanguage=True) if res: dia.exec() @@ -1268,7 +1295,11 @@ del opts[opts.index("--force")] dlg = SvnMergeDialog( - self.mergeList[0], self.mergeList[1], self.mergeList[2], force + self.mergeList[0], + self.mergeList[1], + self.mergeList[2], + force=force, + parent=self.__ui, ) if dlg.exec() == QDialog.DialogCode.Accepted: urlrev1, urlrev2, target, force = dlg.getParameters() @@ -1310,7 +1341,7 @@ args.append(self.__svnURL(urlrev2)) args.append(fname) - dia = SvnDialog(self.tr("Merging {0}").format(name)) + dia = SvnDialog(self.tr("Merging {0}").format(name), parent=self.__ui) res = dia.startProcess(args, dname) if res: dia.exec() @@ -1599,7 +1630,7 @@ self.addArguments(args, self.options["global"]) args.append(name) - dia = SvnDialog(self.tr("Cleaning up {0}").format(name)) + dia = SvnDialog(self.tr("Cleaning up {0}").format(name), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -1613,7 +1644,9 @@ """ from .SvnCommandDialog import SvnCommandDialog - dlg = SvnCommandDialog(self.commandHistory, self.wdHistory, name) + dlg = SvnCommandDialog( + self.commandHistory, self.wdHistory, name, parent=self.__ui + ) if dlg.exec() == QDialog.DialogCode.Accepted: command, wd = dlg.getData() commandList = Utilities.parseOptionString(command) @@ -1630,7 +1663,7 @@ args = [] self.addArguments(args, commandList) - dia = SvnDialog(self.tr("Subversion command")) + dia = SvnDialog(self.tr("Subversion command"), parent=self.__ui) res = dia.startProcess(args, wd) if res: dia.exec() @@ -1813,7 +1846,7 @@ args.append("--recursive") args.append(name) - dia = SvnDialog(self.tr("Resolving conficts")) + dia = SvnDialog(self.tr("Resolving conficts"), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -1833,7 +1866,7 @@ from .SvnCopyDialog import SvnCopyDialog rx_prot = re.compile("(file:|svn:|svn+ssh:|http:|https:).+") - dlg = SvnCopyDialog(name) + dlg = SvnCopyDialog(name, parent=self.__ui) res = False if dlg.exec() == QDialog.DialogCode.Accepted: target, force = dlg.getData() @@ -1849,7 +1882,7 @@ args.append(name) args.append(target) - dia = SvnDialog(self.tr("Copying {0}").format(name)) + dia = SvnDialog(self.tr("Copying {0}").format(name), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -1893,7 +1926,7 @@ """ from .SvnPropSetDialog import SvnPropSetDialog - dlg = SvnPropSetDialog() + dlg = SvnPropSetDialog(parent=self.__ui) if dlg.exec() == QDialog.DialogCode.Accepted: propName, fileFlag, propValue = dlg.getData() if not propName: @@ -1920,7 +1953,7 @@ dname, fname = self.splitPath(name) args.append(fname) - dia = SvnDialog(self.tr("Subversion Set Property")) + dia = SvnDialog(self.tr("Subversion Set Property"), parent=self.__ui) res = dia.startProcess(args, dname) if res: dia.exec() @@ -1965,7 +1998,7 @@ dname, fname = self.splitPath(name) args.append(fname) - dia = SvnDialog(self.tr("Subversion Delete Property")) + dia = SvnDialog(self.tr("Subversion Delete Property"), parent=self.__ui) res = dia.startProcess(args, dname) if res: dia.exec() @@ -2048,7 +2081,7 @@ project = ericApp().getObject("Project") if nam == project.ppath and not project.saveAllScripts(): return - dlg = SvnRevisionSelectionDialog() + dlg = SvnRevisionSelectionDialog(parent=self.__ui) if dlg.exec() == QDialog.DialogCode.Accepted: revisions = dlg.getRevisions() self.diff = SvnDiffDialog(self) @@ -2086,7 +2119,9 @@ dname = self.splitPath(names[0])[0] - dlg = SvnUrlSelectionDialog(self, self.tagsList, self.branchesList, dname) + dlg = SvnUrlSelectionDialog( + self, self.tagsList, self.branchesList, dname, parent=self.__ui + ) if dlg.exec() == QDialog.DialogCode.Accepted: urls, summary = dlg.getURLs() self.diff = SvnDiffDialog(self) @@ -2165,7 +2200,7 @@ raise ValueError("Wrong parameter type") if extended: - dlg = SvnRevisionSelectionDialog() + dlg = SvnRevisionSelectionDialog(parent=self.__ui) if dlg.exec() == QDialog.DialogCode.Accepted: rev1, rev2 = dlg.getRevisions() if rev1 == "WORKING": @@ -2257,7 +2292,7 @@ dname, fname = self.splitPath(name) args.append(fname) - dia = SvnDialog(self.tr("Locking in the Subversion repository"), parent) + dia = SvnDialog(self.tr("Locking in the Subversion repository"), parent=parent) res = dia.startProcess(args, dname) if res: dia.exec() @@ -2285,7 +2320,9 @@ dname, fname = self.splitPath(name) args.append(fname) - dia = SvnDialog(self.tr("Unlocking in the Subversion repository"), parent) + dia = SvnDialog( + self.tr("Unlocking in the Subversion repository"), parent=parent + ) res = dia.startProcess(args, dname) if res: dia.exec() @@ -2300,7 +2337,7 @@ from .SvnRelocateDialog import SvnRelocateDialog currUrl = self.svnGetReposName(projectPath) - dlg = SvnRelocateDialog(currUrl) + dlg = SvnRelocateDialog(currUrl, parent=self.__ui) if dlg.exec() == QDialog.DialogCode.Accepted: newUrl, inside = dlg.getData() args = [] @@ -2311,7 +2348,7 @@ args.append(newUrl) args.append(projectPath) - dia = SvnDialog(self.tr("Relocating")) + dia = SvnDialog(self.tr("Relocating"), parent=self.__ui) res = dia.startProcess(args) if res: dia.exec() @@ -2364,7 +2401,7 @@ dname, fname = self.splitPath(names) args.append(fname) - dia = SvnDialog(self.tr("Remove from changelist")) + dia = SvnDialog(self.tr("Remove from changelist"), parent=self.__ui) res = dia.startProcess(args, dname) if res: dia.exec() @@ -2401,7 +2438,7 @@ dname, fname = self.splitPath(names) args.append(fname) - dia = SvnDialog(self.tr("Remove from changelist")) + dia = SvnDialog(self.tr("Remove from changelist"), parent=self.__ui) res = dia.startProcess(args, dname) if res: dia.exec() @@ -2471,7 +2508,7 @@ args.append("upgrade") args.append(".") - dia = SvnDialog(self.tr("Upgrade")) + dia = SvnDialog(self.tr("Upgrade"), parent=self.__ui) res = dia.startProcess(args, path) if res: dia.exec()