# eric6.Project.AddDirectoryDialog

Module implementing a dialog to add files of a directory to the project.

### Global Attributes

None

### Classes

AddDirectoryDialog | Class implementing a dialog to add files of a directory to the project.

### Functions

None

## AddDirectoryDialog

Class implementing a dialog to add files of a directory to the project.

### Derived from

QDialog, Ui_AddDirectoryDialog

### Class Attributes

None

### Class Methods

None

### Methods

AddDirectoryDialog | Constructor
getData | Public slot to retrieve the dialogs data.
on_filterComboBox_highlighted | Private slot to handle the selection of a file type.
on_sourceDirPicker_textChanged | Private slot to handle the source directory text changed.

### Static Methods

None

#### AddDirectoryDialog (Constructor)

AddDirectoryDialog(pro, filter='source', parent=None, name=None, startdir=None)

Constructor

pro
  reference to the project object
filter
  file type filter (string)
parent
  parent widget of this dialog (QWidget)
name
  name of this dialog (string)
startdir
  start directory for the selection dialog

#### AddDirectoryDialog.getData

getData()

Public slot to retrieve the dialogs data.

Returns:
  tuple of four values (string, string, string, boolean) giving the selected file type, the source and target directory and a flag indicating a recursive add

#### AddDirectoryDialog.on_filterComboBox_highlighted

on_filterComboBox_highlighted(fileType)

Private slot to handle the selection of a file type.

fileType
  the selected file type (string)

#### AddDirectoryDialog.on_sourceDirPicker_textChanged

on_sourceDirPicker_textChanged(dir)

Private slot to handle the source directory text changed.

If the entered source directory is a subdirectory of the current projects main directory, the target directory path is synchronized. It is assumed, that the user wants to add a bunch of files to the project in place.

dir
  the text of the source directory line edit (string)

Up