From ef9b45c5d9cb0e85c27ba980cb849afe22446949 Mon Sep 17 00:00:00 2001 From: Robert O'Callahan Date: Fri, 4 Jan 2013 02:23:09 +1300 Subject: [PATCH] Bug 825866. Part 4: Remove nsIView's IID as it's not needed anymore. r=tnikkel --- view/public/nsIView.h | 10 ---------- view/src/nsView.cpp | 19 ------------------- 2 files changed, 29 deletions(-) diff --git a/view/public/nsIView.h b/view/public/nsIView.h index 42c3820914b..18112bca8bd 100644 --- a/view/public/nsIView.h +++ b/view/public/nsIView.h @@ -34,10 +34,6 @@ enum nsViewVisibility { nsViewVisibility_kShow = 1 }; -#define NS_IVIEW_IID \ -{ 0x7f979fcc, 0xa15a, 0x4f8a, \ - { 0x8b, 0x68, 0xa4, 0x16, 0xa1, 0x87, 0xad, 0xdc } } - // Public view flags // Indicates that the view is using auto z-indexing @@ -69,8 +65,6 @@ enum nsViewVisibility { class nsIView MOZ_FINAL : public nsIWidgetListener { public: - NS_DECLARE_STATIC_IID_ACCESSOR(NS_IVIEW_IID) - nsIView(nsViewManager* aViewManager = nullptr, nsViewVisibility aVisibility = nsViewVisibility_kShow); @@ -347,8 +341,6 @@ public: // origin) to view origin expressed in appunits of this. nsPoint ViewToWidgetOffset() const { return mViewToWidgetOffset; } - NS_IMETHOD QueryInterface(const nsIID& aIID, void** aInstancePtr); - /** * Called to indicate that the position of the view has been changed. * The specified coordinates are in the parent view's coordinate space. @@ -488,6 +480,4 @@ protected: bool mInAlternatePaint; }; -NS_DEFINE_STATIC_IID_ACCESSOR(nsIView, NS_IVIEW_IID) - #endif diff --git a/view/src/nsView.cpp b/view/src/nsView.cpp index 53234abbd58..e4d87c22f4a 100644 --- a/view/src/nsView.cpp +++ b/view/src/nsView.cpp @@ -117,25 +117,6 @@ void nsIView::DestroyWidget() } } -nsresult nsIView::QueryInterface(const nsIID& aIID, void** aInstancePtr) -{ - if (nullptr == aInstancePtr) { - return NS_ERROR_NULL_POINTER; - } - - NS_ASSERTION(!aIID.Equals(NS_GET_IID(nsISupports)), - "Someone expects views to be ISupports-derived!"); - - *aInstancePtr = nullptr; - - if (aIID.Equals(NS_GET_IID(nsIView))) { - *aInstancePtr = (void*)(nsIView*)this; - return NS_OK; - } - - return NS_NOINTERFACE; -} - nsIView* nsIView::GetViewFor(nsIWidget* aWidget) { NS_PRECONDITION(nullptr != aWidget, "null widget ptr");