Compile error

For help with anything that CEGUI doesn't offer straight out-of-the-box, e.g.:
- Implementation of new features, such as new Core classes, widgets, WindowRenderers, etc. ...
- Modification of any existing features for specific purposes
- Integration of CEGUI in new engines or frameworks and writing of new plugins (Renderer, Parser, ...) or modules

Moderators: CEGUI MVP, CEGUI Team

User avatar
noname
Not too shy to talk
Not too shy to talk
Posts: 21
Joined: Wed Jan 12, 2005 12:06

Compile error

Postby noname » Tue Mar 01, 2005 06:56

when I register EventListeners error occured.
error info:
ESGUISys.cpp
d:\OtherProj\cegui_mk2\Demo_Win32\CEGUISys\ESGUISys.cpp(219) : error C2661: “CEGUI::SubscriberTemplate<Ret,Args>::__ctor” : 没有重载函数接受 2 个参数(no overloaded function takes 2 parameters)
with
[
Ret=bool,
Args=const CEGUI::EventArgs &
]
and
[
Ret=bool,
Args=const CEGUI::EventArgs &
]

code:

// Create
FrameWindow* loginWnd = (FrameWindow*)WindowManager::getSingleton().createWindow((utf8*)"TaharezLook/FrameWindow", (utf8*)"LoginWindow" ) ;
rootWnd->addChildWindow(loginWnd);
loginWnd->setPosition(Point(0.0f, 0.0f));
loginWnd->setMaximumSize(Size(0.65f, 0.65f));
loginWnd->setMinimumSize(Size(0.1f, 0.1f));
loginWnd->setSize(Size(0.9f, 0.5f));
loginWnd->setCloseButtonEnabled(true);
loginWnd->setText((utf8*)"CEGUI-Demo" ) ;


//====================================================================================================
void ESGUISys::registerEventListeners(void)
{
using namespace CEGUI;

Window* loginWnd = WindowManager::getSingleton().getWindow((utf8*)"LoginWindow" ) ;
loginWnd->subscribeEvent(FrameWindow::EventCloseClicked, Event::Subscriber(&ESGUISys::quitHandler,this) ) ;

//PushButton* loginButton = (PushButton*)WindowManager::getSingleton().getWindow((utf8*)"LoginButton" ) ;
//loginButton->subscribeEvent(PushButton::EventClicked, Event::Subscriber(&ESGUISys::loginHandler, this));
//loginButton->subscribeEvent(PushButton::EventClicked, Event::Subscriber(&ESGUISys::loginHandler,this));

}

What can I do for this ? All of CEGUI is new version .

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Re: Compile error

Postby CrazyEddie » Tue Mar 01, 2005 14:10

What's the prototype for loginHandler look like?

User avatar
noname
Not too shy to talk
Not too shy to talk
Posts: 21
Joined: Wed Jan 12, 2005 12:06

Re: Compile error

Postby noname » Wed Mar 02, 2005 00:09

not loginHandler ,it is quitHandler .

I have found why.
Thanks.


Return to “Modifications / Integrations / Customisations”

Who is online

Users browsing this forum: Bing [Bot] and 4 guests