Bug 1434830 - Port bug 1434819: Replace use of nsIDOMNodeFilter. r=bz
authorJorg K <jorgk@jorgk.com>
Thu, 01 Feb 2018 23:10:59 +0100
changeset 31022 a1956e0c9e16d8c4f5ceb7266534829af0de03b5
parent 31021 6a1bb92d2e928b4d442854c74719d5ead17145cd
child 31023 e3d2a28fffec7d68d6640d5b74b93af7b253b2cc
push id383
push userclokep@gmail.com
push dateMon, 07 May 2018 21:52:48 +0000
reviewersbz
bugs1434830, 1434819
Bug 1434830 - Port bug 1434819: Replace use of nsIDOMNodeFilter. r=bz
chat/modules/imThemes.jsm
im/installer/package-manifest.in
im/installer/removed-files.in
mail/installer/package-manifest.in
mail/installer/removed-files.in
suite/installer/package-manifest.in
suite/installer/removed-files.in
--- a/chat/modules/imThemes.jsm
+++ b/chat/modules/imThemes.jsm
@@ -779,17 +779,19 @@ SelectedMessage.prototype = {
   // Helper function that returns the first span node of class
   // ib-msg-text under the rootNodes of the selected message.
   _getSpanNode: function() {
     // first use the cached value if any
     if (this._spanNode)
       return this._spanNode;
 
     let spanNode = null;
-    const NodeFilter = Ci.nsIDOMNodeFilter;
+    // If we could use NodeFilter.webidl, we wouldn't have to make up our own
+    // object. FILTER_REJECT is not used here, but included for completeness.
+    const NodeFilter = { SHOW_ELEMENT: 0x1, FILTER_ACCEPT: 1, FILTER_REJECT: 2, FILTER_SKIP: 3 };
     // helper filter function for the tree walker
     let filter = function(node) {
       return node.className == "ib-msg-txt" ? NodeFilter.FILTER_ACCEPT
                                             : NodeFilter.FILTER_SKIP;
     };
     // walk the DOM subtrees of each root, keep the first correct span node
     for (let i = 0; !spanNode && i < this._rootNodes.length; ++i) {
       let rootNode = this._rootNodes[i];
--- a/im/installer/package-manifest.in
+++ b/im/installer/package-manifest.in
@@ -481,17 +481,16 @@
 @RESPATH@/components/dom_presentation.xpt
 @RESPATH@/components/dom_quota.xpt
 @RESPATH@/components/dom_range.xpt
 @RESPATH@/components/dom_security.xpt
 @RESPATH@/components/dom_sidebar.xpt
 @RESPATH@/components/dom_smil.xpt
 @RESPATH@/components/dom_storage.xpt
 @RESPATH@/components/dom_system.xpt
-@RESPATH@/components/dom_traversal.xpt
 @RESPATH@/components/dom_webspeechrecognition.xpt
 @RESPATH@/components/dom_webspeechsynth.xpt
 @RESPATH@/components/dom_workers.xpt
 @RESPATH@/components/dom_xbl.xpt
 @RESPATH@/components/dom_xhr.xpt
 @RESPATH@/components/dom_xpath.xpt
 @RESPATH@/components/dom_xul.xpt
 @RESPATH@/components/NetworkGeolocationProvider.js
--- a/im/installer/removed-files.in
+++ b/im/installer/removed-files.in
@@ -118,17 +118,16 @@ components/dom_geolocation.xpt
 components/dom_html.xpt
 components/dom_loadsave.xpt
 components/dom_offline.xpt
 components/dom_range.xpt
 components/dom_sidebar.xpt
 components/dom_storage.xpt
 components/dom_svg.xpt
 components/dom_threads.xpt
-components/dom_traversal.xpt
 components/dom_views.xpt
 components/dom_xbl.xpt
 components/dom_xpath.xpt
 components/dom_xul.xpt
 components/downloads.xpt
 components/editor.xpt
 components/embed_base.xpt
 components/extensions.xpt
--- a/mail/installer/package-manifest.in
+++ b/mail/installer/package-manifest.in
@@ -444,17 +444,16 @@
 @RESPATH@/components/dom_presentation.xpt
 @RESPATH@/components/dom_push.xpt
 @RESPATH@/components/dom_quota.xpt
 @RESPATH@/components/dom_range.xpt
 @RESPATH@/components/dom_security.xpt
 @RESPATH@/components/dom_sidebar.xpt
 @RESPATH@/components/dom_storage.xpt
 @RESPATH@/components/dom_system.xpt
-@RESPATH@/components/dom_traversal.xpt
 @RESPATH@/components/dom_webspeechrecognition.xpt
 @RESPATH@/components/dom_workers.xpt
 @RESPATH@/components/dom_xbl.xpt
 @RESPATH@/components/dom_xhr.xpt
 @RESPATH@/components/dom_xpath.xpt
 @RESPATH@/components/dom_xul.xpt
 @RESPATH@/components/downloads.xpt
 @RESPATH@/components/editor.xpt
--- a/mail/installer/removed-files.in
+++ b/mail/installer/removed-files.in
@@ -903,17 +903,16 @@ uninstall/uninstall.exe
   components/docshell_base.xpt
   components/dom.xpt
   components/dom_base.xpt
   components/dom_core.xpt
   components/dom_events.xpt
   components/dom_html.xpt
   components/dom_offline.xpt
   components/dom_range.xpt
-  components/dom_traversal.xpt
   components/dom_views.xpt
   components/dom_xbl.xpt
   components/dom_xpath.xpt
   components/dom_xul.xpt
   components/editor.xpt
   components/embed_base.xpt
   components/extensions.xpt
   components/exthandler.xpt
@@ -1039,17 +1038,16 @@ uninstall/uninstall.exe
   @DIR_MACOS@components/dom_html.xpt
   @DIR_MACOS@components/dom_offline.xpt
   @DIR_MACOS@components/dom_range.xpt
   @DIR_MACOS@components/dom_sidebar.xpt
   @DIR_MACOS@components/dom_smil.xpt
   @DIR_MACOS@components/dom_storage.xpt
   @DIR_MACOS@components/dom_svg.xpt
   @DIR_MACOS@components/dom_threads.xpt
-  @DIR_MACOS@components/dom_traversal.xpt
   @DIR_MACOS@components/dom_views.xpt
   @DIR_MACOS@components/dom_xbl.xpt
   @DIR_MACOS@components/dom_xpath.xpt
   @DIR_MACOS@components/dom_xul.xpt
   @DIR_MACOS@components/downloads.xpt
   @DIR_MACOS@components/editor.xpt
   @DIR_MACOS@components/embed_base.xpt
   @DIR_MACOS@components/extensions.xpt
--- a/suite/installer/package-manifest.in
+++ b/suite/installer/package-manifest.in
@@ -210,17 +210,16 @@
 @RESPATH@/components/dom_quota.xpt
 @RESPATH@/components/dom_range.xpt
 @RESPATH@/components/dom_security.xpt
 @RESPATH@/components/dom_sidebar.xpt
 @RESPATH@/components/dom_smil.xpt
 @RESPATH@/components/dom_storage.xpt
 @RESPATH@/components/dom_svg.xpt
 @RESPATH@/components/dom_system.xpt
-@RESPATH@/components/dom_traversal.xpt
 #ifdef MOZ_WEBSPEECH
 @RESPATH@/components/dom_webspeechrecognition.xpt
 @RESPATH@/components/dom_webspeechsynth.xpt
 #endif
 @RESPATH@/components/dom_workers.xpt
 @RESPATH@/components/dom_xbl.xpt
 @RESPATH@/components/dom_xhr.xpt
 @RESPATH@/components/dom_xpath.xpt
--- a/suite/installer/removed-files.in
+++ b/suite/installer/removed-files.in
@@ -1280,17 +1280,16 @@ components/xpautoc.dll
 @DIR_MACOS@components/dom_html.xpt
 @DIR_MACOS@components/dom_offline.xpt
 @DIR_MACOS@components/dom_range.xpt
 @DIR_MACOS@components/dom_sidebar.xpt
 @DIR_MACOS@components/dom_smil.xpt
 @DIR_MACOS@components/dom_storage.xpt
 @DIR_MACOS@components/dom_svg.xpt
 @DIR_MACOS@components/dom_threads.xpt
-@DIR_MACOS@components/dom_traversal.xpt
 @DIR_MACOS@components/dom_views.xpt
 @DIR_MACOS@components/dom_xbl.xpt
 @DIR_MACOS@components/dom_xpath.xpt
 @DIR_MACOS@components/dom_xul.xpt
 @DIR_MACOS@components/downloads.xpt
 @DIR_MACOS@components/editor.xpt
 @DIR_MACOS@components/embed_base.xpt
 @DIR_MACOS@components/extensions.xpt