Bug 1272409 - Fix fuzzy unified build failed after adding new files into dom/base. r=dholbert
authorBoris Chiou <boris.chiou@gmail.com>
Fri, 26 Apr 2019 20:29:30 +0000
changeset 530406 7b8695f2ca823fd8fa6e89d7327c7a2652a7ac51
parent 530405 776c731d7c71a3a9845671c624c8335d5533dc81
child 530407 2f3cfdbcb9003bb1cc33456181bf4206740caad9
push id11265
push userffxbld-merge
push dateMon, 13 May 2019 10:53:39 +0000
treeherdermozilla-beta@77e0fe8dbdd3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdholbert
bugs1272409
milestone68.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 1272409 - Fix fuzzy unified build failed after adding new files into dom/base. r=dholbert Differential Revision: https://phabricator.services.mozilla.com/D28934
dom/base/nsGlobalWindowCommands.cpp
dom/base/nsNodeUtils.cpp
dom/base/nsOpenURIInFrameParams.cpp
dom/base/nsOpenURIInFrameParams.h
--- a/dom/base/nsGlobalWindowCommands.cpp
+++ b/dom/base/nsGlobalWindowCommands.cpp
@@ -28,16 +28,17 @@
 #include "nsFocusManager.h"
 #include "nsCopySupport.h"
 #include "nsIClipboard.h"
 #include "ContentEventHandler.h"
 #include "nsContentUtils.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/BasicEvents.h"
 #include "mozilla/TextEvents.h"
+#include "mozilla/dom/Document.h"
 #include "mozilla/dom/Selection.h"
 #include "mozilla/layers/KeyboardMap.h"
 
 using namespace mozilla;
 using namespace mozilla::layers;
 
 constexpr const char *sSelectAllString = "cmd_selectAll";
 constexpr const char *sSelectNoneString = "cmd_selectNone";
@@ -479,17 +480,17 @@ nsresult nsClipboardCommand::IsCommandEn
 
   if (strcmp(aCommandName, "cmd_copy") && strcmp(aCommandName, "cmd_cut") &&
       strcmp(aCommandName, "cmd_paste")) {
     return NS_OK;
   }
 
   nsCOMPtr<nsPIDOMWindowOuter> window = do_QueryInterface(aContext);
   NS_ENSURE_TRUE(window, NS_ERROR_FAILURE);
-  RefPtr<Document> doc = window->GetExtantDoc();
+  RefPtr<dom::Document> doc = window->GetExtantDoc();
   NS_ENSURE_TRUE(doc, NS_ERROR_FAILURE);
 
   if (doc->IsHTMLOrXHTML()) {
     // In HTML and XHTML documents, we always want the cut, copy and paste
     // commands to be enabled.
     *outCmdEnabled = true;
   } else {
     // Cut isn't enabled in xul documents which use nsClipboardCommand
--- a/dom/base/nsNodeUtils.cpp
+++ b/dom/base/nsNodeUtils.cpp
@@ -206,25 +206,25 @@ void nsNodeUtils::ContentRemoved(nsINode
   MOZ_ASSERT(aChild->GetParentNode() == aContainer,
              "We expect the parent link to be still around at this point");
   IMPL_MUTATION_NOTIFICATION(ContentRemoved, aContainer,
                              (aChild, aPreviousSibling),
                              IsRemoveNotification::Yes);
 }
 
 Maybe<NonOwningAnimationTarget> nsNodeUtils::GetTargetForAnimation(
-    const Animation* aAnimation) {
+    const dom::Animation* aAnimation) {
   AnimationEffect* effect = aAnimation->GetEffect();
   if (!effect || !effect->AsKeyframeEffect()) {
     return Nothing();
   }
   return effect->AsKeyframeEffect()->GetTarget();
 }
 
-void nsNodeUtils::AnimationMutated(Animation* aAnimation,
+void nsNodeUtils::AnimationMutated(dom::Animation* aAnimation,
                                    AnimationMutationType aMutatedType) {
   Maybe<NonOwningAnimationTarget> target = GetTargetForAnimation(aAnimation);
   if (!target) {
     return;
   }
 
   // A pseudo element and its parent element use the same owner doc.
   Document* doc = target->mElement->OwnerDoc();
@@ -242,25 +242,25 @@ void nsNodeUtils::AnimationMutated(Anima
         IMPL_ANIMATION_NOTIFICATION(AnimationRemoved, elem, (aAnimation));
         break;
       default:
         MOZ_ASSERT_UNREACHABLE("unexpected mutation type");
     }
   }
 }
 
-void nsNodeUtils::AnimationAdded(Animation* aAnimation) {
+void nsNodeUtils::AnimationAdded(dom::Animation* aAnimation) {
   AnimationMutated(aAnimation, AnimationMutationType::Added);
 }
 
-void nsNodeUtils::AnimationChanged(Animation* aAnimation) {
+void nsNodeUtils::AnimationChanged(dom::Animation* aAnimation) {
   AnimationMutated(aAnimation, AnimationMutationType::Changed);
 }
 
-void nsNodeUtils::AnimationRemoved(Animation* aAnimation) {
+void nsNodeUtils::AnimationRemoved(dom::Animation* aAnimation) {
   AnimationMutated(aAnimation, AnimationMutationType::Removed);
 }
 
 void nsNodeUtils::LastRelease(nsINode* aNode) {
   nsINode::nsSlots* slots = aNode->GetExistingSlots();
   if (slots) {
     if (!slots->mMutationObservers.IsEmpty()) {
       NS_OBSERVER_AUTO_ARRAY_NOTIFY_OBSERVERS(slots->mMutationObservers,
--- a/dom/base/nsOpenURIInFrameParams.cpp
+++ b/dom/base/nsOpenURIInFrameParams.cpp
@@ -1,31 +1,33 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsOpenURIInFrameParams.h"
 #include "mozilla/BasePrincipal.h"
+#include "mozilla/dom/Element.h"
 #include "mozilla/dom/ToJSValue.h"
 #include "mozilla/net/ReferrerPolicy.h"
 
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsOpenURIInFrameParams)
   NS_INTERFACE_MAP_ENTRY(nsIOpenURIInFrameParams)
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
 NS_IMPL_CYCLE_COLLECTION(nsOpenURIInFrameParams, mOpenerBrowser)
 
 NS_IMPL_CYCLE_COLLECTING_ADDREF(nsOpenURIInFrameParams)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(nsOpenURIInFrameParams)
 
 nsOpenURIInFrameParams::nsOpenURIInFrameParams(
-    const mozilla::OriginAttributes& aOriginAttributes, Element* aOpener)
+    const mozilla::OriginAttributes& aOriginAttributes,
+    mozilla::dom::Element* aOpener)
     : mOpenerOriginAttributes(aOriginAttributes), mOpenerBrowser(aOpener) {}
 
 nsOpenURIInFrameParams::~nsOpenURIInFrameParams() {}
 
 NS_IMETHODIMP
 nsOpenURIInFrameParams::GetReferrerInfo(nsIReferrerInfo** aReferrerInfo) {
   NS_IF_ADDREF(*aReferrerInfo = mReferrerInfo);
   return NS_OK;
@@ -67,18 +69,19 @@ nsOpenURIInFrameParams::GetCsp(nsIConten
 
 NS_IMETHODIMP
 nsOpenURIInFrameParams::SetCsp(nsIContentSecurityPolicy* aCsp) {
   NS_ENSURE_TRUE(aCsp, NS_ERROR_INVALID_ARG);
   mCsp = aCsp;
   return NS_OK;
 }
 
-nsresult nsOpenURIInFrameParams::GetOpenerBrowser(Element** aOpenerBrowser) {
-  RefPtr<Element> owner = mOpenerBrowser;
+nsresult nsOpenURIInFrameParams::GetOpenerBrowser(
+    mozilla::dom::Element** aOpenerBrowser) {
+  RefPtr<mozilla::dom::Element> owner = mOpenerBrowser;
   owner.forget(aOpenerBrowser);
   return NS_OK;
 }
 
 NS_IMETHODIMP
 nsOpenURIInFrameParams::GetOpenerOriginAttributes(
     JSContext* aCx, JS::MutableHandle<JS::Value> aValue) {
   bool ok = ToJSValue(aCx, mOpenerOriginAttributes, aValue);
--- a/dom/base/nsOpenURIInFrameParams.h
+++ b/dom/base/nsOpenURIInFrameParams.h
@@ -3,33 +3,39 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "mozilla/BasePrincipal.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsIBrowserDOMWindow.h"
 #include "nsFrameLoaderOwner.h"
+#include "nsIContentSecurityPolicy.h"
+#include "nsIPrincipal.h"
 #include "nsIReferrerInfo.h"
 #include "nsString.h"
 
 namespace mozilla {
 class OriginAttributes;
-}
+namespace dom {
+class Element;
+}  // namespace dom
+}  // namespace mozilla
 
 class nsOpenURIInFrameParams final : public nsIOpenURIInFrameParams {
  public:
   NS_DECL_CYCLE_COLLECTION_CLASS(nsOpenURIInFrameParams)
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
   NS_DECL_NSIOPENURIINFRAMEPARAMS
 
   explicit nsOpenURIInFrameParams(
-      const mozilla::OriginAttributes& aOriginAttributes, Element* aOpener);
+      const mozilla::OriginAttributes& aOriginAttributes,
+      mozilla::dom::Element* aOpener);
 
  private:
   ~nsOpenURIInFrameParams();
 
   mozilla::OriginAttributes mOpenerOriginAttributes;
-  RefPtr<Element> mOpenerBrowser;
+  RefPtr<mozilla::dom::Element> mOpenerBrowser;
   nsCOMPtr<nsIReferrerInfo> mReferrerInfo;
   nsCOMPtr<nsIPrincipal> mTriggeringPrincipal;
   nsCOMPtr<nsIContentSecurityPolicy> mCsp;
 };