зеркало из https://github.com/mozilla/pjs.git
Added back commented out destruction of XImages and buffers
This commit is contained in:
Родитель
7023fda1bb
Коммит
9ef7f93f84
|
@ -53,23 +53,23 @@ nsImageUnix :: ~nsImageUnix()
|
|||
XDestroyImage(mImage);
|
||||
mImage = nsnull;
|
||||
}
|
||||
if(nsnull != mConvertedBits)
|
||||
{
|
||||
//NOD delete[] (PRUint8*)mConvertedBits;
|
||||
|
||||
if(nsnull != mConvertedBits) {
|
||||
delete[] (PRUint8*)mConvertedBits;
|
||||
mConvertedBits = nsnull;
|
||||
}
|
||||
}
|
||||
|
||||
if(nsnull != mImageBits)
|
||||
{
|
||||
//NOD delete[] (PRUint8*)mImageBits;
|
||||
if(nsnull != mImageBits) {
|
||||
delete[] (PRUint8*)mImageBits;
|
||||
mImageBits = nsnull;
|
||||
}
|
||||
//NOD if(nsnull!= mColorMap)
|
||||
//NOD delete mColorMap;
|
||||
}
|
||||
|
||||
//NOD if (nsnull != mAlphaBits) {
|
||||
//NOD delete mAlphaBits;
|
||||
//NOD }
|
||||
if(nsnull!= mColorMap)
|
||||
delete mColorMap;
|
||||
|
||||
if (nsnull != mAlphaBits) {
|
||||
delete mAlphaBits;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -79,16 +79,16 @@ NS_IMPL_ISUPPORTS(nsImageUnix, kIImageIID);
|
|||
|
||||
nsresult nsImageUnix :: Init(PRInt32 aWidth, PRInt32 aHeight, PRInt32 aDepth,nsMaskRequirements aMaskRequirements)
|
||||
{
|
||||
//NOD if(nsnull != mImageBits)
|
||||
//NOD delete[] (PRUint8*)mImageBits;
|
||||
if(nsnull != mImageBits)
|
||||
delete[] (PRUint8*)mImageBits;
|
||||
|
||||
//NOD if(nsnull != mColorMap)
|
||||
//NOD delete[] mColorMap;
|
||||
if(nsnull != mColorMap)
|
||||
delete[] mColorMap;
|
||||
|
||||
//NOD if (nsnull != mImage) {
|
||||
//NOD XDestroyImage(mImage);
|
||||
//NOD mImage = nsnull;
|
||||
//NOD }
|
||||
if (nsnull != mImage) {
|
||||
XDestroyImage(mImage);
|
||||
mImage = nsnull;
|
||||
}
|
||||
mWidth = aWidth;
|
||||
mHeight = aHeight;
|
||||
mDepth = aDepth;
|
||||
|
|
Загрузка…
Ссылка в новой задаче