diff options
author | Arno <arno@disconnect.de> | 2017-12-26 19:48:10 +0100 |
---|---|---|
committer | Arno <arno@disconnect.de> | 2017-12-26 19:51:26 +0100 |
commit | 808dbebbc2f90c4ff1722410d2d40d52c07cef3d (patch) | |
tree | 274871ef4bc028a8d8bdd3299dc947ca9cb8b1e2 | |
parent | 71c0c7064d37097cb7371ae07e880bcf362c04c9 (diff) | |
download | SheMov-808dbebbc2f90c4ff1722410d2d40d52c07cef3d.tar.gz SheMov-808dbebbc2f90c4ff1722410d2d40d52c07cef3d.tar.bz2 SheMov-808dbebbc2f90c4ff1722410d2d40d52c07cef3d.zip |
Get rid of PVAddMapper QSignalMapper
One has to ask what it is good for now, maybe totally useless after
revamping the slide dialog, but that's for another commit...
This also eliminates QSignalMapper from shemov.{h,cpp}
-rw-r--r-- | shemov.cpp | 9 | ||||
-rw-r--r-- | shemov.h | 1 |
2 files changed, 2 insertions, 8 deletions
@@ -10,7 +10,6 @@ #include <QMenuBar> #include <QStatusBar> #include <QLabel> -#include <QSignalMapper> #include <QSettings> #include <QMessageBox> #include <QCloseEvent> @@ -528,16 +527,12 @@ void SheMov::createActions(){ mPicWidget->picView()->addAction(mPVToggleA); // Add selected + Replace with selected - QSignalMapper *PVAddMapper = new QSignalMapper(this); mPVAddA = new QAction(QIcon(":/used_tampon.png"), tr("Add selected"), this); - connect(mPVAddA, SIGNAL(triggered()), PVAddMapper, SLOT(map())); - PVAddMapper->setMapping(mPVAddA, false); + connect(mPVAddA, &QAction::triggered, [=] { mPicWidget->picView()->setPVData(false); }); mPicWidget->picView()->addAction(mPVAddA); mPVReplaceA = new QAction(QIcon(":/clean_tampon.png"), tr("Replace with selected"), this); - connect(mPVReplaceA, SIGNAL(triggered()), PVAddMapper, SLOT(map())); - PVAddMapper->setMapping(mPVReplaceA, true); + connect(mPVReplaceA, &QAction::triggered, [=] { mPicWidget->picView()->setPVData(true); }); mPicWidget->picView()->addAction(mPVReplaceA); - connect(PVAddMapper, SIGNAL(mapped(int)), mPicWidget->picView(), SLOT(setPVData(int))); // Refresh mPicWidget->picView()->addAction(createSeparator()); @@ -14,7 +14,6 @@ class QTabWidget; class FilesystemWidget; class QLabel; -class QSignalMapper; class QActionGroup; class NewMovieWizard; class PicturesWidget; |