Skip to content

Commit

Permalink
[xulrunner] Make fullscreen enabling work as used to with pref full-s…
Browse files Browse the repository at this point in the history
…creen-api.content-only. Fixes JB#44129

We don't have chrome from doc shell point of view. This commit
sha1 3116f3b offends fullscreen API to work without chrome
and shall not make root docShell act as chrome. We previously had
"full-screen-api.content-only" pref set to "true".
  • Loading branch information
rainemak committed Jan 10, 2019
1 parent d3f701d commit 54b9d2b
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
@@ -0,0 +1,40 @@
From d291c69ef662fd7b77946f764f63474a86d9115c Mon Sep 17 00:00:00 2001
From: Raine Makelainen <raine.makelainen@jolla.com>
Date: Thu, 10 Jan 2019 15:21:24 +0200
Subject: [PATCH 12/12] [xulrunner] Make fullscreen enabling work as used to
with pref full-screen-api.content-only. Fixes JB#44129

We don't have chrome from doc shell point of view. This commit
sha1 3116f3bf53df offends fullscreen API to work without chrome
and shall not make root docShell act as chrome. We previously had
"full-screen-api.content-only" pref set to "true".

Signed-off-by: Raine Makelainen <raine.makelainen@jolla.com>
---
dom/base/nsGlobalWindow.cpp | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp
index 080b0302f021..c90f4271765f 100644
--- a/dom/base/nsGlobalWindow.cpp
+++ b/dom/base/nsGlobalWindow.cpp
@@ -6032,10 +6032,16 @@ nsGlobalWindow::SetFullscreenInternal(FullscreenReason aReason,
if (rootItem != mDocShell)
return window->SetFullscreenInternal(aReason, aFullScreen, aHMD);

+ // We don't have chrome from doc shell point of view. This commit
+ // sha1 3116f3bf53df offends fullscreen API to work without chrome
+ // and shall not make root docShell act as chrome. We previously had
+ // "full-screen-api.content-only" pref set to "true".
+#if 0
// make sure we don't try to set full screen on a non-chrome window,
// which might happen in embedding world
if (mDocShell->ItemType() != nsIDocShellTreeItem::typeChrome)
return NS_ERROR_FAILURE;
+#endif

// If we are already in full screen mode, just return.
if (mFullScreen == aFullScreen)
--
2.20.1

2 changes: 2 additions & 0 deletions rpm/xulrunner-qt5.spec
Expand Up @@ -55,6 +55,7 @@ Patch8: 0008-Adapt-LoginManager-to-EmbedLite.-Fixes-JB21980.patch
Patch9: 0009-Bug-1253215-Initialize-RequestSyncService-only-if-it.patch
Patch10: 0010-Don-t-print-errors-from-DataReportingService.patch
Patch11: 0011-Don-t-try-to-access-undefined-app-list-of-AppsServic.patch
Patch12: 0012-xulrunner-Make-fullscreen-enabling-work-as-used-to-w.patch
BuildRequires: pkgconfig(Qt5Quick)
BuildRequires: pkgconfig(Qt5Network)
BuildRequires: pkgconfig(pango)
Expand Down Expand Up @@ -154,6 +155,7 @@ Tests and misc files for xulrunner.
%patch9 -p1
%patch10 -p1
%patch11 -p1
%patch12 -p1

mkdir -p "%BUILD_DIR"
cp -rf "%BASE_CONFIG" "%BUILD_DIR"/mozconfig
Expand Down

0 comments on commit 54b9d2b

Please sign in to comment.