Signals and Slots GUI wrapper

Post those lines of code you feel like sharing or find what you require for your project here; or simply use them as tutorials.
Post Reply
SLC
Posts: 21
Joined: Mon Jan 06, 2014 9:41 pm

Signals and Slots GUI wrapper

Post by SLC »

This is something I made tonight as a fun project after I noticed it gets a bit annoying to have a switch case for all gui elements especially when the user interface might be a little populated. I wish the developers would think about including the option to associate an arbitrary user pointer with gui element instances so I don't have to take this weird approach.

The source can be found here. The Irrlicht tutorial on user interface was converted as an example.

It requires a decent compiler with C++11 features. I've tested this on MinGW GCC 5.2.0 x32 and I know it works on lower versions as well. As for visual studio I have no idea. But I know VS to be a bit sketchy on new C++ features. Either requires some workarounds (if you're lucky) or not having that feature at all. So be warned VS users.

I haven't spent much time testing it so please expect some bugs. If you find any then please let me know and I'll fix it as soon as possible.
sudi
Posts: 1686
Joined: Fri Aug 26, 2005 8:38 pm

Re: Signals and Slots GUI wrapper

Post by sudi »

Nice!

Shameless plug on my part...without c++11 and with a lot less code: http://irrlicht.sourceforge.net/forum/v ... =9&t=43344
We're programmers. Programmers are, in their hearts, architects, and the first thing they want to do when they get to a site is to bulldoze the place flat and build something grand. We're not excited by renovation:tinkering,improving,planting flower beds.
Post Reply