Bug 1498713 - Use .children for context menu test helper instead of .childNodes to fix tests in browser.xhtml;r=bdahl
authorBrian Grinstead <bgrinstead@mozilla.com>
Fri, 12 Oct 2018 21:12:55 +0000
changeset 499404 a8ec93d4b848fa03c678e79ac23f91b8501e3417
parent 499403 994a0ec3420ff869b56aa868a2ca471390751e60
child 499405 b8b3597d7702e4e6d7c3358f19384b49d8c220c0
push id1864
push userffxbld-merge
push dateMon, 03 Dec 2018 15:51:40 +0000
treeherdermozilla-release@f040763d99ad [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbdahl
bugs1498713
milestone64.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1498713 - Use .children for context menu test helper instead of .childNodes to fix tests in browser.xhtml;r=bdahl Differential Revision: https://phabricator.services.mozilla.com/D8604
browser/base/content/test/general/contextmenu_common.js
--- a/browser/base/content/test/general/contextmenu_common.js
+++ b/browser/base/content/test/general/contextmenu_common.js
@@ -31,18 +31,18 @@ function openContextMenuFor(element, shi
 
 function closeContextMenu() {
     contextMenu.hidePopup();
 }
 
 function getVisibleMenuItems(aMenu, aData) {
     var items = [];
     var accessKeys = {};
-    for (var i = 0; i < aMenu.childNodes.length; i++) {
-        var item = aMenu.childNodes[i];
+    for (var i = 0; i < aMenu.children.length; i++) {
+        var item = aMenu.children[i];
         if (item.hidden)
             continue;
 
         var key = item.accessKey;
         if (key)
             key = key.toLowerCase();
 
         var isPageMenuItem = item.hasAttribute("generateditemid");