Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 10 Feb 2018 00:42:01 +0000 (UTC)
From:      Jan Beich <jbeich@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org
Subject:   svn commit: r461353 - in branches/2018Q1/www/waterfox: . files
Message-ID:  <201802100042.w1A0g1n8090497@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: jbeich
Date: Sat Feb 10 00:42:01 2018
New Revision: 461353
URL: https://svnweb.freebsd.org/changeset/ports/461353

Log:
  MFH: r461350
  
  www/waterfox: apply more FF57 fixes
  
  Approved by:	ports-secteam blanket

Added:
  branches/2018Q1/www/waterfox/files/patch-bug1338764
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1338764
  branches/2018Q1/www/waterfox/files/patch-bug1352453
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1352453
  branches/2018Q1/www/waterfox/files/patch-bug1360603
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1360603
  branches/2018Q1/www/waterfox/files/patch-bug1370508
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1370508
  branches/2018Q1/www/waterfox/files/patch-bug1377158
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1377158
  branches/2018Q1/www/waterfox/files/patch-bug1388319
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1388319
  branches/2018Q1/www/waterfox/files/patch-bug1394146
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1394146
  branches/2018Q1/www/waterfox/files/patch-bug1397671
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1397671
  branches/2018Q1/www/waterfox/files/patch-bug1398983
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1398983
  branches/2018Q1/www/waterfox/files/patch-bug1400540
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1400540
  branches/2018Q1/www/waterfox/files/patch-bug1401416
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1401416
  branches/2018Q1/www/waterfox/files/patch-bug1401909
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1401909
  branches/2018Q1/www/waterfox/files/patch-bug1401992
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1401992
  branches/2018Q1/www/waterfox/files/patch-bug1402094
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1402094
  branches/2018Q1/www/waterfox/files/patch-bug1402205
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1402205
  branches/2018Q1/www/waterfox/files/patch-bug1402366
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1402366
  branches/2018Q1/www/waterfox/files/patch-bug1402469
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1402469
  branches/2018Q1/www/waterfox/files/patch-bug1402681
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1402681
  branches/2018Q1/www/waterfox/files/patch-bug1403282
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1403282
  branches/2018Q1/www/waterfox/files/patch-bug1403465
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1403465
  branches/2018Q1/www/waterfox/files/patch-bug1403473
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1403473
  branches/2018Q1/www/waterfox/files/patch-bug1403592
     - copied unchanged from r461350, head/www/waterfox/files/patch-bug1403592
Modified:
  branches/2018Q1/www/waterfox/Makefile
Directory Properties:
  branches/2018Q1/   (props changed)

Modified: branches/2018Q1/www/waterfox/Makefile
==============================================================================
--- branches/2018Q1/www/waterfox/Makefile	Sat Feb 10 00:41:41 2018	(r461352)
+++ branches/2018Q1/www/waterfox/Makefile	Sat Feb 10 00:42:01 2018	(r461353)
@@ -2,7 +2,7 @@
 
 PORTNAME=	waterfox
 DISTVERSION=	56.0.4
-PORTREVISION=	2
+PORTREVISION=	3
 CATEGORIES=	www ipv6
 
 MAINTAINER=	jbeich@FreeBSD.org

Copied: branches/2018Q1/www/waterfox/files/patch-bug1338764 (from r461350, head/www/waterfox/files/patch-bug1338764)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1338764	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1338764)
@@ -0,0 +1,120 @@
+commit 0e98738d78b9
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Mon Jul 17 15:10:50 2017 +1000
+
+    Bug 1338764 part 1 - Use const rather than enum for context flags of nsStyleSVG. r=manishearth
+    
+    MozReview-Commit-ID: KzORnfVXgLJ
+    
+    --HG--
+    extra : rebase_source : 365842d6e6fda4b35a5932272773a3d88bfc04c6
+---
+ layout/style/nsStyleStruct.h | 22 +++++++++++++---------
+ 1 file changed, 13 insertions(+), 9 deletions(-)
+
+diff --git layout/style/nsStyleStruct.h layout/style/nsStyleStruct.h
+index 59833e37f3bb..eccc02380f7e 100644
+--- layout/style/nsStyleStruct.h
++++ layout/style/nsStyleStruct.h
+@@ -3603,15 +3603,19 @@ private:
+   // Flags to represent the use of context-fill and context-stroke
+   // for fill-opacity or stroke-opacity, and context-value for stroke-dasharray,
+   // stroke-dashoffset and stroke-width.
+-  enum {
+-    FILL_OPACITY_SOURCE_MASK   = 0x03,  // fill-opacity: context-{fill,stroke}
+-    STROKE_OPACITY_SOURCE_MASK = 0x0C,  // stroke-opacity: context-{fill,stroke}
+-    STROKE_DASHARRAY_CONTEXT   = 0x10,  // stroke-dasharray: context-value
+-    STROKE_DASHOFFSET_CONTEXT  = 0x20,  // stroke-dashoffset: context-value
+-    STROKE_WIDTH_CONTEXT       = 0x40,  // stroke-width: context-value
+-    FILL_OPACITY_SOURCE_SHIFT   = 0,
+-    STROKE_OPACITY_SOURCE_SHIFT = 2,
+-  };
++
++  // fill-opacity: context-{fill,stroke}
++  static const uint8_t FILL_OPACITY_SOURCE_MASK   = 0x03;
++  // stroke-opacity: context-{fill,stroke}
++  static const uint8_t STROKE_OPACITY_SOURCE_MASK = 0x0C;
++  // stroke-dasharray: context-value
++  static const uint8_t STROKE_DASHARRAY_CONTEXT   = 0x10;
++  // stroke-dashoffset: context-value
++  static const uint8_t STROKE_DASHOFFSET_CONTEXT  = 0x20;
++  // stroke-width: context-value
++  static const uint8_t STROKE_WIDTH_CONTEXT       = 0x40;
++  static const uint8_t FILL_OPACITY_SOURCE_SHIFT   = 0;
++  static const uint8_t STROKE_OPACITY_SOURCE_SHIFT = 2;
+ 
+   uint8_t          mContextFlags;     // [inherited]
+ };
+
+commit 63d6f06939ee
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Tue Aug 1 16:05:04 2017 +1000
+
+    Bug 1338764 part 2 - Add context-{fill,stroke}-opacity support to {fill,stroke}-opacity. r=manishearth
+    
+    MozReview-Commit-ID: HzUHmZb8ICl
+    
+    --HG--
+    extra : rebase_source : b8746c4d9d4cfc3abe6645f583dc08d0f7c75341
+---
+ layout/style/ServoBindings.toml | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git layout/style/ServoBindings.toml layout/style/ServoBindings.toml
+index 5e09c24eb0e3..6d8e979fdc1f 100644
+--- layout/style/ServoBindings.toml
++++ layout/style/ServoBindings.toml
+@@ -232,6 +232,7 @@ whitelist-types = [
+     "nsStylePadding",
+     "nsStylePosition",
+     "nsStyleSVG",
++    "nsStyleSVGOpacitySource",
+     "nsStyleSVGPaint",
+     "nsStyleSVGReset",
+     "nsStyleTable",
+@@ -458,6 +459,7 @@ structs-types = [
+     "nsStylePosition",
+     "nsStyleQuoteValues",
+     "nsStyleSVG",
++    "nsStyleSVGOpacitySource",
+     "nsStyleSVGPaint",
+     "nsStyleSVGReset",
+     "nsStyleTable",
+
+commit 03e036aff26d
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Tue Aug 1 16:38:27 2017 +1000
+
+    Bug 1338764 part 3 - Update test expectations. r=manishearth
+    
+    MozReview-Commit-ID: HzN5WP210G7
+    
+    --HG--
+    extra : rebase_source : c3585958cb5159a242515a80f226e43f506319d8
+---
+ layout/style/test/stylo-failures.md | 8 --------
+ 1 file changed, 8 deletions(-)
+
+diff --git layout/style/test/stylo-failures.md layout/style/test/stylo-failures.md
+index 0509269b1334..d69fa898d9be 100644
+--- layout/style/test/stylo-failures.md
++++ layout/style/test/stylo-failures.md
+@@ -34,10 +34,6 @@ to mochitest command.
+ * Animation support:
+   * SMIL Animation
+     * test_restyles_in_smil_animation.html [2]
+-* Unsupported values
+-  * SVG-in-OpenType values not supported servo/servo#15211 bug 1338764
+-    * test_value_storage.html `context-` [7]
+-    * test_bug798843_pref.html [3]
+ * Incorrect serialization
+   * place-{content,items,self} shorthands bug 1363971
+     * test_align_shorthand_serialization.html [6]
+@@ -58,7 +54,3 @@ to mochitest command.
+ ## Unknown / Unsure
+ 
+ ## Ignore
+-
+-* Ignore for now since should be mostly identical to test_value_storage.html
+-  * test_value_cloning.html [*]
+-  * test_value_computation.html [*]

Copied: branches/2018Q1/www/waterfox/files/patch-bug1352453 (from r461350, head/www/waterfox/files/patch-bug1352453)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1352453	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1352453)
@@ -0,0 +1,27 @@
+commit 96ac0874dc2e
+Author: Ethan Lin <ethlin@mozilla.com>
+Date:   Sat Sep 23 15:06:07 2017 +0800
+
+    Bug 1352453 - Check image dimension when computing border space size. r=heycam, a=sledru
+    
+    MozReview-Commit-ID: LQcf9UGyUUq
+    
+    --HG--
+    extra : source : 6974ff079df11b3e7dc46e2df754149321e3f3aa
+---
+ layout/painting/nsCSSRendering.cpp | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git layout/painting/nsCSSRendering.cpp layout/painting/nsCSSRendering.cpp
+index 89760f33229b..55051c9ac376 100644
+--- layout/painting/nsCSSRendering.cpp
++++ layout/painting/nsCSSRendering.cpp
+@@ -3068,7 +3068,7 @@ nsCSSRendering::ComputeBorderSpacedRepeatSize(nscoord aImageDimension,
+                                               nscoord aAvailableSpace,
+                                               nscoord& aSpace)
+ {
+-  int32_t count = aAvailableSpace / aImageDimension;
++  int32_t count = aImageDimension ? (aAvailableSpace / aImageDimension) : 0;
+   aSpace = (aAvailableSpace - aImageDimension * count) / (count + 1);
+   return aSpace + aImageDimension;
+ }

Copied: branches/2018Q1/www/waterfox/files/patch-bug1360603 (from r461350, head/www/waterfox/files/patch-bug1360603)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1360603	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1360603)
@@ -0,0 +1,101 @@
+commit b5d0a61cd5df
+Author: Amy Chung <amchung@mozilla.com>
+Date:   Sun Sep 24 00:38:32 2017 +0800
+
+    Bug 1360603 - Mark the save channel as throttleable. r=baku, a=sledru
+    
+    --HG--
+    extra : source : d409c2ac7d88b7193e8369aa3359a9368e1135b3
+---
+ dom/webbrowserpersist/nsWebBrowserPersist.cpp | 7 +++++++
+ 1 file changed, 7 insertions(+)
+
+diff --git dom/webbrowserpersist/nsWebBrowserPersist.cpp dom/webbrowserpersist/nsWebBrowserPersist.cpp
+index a9b37ed281ca..a5971216d8b4 100644
+--- dom/webbrowserpersist/nsWebBrowserPersist.cpp
++++ dom/webbrowserpersist/nsWebBrowserPersist.cpp
+@@ -13,6 +13,7 @@
+ #include "nsAutoPtr.h"
+ #include "nsNetCID.h"
+ #include "nsNetUtil.h"
++#include "nsIClassOfService.h"
+ #include "nsIInterfaceRequestorUtils.h"
+ #include "nsILoadContext.h"
+ #include "nsIPrivateBrowsingChannel.h"
+@@ -1497,6 +1498,12 @@ nsresult nsWebBrowserPersist::SaveChannelInternal(
+         return StartUpload(bufferedInputStream, aFile, contentType);
+     }
+ 
++    // Mark save channel as throttleable.
++    nsCOMPtr<nsIClassOfService> cos(do_QueryInterface(aChannel));
++    if (cos) {
++      cos->AddClassFlags(nsIClassOfService::Throttleable);
++    }
++
+     // Read from the input channel
+     nsresult rv = NS_MaybeOpenChannelUsingAsyncOpen2(aChannel, this);
+     if (rv == NS_ERROR_NO_CONTENT)
+commit 1e11071bc4f9
+Author: Amy Chung <amchung@mozilla.com>
+Date:   Sun Sep 24 00:56:04 2017 +0800
+
+    Bug 1360603 - Confirm the Throttleable flag on browser_saveImageURL.js. r=baku, a=sledru
+    
+    --HG--
+    extra : source : 6d7610f4d26d76878b83b1f2489a96116c2bdf15
+---
+ toolkit/content/contentAreaUtils.js                   |  4 ++++
+ toolkit/content/tests/browser/browser_saveImageURL.js | 18 ++++++++++++++++++
+ 2 files changed, 22 insertions(+)
+
+diff --git toolkit/content/contentAreaUtils.js toolkit/content/contentAreaUtils.js
+index fba70c91c8a3..1492b4c1654c 100644
+--- toolkit/content/contentAreaUtils.js
++++ toolkit/content/contentAreaUtils.js
+@@ -1264,6 +1264,10 @@ function openURL(aURL) {
+       loadUsingSystemPrincipal: true
+     });
+ 
++    if (channel) {
++      channel.channelIsForDownload = true;
++    }
++
+     var uriLoader = Components.classes["@mozilla.org/uriloader;1"]
+                               .getService(Components.interfaces.nsIURILoader);
+     uriLoader.openURI(channel,
+diff --git toolkit/content/tests/browser/browser_saveImageURL.js toolkit/content/tests/browser/browser_saveImageURL.js
+index fe10482f35dc..0d9c872921c2 100644
+--- toolkit/content/tests/browser/browser_saveImageURL.js
++++ toolkit/content/tests/browser/browser_saveImageURL.js
+@@ -37,6 +37,15 @@ add_task(async function preferred_API() {
+     });
+ 
+     saveImageURL(url, "image.jpg", null, true, false, null, null, null, null, false);
++    let channel = content.document.docShell.currentDocumentChannel;
++    if (channel) {
++      ok(true, channel.QueryInterface(Ci.nsIHttpChannelInternal)
++                      .channelIsForDownload);
++
++      // Throttleable is the only class flag assigned to downloads.
++      ok(channel.QueryInterface(Ci.nsIClassOfService).classFlags,
++         Ci.nsIClassOfService.Throttleable);
++    }
+     await waitForFilePicker();
+   });
+ });
+@@ -64,6 +73,15 @@ add_task(async function deprecated_API() {
+     // pass the XUL document instead to test this interface.
+     let doc = document;
+ 
++    let channel = content.document.docShell.currentDocumentChannel;
++    if (channel) {
++      ok(true, channel.QueryInterface(Ci.nsIHttpChannelInternal)
++                      .channelIsForDownload);
++
++      // Throttleable is the only class flag assigned to downloads.
++      ok(channel.QueryInterface(Ci.nsIClassOfService).classFlags,
++         Ci.nsIClassOfService.Throttleable);
++    }
+     saveImageURL(url, "image.jpg", null, true, false, null, doc, null, null);
+     await waitForFilePicker();
+   });

Copied: branches/2018Q1/www/waterfox/files/patch-bug1370508 (from r461350, head/www/waterfox/files/patch-bug1370508)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1370508	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1370508)
@@ -0,0 +1,79 @@
+commit c40f44ef9b35
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Wed Aug 9 19:57:33 2017 +1000
+
+    Bug 1370508 - Enable stylo on generic XML documents. r=heycam
+    
+    MozReview-Commit-ID: 4XQ9RPQ7oa1
+    
+    --HG--
+    extra : rebase_source : 74e411e2280e818fc1fbd2efda677565cfa2f8b6
+---
+ dom/base/nsDocument.cpp                                           | 3 +--
+ layout/reftests/w3c-css/failures.list                             | 4 ++++
+ layout/reftests/w3c-css/received/reftest.list                     | 2 +-
+ layout/xul/crashtests/crashtests.list                             | 2 +-
+ testing/web-platform/meta/css/css-namespaces-3/syntax-013.xml.ini | 4 ++++
+ 5 files changed, 11 insertions(+), 4 deletions(-)
+
+diff --git dom/base/nsDocument.cpp dom/base/nsDocument.cpp
+index 2a01e6ec3a67..66a860ff3257 100644
+--- dom/base/nsDocument.cpp
++++ dom/base/nsDocument.cpp
+@@ -13293,8 +13293,7 @@ nsIDocument::UpdateStyleBackendType()
+       mStyleBackendType = StyleBackendType::Servo;
+     } else if (!mDocumentContainer) {
+       NS_WARNING("stylo: No docshell yet, assuming Gecko style system");
+-    } else if ((IsHTMLOrXHTML() || IsSVGDocument()) &&
+-               IsContentDocument()) {
++    } else if (!IsXULDocument() && IsContentDocument()) {
+       // Disable stylo for about: pages other than about:blank, since
+       // they tend to use unsupported selectors like XUL tree pseudos.
+       bool isAbout = false;
+diff --git layout/reftests/w3c-css/failures.list layout/reftests/w3c-css/failures.list
+index 966f69ff9ae0..1560f4ad673d 100644
+--- layout/reftests/w3c-css/failures.list
++++ layout/reftests/w3c-css/failures.list
+@@ -314,3 +314,7 @@ fuzzy(255,2808) css-multicol-1/multicol-rule-large-001.xht
+ fails-if(!styloVsGecko) css-multicol-1/multicol-fill-auto-block-children-001.xht
+ fails-if(!styloVsGecko) css-multicol-1/multicol-fill-auto-block-children-002.xht
+ fails-if(!styloVsGecko) css-multicol-1/multicol-span-all-block-sibling-003.xht
++
++#### CSS Namespaces 3 ##############################################
++
++fails-if(stylo||styloVsGecko) css-namespaces-3/syntax-013.xml
+diff --git layout/reftests/w3c-css/received/reftest.list layout/reftests/w3c-css/received/reftest.list
+index eb6151266acd..128d1fcf8121 100644
+--- layout/reftests/w3c-css/received/reftest.list
++++ layout/reftests/w3c-css/received/reftest.list
+@@ -205,7 +205,7 @@ fails-if(!styloVsGecko) == css-multicol-1/multicol-zero-height-001.xht css-multi
+ == css-namespaces-3/syntax-010.xml css-namespaces-3/reftest/ref-lime-3.xml
+ == css-namespaces-3/syntax-011.xml css-namespaces-3/reftest/ref-lime-6.xml
+ == css-namespaces-3/syntax-012.xml css-namespaces-3/reftest/ref-lime-3.xml
+-== css-namespaces-3/syntax-013.xml css-namespaces-3/reftest/ref-lime-5.xml
++fails-if(stylo||styloVsGecko) == css-namespaces-3/syntax-013.xml css-namespaces-3/reftest/ref-lime-5.xml # bug 1388911
+ == css-namespaces-3/syntax-014.xml css-namespaces-3/reftest/ref-lime-3.xml
+ == css-namespaces-3/syntax-015.xml css-namespaces-3/reftest/ref-lime-1.xml
+ fails-if(!styloVsGecko) == css-values-3/attr-color-invalid-cast.html css-values-3/reference/200-200-green.html
+diff --git layout/xul/crashtests/crashtests.list layout/xul/crashtests/crashtests.list
+index c1445cb5ec7a..e60af3526383 100644
+--- layout/xul/crashtests/crashtests.list
++++ layout/xul/crashtests/crashtests.list
+@@ -1,6 +1,6 @@
+ load 131008-1.xul
+ load 137216-1.xul
+-load 140218-1.xml
++asserts-if(stylo,3) load 140218-1.xml
+ load 151826-1.xul
+ load 168724-1.xul
+ load 189814-1.xul
+diff --git testing/web-platform/meta/css/css-namespaces-3/syntax-013.xml.ini testing/web-platform/meta/css/css-namespaces-3/syntax-013.xml.ini
+new file mode 100644
+index 000000000000..b034ccf978f5
+--- /dev/null
++++ testing/web-platform/meta/css/css-namespaces-3/syntax-013.xml.ini
+@@ -0,0 +1,4 @@
++[syntax-013.xml]
++  type: reftest
++  expected:
++    if stylo: FAIL

Copied: branches/2018Q1/www/waterfox/files/patch-bug1377158 (from r461350, head/www/waterfox/files/patch-bug1377158)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1377158	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1377158)
@@ -0,0 +1,285 @@
+commit 9e809e01c262
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Thu Aug 3 11:24:55 2017 +1000
+
+    Bug 1377158 - (Part 1) Set style backend to stylo when SVG is used as an image. r=heycam
+    
+    MozReview-Commit-ID: 9FnA8X84h87
+    
+    --HG--
+    extra : rebase_source : 49a6140c4c78c35f755710934c798ce46dafa213
+---
+ dom/base/nsDocument.cpp | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git dom/base/nsDocument.cpp dom/base/nsDocument.cpp
+index 3585a7e222df..b4773160af92 100644
+--- dom/base/nsDocument.cpp
++++ dom/base/nsDocument.cpp
+@@ -13219,7 +13219,10 @@ nsIDocument::UpdateStyleBackendType()
+ 
+ #ifdef MOZ_STYLO
+   if (nsLayoutUtils::StyloEnabled()) {
+-    if (!mDocumentContainer) {
++    if (IsBeingUsedAsImage()) {
++      // Enable stylo for SVG-as-image.
++      mStyleBackendType = StyleBackendType::Servo;
++    } else if (!mDocumentContainer) {
+       NS_WARNING("stylo: No docshell yet, assuming Gecko style system");
+     } else if ((IsHTMLOrXHTML() || IsSVGDocument()) &&
+                IsContentDocument()) {
+
+commit e418f1ccf520
+Author: KuoE0 <kuoe0.tw@gmail.com>
+Date:   Mon Jul 24 11:51:20 2017 +0800
+
+    Bug 1377158 - (Part 2) Add the info of StyloEnabled() to hash function to make reftests of styloVsGecko get the correct caches. r=heycam
+    
+    MozReview-Commit-ID: 7cyXheHQ7Ot
+    
+    --HG--
+    extra : rebase_source : 4a92de63228cb2a138d95d8f366b39122dbdc05e
+---
+ image/ImageCacheKey.cpp | 20 ++++++++++++++++----
+ image/ImageCacheKey.h   |  7 ++++++-
+ 2 files changed, 22 insertions(+), 5 deletions(-)
+
+diff --git image/ImageCacheKey.cpp image/ImageCacheKey.cpp
+index c3327155c1cd..2dfdc7c763cc 100644
+--- image/ImageCacheKey.cpp
++++ image/ImageCacheKey.cpp
+@@ -8,6 +8,7 @@
+ #include "mozilla/Move.h"
+ #include "ImageURL.h"
+ #include "nsHostObjectProtocolHandler.h"
++#include "nsLayoutUtils.h"
+ #include "nsString.h"
+ #include "mozilla/dom/File.h"
+ #include "mozilla/dom/workers/ServiceWorkerManager.h"
+@@ -53,6 +54,7 @@ ImageCacheKey::ImageCacheKey(nsIURI* aURI,
+   , mOriginAttributes(aAttrs)
+   , mControlledDocument(GetControlledDocumentToken(aDocument))
+   , mIsChrome(URISchemeIs(mURI, "chrome"))
++  , mIsStyloEnabled(nsLayoutUtils::StyloEnabled())
+ {
+   NS_ENSURE_SUCCESS_VOID(aRv);
+ 
+@@ -62,7 +64,8 @@ ImageCacheKey::ImageCacheKey(nsIURI* aURI,
+     mBlobSerial = BlobSerial(mURI);
+   }
+ 
+-  mHash = ComputeHash(mURI, mBlobSerial, mOriginAttributes, mControlledDocument);
++  mHash = ComputeHash(mURI, mBlobSerial, mOriginAttributes, mControlledDocument,
++                      mIsStyloEnabled);
+ }
+ 
+ ImageCacheKey::ImageCacheKey(ImageURL* aURI,
+@@ -72,6 +75,7 @@ ImageCacheKey::ImageCacheKey(ImageURL* aURI,
+   , mOriginAttributes(aAttrs)
+   , mControlledDocument(GetControlledDocumentToken(aDocument))
+   , mIsChrome(URISchemeIs(mURI, "chrome"))
++  , mIsStyloEnabled(nsLayoutUtils::StyloEnabled())
+ {
+   MOZ_ASSERT(aURI);
+ 
+@@ -79,7 +83,8 @@ ImageCacheKey::ImageCacheKey(ImageURL* aURI,
+     mBlobSerial = BlobSerial(mURI);
+   }
+ 
+-  mHash = ComputeHash(mURI, mBlobSerial, mOriginAttributes, mControlledDocument);
++  mHash = ComputeHash(mURI, mBlobSerial, mOriginAttributes, mControlledDocument,
++                      mIsStyloEnabled);
+ }
+ 
+ ImageCacheKey::ImageCacheKey(const ImageCacheKey& aOther)
+@@ -89,6 +94,7 @@ ImageCacheKey::ImageCacheKey(const ImageCacheKey& aOther)
+   , mControlledDocument(aOther.mControlledDocument)
+   , mHash(aOther.mHash)
+   , mIsChrome(aOther.mIsChrome)
++  , mIsStyloEnabled(aOther.mIsStyloEnabled)
+ { }
+ 
+ ImageCacheKey::ImageCacheKey(ImageCacheKey&& aOther)
+@@ -98,11 +104,15 @@ ImageCacheKey::ImageCacheKey(ImageCacheKey&& aOther)
+   , mControlledDocument(aOther.mControlledDocument)
+   , mHash(aOther.mHash)
+   , mIsChrome(aOther.mIsChrome)
++  , mIsStyloEnabled(aOther.mIsStyloEnabled)
+ { }
+ 
+ bool
+ ImageCacheKey::operator==(const ImageCacheKey& aOther) const
+ {
++  if (mIsStyloEnabled != aOther.mIsStyloEnabled) {
++    return false;
++  }
+   // Don't share the image cache between a controlled document and anything else.
+   if (mControlledDocument != aOther.mControlledDocument) {
+     return false;
+@@ -132,7 +142,8 @@ ImageCacheKey::Spec() const
+ ImageCacheKey::ComputeHash(ImageURL* aURI,
+                            const Maybe<uint64_t>& aBlobSerial,
+                            const OriginAttributes& aAttrs,
+-                           void* aControlledDocument)
++                           void* aControlledDocument,
++                           bool aIsStyloEnabled)
+ {
+   // Since we frequently call Hash() several times in a row on the same
+   // ImageCacheKey, as an optimization we compute our hash once and store it.
+@@ -142,7 +153,8 @@ ImageCacheKey::ComputeHash(ImageURL* aURI,
+   aAttrs.CreateSuffix(suffix);
+ 
+   return AddToHash(0, aURI->ComputeHash(aBlobSerial),
+-                   HashString(suffix), HashString(ptr));
++                   HashString(suffix), HashString(ptr),
++                   aIsStyloEnabled);
+ }
+ 
+ /* static */ void*
+diff --git image/ImageCacheKey.h image/ImageCacheKey.h
+index c5acd0ea495e..6d676ccb6338 100644
+--- image/ImageCacheKey.h
++++ image/ImageCacheKey.h
+@@ -58,7 +58,8 @@ private:
+   static PLDHashNumber ComputeHash(ImageURL* aURI,
+                                    const Maybe<uint64_t>& aBlobSerial,
+                                    const OriginAttributes& aAttrs,
+-                                   void* aControlledDocument);
++                                   void* aControlledDocument,
++                                   bool aIsStyloEnabled);
+   static void* GetControlledDocumentToken(nsIDocument* aDocument);
+ 
+   RefPtr<ImageURL> mURI;
+@@ -67,6 +68,10 @@ private:
+   void* mControlledDocument;
+   PLDHashNumber mHash;
+   bool mIsChrome;
++  // To prevent the reftests of styloVsGecko taking the same image cache after
++  // refreshing, we need to store different caches of stylo and gecko. So, we
++  // also consider the info of StyloEnabled() in ImageCacheKey.
++  bool mIsStyloEnabled;
+ };
+ 
+ } // namespace image
+
+commit c95ed14053c7
+Author: KuoE0 <kuoe0.tw@gmail.com>
+Date:   Thu Jul 27 14:06:54 2017 +0800
+
+    Bug 1377158 - (Part 3) Update the expectation of test cases. r=bholley,heycam
+    
+    MozReview-Commit-ID: K3gmTudkzol
+    
+    --HG--
+    extra : rebase_source : 32ba6ceb37fa2f29cde8d2534d73108e87dfa406
+---
+ layout/reftests/css-break/reftest.list        | 2 +-
+ layout/reftests/svg/as-image/reftest.list     | 2 +-
+ layout/reftests/table-background/reftest.list | 8 ++++----
+ 3 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git layout/reftests/css-break/reftest.list layout/reftests/css-break/reftest.list
+index 4364cf7d93fc..54cfbcbbeefc 100644
+--- layout/reftests/css-break/reftest.list
++++ layout/reftests/css-break/reftest.list
+@@ -2,7 +2,7 @@ default-preferences pref(layout.css.box-decoration-break.enabled,true)
+ 
+ == box-decoration-break-1.html box-decoration-break-1-ref.html
+ fuzzy(1,20) fuzzy-if(skiaContent,1,700) fuzzy-if(webrender,4-4,3273-3273) == box-decoration-break-with-inset-box-shadow-1.html box-decoration-break-with-inset-box-shadow-1-ref.html
+-fuzzy(16,460) fuzzy-if(Android,10,3673) fuzzy-if(skiaContent,57,374) == box-decoration-break-with-outset-box-shadow-1.html box-decoration-break-with-outset-box-shadow-1-ref.html
++fuzzy(16,460) fuzzy-if(Android,10,3673) fuzzy-if(skiaContent,57,374) fuzzy-if(styloVsGecko,1,420) == box-decoration-break-with-outset-box-shadow-1.html box-decoration-break-with-outset-box-shadow-1-ref.html # Bug 1386543
+ random-if(!gtkWidget) HTTP(..) == box-decoration-break-border-image.html box-decoration-break-border-image-ref.html
+ == box-decoration-break-block-border-padding.html box-decoration-break-block-border-padding-ref.html
+ == box-decoration-break-block-margin.html box-decoration-break-block-margin-ref.html
+diff --git layout/reftests/svg/as-image/reftest.list layout/reftests/svg/as-image/reftest.list
+index d5feb66693ad..acff18d18b50 100644
+--- layout/reftests/svg/as-image/reftest.list
++++ layout/reftests/svg/as-image/reftest.list
+@@ -58,7 +58,7 @@ fuzzy(1,2) fuzzy-if(azureSkia,1,40000) == canvas-drawImage-alpha-2.html canvas-d
+ # context-fill:
+ == context-fill-01.html blue100x100-ref.html
+ test-pref(svg.context-properties.content.enabled,true) == context-fill-01.html lime100x100-ref.html
+-== context-fill-02.html transparent100x100-w-border-ref.html
++fails-if(styloVsGecko||stylo) == context-fill-02.html transparent100x100-w-border-ref.html # Bug 1380590
+ test-pref(svg.context-properties.content.enabled,true) == context-fill-02.html lime100x100-w-border-ref.html
+ test-pref(svg.context-properties.content.enabled,true) == context-fill-03.html lime100x100-50pct-ref.html
+ # fuzz because on win8 the r & b components are off by one
+diff --git layout/reftests/table-background/reftest.list layout/reftests/table-background/reftest.list
+index d8a138112527..df2f629d0d7f 100644
+--- layout/reftests/table-background/reftest.list
++++ layout/reftests/table-background/reftest.list
+@@ -1,11 +1,11 @@
+ # these could be moved to crashtests
+ != backgr_border-table-cell.html empty.html
+-!= backgr_border-table-column-group.html empty.html
++fuzzy-if(styloVsGecko,5,330) != backgr_border-table-column-group.html empty.html # Bug 1386543
+ # This seems to be caused by bug 527825
+-asserts-if(gtkWidget,0-12) != backgr_border-table-column.html empty.html
++fuzzy-if(styloVsGecko,5,561) asserts-if(gtkWidget,0-12) != backgr_border-table-column.html empty.html # Bug 1386543
+ asserts-if(gtkWidget,0-6) != backgr_border-table-quirks.html empty.html
+-!= backgr_border-table-row-group.html empty.html
+-!= backgr_border-table-row.html empty.html
++fuzzy-if(styloVsGecko,1,168) != backgr_border-table-row-group.html empty.html # Bug 1386543
++fuzzy-if(styloVsGecko,1,168) != backgr_border-table-row.html empty.html # Bug 1386543
+ != backgr_border-table.html empty.html
+ != backgr_fixed-bg.html empty.html
+ != backgr_index.html empty.html
+
+commit dd7cb82fb7b5
+Author: KuoE0 <kuoe0.tw@gmail.com>
+Date:   Fri Jul 28 00:23:05 2017 +0800
+
+    Bug 1377158 - (Part 4) Reduce the assertion cost to check reconstruction frame hint. r=bholley,heycam
+    
+    The original assertion took too long time to check nsStyleChangeList. It
+    caused the test case with many elements timed-out and failed.
+    
+    MozReview-Commit-ID: FpNZvdQFTtR
+    
+    --HG--
+    extra : rebase_source : c68072448061c4dcc8399131924cf718a5e53700
+---
+ layout/base/nsStyleChangeList.cpp | 30 +++++++++++++++++++-----------
+ 1 file changed, 19 insertions(+), 11 deletions(-)
+
+diff --git layout/base/nsStyleChangeList.cpp layout/base/nsStyleChangeList.cpp
+index 6f68cded3814..af6256f46c22 100644
+--- layout/base/nsStyleChangeList.cpp
++++ layout/base/nsStyleChangeList.cpp
+@@ -41,17 +41,25 @@ nsStyleChangeList::AppendChange(nsIFrame* aFrame, nsIContent* aContent, nsChange
+              (aHint & nsChangeHint_NeedReflow),
+              "Reflow hint bits set without actually asking for a reflow");
+ 
+-  // If Servo fires reconstruct at a node, it is the only change hint fired at
+-  // that node.
+-  if (IsServo()) {
+-    for (size_t i = 0; i < Length(); ++i) {
+-      MOZ_ASSERT(!aContent || !((aHint | (*this)[i].mHint) & nsChangeHint_ReconstructFrame) ||
+-                 (*this)[i].mContent != aContent);
+-    }
+-  } else {
+-    // Filter out all other changes for same content for Gecko (Servo asserts against this
+-    // case above).
+-    if (aContent && (aHint & nsChangeHint_ReconstructFrame)) {
++  if (aContent && (aHint & nsChangeHint_ReconstructFrame)) {
++    // If Servo fires reconstruct at a node, it is the only change hint fired at
++    // that node.
++    if (IsServo()) {
++      // Note: Because we check whether |aHint| is a reconstruct above (which is
++      // necessary to avoid debug test timeouts on certain crashtests), this check
++      // will not find bugs where we add a non-reconstruct hint for an element after
++      // adding a reconstruct. This is ok though, since ProcessRestyledFrames will
++      // handle that case via mDestroyedFrames.
++      for (size_t i = 0; i < Length(); ++i) {
++        MOZ_ASSERT(aContent != (*this)[i].mContent ||
++                   !((*this)[i].mHint & nsChangeHint_ReconstructFrame),
++                   "Should not append a non-ReconstructFrame hint after \
++                   appending a ReconstructFrame hint for the same \
++                   content.");
++      }
++    } else {
++      // Filter out all other changes for same content for Gecko (Servo asserts against this
++      // case above).
+       // NOTE: This is captured by reference to please static analysis.
+       // Capturing it by value as a pointer should be fine in this case.
+       RemoveElementsBy([&](const nsStyleChangeData& aData) {

Copied: branches/2018Q1/www/waterfox/files/patch-bug1388319 (from r461350, head/www/waterfox/files/patch-bug1388319)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1388319	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1388319)
@@ -0,0 +1,30 @@
+commit e572d7e6e7cf
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Tue Aug 8 22:41:32 2017 +1000
+
+    Bug 1388319 - Mark ServoStyleSet dirty in its Init. r=emilio
+    
+    MozReview-Commit-ID: 804KasIiS6E
+    
+    --HG--
+    extra : rebase_source : 36eb21c5ffc4321aef652947455e73970419803a
+---
+ layout/style/ServoStyleSet.cpp | 5 +++--
+ 1 file changed, 3 insertions(+), 2 deletions(-)
+
+diff --git layout/style/ServoStyleSet.cpp layout/style/ServoStyleSet.cpp
+index adb3cba922d2..a1cd15903ade 100644
+--- layout/style/ServoStyleSet.cpp
++++ layout/style/ServoStyleSet.cpp
+@@ -81,8 +81,9 @@ ServoStyleSet::Init(nsPresContext* aPresContext, nsBindingManager* aBindingManag
+     }
+   }
+ 
+-  // No need to Servo_StyleSet_FlushStyleSheets because we just created the
+-  // mRawSet, so there was nothing to flush.
++  // We added prefilled stylesheets into mRawSet, so the stylist is dirty.
++  // The Stylist should be updated later when necessary.
++  SetStylistStyleSheetsDirty();
+ }
+ 
+ void

Copied: branches/2018Q1/www/waterfox/files/patch-bug1394146 (from r461350, head/www/waterfox/files/patch-bug1394146)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1394146	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1394146)
@@ -0,0 +1,119 @@
+commit f8221b58e542
+Author: Sean Stangl <sstangl@mozilla.com>
+Date:   Thu Sep 21 15:37:00 2017 -0400
+
+    Bug 1394146 - Avoid overflow on backwards iteration of IC entries. r=jandem, a=sledru
+    
+    --HG--
+    extra : source : 9f05ef54c84d9b63fb3ad2dd2916df34cb35df8d
+    extra : histedit_source : 753ccc8652983bb35d3a1f9f89638902d3b0a2a5
+---
+ js/src/jit/BaselineJIT.cpp    | 11 +++++++++--
+ js/src/jit/IonControlFlow.cpp | 16 ++++++++++++----
+ 2 files changed, 21 insertions(+), 6 deletions(-)
+
+diff --git js/src/jit/BaselineJIT.cpp js/src/jit/BaselineJIT.cpp
+index 3e25fd7b7120..baec7b63b8f0 100644
+--- js/src/jit/BaselineJIT.cpp
++++ js/src/jit/BaselineJIT.cpp
+@@ -669,12 +669,16 @@ BaselineScript::maybeICEntryFromPCOffset(uint32_t pcOffset)
+     if (!ComputeBinarySearchMid(this, pcOffset, &mid))
+         return nullptr;
+ 
++    MOZ_ASSERT(mid < numICEntries());
++
+     // Found an IC entry with a matching PC offset.  Search backward, and then
+     // forward from this IC entry, looking for one with the same PC offset which
+     // has isForOp() set.
+-    for (size_t i = mid; i < numICEntries() && icEntry(i).pcOffset() == pcOffset; i--) {
++    for (size_t i = mid; icEntry(i).pcOffset() == pcOffset; i--) {
+         if (icEntry(i).isForOp())
+             return &icEntry(i);
++        if (i == 0)
++            break;
+     }
+     for (size_t i = mid+1; i < numICEntries() && icEntry(i).pcOffset() == pcOffset; i++) {
+         if (icEntry(i).isForOp())
+@@ -728,10 +732,13 @@ BaselineScript::callVMEntryFromPCOffset(uint32_t pcOffset)
+     // inserted by VM calls.
+     size_t mid;
+     MOZ_ALWAYS_TRUE(ComputeBinarySearchMid(this, pcOffset, &mid));
++    MOZ_ASSERT(mid < numICEntries());
+ 
+-    for (size_t i = mid; i < numICEntries() && icEntry(i).pcOffset() == pcOffset; i--) {
++    for (size_t i = mid; icEntry(i).pcOffset() == pcOffset; i--) {
+         if (icEntry(i).kind() == ICEntry::Kind_CallVM)
+             return icEntry(i);
++        if (i == 0)
++            break;
+     }
+     for (size_t i = mid+1; i < numICEntries() && icEntry(i).pcOffset() == pcOffset; i++) {
+         if (icEntry(i).kind() == ICEntry::Kind_CallVM)
+diff --git js/src/jit/IonControlFlow.cpp js/src/jit/IonControlFlow.cpp
+index 4f27cd53dcaa..8d8a796d3f3b 100644
+--- js/src/jit/IonControlFlow.cpp
++++ js/src/jit/IonControlFlow.cpp
+@@ -1619,7 +1619,7 @@ ControlFlowGenerator::processBreak(JSOp op, jssrcnote* sn)
+     DebugOnly<bool> found = false;
+ 
+     if (SN_TYPE(sn) == SRC_BREAK2LABEL) {
+-        for (size_t i = labels_.length() - 1; i < labels_.length(); i--) {
++        for (size_t i = labels_.length() - 1; ; i--) {
+             CFGState& cfg = cfgStack_[labels_[i].cfgEntry];
+             MOZ_ASSERT(cfg.state == CFGState::LABEL);
+             if (cfg.stopAt == target) {
+@@ -1627,9 +1627,11 @@ ControlFlowGenerator::processBreak(JSOp op, jssrcnote* sn)
+                 found = true;
+                 break;
+             }
++            if (i == 0)
++                break;
+         }
+     } else {
+-        for (size_t i = loops_.length() - 1; i < loops_.length(); i--) {
++        for (size_t i = loops_.length() - 1; ; i--) {
+             CFGState& cfg = cfgStack_[loops_[i].cfgEntry];
+             MOZ_ASSERT(cfg.isLoop());
+             if (cfg.loop.exitpc == target) {
+@@ -1637,6 +1639,8 @@ ControlFlowGenerator::processBreak(JSOp op, jssrcnote* sn)
+                 found = true;
+                 break;
+             }
++            if (i == 0)
++                break;
+         }
+     }
+ 
+@@ -1665,7 +1669,7 @@ ControlFlowGenerator::processContinue(JSOp op)
+     // Find the target loop.
+     CFGState* found = nullptr;
+     jsbytecode* target = pc + GetJumpOffset(pc);
+-    for (size_t i = loops_.length() - 1; i < loops_.length(); i--) {
++    for (size_t i = loops_.length() - 1; ; i--) {
+         // +1 to skip JSOP_JUMPTARGET.
+         if (loops_[i].continuepc == target + 1 ||
+             EffectiveContinue(loops_[i].continuepc) == target)
+@@ -1673,6 +1677,8 @@ ControlFlowGenerator::processContinue(JSOp op)
+             found = &cfgStack_[loops_[i].cfgEntry];
+             break;
+         }
++        if (i == 0)
++            break;
+     }
+ 
+     // There must always be a valid target loop structure. If not, there's
+@@ -1698,11 +1704,13 @@ ControlFlowGenerator::processSwitchBreak(JSOp op)
+     // Find the target switch.
+     CFGState* found = nullptr;
+     jsbytecode* target = pc + GetJumpOffset(pc);
+-    for (size_t i = switches_.length() - 1; i < switches_.length(); i--) {
++    for (size_t i = switches_.length() - 1; ; i--) {
+         if (switches_[i].continuepc == target) {
+             found = &cfgStack_[switches_[i].cfgEntry];
+             break;
+         }
++        if (i == 0)
++            break;
+     }
+ 
+     // There must always be a valid target loop structure. If not, there's

Copied: branches/2018Q1/www/waterfox/files/patch-bug1397671 (from r461350, head/www/waterfox/files/patch-bug1397671)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1397671	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1397671)
@@ -0,0 +1,105 @@
+commit 553df1231272
+Author: Matt Woodrow <mwoodrow@mozilla.com>
+Date:   Tue Sep 26 15:57:56 2017 +1300
+
+    Bug 1397671 - Don't treat SVG transformed frames as being transformed for the purposes of computing Combines3DTransformWithAncestors. r=dbaron, a=sledru
+    
+    --HG--
+    extra : source : 70b150570407df427bed31965fe29cf8736beab6
+---
+ layout/generic/nsFrame.cpp                         | 11 +++++++++--
+ layout/generic/nsIFrame.h                          |  6 ++++++
+ layout/reftests/transform-3d/preserve3d-8-ref.html | 11 +++++++++++
+ layout/reftests/transform-3d/preserve3d-8.html     | 17 +++++++++++++++++
+ 4 files changed, 43 insertions(+), 2 deletions(-)
+
+diff --git layout/generic/nsFrame.cpp layout/generic/nsFrame.cpp
+index 6e6f2bfa5379..02d1dafec21e 100644
+--- layout/generic/nsFrame.cpp
++++ layout/generic/nsFrame.cpp
+@@ -1326,11 +1326,18 @@ nsIFrame::GetMarginRectRelativeToSelf() const
+ bool
+ nsIFrame::IsTransformed(const nsStyleDisplay* aStyleDisplay,
+                         EffectSet* aEffectSet) const
++{
++  return IsCSSTransformed(aStyleDisplay, aEffectSet) ||
++         IsSVGTransformed();
++}
++
++bool
++nsIFrame::IsCSSTransformed(const nsStyleDisplay* aStyleDisplay,
++                           EffectSet* aEffectSet) const
+ {
+   MOZ_ASSERT(aStyleDisplay == StyleDisplay());
+   return ((mState & NS_FRAME_MAY_BE_TRANSFORMED) &&
+           (aStyleDisplay->HasTransform(this) ||
+-           IsSVGTransformed() ||
+            HasAnimationOfTransform(aEffectSet)));
+ }
+ 
+@@ -1402,7 +1409,7 @@ nsIFrame::Combines3DTransformWithAncestors(const nsStyleDisplay* aStyleDisplay,
+   if (!parent || !parent->Extend3DContext()) {
+     return false;
+   }
+-  return IsTransformed(aStyleDisplay,aEffectSet) ||
++  return IsCSSTransformed(aStyleDisplay, aEffectSet) ||
+          BackfaceIsHidden(aStyleDisplay);
+ }
+ 
+diff --git layout/generic/nsIFrame.h layout/generic/nsIFrame.h
+index e8fb4c71a16f..b3ca08370d34 100644
+--- layout/generic/nsIFrame.h
++++ layout/generic/nsIFrame.h
+@@ -1724,6 +1724,12 @@ public:
+     return IsTransformed(StyleDisplay(), aEffectSet);
+   }
+ 
++  /**
++   * Same as IsTransformed, except that it doesn't take SVG transforms
++   * into account.
++   */
++  bool IsCSSTransformed(const nsStyleDisplay* aStyleDisplay, mozilla::EffectSet* aEffectSet = nullptr) const;
++
+   /**
+    * True if this frame has any animation of transform in effect.
+    *
+diff --git layout/reftests/transform-3d/preserve3d-8-ref.html layout/reftests/transform-3d/preserve3d-8-ref.html
+new file mode 100644
+index 000000000000..afddf05d4d81
+--- /dev/null
++++ layout/reftests/transform-3d/preserve3d-8-ref.html
+@@ -0,0 +1,11 @@
++<html>
++<head>
++</head>
++<body style="width:100px">
++  <svg xmlns="http://www.w3.org/2000/svg" version="1.1" id="js" viewBox="0 0 200 200" style="transform: rotateX(180deg)">
++    <g>
++      <rect width="100" height="100" style="fill:rgb(0,0,255)"></rect>
++    </g>
++  </svg>
++</body>
++</html>
+diff --git layout/reftests/transform-3d/preserve3d-8.html layout/reftests/transform-3d/preserve3d-8.html
+new file mode 100644
+index 000000000000..76e9c10c33bc
+--- /dev/null
++++ layout/reftests/transform-3d/preserve3d-8.html
+@@ -0,0 +1,17 @@
++<html>
++<head>
++</head>
++<body>
++  <div style="transform: rotatex(45deg); transform-style: preserve-3d; width: 100px;">
++    <div style="transform: rotatex(45deg); transform-style: preserve-3d; width: 100px;">
++      <div style="transform: rotatex(45deg); transform-style: preserve-3d; width: 100px;">
++        <svg xmlns="http://www.w3.org/2000/svg" version="1.1" id="js" viewBox="0 0 200 200" style="transform: rotateX(45deg)">
++          <g>
++            <rect width="100" height="100" style="fill:rgb(0,0,255)"></rect>
++          </g>
++        </svg>
++      </div>
++    </div>
++  </div>
++</body>
++</html>

Copied: branches/2018Q1/www/waterfox/files/patch-bug1398983 (from r461350, head/www/waterfox/files/patch-bug1398983)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1398983	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1398983)
@@ -0,0 +1,25 @@
+commit 6b2dbc2b8216
+Author: Bobby Holley <bobbyholley@gmail.com>
+Date:   Fri Sep 15 12:25:46 2017 -0700
+
+    Bug 1398983 - Remove warning about assuming gecko style system. r=me
+    
+    MozReview-Commit-ID: BCeG81uxLvS
+---
+ dom/base/nsDocument.cpp | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git dom/base/nsDocument.cpp dom/base/nsDocument.cpp
+index 9d9af08ba04b..076fe1a5d444 100644
+--- dom/base/nsDocument.cpp
++++ dom/base/nsDocument.cpp
+@@ -13490,7 +13490,8 @@ nsIDocument::UpdateStyleBackendType()
+       // Enable stylo for SVG-as-image.
+       mStyleBackendType = StyleBackendType::Servo;
+     } else if (!mDocumentContainer) {
+-      NS_WARNING("stylo: No docshell yet, assuming Gecko style system");
++      // Not docshell, assume Gecko. Various callers can end up setting this
++      // explicitly afterwards to inherit it in various situations.
+     } else if (!IsXULDocument() && IsContentDocument()) {
+       // Disable stylo for about: pages other than about:blank, since
+       // they tend to use unsupported selectors like XUL tree pseudos.

Copied: branches/2018Q1/www/waterfox/files/patch-bug1400540 (from r461350, head/www/waterfox/files/patch-bug1400540)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1400540	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1400540)
@@ -0,0 +1,47 @@
+commit 6905267b2878
+Author: Xidorn Quan <me@upsuper.org>
+Date:   Wed Sep 20 08:26:53 2017 +1000
+
+    Bug 1400540 - Decide style backend type based on principal. r=bholley
+    
+    MozReview-Commit-ID: A4y9Shdbr7g
+    
+    --HG--
+    extra : source : cdfe5e5e059273a1c7fc6506d6e0fecb2bb7affb
+---
+ dom/base/nsDocument.cpp | 21 ++++++++-------------
+ 1 file changed, 8 insertions(+), 13 deletions(-)
+
+diff --git dom/base/nsDocument.cpp dom/base/nsDocument.cpp
+index 642960e6a155..265af0df07b9 100644
+--- dom/base/nsDocument.cpp
++++ dom/base/nsDocument.cpp
+@@ -13465,20 +13465,15 @@ nsIDocument::UpdateStyleBackendType()
+ 
+ #ifdef MOZ_STYLO
+   if (nsLayoutUtils::StyloEnabled()) {
+-    if (IsBeingUsedAsImage()) {
+-      // Enable stylo for SVG-as-image.
++    // Disable stylo only for system principal. Other principals aren't
++    // able to use XUL by default, and the back door to enable XUL is
++    // mostly just for testing, which means they don't matter, and we
++    // shouldn't respect them at the same time.
++    // Note that, since tests can have XUL support, we still need to
++    // explicitly exclude XUL documents here.
++    if (!nsContentUtils::IsSystemPrincipal(NodePrincipal()) &&
++        !IsXULDocument()) {
+       mStyleBackendType = StyleBackendType::Servo;
+-    } else if (!mDocumentContainer) {
+-      // Not docshell, assume Gecko. Various callers can end up setting this
+-      // explicitly afterwards to inherit it in various situations.
+-    } else if (!IsXULDocument() && IsContentDocument()) {
+-      // Disable stylo for about: pages other than about:blank, since
+-      // they tend to use unsupported selectors like XUL tree pseudos.
+-      bool isAbout = false;
+-      mDocumentURI->SchemeIs("about", &isAbout);
+-      if (!isAbout || NS_IsAboutBlank(mDocumentURI)) {
+-        mStyleBackendType = StyleBackendType::Servo;
+-      }
+     }
+   }
+ #endif

Copied: branches/2018Q1/www/waterfox/files/patch-bug1401416 (from r461350, head/www/waterfox/files/patch-bug1401416)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2018Q1/www/waterfox/files/patch-bug1401416	Sat Feb 10 00:42:01 2018	(r461353, copy of r461350, head/www/waterfox/files/patch-bug1401416)
@@ -0,0 +1,29 @@
+commit c5123938eb1e
+Author: Tobias Schneider <schneider@jancona.com>
+Date:   Thu Sep 21 12:43:35 2017 -0700
+
+    Bug 1401416 - [intersection-observer] Let intersection rect be empty if do_QueryFrame(rootFrame) returns null. r=dholbert, a=sledru
+    
+    --HG--
+    extra : source : 90be30b5206c2b2724d61f4f6782197bfa768428
+---
+ dom/base/DOMIntersectionObserver.cpp | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git dom/base/DOMIntersectionObserver.cpp dom/base/DOMIntersectionObserver.cpp
+index 606a1de5ed8c..1ca909e3cfbf 100644
+--- dom/base/DOMIntersectionObserver.cpp
++++ dom/base/DOMIntersectionObserver.cpp
+@@ -308,7 +308,11 @@ DOMIntersectionObserver::Update(nsIDocument* aDocument, DOMHighResTimeStamp time
+         }

*** DIFF OUTPUT TRUNCATED AT 1000 LINES ***



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802100042.w1A0g1n8090497>