Bug 614392 patch 2: Update concrete imgIContainer::GetType() implementations with NS_IMETHOD_(). r=joe sr=bz a=blocking-beta9+

This commit is contained in:
Daniel Holbert 2010-12-07 10:40:28 -08:00
Родитель f715fd8c32
Коммит b0db35142b
4 изменённых файлов: 22 добавлений и 8 удалений

Просмотреть файл

@ -420,10 +420,18 @@ RasterImage::GetType(PRUint16 *aType)
{
NS_ENSURE_ARG_POINTER(aType);
*aType = imgIContainer::TYPE_RASTER;
*aType = GetType();
return NS_OK;
}
//******************************************************************************
/* [noscript, notxpcom] PRUint16 GetType(); */
NS_IMETHODIMP_(PRUint16)
RasterImage::GetType()
{
return imgIContainer::TYPE_RASTER;
}
imgFrame*
RasterImage::GetImgFrame(PRUint32 framenum)
{

Просмотреть файл

@ -169,6 +169,7 @@ public:
NS_SCRIPTABLE NS_IMETHOD GetWidth(PRInt32 *aWidth);
NS_SCRIPTABLE NS_IMETHOD GetHeight(PRInt32 *aHeight);
NS_SCRIPTABLE NS_IMETHOD GetType(PRUint16 *aType);
NS_IMETHOD_(PRUint16) GetType(void);
NS_SCRIPTABLE NS_IMETHOD GetAnimated(PRBool *aAnimated);
NS_SCRIPTABLE NS_IMETHOD GetCurrentFrameIsOpaque(PRBool *aCurrentFrameIsOpaque);
NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval NS_OUTPARAM);
@ -188,9 +189,6 @@ public:
virtual nsresult StartAnimation();
virtual nsresult StopAnimation();
// C++-only version of imgIContainer::GetType, for convenience
virtual PRUint16 GetType() { return imgIContainer::TYPE_RASTER; }
// Methods inherited from Image
nsresult Init(imgIDecoderObserver* aObserver,
const char* aMimeType,

Просмотреть файл

@ -346,10 +346,20 @@ VectorImage::GetHeight(PRInt32* aHeight)
NS_IMETHODIMP
VectorImage::GetType(PRUint16* aType)
{
*aType = imgIContainer::TYPE_VECTOR;
NS_ENSURE_ARG_POINTER(aType);
*aType = GetType();
return NS_OK;
}
//******************************************************************************
/* [noscript, notxpcom] PRUint16 GetType(); */
NS_IMETHODIMP_(PRUint16)
VectorImage::GetType()
{
return imgIContainer::TYPE_VECTOR;
}
//******************************************************************************
/* readonly attribute boolean animated; */
NS_IMETHODIMP

Просмотреть файл

@ -64,6 +64,7 @@ public:
NS_SCRIPTABLE NS_IMETHOD GetWidth(PRInt32 *aWidth);
NS_SCRIPTABLE NS_IMETHOD GetHeight(PRInt32 *aHeight);
NS_SCRIPTABLE NS_IMETHOD GetType(PRUint16 *aType);
NS_IMETHOD_(PRUint16) GetType(void);
NS_SCRIPTABLE NS_IMETHOD GetAnimated(PRBool *aAnimated);
NS_SCRIPTABLE NS_IMETHOD GetCurrentFrameIsOpaque(PRBool *aCurrentFrameIsOpaque);
NS_IMETHOD GetFrame(PRUint32 aWhichFrame, PRUint32 aFlags, gfxASurface **_retval NS_OUTPARAM);
@ -80,9 +81,6 @@ public:
VectorImage(imgStatusTracker* aStatusTracker = nsnull);
virtual ~VectorImage();
// C++-only version of imgIContainer::GetType, for convenience
PRUint16 GetType() { return imgIContainer::TYPE_VECTOR; }
// Methods inherited from Image
nsresult Init(imgIDecoderObserver* aObserver,
const char* aMimeType,