eric7/E5Gui/E5FileSaveConfirmDialog.py

branch
eric7
changeset 8350
74a3b2a6a944
parent 8327
666c2b81cbb7
equal deleted inserted replaced
8348:f4775ae8f441 8350:74a3b2a6a944
7 Module implementing a dialog to enter a file system path using a file picker. 7 Module implementing a dialog to enter a file system path using a file picker.
8 """ 8 """
9 9
10 import os 10 import os
11 11
12 from PyQt6.QtWidgets import QDialog, QDialogButtonBox, QVBoxLayout, QLabel 12 from PyQt6.QtWidgets import (
13 QDialog, QDialogButtonBox, QVBoxLayout, QLabel, QLineEdit
14 )
13 15
14 from .E5PathPicker import E5PathPicker, E5PathPickerModes 16 from .E5PathPicker import E5PathPicker, E5PathPickerModes
15 from .E5LineEdit import E5ClearableLineEdit
16 17
17 18
18 class E5FileSaveConfirmDialog(QDialog): 19 class E5FileSaveConfirmDialog(QDialog):
19 """ 20 """
20 Class implementing a dialog to enter a file system path using a file 21 Class implementing a dialog to enter a file system path using a file
53 54
54 if picker: 55 if picker:
55 self.__pathPicker = E5PathPicker(self) 56 self.__pathPicker = E5PathPicker(self)
56 self.__pathPicker.setMode(E5PathPickerModes.SAVE_FILE_MODE) 57 self.__pathPicker.setMode(E5PathPickerModes.SAVE_FILE_MODE)
57 else: 58 else:
58 self.__pathPicker = E5ClearableLineEdit(self) 59 self.__pathPicker = QLineEdit(self)
60 self.__pathPicker.setClearButtonEnabled(True)
59 61
60 self.__buttonBox = QDialogButtonBox(self) 62 self.__buttonBox = QDialogButtonBox(self)
61 self.__cancelButton = self.__buttonBox.addButton( 63 self.__cancelButton = self.__buttonBox.addButton(
62 QDialogButtonBox.StandardButton.Cancel) 64 QDialogButtonBox.StandardButton.Cancel)
63 self.__overwriteButton = self.__buttonBox.addButton( 65 self.__overwriteButton = self.__buttonBox.addButton(

eric ide

mercurial