зеркало из https://github.com/mozilla/pjs.git
Modified nsRegionWin::Init to allow for init to be called multiple times on the same instance without leaking HRGN handles. The view manager re-uses nsIRegions by calling Init on an existing instance. bug=19114; r=buster@netscape.com
This commit is contained in:
Родитель
bcc9cef6bd
Коммит
670cd92de5
|
@ -58,6 +58,10 @@ NS_IMPL_RELEASE(nsRegionWin)
|
|||
|
||||
nsresult nsRegionWin :: Init(void)
|
||||
{
|
||||
if (NULL != mRegion) {
|
||||
::DeleteObject(mRegion);
|
||||
FreeRects(nsnull);
|
||||
}
|
||||
mRegion = ::CreateRectRgn(0, 0, 0, 0);
|
||||
mRegionType = NULLREGION;
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче