c++ - Append to a parent function via classes? -


in project have parent class cwnd base win32 window classes down chain. create instances of class template declaration can have many different types of windows.

i add members so:

void cchildwndclass::onsize(hwnd hwnd, uint state, int nwidth, int nheight) {     // } 

the problem these members virtual. in events (ie: ondestroy) there code execute in every window class regardless without having copy paste each child class because overrides parents original code.

how can have functions in children classes append code themselves, rather override?

subclass class functionality desire, , subclass class of own obtain similar subclasses.

the method don't want implement, don't, , continue virtual in subsubclasses.

people use make libraries in situations.


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -