Skip to content

Commit

Permalink
fix: The first attempt to switch from windowed mode to fullscreen mod…
Browse files Browse the repository at this point in the history
…e failed.

delay the timer to 1 sec

log: as title
issue: linuxdeepin/developer-center#8137
  • Loading branch information
robertkill authored and BLumia committed Apr 23, 2024
1 parent 91d1156 commit 05b57db
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions launchercontroller.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ LauncherController::LauncherController(QObject *parent)
m_currentFrame = QStringLiteral("FullscreenFrame");
}

// Interval set to 500=>700ms for issue https://github.com/linuxdeepin/developer-center/issues/8137
m_timer->setInterval(700);
// Interval set to 500=>1000ms for issue https://github.com/linuxdeepin/developer-center/issues/8137
m_timer->setInterval(1000);
m_timer->setSingleShot(true);

connect(DGuiApplicationHelper::instance(), &DGuiApplicationHelper::newProcessInstance,
Expand Down Expand Up @@ -131,6 +131,7 @@ void LauncherController::setCurrentFrame(const QString &frame)
settings.setValue("current_frame", frame);

m_currentFrame = frame;
qDebug() << "set current frame:" << m_currentFrame;
m_timer->start();
emit currentFrameChanged();
}
Expand All @@ -143,6 +144,7 @@ void LauncherController::hideWithTimer()
{
if (visible()) {
m_timer->start();
qDebug() << "hide with timer";
setVisible(false);
}
}
Expand Down

0 comments on commit 05b57db

Please sign in to comment.