c++ - CFormView cleanup when switching Views -


where best place cleanup gdi objects in cformview?

i have tried in cformview::ondestroy not called when switching views.

void cmyview::ondestroy() {     cformview::ondestroy();      if (m_brush.m_hobject!=null)         verify(m_brush.deleteobject()); } 

the problem have many gdi objects created in oninitialupdate created everytime user activates view. need better method of cleaning gdi objects when user switches views.


Comments

Popular posts from this blog

c# - Validate object ID from GET to POST -

node.js - Custom Model Validator SailsJS -

php - Find a regex to take part of Email -