Skip to content

Commit

Permalink
Try to fix spotlight issue on KDE desktops jahnf#5
Browse files Browse the repository at this point in the history
  • Loading branch information
jahnf committed Mar 15, 2019
1 parent 21c30f0 commit 3825e78
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions projecteurapp.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,12 @@ ProjecteurApplication::ProjecteurApplication(int &argc, char **argv)
}
});

window->setScreen(screen);
window->setPosition(screen->availableGeometry().topLeft());
window->setFlag(Qt::WindowTransparentForInput, true);
window->setFlag(Qt::Tool, true);

window->setScreen(screen);
window->setPosition(screen->availableGeometry().topLeft());
window->setWidth(screen->availableGeometry().width());
window->setHeight(screen->availableGeometry().height());
connect(this, &ProjecteurApplication::aboutToQuit, [window](){ if (window) window->close(); });

// Example code for global shortcuts...
Expand Down Expand Up @@ -148,8 +149,11 @@ ProjecteurApplication::ProjecteurApplication(int &argc, char **argv)
window->hide();
window->setGeometry(QRect(screen->availableGeometry().topLeft(), QSize(400,320)));
window->setScreen(screen);
window->setPosition(screen->availableGeometry().topLeft());
window->setWidth(screen->availableGeometry().width());
window->setHeight(screen->availableGeometry().height());
if (wasVisible) {
QTimer::singleShot(0,[window,this]() {
QTimer::singleShot(0, [window,this]() {
window->showMaximized();
if(m_dialog->isVisible()) {
m_dialog->raise();
Expand Down

0 comments on commit 3825e78

Please sign in to comment.