i've an IGUIbutton that has an image (button->setImage(...)), the image works fine, but
when i disable the button using setEnable(false) the image does not change. this is bad cause the user can't see if the button is enabled or disabled. so i've added an condition on CGUIButton.cpp draw() method:
Code: Select all
if (!IsEnabled)
{
core::position2d<s32> pos = spritePos;
pos.X -= ImageRect.getWidth() / 2;
pos.Y -= ImageRect.getHeight() / 2;
driver->draw2DRectangle(irr::video::SColor(150,255,255,255), core::recti(pos, ImageRect.getSize()) );
}