Skip to content

Commit

Permalink
Fix Irrlicht 1.9 support
Browse files Browse the repository at this point in the history
  • Loading branch information
sfan5 committed Sep 6, 2019
1 parent 5c97eea commit ea9b241
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/gui/guiButton.h
Expand Up @@ -14,7 +14,7 @@

using namespace irr;

#if (IRRLICHT_VERSION_MAJOR > 1 || IRRLICHT_VERSION_MINOR != 8 || IRRLICHT_VERSION_REVISION < 5)
#if (IRRLICHT_VERSION_MAJOR == 1 && IRRLICHT_VERSION_MINOR <= 8)
namespace irr { namespace gui {

//! State of buttons used for drawing texture images.
Expand Down Expand Up @@ -142,9 +142,11 @@ class GUIButton : public gui::IGUIButton
video::SColor color=video::SColor(255,255,255,255),
bool loop=false, bool scale=false);

#if (IRRLICHT_VERSION_MAJOR == 1 && IRRLICHT_VERSION_MINOR <= 8)
void setSprite(gui::EGUI_BUTTON_STATE state, s32 index, video::SColor color, bool loop) override {
setSprite(state, index, color, loop, false);
}
#endif

//! Get the sprite-index for the given state or -1 when no sprite is set
virtual s32 getSpriteIndex(gui::EGUI_BUTTON_STATE state) const;
Expand Down

0 comments on commit ea9b241

Please sign in to comment.