Bug 1290234 - remove uses of nsIDOMNode constants from inspector; r?gregtatum draft
authorTom Tromey <tom@tromey.com>
Thu, 28 Jul 2016 14:03:50 -0600
changeset 393926 a499adfa7b003e53b6e3c708425921ff4a867207
parent 393925 d04e5bdd5b67f87fba285bf48253b279cbc58ac1
child 526701 a402b3a61d5ff24bd055bb6ba007b6b08aab7814
push id24449
push userbmo:ttromey@mozilla.com
push dateThu, 28 Jul 2016 20:04:32 +0000
reviewersgregtatum
bugs1290234
milestone50.0a1
Bug 1290234 - remove uses of nsIDOMNode constants from inspector; r?gregtatum MozReview-Commit-ID: G73Dn8shdkp
devtools/client/inspector/markup/markup.js
--- a/devtools/client/inspector/markup/markup.js
+++ b/devtools/client/inspector/markup/markup.js
@@ -894,19 +894,19 @@ MarkupView.prototype = {
 
           // If we can't move as the user wants, we move to the other direction.
           // If there is no sibling elements anymore, move to the parent node.
           if (!focusNode) {
             focusNode = nextSibling || prevSibling || parent;
           }
 
           let isNextSiblingText = nextSibling ?
-            nextSibling.nodeType === Ci.nsIDOMNode.TEXT_NODE : false;
+            nextSibling.nodeType === nodeConstants.TEXT_NODE : false;
           let isPrevSiblingText = prevSibling ?
-            prevSibling.nodeType === Ci.nsIDOMNode.TEXT_NODE : false;
+            prevSibling.nodeType === nodeConstants.TEXT_NODE : false;
 
           // If the parent had two children and the next or previous sibling
           // is a text node, then it now has only a single text node, is about
           // to be in-lined; and focus should move to the parent.
           if (parent.numChildren === 2
               && (isNextSiblingText || isPrevSiblingText)) {
             focusNode = parent;
           }