Author Topic: Masking the private methods from classes?  (Read 7990 times)

Offline rickg22

  • Lives here!
  • ****
  • Posts: 2283
Masking the private methods from classes?
« on: May 31, 2005, 01:13:11 am »
Guys, I was compiling CB the other day when I realized that everytime I wanted to add a new event handling method to C::B, the *WHOLE* SDK had to be recompiled. AND the plugins. :x

So I thought about this: What if we subclass say, EditorManager (as an example) this way:
Code

class EditorManager:public wxEvtHandler
{
   public:
     ...
  (no private stuff here)
}

And in the .cpp file:

Code
class myEditorManager:public EditorManager
{
   (insert your event handling methods here)
}


This way, we could tamper with it and add/remove private methods as we please, without having to recompile dependent files! :D (This would also bring stability to 3rd-party plugins, since they wouldn't have to be recompiled everytime we make an internal change in the SDK).

Pros/cons, everyone? Or is there an easier way?