myPrefs.getString( Prefs::OPEN_DIALOG_FOLDER ),
tr( "Torrent Files (*.torrent);;All Files (*.*)" ) );
myFileDialog->setFileMode( QFileDialog::ExistingFiles );
+ myFileDialog->setAttribute( Qt::WA_DeleteOnClose );
QCheckBox * button = new QCheckBox( tr( "Show &options dialog" ) );
button->setChecked( myPrefs.getBool( Prefs::OPTIONS_PROMPT ) );
{
QFileDialog * d = new QFileDialog( this, tr( "Select File" ) );
d->setFileMode( QFileDialog::ExistingFile );
+ d->setAttribute( Qt::WA_DeleteOnClose );
connect( d, SIGNAL(filesSelected(const QStringList&)),
this, SLOT(onFileSelected(const QStringList&)) );
d->show( );
MakeDialog :: onFolderClicked( )
{
QFileDialog * d = new QFileDialog( this, tr( "Select Folder" ) );
- d->setFileMode( QFileDialog::DirectoryOnly );
+ d->setFileMode( QFileDialog::Directory );
+ d->setOption( QFileDialog::ShowDirsOnly );
+ d->setAttribute( Qt::WA_DeleteOnClose );
connect( d, SIGNAL(filesSelected(const QStringList&)),
this, SLOT(onFolderSelected(const QStringList&)) );
d->show( );
MakeDialog :: onDestinationClicked( )
{
QFileDialog * d = new QFileDialog( this, tr( "Select Folder" ) );
- d->setFileMode( QFileDialog::DirectoryOnly );
+ d->setFileMode( QFileDialog::Directory );
+ d->setOption( QFileDialog::ShowDirsOnly );
+ d->setAttribute( Qt::WA_DeleteOnClose );
connect( d, SIGNAL(filesSelected(const QStringList&)),
this, SLOT(onDestinationSelected(const QStringList&)) );
d->show( );
QFileInfo(myAdd.filename).absolutePath(),
tr( "Torrent Files (*.torrent);;All Files (*.*)" ) );
d->setFileMode( QFileDialog::ExistingFile );
+ d->setAttribute( Qt::WA_DeleteOnClose );
connect( d, SIGNAL(filesSelected(const QStringList&)), this, SLOT(onFilesSelected(const QStringList&)) );
d->show( );
}
tr( "Select Destination" ),
myDestination.absolutePath( ) );
d->setFileMode( QFileDialog::Directory );
+ d->setAttribute( Qt::WA_DeleteOnClose );
connect( d, SIGNAL(filesSelected(const QStringList&)), this, SLOT(onDestinationsSelected(const QStringList&)) );
d->show( );
}