Well I want to send a mouse click event from eventhandler.cpp and then to catch that event in a "widget".cpp file.
But I dont know how to send and catch events.
Can someone please help me with it.?
How to send generic event from eventhandler.cpp to wiidgets
Re: How to send generic event from eventhandler.cpp to wiidg
Eventhandler and widget are very common terms - meaning there are lot's of those. You have to be a little bit more specific what you are talking about. Are you trying to combine 2 libraries somehow? Which ones?
You have to give a lot of information if you ask for help. As we have no idea otherwise what you are doing. For example which eventhandler.cpp or widget.cpp you are talking about.
You have to give a lot of information if you ask for help. As we have no idea otherwise what you are doing. For example which eventhandler.cpp or widget.cpp you are talking about.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: How to send generic event from eventhandler.cpp to wiidg
Okay, Well I have a class EventHandler which has the onEvent method which is being called every time an event occurs.The software I am using also uses Irrlicht.
It also has certain widgets like scroll bars, spinners etc.
What I want to do is send a generic event from the EventHandler class and catch that for a particular widget.
Like for a certain mouse click I want to get the mouse position but my widget class cannot access SEvent structure.
The eventhandler class is a friend class of the widget class and can access SEvent structure.
So do you now get the picture or want something more.
Sorry,for providing such less info earliar.
Thank You
Nalin
It also has certain widgets like scroll bars, spinners etc.
What I want to do is send a generic event from the EventHandler class and catch that for a particular widget.
Like for a certain mouse click I want to get the mouse position but my widget class cannot access SEvent structure.
The eventhandler class is a friend class of the widget class and can access SEvent structure.
So do you now get the picture or want something more.
Sorry,for providing such less info earliar.
Thank You
Nalin
Re: How to send generic event from eventhandler.cpp to wiidg
So your EventHandler class is about an Irrlicht event handler, do I understand that correct? I do not understand at all yet what your widget class is or does. Is this one of your own classes? What is it supposed to do? Is it some alternative to the Irrlicht GUI system which you are writing yourself?
Maybe it would help if you could show us some actual code what this is about.
Maybe it would help if you could show us some actual code what this is about.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm