Page 1 of 1

"use of 'auto' variable" err in Dev C++

Posted: Wed Nov 10, 2004 2:53 am
by PriestlyD
Here's the deal, chaps:

I'm trying to create a simple event reciever for my test gui in my own little tech demo.

Here's the receiver:
class MyEventReceiver : public IEventReceiver
{
public:
virtual bool OnEvent(SEvent event)
{
if (event.EventType == EET_GUI_EVENT)
{
s32 id = event.GUIEvent.Caller->getID();

switch(event.GUIEvent.EventType)
{

case EGET_BUTTON_CLICKED:

if (id == 101)
{
device->closeDevice();
return true;
}

if (id == 102)
{
if (planet->isVisible(true))
{
planet->setVisible(false);
}
else
{
planet->setVisible(true);
}
}



break;
}
}

return false;
}
};
This portion of my code comes after all the declarations, and produces no other errors other than:

use of 'auto' variable from containing funtion followed be the decleration of one of my pointers.

I'm not looking for a definitive answer to the problem as much as what it exactly means.

Thanks for any assistance in advance. :)