diff --git a/ChangeLog b/ChangeLog index f23074a7..861af805 100644 --- a/ChangeLog +++ b/ChangeLog @@ -16039,3 +16039,6 @@ in 'lib/rddropbox.cpp' and 'lib/rddropbox.h'. * Added a 'Force to Monaural' checkbox to the 'Edit Dropbox' dialog in rdadmin(1). +2017-09-20 Fred Gleason + * Added a 'Reset' button to the 'Edit Dropbox' dialog + in rdadmin(1). diff --git a/rdadmin/edit_dropbox.cpp b/rdadmin/edit_dropbox.cpp index 7276b1e9..a91599d0 100644 --- a/rdadmin/edit_dropbox.cpp +++ b/rdadmin/edit_dropbox.cpp @@ -56,7 +56,8 @@ EditDropbox::EditDropbox(int id,QWidget *parent) box_dropbox=new RDDropbox(id); - setCaption(tr("Dropbox Configuration")); + setCaption(tr("Dropbox Configuration")+" ["+ + tr("ID")+QString().sprintf(": %d]",id)); // // Create Fonts @@ -343,6 +344,17 @@ EditDropbox::EditDropbox(int id,QWidget *parent) this,SLOT(createDatesToggledData(bool))); + // + // Reset Button + // + QPushButton *reset_button=new QPushButton(this); + reset_button-> + setGeometry(10,sizeHint().height()-60,80,50); + reset_button->setDefault(true); + reset_button->setFont(font); + reset_button->setText(tr("&Reset")); + connect(reset_button,SIGNAL(clicked()),this,SLOT(resetData())); + // // Ok Button // @@ -492,6 +504,23 @@ void EditDropbox::createDatesToggledData(bool state) } +void EditDropbox::resetData() +{ + if(QMessageBox::question(this,"RDAdmin - "+tr("Reset Dropbox"), + tr("Resetting the dropbox will clear the list of already imported\nfiles, causing any whose files remain to be imported again.")+"\n\n"+tr("Reset the dropbox?"), + QMessageBox::Yes,QMessageBox::No)!=QMessageBox::Yes) { + return; + } + QString sql=QString("delete from DROPBOX_PATHS where ")+ + QString().sprintf("DROPBOX_ID=%d",box_dropbox->id()); + printf("SQL: %s\n",(const char *)sql); + RDSqlQuery *q=new RDSqlQuery(sql); + delete q; + QMessageBox::information(this,"RDAdmin - "+tr("Reset Dropbox"), + tr("The dropbox has been reset.")); +} + + void EditDropbox::okData() { QString sql; diff --git a/rdadmin/edit_dropbox.h b/rdadmin/edit_dropbox.h index cd7842e4..660fafbd 100644 --- a/rdadmin/edit_dropbox.h +++ b/rdadmin/edit_dropbox.h @@ -54,6 +54,7 @@ class EditDropbox : public QDialog void normalizationToggledData(bool state); void autotrimToggledData(bool state); void createDatesToggledData(bool state); + void resetData(); void okData(); void cancelData(); diff --git a/rdadmin/rdadmin_cs.ts b/rdadmin/rdadmin_cs.ts index c7c3e075..5f57c587 100644 --- a/rdadmin/rdadmin_cs.ts +++ b/rdadmin/rdadmin_cs.ts @@ -1251,6 +1251,31 @@ nastaveném pro běh služby CAE pro naplnění databáze se zdroji zvuku.Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_de.ts b/rdadmin/rdadmin_de.ts index 77819711..196684bc 100644 --- a/rdadmin/rdadmin_de.ts +++ b/rdadmin/rdadmin_de.ts @@ -1219,6 +1219,31 @@ configured to run the CAE service in order to populate the audio resources datab Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_es.ts b/rdadmin/rdadmin_es.ts index c25aa99d..7ed2a2f0 100644 --- a/rdadmin/rdadmin_es.ts +++ b/rdadmin/rdadmin_es.ts @@ -1245,6 +1245,31 @@ computador para obtener los recursos de audio de dicho equipo. Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_fr.ts b/rdadmin/rdadmin_fr.ts index 9c2ca06e..0a59ee24 100644 --- a/rdadmin/rdadmin_fr.ts +++ b/rdadmin/rdadmin_fr.ts @@ -1006,6 +1006,31 @@ configured to run the CAE service in order to populate the audio resources datab Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_nb.ts b/rdadmin/rdadmin_nb.ts index 53b838c8..52f73b93 100644 --- a/rdadmin/rdadmin_nb.ts +++ b/rdadmin/rdadmin_nb.ts @@ -1201,6 +1201,31 @@ configured to run the CAE service in order to populate the audio resources datab Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_nn.ts b/rdadmin/rdadmin_nn.ts index 53b838c8..52f73b93 100644 --- a/rdadmin/rdadmin_nn.ts +++ b/rdadmin/rdadmin_nn.ts @@ -1201,6 +1201,31 @@ configured to run the CAE service in order to populate the audio resources datab Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder diff --git a/rdadmin/rdadmin_pt_BR.ts b/rdadmin/rdadmin_pt_BR.ts index 8f69f085..c60717ef 100644 --- a/rdadmin/rdadmin_pt_BR.ts +++ b/rdadmin/rdadmin_pt_BR.ts @@ -1202,6 +1202,31 @@ configured to run the CAE service in order to populate the audio resources datab Force to Monaural + + &Reset + + + + ID + + + + Reset Dropbox + + + + Reset the dropbox? + + + + The dropbox has been reset. + + + + Resetting the dropbox will clear the list of already imported +files, causing any whose files remain to be imported again. + + EditEncoder