Bug 505385 - Part 16: Remove nsStubImageDecoderObserver. r=joe
authorJosh Matthews <josh@joshmatthews.net>
Fri, 12 Oct 2012 12:11:23 -0400
changeset 110240 353b9b430a96f6058c74fdebd563735e378aec3b
parent 110239 395f1c3e4bc348edc2f3949bb47553190fec4951
child 110241 90b6d2a44348697568047fcc43e3e3dae5ce6370
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
reviewersjoe
bugs505385
milestone19.0a1
Bug 505385 - Part 16: Remove nsStubImageDecoderObserver. r=joe
content/base/src/Makefile.in
content/base/src/nsStubImageDecoderObserver.cpp
content/base/src/nsStubImageDecoderObserver.h
--- a/content/base/src/Makefile.in
+++ b/content/base/src/Makefile.in
@@ -23,17 +23,16 @@ EXPORTS		= \
 		nsGkAtomList.h \
 		nsGkAtoms.h \
 		nsNodeInfoManager.h \
 		nsNodeUtils.h \
 		nsPropertyTable.h \
 		nsRange.h \
 		nsScriptLoader.h \
 		nsStubDocumentObserver.h \
-		nsStubImageDecoderObserver.h \
 		nsStubMutationObserver.h \
 		nsTextFragment.h \
 		mozAutoDocUpdate.h \
 		nsFrameMessageManager.h \
 		nsAttrAndChildArray.h \
 		nsAttrValue.h \
 		nsAttrValueInlines.h \
 		nsCrossSiteListenerProxy.h \
@@ -104,17 +103,16 @@ CPPSRCS		= \
 		nsObjectLoadingContent.cpp \
 		nsPlainTextSerializer.cpp \
 		nsPropertyTable.cpp \
 		nsRange.cpp \
 		nsReferencedElement.cpp \
 		nsScriptElement.cpp \
 		nsScriptLoader.cpp \
 		nsStubDocumentObserver.cpp \
-		nsStubImageDecoderObserver.cpp \
 		nsStubMutationObserver.cpp \
 		nsStyledElement.cpp \
 		nsStyleLinkElement.cpp \
 		nsSyncLoadService.cpp \
 		nsTextFragment.cpp \
 		nsTextNode.cpp \
 		nsTraversal.cpp \
 		nsTreeSanitizer.cpp \
deleted file mode 100644
--- a/content/base/src/nsStubImageDecoderObserver.cpp
+++ /dev/null
@@ -1,89 +0,0 @@
-/* vim: set shiftwidth=4 tabstop=8 autoindent cindent expandtab: */
-/* 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 "nsStubImageDecoderObserver.h"
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStartRequest(imgIRequest *aRequest)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStartDecode(imgIRequest *aRequest)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStartContainer(imgIRequest *aRequest,
-                                             imgIContainer *aContainer)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStartFrame(imgIRequest *aRequest,
-                                         uint32_t aFrame)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnDataAvailable(imgIRequest *aRequest,
-                                            bool aCurrentFrame,
-                                            const nsIntRect * aRect)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStopFrame(imgIRequest *aRequest,
-                                        uint32_t aFrame)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStopContainer(imgIRequest *aRequest,
-                                            imgIContainer *aContainer)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStopDecode(imgIRequest *aRequest,
-                                         nsresult status,
-                                         const PRUnichar *statusArg)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnStopRequest(imgIRequest *aRequest, 
-                                          bool aIsLastPart)
-{
-    return NS_OK;
-}
-
-NS_IMETHODIMP 
-nsStubImageDecoderObserver::OnDiscard(imgIRequest *aRequest)
-{
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::OnImageIsAnimated(imgIRequest *aRequest)
-{
-  return NS_OK;
-}
-
-NS_IMETHODIMP
-nsStubImageDecoderObserver::FrameChanged(imgIRequest* aRequest,
-                                         imgIContainer *aContainer,
-                                         const nsIntRect *aDirtyRect)
-{
-    return NS_OK;
-}
deleted file mode 100644
--- a/content/base/src/nsStubImageDecoderObserver.h
+++ /dev/null
@@ -1,35 +0,0 @@
-/* vim: set shiftwidth=4 tabstop=8 autoindent cindent expandtab: */
-/* 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/. */
-
-/*
- * nsStubImageDecoderObserver is an implementation of the imgIDecoderObserver
- * interface (except for the methods on nsISupports) that is intended to be
- * used as a base class within the content/layout library.  All methods do
- * nothing.
- */
-
-#ifndef nsStubImageDecoderObserver_h_
-#define nsStubImageDecoderObserver_h_
-
-#include "imgIDecoderObserver.h"
-
-/**
- * There are two advantages to inheriting from nsStubImageDecoderObserver
- * rather than directly from imgIDecoderObserver:
- *  1. smaller compiled code size (since there's no need for the code
- *     for the empty virtual function implementations for every
- *     imgIDecoderObserver implementation)
- *  2. the performance of document's loop over observers benefits from
- *     the fact that more of the functions called are the same (which
- *     can reduce instruction cache misses and perhaps improve branch
- *     prediction)
- */
-class nsStubImageDecoderObserver : public imgIDecoderObserver {
-public:
-    NS_DECL_IMGICONTAINEROBSERVER
-    NS_DECL_IMGIDECODEROBSERVER
-};
-
-#endif /* !defined(nsStubImageDecoderObserver_h_) */