mirror of
https://gitlab.com/kelteseth/ScreenPlay.git
synced 2024-11-06 19:12:30 +01:00
Add Window termination on error to avoid zombie windows
This commit is contained in:
parent
59758487b4
commit
536813e52d
@ -182,6 +182,15 @@ WinWindow::WinWindow(
|
||||
connect(sdk(), &ScreenPlaySDK::incommingMessage, this, &WinWindow::messageReceived);
|
||||
connect(sdk(), &ScreenPlaySDK::replaceWallpaper, this, &WinWindow::replaceWallpaper);
|
||||
connect(&m_checkForFullScreenWindowTimer, &QTimer::timeout, this, &WinWindow::checkForFullScreenWindow);
|
||||
connect(
|
||||
&m_window, &QQuickView::statusChanged,
|
||||
this, [](auto status) {
|
||||
if (status == QQuickView::Status::Error) {
|
||||
qInfo() << status;
|
||||
QCoreApplication::exit(-1);
|
||||
}
|
||||
},
|
||||
Qt::QueuedConnection);
|
||||
|
||||
const auto screens = QApplication::screens();
|
||||
for (const auto& screen : screens) {
|
||||
|
Loading…
Reference in New Issue
Block a user