S
snabhi
Guest
void CTest::OnPaint()
{
CPaintDC dc(this);
CBrush brush(GetSysColor(COLOR_WINDOW));
dc.FillRect(&dc.m_ps.rcPaint, &brush);
.
.
.
}
Is it necessary to call brush.DeleteObject() at the end of OnPaint() event handler?
If I don't call, would it cause GDI handle leak?
Continue reading...
{
CPaintDC dc(this);
CBrush brush(GetSysColor(COLOR_WINDOW));
dc.FillRect(&dc.m_ps.rcPaint, &brush);
.
.
.
}
Is it necessary to call brush.DeleteObject() at the end of OnPaint() event handler?
If I don't call, would it cause GDI handle leak?
Continue reading...