Bug 774556 - Remove nsIDOMWindowPerformance* XPCOM interfaces; r=bzbarsky
authorEhsan Akhgari <ehsan@mozilla.com>
Mon, 16 Jul 2012 22:44:22 -0400
changeset 99536 b722257d15b35172b7b8f637ae4996dd2211e761
parent 99535 fb282ed64bf7d7ddaf894b24cc62207b2f0133e4
child 99537 f90923727eee9c77e7d595bd5fed84de15454c45
push id23140
push useremorley@mozilla.com
push dateWed, 18 Jul 2012 12:33:13 +0000
treeherdermozilla-central@134e66224b04 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbzbarsky
bugs774556
milestone17.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 774556 - Remove nsIDOMWindowPerformance* XPCOM interfaces; r=bzbarsky
docshell/base/nsDocShell.cpp
dom/base/nsDOMClassInfo.cpp
dom/base/nsDOMClassInfoClasses.h
dom/base/nsDOMNavigationTiming.cpp
dom/base/nsDOMNavigationTiming.h
dom/base/nsGlobalWindow.cpp
dom/base/nsPerformance.cpp
dom/base/nsPerformance.h
dom/interfaces/base/Makefile.in
dom/interfaces/base/domstubs.idl
dom/interfaces/base/nsIDOMPerformance.idl
dom/interfaces/base/nsIDOMPerformanceNavigation.idl
dom/interfaces/base/nsIDOMPerformanceTiming.idl
dom/interfaces/base/nsIDOMWindow.idl
--- a/docshell/base/nsDocShell.cpp
+++ b/docshell/base/nsDocShell.cpp
@@ -633,49 +633,49 @@ DispatchPings(nsIContent *content, nsIUR
 static nsDOMPerformanceNavigationType
 ConvertLoadTypeToNavigationType(PRUint32 aLoadType)
 {
   // Not initialized, assume it's normal load.
   if (aLoadType == 0) {
     aLoadType = LOAD_NORMAL;
   }
 
-  nsDOMPerformanceNavigationType result = nsIDOMPerformanceNavigation::TYPE_RESERVED;
+  nsDOMPerformanceNavigationType result = dom::PerformanceNavigation::TYPE_RESERVED;
   switch (aLoadType) {
     case LOAD_NORMAL:
     case LOAD_NORMAL_EXTERNAL:
     case LOAD_NORMAL_BYPASS_CACHE:
     case LOAD_NORMAL_BYPASS_PROXY:
     case LOAD_NORMAL_BYPASS_PROXY_AND_CACHE:
     case LOAD_NORMAL_REPLACE:
     case LOAD_LINK:
     case LOAD_STOP_CONTENT:
     case LOAD_REPLACE_BYPASS_CACHE:
-        result = nsIDOMPerformanceNavigation::TYPE_NAVIGATE;
+        result = dom::PerformanceNavigation::TYPE_NAVIGATE;
         break;
     case LOAD_HISTORY:
-        result = nsIDOMPerformanceNavigation::TYPE_BACK_FORWARD;
+        result = dom::PerformanceNavigation::TYPE_BACK_FORWARD;
         break;
     case LOAD_RELOAD_NORMAL:
     case LOAD_RELOAD_CHARSET_CHANGE:
     case LOAD_RELOAD_BYPASS_CACHE:
     case LOAD_RELOAD_BYPASS_PROXY:
     case LOAD_RELOAD_BYPASS_PROXY_AND_CACHE:
-        result = nsIDOMPerformanceNavigation::TYPE_RELOAD;
+        result = dom::PerformanceNavigation::TYPE_RELOAD;
         break;
     case LOAD_STOP_CONTENT_AND_REPLACE:
     case LOAD_REFRESH:
     case LOAD_BYPASS_HISTORY:
     case LOAD_ERROR_PAGE:
     case LOAD_PUSHSTATE:
-        result = nsIDOMPerformanceNavigation::TYPE_RESERVED;
+        result = dom::PerformanceNavigation::TYPE_RESERVED;
         break;
     default:
         // NS_NOTREACHED("Unexpected load type value");
-        result = nsIDOMPerformanceNavigation::TYPE_RESERVED;
+        result = dom::PerformanceNavigation::TYPE_RESERVED;
         break;
   }
 
   return result;
 }
 
 static nsISHEntry* GetRootSHEntry(nsISHEntry *entry);
 
--- a/dom/base/nsDOMClassInfo.cpp
+++ b/dom/base/nsDOMClassInfo.cpp
@@ -98,19 +98,16 @@
 #include "nsIDOMWindow.h"
 #include "nsPIDOMWindow.h"
 #include "nsIDOMJSWindow.h"
 #include "nsIDOMWindowCollection.h"
 #include "nsIDOMHistory.h"
 #include "nsIDOMMediaList.h"
 #include "nsIDOMChromeWindow.h"
 #include "nsIDOMConstructor.h"
-#include "nsIDOMPerformanceTiming.h"
-#include "nsIDOMPerformanceNavigation.h"
-#include "nsIDOMPerformance.h"
 #include "nsClientRect.h"
 #include "nsIDOMHTMLPropertiesCollection.h"
 
 // DOM core includes
 #include "nsDOMError.h"
 #include "nsIDOMDOMException.h"
 #include "nsIDOMNode.h"
 #include "nsIDOMNamedNodeMap.h"
@@ -744,22 +741,16 @@ static nsDOMClassInfoData sClassInfoData
                            DOM_DEFAULT_SCRIPTABLE_FLAGS)
   NS_DEFINE_CLASSINFO_DATA(MimeTypeArray, nsMimeTypeArraySH,
                            ARRAY_SCRIPTABLE_FLAGS)
   NS_DEFINE_CLASSINFO_DATA(BarProp, nsDOMGenericSH,
                            DOM_DEFAULT_SCRIPTABLE_FLAGS)
   NS_DEFINE_CLASSINFO_DATA(History, nsHistorySH,
                            ARRAY_SCRIPTABLE_FLAGS |
                            nsIXPCScriptable::WANT_PRECREATE)
-  NS_DEFINE_CLASSINFO_DATA(PerformanceTiming, nsDOMGenericSH,
-                           DOM_DEFAULT_SCRIPTABLE_FLAGS)
-  NS_DEFINE_CLASSINFO_DATA(PerformanceNavigation, nsDOMGenericSH,
-                           DOM_DEFAULT_SCRIPTABLE_FLAGS)
-  NS_DEFINE_CLASSINFO_DATA(Performance, nsDOMGenericSH,
-                           DOM_DEFAULT_SCRIPTABLE_FLAGS)
   NS_DEFINE_CLASSINFO_DATA(Screen, nsDOMGenericSH,
                            DOM_DEFAULT_SCRIPTABLE_FLAGS)
   NS_DEFINE_CLASSINFO_DATA(DOMPrototype, nsDOMConstructorSH,
                            DOM_BASE_SCRIPTABLE_FLAGS |
                            nsIXPCScriptable::WANT_PRECREATE |
                            nsIXPCScriptable::WANT_NEWRESOLVE |
                            nsIXPCScriptable::WANT_HASINSTANCE |
                            nsIXPCScriptable::DONT_ENUM_QUERY_INTERFACE)
@@ -2509,31 +2500,16 @@ nsDOMClassInfo::Init()
   DOM_CLASSINFO_MAP_BEGIN(BarProp, nsIDOMBarProp)
     DOM_CLASSINFO_MAP_ENTRY(nsIDOMBarProp)
   DOM_CLASSINFO_MAP_END
 
   DOM_CLASSINFO_MAP_BEGIN(History, nsIDOMHistory)
     DOM_CLASSINFO_MAP_ENTRY(nsIDOMHistory)
   DOM_CLASSINFO_MAP_END
 
-  DOM_CLASSINFO_MAP_BEGIN_MAYBE_DISABLE(PerformanceTiming, nsIDOMPerformanceTiming,
-                                        !nsGlobalWindow::HasPerformanceSupport())
-    DOM_CLASSINFO_MAP_ENTRY(nsIDOMPerformanceTiming)
-  DOM_CLASSINFO_MAP_END
-
-  DOM_CLASSINFO_MAP_BEGIN_MAYBE_DISABLE(PerformanceNavigation, nsIDOMPerformanceNavigation,
-                                        !nsGlobalWindow::HasPerformanceSupport())
-    DOM_CLASSINFO_MAP_ENTRY(nsIDOMPerformanceNavigation)
-  DOM_CLASSINFO_MAP_END
-
-  DOM_CLASSINFO_MAP_BEGIN_MAYBE_DISABLE(Performance, nsIDOMPerformance,
-                                        !nsGlobalWindow::HasPerformanceSupport())
-    DOM_CLASSINFO_MAP_ENTRY(nsIDOMPerformance)
-  DOM_CLASSINFO_MAP_END
-
   DOM_CLASSINFO_MAP_BEGIN(Screen, nsIDOMScreen)
     DOM_CLASSINFO_MAP_ENTRY(nsIDOMScreen)
     DOM_CLASSINFO_MAP_ENTRY(nsIDOMEventTarget)
   DOM_CLASSINFO_MAP_END
 
   DOM_CLASSINFO_MAP_BEGIN_NO_CLASS_IF(DOMPrototype, nsIDOMDOMConstructor)
     DOM_CLASSINFO_MAP_ENTRY(nsIDOMDOMConstructor)
   DOM_CLASSINFO_MAP_END
--- a/dom/base/nsDOMClassInfoClasses.h
+++ b/dom/base/nsDOMClassInfoClasses.h
@@ -7,19 +7,16 @@ DOMCI_CLASS(Window)
 DOMCI_CLASS(Location)
 DOMCI_CLASS(Navigator)
 DOMCI_CLASS(Plugin)
 DOMCI_CLASS(PluginArray)
 DOMCI_CLASS(MimeType)
 DOMCI_CLASS(MimeTypeArray)
 DOMCI_CLASS(BarProp)
 DOMCI_CLASS(History)
-DOMCI_CLASS(PerformanceTiming)
-DOMCI_CLASS(PerformanceNavigation)
-DOMCI_CLASS(Performance)
 DOMCI_CLASS(Screen)
 DOMCI_CLASS(DOMPrototype)
 DOMCI_CLASS(DOMConstructor)
 
 // Core classes
 DOMCI_CLASS(XMLDocument)
 DOMCI_CLASS(DocumentType)
 DOMCI_CLASS(DOMImplementation)
--- a/dom/base/nsDOMNavigationTiming.cpp
+++ b/dom/base/nsDOMNavigationTiming.cpp
@@ -19,17 +19,17 @@ nsDOMNavigationTiming::nsDOMNavigationTi
 
 nsDOMNavigationTiming::~nsDOMNavigationTiming()
 {
 }
 
 void
 nsDOMNavigationTiming::Clear()
 {
-  mNavigationType = nsIDOMPerformanceNavigation::TYPE_RESERVED;
+  mNavigationType = mozilla::dom::PerformanceNavigation::TYPE_RESERVED;
   mNavigationStart = 0;
   mFetchStart = 0;
   mRedirectStart = 0;
   mRedirectEnd = 0;
   mRedirectCount = 0;
   mBeforeUnloadStart = 0;
   mUnloadStart = 0;
   mUnloadEnd = 0;
--- a/dom/base/nsDOMNavigationTiming.h
+++ b/dom/base/nsDOMNavigationTiming.h
@@ -1,26 +1,39 @@
 /* -*- Mode: C++; 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/. */
 
 #ifndef nsDOMNavigationTiming_h___
 #define nsDOMNavigationTiming_h___
 
-#include "nsIDOMPerformanceTiming.h"
-#include "nsIDOMPerformanceNavigation.h"
 #include "nscore.h"
 #include "nsCOMPtr.h"
 #include "nsCOMArray.h"
 #include "mozilla/TimeStamp.h"
 #include "nsIURI.h"
 
 class nsDOMNavigationTimingClock;
 
+typedef unsigned long long DOMTimeMilliSec;
+typedef double DOMHighResTimeStamp;
+typedef unsigned short nsDOMPerformanceNavigationType;
+
+namespace mozilla {
+namespace dom {
+namespace PerformanceNavigation {
+static const nsDOMPerformanceNavigationType TYPE_NAVIGATE = 0;
+static const nsDOMPerformanceNavigationType TYPE_RELOAD = 1;
+static const nsDOMPerformanceNavigationType TYPE_BACK_FORWARD = 2;
+static const nsDOMPerformanceNavigationType TYPE_RESERVED = 255;
+}
+}
+}
+
 class nsDOMNavigationTiming
 {
 public:
   nsDOMNavigationTiming();
 
   NS_INLINE_DECL_REFCOUNTING(nsDOMNavigationTiming)
 
   nsDOMPerformanceNavigationType GetType() const {
--- a/dom/base/nsGlobalWindow.cpp
+++ b/dom/base/nsGlobalWindow.cpp
@@ -2915,17 +2915,17 @@ nsGlobalWindow::GetHistory(nsIDOMHistory
     }
   }
 
   NS_IF_ADDREF(*aHistory = mHistory);
   return NS_OK;
 }
 
 NS_IMETHODIMP
-nsGlobalWindow::GetPerformance(nsIDOMPerformance** aPerformance)
+nsGlobalWindow::GetPerformance(nsISupports** aPerformance)
 {
   FORWARD_TO_INNER(GetPerformance, (aPerformance), NS_ERROR_NOT_INITIALIZED);
 
   *aPerformance = nsnull;
 
   if (nsGlobalWindow::HasPerformanceSupport()) {
     if (!mPerformance) {
       if (!mDoc) {
--- a/dom/base/nsPerformance.cpp
+++ b/dom/base/nsPerformance.cpp
@@ -4,17 +4,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "nsPerformance.h"
 #include "TimeStamp.h"
 #include "nsCOMPtr.h"
 #include "nscore.h"
 #include "nsIDocShell.h"
 #include "nsITimedChannel.h"
-#include "nsDOMClassInfoID.h"
 #include "nsDOMNavigationTiming.h"
 #include "nsContentUtils.h"
 #include "nsIDOMWindow.h"
 #include "mozilla/dom/PerformanceBinding.h"
 #include "mozilla/dom/PerformanceTimingBinding.h"
 #include "mozilla/dom/PerformanceNavigationBinding.h"
 
 using namespace mozilla;
@@ -23,261 +22,119 @@ DOMCI_DATA(PerformanceTiming, nsPerforma
 
 NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_1(nsPerformanceTiming, mPerformance)
 NS_IMPL_CYCLE_COLLECTING_ADDREF(nsPerformanceTiming)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(nsPerformanceTiming)
 
 // QueryInterface implementation for nsPerformanceTiming
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsPerformanceTiming)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
-  NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIDOMPerformanceTiming)
-  NS_INTERFACE_MAP_ENTRY(nsIDOMPerformanceTiming)
-  NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(PerformanceTiming)
+  NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
 nsPerformanceTiming::nsPerformanceTiming(nsPerformance* aPerformance,
                                          nsITimedChannel* aChannel)
   : mPerformance(aPerformance),
     mChannel(aChannel)
 {
   MOZ_ASSERT(aPerformance, "Parent performance object should be provided");
   SetIsDOMBinding();
 }
 
 nsPerformanceTiming::~nsPerformanceTiming()
 {
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetNavigationStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetNavigationStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetUnloadEventStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetUnloadEventStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetUnloadEventEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetUnloadEventEnd();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetRedirectStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetRedirectStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetRedirectEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetRedirectEnd();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetFetchStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetFetchStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomainLookupStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomainLookupStart();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetDomainLookupStart() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetDomainLookupStart(&stamp);
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomainLookupEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomainLookupEnd();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetDomainLookupEnd() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetDomainLookupEnd(&stamp);
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetConnectStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetConnectStart();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetConnectStart() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetConnectStart(&stamp);
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetConnectEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetConnectEnd();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetConnectEnd() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetConnectEnd(&stamp);
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetRequestStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetRequestStart();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetRequestStart() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetRequestStart(&stamp);
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetResponseStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetResponseStart();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetResponseStart() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetResponseStart(&stamp);
   mozilla::TimeStamp cacheStamp;
   mChannel->GetCacheReadStart(&cacheStamp);
   if (stamp.IsNull() || (!cacheStamp.IsNull() && cacheStamp < stamp)) {
     stamp = cacheStamp;
   }
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetResponseEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetResponseEnd();
-  return NS_OK;
-}
-
 DOMTimeMilliSec
 nsPerformanceTiming::GetResponseEnd() const
 {
   if (!mChannel) {
     return GetFetchStart();
   }
   mozilla::TimeStamp stamp;
   mChannel->GetResponseEnd(&stamp);
   mozilla::TimeStamp cacheStamp;
   mChannel->GetCacheReadEnd(&cacheStamp);
   if (stamp.IsNull() || (!cacheStamp.IsNull() && cacheStamp < stamp)) {
     stamp = cacheStamp;
   }
   return GetDOMTiming()->TimeStampToDOMOrFetchStart(stamp);
 }
 
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomLoading(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomLoading();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomInteractive(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomInteractive();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomContentLoadedEventStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomContentLoadedEventStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomContentLoadedEventEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomContentLoadedEventEnd();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetDomComplete(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetDomComplete();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetLoadEventStart(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetLoadEventStart();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceTiming::GetLoadEventEnd(DOMTimeMilliSec* aTime)
-{
-  *aTime = GetLoadEventEnd();
-  return NS_OK;
-}
-
 JSObject*
 nsPerformanceTiming::WrapObject(JSContext *cx, JSObject *scope,
                                 bool *triedToWrap)
 {
   return dom::PerformanceTimingBinding::Wrap(cx, scope, this,
                                              triedToWrap);
 }
 
@@ -287,47 +144,30 @@ DOMCI_DATA(PerformanceNavigation, nsPerf
 
 NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE_1(nsPerformanceNavigation, mPerformance)
 NS_IMPL_CYCLE_COLLECTING_ADDREF(nsPerformanceNavigation)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(nsPerformanceNavigation)
 
 // QueryInterface implementation for nsPerformanceNavigation
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsPerformanceNavigation)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
-  NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIDOMPerformanceNavigation)
-  NS_INTERFACE_MAP_ENTRY(nsIDOMPerformanceNavigation)
-  NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(PerformanceNavigation)
+  NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
 nsPerformanceNavigation::nsPerformanceNavigation(nsPerformance* aPerformance)
   : mPerformance(aPerformance)
 {
   MOZ_ASSERT(aPerformance, "Parent performance object should be provided");
   SetIsDOMBinding();
 }
 
 nsPerformanceNavigation::~nsPerformanceNavigation()
 {
 }
 
-NS_IMETHODIMP
-nsPerformanceNavigation::GetType(
-    nsDOMPerformanceNavigationType* aNavigationType)
-{
-  *aNavigationType = GetType();
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformanceNavigation::GetRedirectCount(PRUint16* aRedirectCount)
-{
-  *aRedirectCount = GetRedirectCount();
-  return NS_OK;
-}
-
 JSObject*
 nsPerformanceNavigation::WrapObject(JSContext *cx, JSObject *scope,
                                     bool *triedToWrap)
 {
   return dom::PerformanceNavigationBinding::Wrap(cx, scope, this,
                                                  triedToWrap);
 }
 
@@ -353,67 +193,38 @@ nsPerformance::nsPerformance(nsIDOMWindo
 
 nsPerformance::~nsPerformance()
 {
 }
 
 // QueryInterface implementation for nsPerformance
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsPerformance)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
-  NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIDOMPerformance)
-  NS_INTERFACE_MAP_ENTRY(nsIDOMPerformance)
-  NS_DOM_INTERFACE_MAP_ENTRY_CLASSINFO(Performance)
+  NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
 
-//
-// nsIDOMPerformance methods
-//
-
 nsPerformanceTiming*
 nsPerformance::GetTiming()
 {
   if (!mTiming) {
     mTiming = new nsPerformanceTiming(this, mChannel);
   }
   return mTiming;
 }
 
-NS_IMETHODIMP
-nsPerformance::GetTiming(nsIDOMPerformanceTiming** aTiming)
-{
-  nsRefPtr<nsPerformanceTiming> timing = GetTiming();
-  timing.forget(aTiming);
-  return NS_OK;
-}
-
 nsPerformanceNavigation*
 nsPerformance::GetNavigation()
 {
   if (!mNavigation) {
     mNavigation = new nsPerformanceNavigation(this);
   }
   return mNavigation;
 }
 
-NS_IMETHODIMP
-nsPerformance::GetNavigation(nsIDOMPerformanceNavigation** aNavigation)
-{
-  nsRefPtr<nsPerformanceNavigation> navigation = GetNavigation();
-  navigation.forget(aNavigation);
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsPerformance::Now(DOMHighResTimeStamp* aNow)
-{
-  *aNow = Now();
-  return NS_OK;
-}
-
 DOMHighResTimeStamp
 nsPerformance::Now()
 {
   return GetDOMTiming()->TimeStampToDOMHighRes(mozilla::TimeStamp::Now());
 }
 
 JSObject*
 nsPerformance::WrapObject(JSContext *cx, JSObject *scope,
--- a/dom/base/nsPerformance.h
+++ b/dom/base/nsPerformance.h
@@ -1,40 +1,37 @@
 /* -*- Mode: C++; 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/. */
 #ifndef nsPerformance_h___
 #define nsPerformance_h___
 
-#include "nsIDOMPerformance.h"
-#include "nsIDOMPerformanceTiming.h"
-#include "nsIDOMPerformanceNavigation.h"
 #include "nscore.h"
 #include "nsCOMPtr.h"
 #include "nsAutoPtr.h"
 #include "mozilla/Attributes.h"
 #include "nsWrapperCache.h"
 #include "nsDOMNavigationTiming.h"
 
 class nsIURI;
 class nsITimedChannel;
+class nsIDOMWindow;
 class nsPerformance;
 struct JSObject;
 struct JSContext;
 
 // Script "performance.timing" object
-class nsPerformanceTiming MOZ_FINAL : public nsIDOMPerformanceTiming,
+class nsPerformanceTiming MOZ_FINAL : public nsISupports,
                                       public nsWrapperCache
 {
 public:
   nsPerformanceTiming(nsPerformance* aPerformance,
                       nsITimedChannel* aChannel);
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_NSIDOMPERFORMANCETIMING
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsPerformanceTiming)
 
   nsDOMNavigationTiming* GetDOMTiming() const;
 
   nsPerformance* GetParentObject() const
   {
     return mPerformance;
   }
@@ -91,23 +88,22 @@ public:
 
 private:
   ~nsPerformanceTiming();
   nsRefPtr<nsPerformance> mPerformance;
   nsCOMPtr<nsITimedChannel> mChannel;
 };
 
 // Script "performance.navigation" object
-class nsPerformanceNavigation MOZ_FINAL : public nsIDOMPerformanceNavigation,
+class nsPerformanceNavigation MOZ_FINAL : public nsISupports,
                                           public nsWrapperCache
 {
 public:
   explicit nsPerformanceNavigation(nsPerformance* aPerformance);
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_NSIDOMPERFORMANCENAVIGATION
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsPerformanceNavigation)
 
   nsDOMNavigationTiming* GetDOMTiming() const;
 
   nsPerformance* GetParentObject() const
   {
     return mPerformance;
   }
@@ -123,26 +119,25 @@ public:
   }
 
 private:
   ~nsPerformanceNavigation();
   nsRefPtr<nsPerformance> mPerformance;
 };
 
 // Script "performance" object
-class nsPerformance MOZ_FINAL : public nsIDOMPerformance,
+class nsPerformance MOZ_FINAL : public nsISupports,
                                 public nsWrapperCache
 {
 public:
   nsPerformance(nsIDOMWindow* aWindow,
                 nsDOMNavigationTiming* aDOMTiming,
                 nsITimedChannel* aChannel);
 
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_NSIDOMPERFORMANCE
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(nsPerformance)
 
   nsDOMNavigationTiming* GetDOMTiming() const
   {
     return mDOMTiming;
   }
 
   nsIDOMWindow* GetParentObject() const
--- a/dom/interfaces/base/Makefile.in
+++ b/dom/interfaces/base/Makefile.in
@@ -49,17 +49,14 @@ XPIDLSRCS =					\
         nsIDOMClientRectList.idl		\
 	nsIFocusManager.idl			\
 	nsIQueryContentEventResult.idl		\
 	nsITabChild.idl				\
 	nsITabParent.idl			\
 	nsIDOMGlobalPropertyInitializer.idl	\
 	nsIDOMGlobalObjectConstructor.idl \
 	nsIStructuredCloneContainer.idl		\
-	nsIDOMPerformance.idl			\
-	nsIDOMPerformanceTiming.idl		\
-	nsIDOMPerformanceNavigation.idl		\
 	nsIIdleObserver.idl			\
 	$(NULL)
 
 include $(topsrcdir)/config/rules.mk
 
 XPIDL_FLAGS += -I$(topsrcdir)/dom/interfaces/events/
--- a/dom/interfaces/base/domstubs.idl
+++ b/dom/interfaces/base/domstubs.idl
@@ -7,18 +7,16 @@
 
 %{C++
 class nsWrapperCache;
 %}
 
 [ptr] native nsWrapperCachePtr(nsWrapperCache);
 
 typedef unsigned long long DOMTimeStamp;
-typedef unsigned long long DOMTimeMilliSec;
-typedef double DOMHighResTimeStamp;
 
 // Core
 interface nsIDOMAttr;
 interface nsIDOMCDATASection;
 interface nsIDOMCharacterData;
 interface nsIDOMComment;
 interface nsIDOMDOMImplementation;
 interface nsIDOMDocument;
deleted file mode 100644
--- a/dom/interfaces/base/nsIDOMPerformance.idl
+++ /dev/null
@@ -1,18 +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"
-interface nsIDOMPerformanceTiming;
-interface nsIDOMPerformanceNavigation;
-
-[scriptable, uuid(ac274ec8-ee9f-44ef-b2f0-b13c22225a98)]
-interface nsIDOMPerformance : nsISupports
-{
-  readonly attribute nsIDOMPerformanceTiming timing;
-  readonly attribute nsIDOMPerformanceNavigation navigation;
-
-  DOMHighResTimeStamp now();
-};
-
deleted file mode 100644
--- a/dom/interfaces/base/nsIDOMPerformanceNavigation.idl
+++ /dev/null
@@ -1,21 +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"
-
-typedef unsigned short nsDOMPerformanceNavigationType;
-
-[scriptable, uuid(a2132ad8-a841-4285-a140-338e8de6c2e0)]
-interface nsIDOMPerformanceNavigation : nsISupports
-{
-  const nsDOMPerformanceNavigationType TYPE_NAVIGATE = 0;
-  const nsDOMPerformanceNavigationType TYPE_RELOAD = 1;
-  const nsDOMPerformanceNavigationType TYPE_BACK_FORWARD = 2;
-  const nsDOMPerformanceNavigationType TYPE_RESERVED = 255;
-
-  readonly attribute nsDOMPerformanceNavigationType type;
-  readonly attribute unsigned short redirectCount;
-};
-
deleted file mode 100644
--- a/dom/interfaces/base/nsIDOMPerformanceTiming.idl
+++ /dev/null
@@ -1,32 +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"
-
-[scriptable, uuid(8e09c825-da49-4a39-876b-ce2ff767dbe1)]
-interface nsIDOMPerformanceTiming : nsISupports
-{
-  readonly attribute DOMTimeMilliSec navigationStart;
-  readonly attribute DOMTimeMilliSec unloadEventStart;
-  readonly attribute DOMTimeMilliSec unloadEventEnd;
-  readonly attribute DOMTimeMilliSec redirectStart;
-  readonly attribute DOMTimeMilliSec redirectEnd;
-  readonly attribute DOMTimeMilliSec fetchStart;
-  readonly attribute DOMTimeMilliSec domainLookupStart;
-  readonly attribute DOMTimeMilliSec domainLookupEnd;
-  readonly attribute DOMTimeMilliSec connectStart;
-  readonly attribute DOMTimeMilliSec connectEnd;
-  readonly attribute DOMTimeMilliSec requestStart;
-  readonly attribute DOMTimeMilliSec responseStart;
-  readonly attribute DOMTimeMilliSec responseEnd;
-  readonly attribute DOMTimeMilliSec domLoading;
-  readonly attribute DOMTimeMilliSec domInteractive;
-  readonly attribute DOMTimeMilliSec domContentLoadedEventStart;
-  readonly attribute DOMTimeMilliSec domContentLoadedEventEnd;
-  readonly attribute DOMTimeMilliSec domComplete;
-  readonly attribute DOMTimeMilliSec loadEventStart;
-  readonly attribute DOMTimeMilliSec loadEventEnd;
-};
-
--- a/dom/interfaces/base/nsIDOMWindow.idl
+++ b/dom/interfaces/base/nsIDOMWindow.idl
@@ -6,17 +6,16 @@
 #include "domstubs.idl"
 
 interface nsIFrameRequestCallback;
 interface nsIControllers;
 interface nsIDOMBlob;
 interface nsIDOMLocation;
 interface nsIDOMMediaQueryList;
 interface nsIDOMOfflineResourceList;
-interface nsIDOMPerformance;
 interface nsIDOMStorage;
 interface nsIPrompt;
 interface nsISelection;
 interface nsIVariant;
 
 [scriptable, uuid(8fc58f56-f769-4368-a098-edd08550cf1a)]
 interface nsIDOMMozURLProperty : nsISupports
 {
@@ -503,17 +502,17 @@ interface nsIDOMWindow : nsISupports
 };
 
 [scriptable, uuid(2146c906-57f7-486c-a1b4-8cdb57ef577f)]
 interface nsIDOMWindowPerformance : nsISupports
 {
   /**
    * A namespace to hold performance related data and statistics.
    */
-  readonly attribute nsIDOMPerformance performance;
+  readonly attribute nsISupports performance;
 };
 
 /**
  * Empty interface for compatibility with older versions.
  * @deprecated Use nsIDOMWindow instead
  */
 [scriptable, uuid(8da641ab-906a-456e-97f2-b77df4ca2d95)]
 interface nsIDOMWindowInternal : nsIDOMWindow {};