Bug 1425440 - Replace RemoveChildAt_Deprecated with RemoveChildNode in nsXULSortService, r=catalinb
authorAndrea Marchesini <amarchesini@mozilla.com>
Tue, 16 Jan 2018 14:17:10 +0100
changeset 453731 293349fdff10dfdfaff678d42ed125b0f559e39b
parent 453730 b0f95e1a8de90e0b1533721bd86d1bd34cedbd3b
child 453732 9ef23aa75c3d494ea56cd2ecf72c3b326acd7249
push id1648
push usermtabara@mozilla.com
push dateThu, 01 Mar 2018 12:45:47 +0000
treeherdermozilla-release@cbb9688c2eeb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerscatalinb
bugs1425440
milestone59.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 1425440 - Replace RemoveChildAt_Deprecated with RemoveChildNode in nsXULSortService, r=catalinb
dom/xul/nsXULSortService.cpp
--- a/dom/xul/nsXULSortService.cpp
+++ b/dom/xul/nsXULSortService.cpp
@@ -175,18 +175,17 @@ XULSortServiceImpl::SortContainer(nsICon
     nsIContent* child = items[i].content;
     nsIContent* parent = child->GetParent();
 
     if (parent) {
       // remember the parent so that it can be reinserted back
       // into the same parent. This is necessary as multiple rules
       // may generate results which get placed in different locations.
       items[i].parent = parent;
-      int32_t index = parent->IndexOf(child);
-      parent->RemoveChildAt_Deprecated(index, true);
+      parent->RemoveChildNode(child, true);
     }
   }
 
   // now add the items back in sorted order
   for (i = 0; i < numResults; i++)
   {
     nsIContent* child = items[i].content;
     nsIContent* parent = items[i].parent;