eric7/EricWidgets/EricDirFileDialog.py

branch
eric7
changeset 8404
c455e281b193
parent 8403
d9fd02e8c28b
child 8406
45d7d0eec4d3
equal deleted inserted replaced
8403:d9fd02e8c28b 8404:c455e281b193
61 # Avoid to close the dialog if only return is pressed 61 # Avoid to close the dialog if only return is pressed
62 if not self.__openBtn.isEnabled(): 62 if not self.__openBtn.isEnabled():
63 return 63 return
64 64
65 self.__selectedFilesFolders = [ 65 self.__selectedFilesFolders = [
66 x.data(QFileSystemModel.Roles.FilePathRole) 66 # TODO: re-enable once PyQt6 is fixed
67 #~ x.data(QFileSystemModel.Roles.FilePathRole)
68 x.data(QFileSystemModel.Roles.FilePathRole.value)
67 for x in self.__tree.selectionModel().selectedIndexes() 69 for x in self.__tree.selectionModel().selectedIndexes()
68 if x.column() == 0] 70 if x.column() == 0]
69 71
70 self.hide() 72 self.hide()
71 73
129 @type QFileDialog.Options 131 @type QFileDialog.Options
130 @return names of the selected files and folders 132 @return names of the selected files and folders
131 @rtype list of str 133 @rtype list of str
132 """ 134 """
133 if options is None: 135 if options is None:
134 options = QFileDialog.Options(0) 136 options = QFileDialog.Option(0)
135 options |= QFileDialog.Option.DontUseNativeDialog 137 options |= QFileDialog.Option.DontUseNativeDialog
136 dlg = EricDirFileDialog(parent, caption, directory, filterStr) 138 dlg = EricDirFileDialog(parent, caption, directory, filterStr)
137 dlg.setOptions(options) 139 dlg.setOptions(options)
138 dlg.exec() 140 dlg.exec()
139 141

eric ide

mercurial