mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-17 11:28:07 +00:00
Fix : keep fullscreen mode on timeout notification.
- Come back to fullscreen when clicking on fullscreen icon in call.
This commit is contained in:
parent
ecf6c9dfd1
commit
1959e90632
3 changed files with 14 additions and 2 deletions
|
|
@ -212,7 +212,7 @@ void Notifier::showNotification (QObject *notification, int timeout) {
|
|||
|
||||
// Destroy it after timeout.
|
||||
QObject::connect(timer, &QTimer::timeout, this, [this, notification]() {
|
||||
deleteNotification(QVariant::fromValue(notification));
|
||||
deleteNotificationOnTimeout(QVariant::fromValue(notification));
|
||||
});
|
||||
|
||||
// Called explicitly (by a click on notification for example)
|
||||
|
|
@ -222,6 +222,16 @@ void Notifier::showNotification (QObject *notification, int timeout) {
|
|||
}
|
||||
|
||||
// -----------------------------------------------------------------------------
|
||||
void Notifier::deleteNotificationOnTimeout(QVariant notification) {
|
||||
#ifdef Q_OS_MACOS
|
||||
for(auto w : QGuiApplication::topLevelWindows()){
|
||||
if( (w->windowState()&Qt::WindowFullScreen)==Qt::WindowFullScreen){
|
||||
w->requestActivate();// Used to get focus on fullscreens on Mac in order to avoid screen switching.
|
||||
}
|
||||
}
|
||||
#endif
|
||||
deleteNotification(notification);
|
||||
}
|
||||
|
||||
void Notifier::deleteNotification (QVariant notification) {
|
||||
mMutex->lock();
|
||||
|
|
|
|||
|
|
@ -60,6 +60,7 @@ public:
|
|||
void notifyRecordingCompleted (const QString &filePath);
|
||||
|
||||
public slots:
|
||||
void deleteNotificationOnTimeout(QVariant notification);
|
||||
void deleteNotification (QVariant notification);
|
||||
|
||||
private:
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
/*
|
||||
/*
|
||||
* Copyright (c) 2010-2020 Belledonne Communications SARL.
|
||||
*
|
||||
* This file is part of linphone-desktop
|
||||
|
|
@ -132,6 +132,7 @@ function openMediaParameters (window, incall) {
|
|||
|
||||
function showFullscreen (position) {
|
||||
if (incall._fullscreen) {
|
||||
incall._fullscreen.raise()
|
||||
return
|
||||
}
|
||||
DesktopTools.DesktopTools.screenSaverStatus = false
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue