Original Post
I am having troubles with a specific initializer list, I'm sure I am not doing something right - but I cannot figure out what:
class CInput
{
...
public:
int INPUT_ESCAPE;
...
};
class CInputW32 : public CInput
{
private:
...
public:
...
};
CInputW32::CInputW32() :
//INPUT_ESCAPE(VK_ESCAPE) // does not work, neither dies CInput::INPUT_ESCAPE(VK_ESCAPE)
{
INPUT_ESCAPE = VK_ESCAPE; // works but I want to use initilizer list to make it look neater.
}
If I use the first initializer list code - I get:
error C2614: 'CInputW32' : illegal member initialization: 'INPUT_ESCAPE' is not a base or member
If I use the second code - I get:
error C2039: 'INPUT_ESCAPE' : is not a member of 'CInput'
Can someone please point out what I am doing wrong - or is this concept not right? Thanks for your time and patience. - Drew [Edited by - Drew_Benton on May 25, 2005 9:48:09 PM]