change slot close, to signal closing
This commit is contained in:
parent
a88c68c0a8
commit
c7295d7fd1
@ -28,10 +28,11 @@ ImageOverlay::ImageOverlay(QPixmap image, QWidget *parent)
|
||||
setAttribute(Qt::WA_TranslucentBackground, true);
|
||||
setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
setWindowState(Qt::WindowFullScreen);
|
||||
close_shortcut_ = new QShortcut(QKeySequence(Qt::Key_Escape), this);
|
||||
|
||||
connect(this, SIGNAL(closing()), this, SLOT(close()));
|
||||
connect(close_shortcut_, &QShortcut::activated, this, &ImageOverlay::closing);
|
||||
connect(this, &ImageOverlay::closing, this, &ImageOverlay::close);
|
||||
|
||||
close_shortcut_ = new QShortcut(QKeySequence(Qt::Key_Escape), this, SLOT(close()));
|
||||
|
||||
raise();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user