When I select to have the callback KeyPressed() inserted from the “Extra Callbacks to insert” menu in the Projucer, it uses:
bool component::keyPressed (const KeyPress& key)
Then, if I add a public KeyListener into the parent field of the Projucer setup, so that it inherits from KeyListener, I get the error "Allocating an object of abstract class type “myGuiClass” - “Unimplemented pure virtual method “keyPressed” in myGuiClass”.
So, it turns out that the method injected by selecting from the “Extra Callbacks to insert” menu isn’t the full signature needed, you actually need to override this:
virtual bool keyPressed (const KeyPress &key, Component *originatingComponent)=0
Am I doing something incorrectly? or should the projucer insert the correct method signature for this? When I unselect that option to have projucer automatically insert it, and insert the correct one and override it, my error goes away.