diff options
author | am <am@f440f766-f032-0410-8965-dc7d17de2ca0> | 2009-07-22 18:44:02 +0000 |
---|---|---|
committer | am <am@f440f766-f032-0410-8965-dc7d17de2ca0> | 2009-07-22 18:44:02 +0000 |
commit | 0e3e202c90e3ccb80310087409936c00189f0cea (patch) | |
tree | a4a38c32e761f024e2dfad6a59097cff15472b9e /editarchiveitemdialog.cpp | |
parent | 84ed109c159dcbd0c9395717d54599e902060b26 (diff) | |
download | SheMov-0e3e202c90e3ccb80310087409936c00189f0cea.tar.gz SheMov-0e3e202c90e3ccb80310087409936c00189f0cea.tar.bz2 SheMov-0e3e202c90e3ccb80310087409936c00189f0cea.zip |
-Finished CoverArchiveEditor (finally, don't like that piece of code, too complicated)
-It's now possible to manually add a movie w/o a file
-Some usability fixes
git-svn-id: file:///var/svn/repos2/shemov/trunk@394 f440f766-f032-0410-8965-dc7d17de2ca0
Diffstat (limited to 'editarchiveitemdialog.cpp')
-rw-r--r-- | editarchiveitemdialog.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/editarchiveitemdialog.cpp b/editarchiveitemdialog.cpp index 6a77300..998ff97 100644 --- a/editarchiveitemdialog.cpp +++ b/editarchiveitemdialog.cpp @@ -103,6 +103,7 @@ EditArchiveItemDialog::EditArchiveItemDialog(ListModel *genre, ListModel *actors ListEditor *genreEditor = new ListEditor(mGenreModel); w2Layout->addWidget(genreEditor); ListEditor *actorsEditor = new ListEditor(mActorsModel); + connect(actorsEditor, SIGNAL(itemAdded(const QString &)), this, SLOT(addActor(const QString &))); w2Layout->addWidget(actorsEditor); w2Layout->addStretch(); w2->setLayout(w2Layout); @@ -197,6 +198,14 @@ void EditArchiveItemDialog::addActor(){ } } +void EditArchiveItemDialog::addActor(const QString &actor){ + int idx = mActors->findText(actor); + if(idx != -1){ + mActors->setCurrentIndex(idx); + addActor(); + } +} + void EditArchiveItemDialog::removeActor(){ QString currentText = mActors->currentText(); if(mActorMap.contains(currentText)){ |