Sat, 26 Apr 2025 12:34:32 +0200
MicroPython
- Added a configuration option to disable the support for the no longer produced Pimoroni Pico Wireless Pack.
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
1 | # -*- coding: utf-8 -*- |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
2 | |
11090
f5f5f5803935
Updated copyright for 2025.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
10439
diff
changeset
|
3 | # Copyright (c) 2013 - 2025 Detlev Offenbach <detlev@die-offenbachs.de> |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
4 | # |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
5 | |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
6 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
7 | Module implementing a dialog to enter the archive data. |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
8 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
9 | |
8318
962bce857696
Replaced all imports of PyQt5 to PyQt6 and started to replace code using obsoleted methods and adapt to the PyQt6 enum usage.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8312
diff
changeset
|
10 | from PyQt6.QtCore import pyqtSlot |
962bce857696
Replaced all imports of PyQt5 to PyQt6 and started to replace code using obsoleted methods and adapt to the PyQt6 enum usage.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8312
diff
changeset
|
11 | from PyQt6.QtWidgets import QDialog, QDialogButtonBox |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
12 | |
9413
80c06d472826
Changed the eric7 import statements to include the package name (i.e. eric7) in order to not fiddle with sys.path.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9221
diff
changeset
|
13 | from eric7.EricWidgets.EricPathPicker import EricPathPickerModes |
9624
b47dfa7a137d
Refactored the Utilities and Globals modules in order to enhance the maintainability.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9473
diff
changeset
|
14 | from eric7.SystemUtilities import OSUtilities |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
15 | |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
16 | from .Ui_HgArchiveDialog import Ui_HgArchiveDialog |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
17 | |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
18 | |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
19 | class HgArchiveDialog(QDialog, Ui_HgArchiveDialog): |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
20 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
21 | Class implementing a dialog to enter the archive data. |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
22 | """ |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
23 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
24 | def __init__(self, vcs, parent=None): |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
25 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
26 | Constructor |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
27 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
28 | @param vcs reference to the Mercurial object (Hg) |
10438
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
29 | @type Hg |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
30 | @param parent reference to the parent widget |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
31 | @type QWidget |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
32 | """ |
8218
7c09585bd960
Applied some more code simplifications suggested by the new Simplify checker (super(Foo, self) => super()).
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8143
diff
changeset
|
33 | super().__init__(parent) |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
34 | self.setupUi(self) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
35 | |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
36 | self.archivePicker.setMode(EricPathPickerModes.SAVE_FILE_ENSURE_EXTENSION_MODE) |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
37 | |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
38 | self.typeComboBox.addItem(self.tr("Detect Automatically"), "") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
39 | self.typeComboBox.addItem(self.tr("Directory of Files"), "files") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
40 | self.typeComboBox.addItem(self.tr("Uncompressed TAR-Archive"), "tar") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
41 | self.typeComboBox.addItem(self.tr("Bzip2 compressed TAR-Archive"), "tbz2") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
42 | self.typeComboBox.addItem(self.tr("Gzip compressed TAR-Archive"), "tgz") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
43 | self.typeComboBox.addItem(self.tr("Uncompressed ZIP-Archive"), "uzip") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
44 | self.typeComboBox.addItem(self.tr("Compressed ZIP-Archive"), "zip") |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
45 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
46 | self.__unixFileFilters = [ |
3190
a9a94491c4fd
Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3186
diff
changeset
|
47 | self.tr("Bzip2 compressed TAR-Archive (*.tar.bz2)"), |
a9a94491c4fd
Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3186
diff
changeset
|
48 | self.tr("Gzip compressed TAR-Archive (*.tar.gz)"), |
a9a94491c4fd
Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3186
diff
changeset
|
49 | self.tr("Uncompressed TAR-Archive (*.tar)"), |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
50 | ] |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
51 | self.__windowsFileFilters = [ |
3190
a9a94491c4fd
Changed the code to use QObject.tr() instead of QObject.trUtf8().
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3186
diff
changeset
|
52 | self.tr("Compressed ZIP-Archive (*.zip)"), |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
53 | self.tr("Uncompressed ZIP-Archive (*.uzip)"), |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
54 | ] |
8259
2bbec88047dd
Applied some more code simplifications suggested by the new Simplify checker (Y108: use ternary operator).
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8218
diff
changeset
|
55 | fileFilters = ( |
2bbec88047dd
Applied some more code simplifications suggested by the new Simplify checker (Y108: use ternary operator).
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8218
diff
changeset
|
56 | ";;".join(self.__windowsFileFilters + self.__unixFileFilters) |
9624
b47dfa7a137d
Refactored the Utilities and Globals modules in order to enhance the maintainability.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9473
diff
changeset
|
57 | if OSUtilities.isWindowsPlatform() |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
58 | else ";;".join(self.__unixFileFilters + self.__windowsFileFilters) |
8259
2bbec88047dd
Applied some more code simplifications suggested by the new Simplify checker (Y108: use ternary operator).
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8218
diff
changeset
|
59 | ) |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
60 | fileFilters += ";;" + self.tr("All Files (*)") |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
61 | |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
62 | self.archivePicker.setFilters(fileFilters) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
63 | |
2821
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
64 | self.__typeFilters = { |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
65 | "tar": ["*.tar"], |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
66 | "tbz2": ["*.tar.bz2", "*.tbz2"], |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
67 | "tgz": ["*.tar.gz", "*.tgz"], |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
68 | "uzip": ["*.uzip", "*.zip"], |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
69 | "zip": ["*.zip"], |
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
70 | } |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
71 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
72 | self.subReposCheckBox.setEnabled(vcs.hasSubrepositories()) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
73 | |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
74 | self.buttonBox.button(QDialogButtonBox.StandardButton.Ok).setEnabled(False) |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
75 | |
7257
c4d0cac9b5c9
Continued to resolve code style issue M841.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
7229
diff
changeset
|
76 | self.__projectPath = ( |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
77 | vcs.getPlugin().getProjectHelper().getProject().getProjectPath() |
7257
c4d0cac9b5c9
Continued to resolve code style issue M841.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
7229
diff
changeset
|
78 | ) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
79 | |
3366
6084bb3c3911
Made some changes to have a bunch of dialogs with correct sizes.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3190
diff
changeset
|
80 | msh = self.minimumSizeHint() |
6084bb3c3911
Made some changes to have a bunch of dialogs with correct sizes.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
3190
diff
changeset
|
81 | self.resize(max(self.width(), msh.width()), msh.height()) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
82 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
83 | @pyqtSlot(str) |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
84 | def on_archivePicker_textChanged(self, archive): |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
85 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
86 | Private slot to handle changes of the archive name. |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
87 | |
10438
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
88 | @param archive name of the archive |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
89 | @type str |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
90 | """ |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
91 | self.buttonBox.button(QDialogButtonBox.StandardButton.Ok).setEnabled( |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
92 | archive != "" |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
93 | ) |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
94 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
95 | @pyqtSlot(int) |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
96 | def on_typeComboBox_activated(self, index): |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
97 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
98 | Private slot to react on changes of the selected archive type. |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
99 | |
10438
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
100 | @param index index of the selected type |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
101 | @type int |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
102 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
103 | type_ = self.typeComboBox.itemData(index) |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
104 | if type_ == "files": |
8356
68ec9c3d4de5
Renamed the modules and classes of the E5Gui package to have the prefix 'Eric' instead of 'E5'.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
8327
diff
changeset
|
105 | self.archivePicker.setMode(EricPathPickerModes.DIRECTORY_MODE) |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
106 | else: |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
107 | self.archivePicker.setMode( |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
108 | EricPathPickerModes.SAVE_FILE_ENSURE_EXTENSION_MODE |
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
109 | ) |
2821
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
110 | if type_ in self.__typeFilters: |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
111 | self.archivePicker.setNameFilters(self.__typeFilters[type_]) |
2821
459cc954bea8
Made the file completer of the Mercurial archive dialog sensitive to the selected file type.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
2820
diff
changeset
|
112 | else: |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
113 | self.archivePicker.setNameFilters([]) |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
114 | |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
115 | def getData(self): |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
116 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
117 | Public method to retrieve the data. |
9221
bf71ee032bb4
Reformatted the source code using the 'Black' utility.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9209
diff
changeset
|
118 | |
10438
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
119 | @return tuple giving the archive name, the archive type, the directory prefix |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
120 | and a flag indicating to recurse into subrepositories |
4cd7e5a8b3cf
Converted some source code documentation to the new style.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
9653
diff
changeset
|
121 | @rtype tuple of (str, str, str, bool) |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
122 | """ |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
123 | return ( |
4593
cc745fa6c914
Modified more dialogs to use the path picker widgets.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
4021
diff
changeset
|
124 | self.archivePicker.text(), |
2820
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
125 | self.typeComboBox.itemData(self.typeComboBox.currentIndex()), |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
126 | self.prefixEdit.text(), |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
127 | self.subReposCheckBox.isChecked(), |
642c1f3c23c8
Started implementing support for the Mercurial archive function.
Detlev Offenbach <detlev@die-offenbachs.de>
parents:
diff
changeset
|
128 | ) |