Context menu for images
Just add a context menu for now - the following commits will make this useful. Signed-off-by: Guido Lerch <guido.lerch@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
committed by
Dirk Hohndel
parent
6381425476
commit
3c3523f9b8
@@ -1610,3 +1610,12 @@ void MainTab::showAndTriggerEditSelective(struct dive_components what)
|
||||
weightModel->changed = true;
|
||||
}
|
||||
}
|
||||
|
||||
void MainTab::contextMenuEvent(QContextMenuEvent *event)
|
||||
{
|
||||
QMenu popup(this);
|
||||
popup.addAction(tr("Delete selected images"), this, SLOT(removeSelectedPhotos()));
|
||||
popup.addAction(tr("Delete all images"), this, SLOT(removeAllPhotos()));
|
||||
QAction *actionTaken = popup.exec(event->globalPos());
|
||||
event->accept();
|
||||
}
|
||||
|
||||
@@ -54,6 +54,7 @@ public:
|
||||
void refreshDisplayedDiveSite();
|
||||
void nextInputField(QKeyEvent *event);
|
||||
void showAndTriggerEditSelective(struct dive_components what);
|
||||
void contextMenuEvent(QContextMenuEvent *event);
|
||||
|
||||
signals:
|
||||
void addDiveFinished();
|
||||
|
||||
Reference in New Issue
Block a user