about summary refs log tree commit diff
path: root/pkgs/aszlig/firefox/mute-by-default.patch
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/aszlig/firefox/mute-by-default.patch')
-rw-r--r--pkgs/aszlig/firefox/mute-by-default.patch19
1 files changed, 11 insertions, 8 deletions
diff --git a/pkgs/aszlig/firefox/mute-by-default.patch b/pkgs/aszlig/firefox/mute-by-default.patch
index 67e6bce4..337ccf0f 100644
--- a/pkgs/aszlig/firefox/mute-by-default.patch
+++ b/pkgs/aszlig/firefox/mute-by-default.patch
@@ -1,11 +1,15 @@
 diff --git a/dom/media/autoplay/AutoplayPolicy.cpp b/dom/media/autoplay/AutoplayPolicy.cpp
-index 77c53ce58acd..688af016a72c 100644
+index 8da0e60ead..90991bf1dc 100644
 --- a/dom/media/autoplay/AutoplayPolicy.cpp
 +++ b/dom/media/autoplay/AutoplayPolicy.cpp
-@@ -78,15 +78,6 @@ static bool IsWindowAllowedToPlay(nsPIDOMWindowInner* aWindow) {
-     return true;
-   }
+@@ -69,18 +69,6 @@ static uint32_t SiteAutoplayPerm(nsPIDOMWindowInner* aWindow) {
+ }
  
+ static bool IsWindowAllowedToPlayByUserGesture(nsPIDOMWindowInner* aWindow) {
+-  if (!aWindow) {
+-    return false;
+-  }
+-
 -  WindowContext* topContext =
 -      aWindow->GetBrowsingContext()->GetTopWindowContext();
 -  if (topContext && topContext->HasBeenUserGestureActivated()) {
@@ -14,7 +18,6 @@ index 77c53ce58acd..688af016a72c 100644
 -        "gesture.");
 -    return true;
 -  }
--
-   Document* currentDoc = aWindow->GetExtantDoc();
-   if (!currentDoc) {
-     return false;
+   return false;
+ }
+