зеркало из https://github.com/mozilla/pjs.git
changed gInstanceClassName from char[256] to const char* to save space. added NS_IF_RELEASE(mFontMetrics) to destructor to fix memory leak. bug=15380, r=sfraser
This commit is contained in:
Родитель
cf345f56c9
Коммит
ec47c4b52f
|
@ -95,7 +95,7 @@ inline void GetPortVisibleRegion(GrafPtr port, RgnHandle visRgn)
|
||||||
//-------------------------------------------------------------------------
|
//-------------------------------------------------------------------------
|
||||||
nsWindow::nsWindow() : nsBaseWidget() , nsDeleteObserved(this)
|
nsWindow::nsWindow() : nsBaseWidget() , nsDeleteObserved(this)
|
||||||
{
|
{
|
||||||
strcpy(gInstanceClassName, "nsWindow");
|
gInstanceClassName = "nsWindow";
|
||||||
|
|
||||||
mParent = nsnull;
|
mParent = nsnull;
|
||||||
mBounds.SetRect(0,0,0,0);
|
mBounds.SetRect(0,0,0,0);
|
||||||
|
@ -168,6 +168,7 @@ nsWindow::~nsWindow()
|
||||||
|
|
||||||
NS_IF_RELEASE(mTempRenderingContext);
|
NS_IF_RELEASE(mTempRenderingContext);
|
||||||
|
|
||||||
|
NS_IF_RELEASE(mFontMetrics);
|
||||||
NS_IF_RELEASE(mMenuBar);
|
NS_IF_RELEASE(mMenuBar);
|
||||||
NS_IF_RELEASE(mMenuListener);
|
NS_IF_RELEASE(mMenuListener);
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче