From c0809dc0b3184b76861a6f1f1442c76472845d65 Mon Sep 17 00:00:00 2001 From: David Rosca Date: Fri, 6 Nov 2015 17:55:57 +0100 Subject: [PATCH] Fix exiting HTML fullscreen with F11 --- src/lib/app/browserwindow.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/lib/app/browserwindow.cpp b/src/lib/app/browserwindow.cpp index a07f5e7bf..ed26cacfe 100644 --- a/src/lib/app/browserwindow.cpp +++ b/src/lib/app/browserwindow.cpp @@ -775,12 +775,15 @@ void BrowserWindow::toggleTabsOnTop(bool enable) void BrowserWindow::toggleFullScreen() { - if (isFullScreen()) { + if (m_isHtmlFullScreen) { + weView()->triggerPageAction(QWebEnginePage::ExitFullScreen); + return; + } + + if (isFullScreen()) showNormal(); - } - else { + else showFullScreen(); - } } void BrowserWindow::enterHtmlFullScreen()