Skip navigation

Well, one thing I love about C++ is #define

I’m going through Ogre now, and I’m seeing A LOT of

CEGUI::WindowManager::getSingleton()

The great thing about C++ is I’m replacing this ugly call with

#define WinMan CEGUI::WindowManager::getSingleton()

So this makes it MUCH better to look at

CEGUI::Combobox* objectComboBox = (CEGUI::Combobox*)CEGUI::WindowManager::getSingleton().getWindow(“OgreGuiDemo/TabCtrl/Page2/ObjectTypeList”);

VS

CEGUI::Combobox* objectComboBox = (CEGUI::Combobox*)WinMan.getWindow(“OgreGuiDemo/TabCtrl/Page2/ObjectTypeList”);

huh?

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: