Bug 1436864 - Remove nsIDOMHistory. r?bz draft
authorAdrian Wielgosik <adrian.wielgosik@gmail.com>
Thu, 08 Feb 2018 22:33:10 +0100
changeset 752894 a3e2fefd6be47d74f371c52273b338b017f8f25e
parent 752727 c5120bcaf7bdcb5cdb06a02b60bd5bfe6a867d06
push id98419
push userbmo:adrian.wielgosik@gmail.com
push dateFri, 09 Feb 2018 07:14:21 +0000
reviewersbz
bugs1436864
milestone60.0a1
Bug 1436864 - Remove nsIDOMHistory. r?bz MozReview-Commit-ID: HVOR03mvW2S
dom/base/nsHistory.cpp
dom/base/nsHistory.h
dom/interfaces/base/moz.build
dom/interfaces/base/nsIDOMHistory.idl
xpcom/reflect/xptinfo/ShimInterfaceInfo.cpp
--- a/dom/base/nsHistory.cpp
+++ b/dom/base/nsHistory.cpp
@@ -29,17 +29,16 @@ using namespace mozilla::dom;
 //  History class implementation
 //
 NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_0(nsHistory)
 NS_IMPL_CYCLE_COLLECTING_ADDREF(nsHistory)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(nsHistory)
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsHistory)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
-  NS_INTERFACE_MAP_ENTRY(nsIDOMHistory) // Empty, needed for extension compat
 NS_INTERFACE_MAP_END
 
 nsHistory::nsHistory(nsPIDOMWindowInner* aInnerWindow)
   : mInnerWindow(do_GetWeakReference(aInnerWindow))
 {
 }
 
 nsHistory::~nsHistory()
--- a/dom/base/nsHistory.h
+++ b/dom/base/nsHistory.h
@@ -6,30 +6,28 @@
 #ifndef nsHistory_h___
 #define nsHistory_h___
 
 #include "mozilla/Attributes.h"
 #include "mozilla/ErrorResult.h"
 #include "mozilla/dom/HistoryBinding.h"
 #include "nsCOMPtr.h"
 #include "nsCycleCollectionParticipant.h"
-#include "nsIDOMHistory.h"
 #include "nsPIDOMWindow.h" // for GetParentObject
 #include "nsStringFwd.h"
 #include "nsWrapperCache.h"
 
 class nsIDocShell;
 class nsISHistory;
 class nsIWeakReference;
 class nsPIDOMWindowInner;
 
 // Script "History" object
-class nsHistory final : public nsIDOMHistory, // Empty, needed for extension
-                                                  // backwards compat
-                            public nsWrapperCache
+class nsHistory final : public nsISupports,
+                        public nsWrapperCache
 {
 public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsHistory)
 
 public:
   explicit nsHistory(nsPIDOMWindowInner* aInnerWindow);
 
--- a/dom/interfaces/base/moz.build
+++ b/dom/interfaces/base/moz.build
@@ -16,17 +16,16 @@ XPIDL_SOURCES += [
     'nsIContentProcess.idl',
     'nsIContentURIGrouper.idl',
     'nsIDOMChromeWindow.idl',
     'nsIDOMClientRect.idl',
     'nsIDOMClientRectList.idl',
     'nsIDOMConstructor.idl',
     'nsIDOMCrypto.idl',
     'nsIDOMGlobalPropertyInitializer.idl',
-    'nsIDOMHistory.idl',
     'nsIDOMModalContentWindow.idl',
     'nsIDOMScreen.idl',
     'nsIDOMWindow.idl',
     'nsIDOMWindowCollection.idl',
     'nsIDOMWindowUtils.idl',
     'nsIFocusManager.idl',
     'nsIIdleObserver.idl',
     'nsIQueryContentEventResult.idl',
deleted file mode 100644
--- a/dom/interfaces/base/nsIDOMHistory.idl
+++ /dev/null
@@ -1,12 +0,0 @@
-/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* 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 "domstubs.idl"
-
-[uuid(55226663-fe68-48ba-addf-08e32eaab569)]
-interface nsIDOMHistory : nsISupports
-{
-  // Empty interface that exists only for extension backwards compat
-};
--- a/xpcom/reflect/xptinfo/ShimInterfaceInfo.cpp
+++ b/xpcom/reflect/xptinfo/ShimInterfaceInfo.cpp
@@ -32,17 +32,16 @@
 #include "nsIDOMDragEvent.h"
 #include "nsIDOMElement.h"
 #include "nsIDOMEvent.h"
 #include "nsIDOMEventTarget.h"
 #include "nsIDOMFileList.h"
 #include "nsIDOMFocusEvent.h"
 #include "nsIDOMFormData.h"
 #include "nsIDOMGeoPositionError.h"
-#include "nsIDOMHistory.h"
 #include "nsIDOMHTMLFormElement.h"
 #include "nsIDOMHTMLInputElement.h"
 #include "nsIDOMHTMLMediaElement.h"
 #include "nsIDOMKeyEvent.h"
 #include "nsIDOMMouseEvent.h"
 #include "nsIDOMMouseScrollEvent.h"
 #include "nsIDOMMutationEvent.h"
 #include "nsIDOMNode.h"
@@ -107,17 +106,16 @@
 #include "mozilla/dom/DragEventBinding.h"
 #include "mozilla/dom/ElementBinding.h"
 #include "mozilla/dom/EventBinding.h"
 #include "mozilla/dom/EventTargetBinding.h"
 #include "mozilla/dom/FileListBinding.h"
 #include "mozilla/dom/FocusEventBinding.h"
 #include "mozilla/dom/FormDataBinding.h"
 #include "mozilla/dom/FrameLoaderBinding.h"
-#include "mozilla/dom/HistoryBinding.h"
 #include "mozilla/dom/HTMLAnchorElementBinding.h"
 #include "mozilla/dom/HTMLAreaElementBinding.h"
 #include "mozilla/dom/HTMLButtonElementBinding.h"
 #include "mozilla/dom/HTMLFormElementBinding.h"
 #include "mozilla/dom/HTMLFrameSetElementBinding.h"
 #include "mozilla/dom/HTMLHtmlElementBinding.h"
 #include "mozilla/dom/HTMLInputElementBinding.h"
 #include "mozilla/dom/HTMLMediaElementBinding.h"
@@ -245,17 +243,16 @@ const ComponentsInterfaceShimEntry kComp
   DEFINE_SHIM(Element),
   DEFINE_SHIM(Event),
   DEFINE_SHIM(EventTarget),
   DEFINE_SHIM(FileList),
   DEFINE_SHIM(FocusEvent),
   DEFINE_SHIM(FormData),
   DEFINE_SHIM_WITH_CUSTOM_INTERFACE(nsIFrameLoader, FrameLoader),
   DEFINE_SHIM_WITH_CUSTOM_INTERFACE(nsIDOMGeoPositionError, PositionError),
-  DEFINE_SHIM(History),
   DEFINE_SHIM(HTMLFormElement),
   DEFINE_SHIM(HTMLInputElement),
   DEFINE_SHIM(HTMLMediaElement),
   DEFINE_SHIM(KeyEvent),
   DEFINE_SHIM_WITH_CUSTOM_INTERFACE(nsIListBoxObject, ListBoxObject),
   DEFINE_SHIM_WITH_CUSTOM_INTERFACE(nsIMenuBoxObject, MenuBoxObject),
   DEFINE_SHIM(MouseEvent),
   DEFINE_SHIM(MouseScrollEvent),