diff src/imagelabel.cpp @ 38:26e1521b9afd

Add the possibility to detach the picture label on doubleclick
author Andre Heinecke <andre.heinecke@intevation.de>
date Wed, 06 May 2015 18:09:34 +0200
parents 6b9b5efcd7f4
children
line wrap: on
line diff
--- a/src/imagelabel.cpp	Wed May 06 17:17:13 2015 +0200
+++ b/src/imagelabel.cpp	Wed May 06 18:09:34 2015 +0200
@@ -34,3 +34,13 @@
     pixSize.scale(size(), Qt::KeepAspectRatio);
     label->setFixedSize(pixSize);
 }
+
+void ImageLabel::mouseDoubleClickEvent(QMouseEvent * e) {
+    QWidget::mouseDoubleClickEvent(e);
+    emit doubleClicked();
+}
+
+void ImageLabel::closeEvent(QCloseEvent *e) {
+    Q_UNUSED(e);
+    emit closeRequested();
+}
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)