TabControl: bug in removeTab

Forum for general chit-chat or off-topic discussion.

Moderators: CEGUI MVP, CEGUI Team

fedyakin
Not too shy to talk
Not too shy to talk
Posts: 22
Joined: Thu Apr 17, 2008 06:13
Location: Arizona, United States of America

TabControl: bug in removeTab

Postby fedyakin » Tue May 13, 2008 21:06

I'm not sure where the proper place is to report this:

When a window is added to a tab control (addTab), the window subscribes to EventTextChanged, with a member function of the tab control as the handler. When it is removed from the tab control (removeTab), this event handler is not removed from the window.

This prevents renaming the window once it has been removed from a tab. It could also cause a crash if the tab has been deleted.

The simplest solution I see is if the tab control keeps a mapping of window pointers to Event::Connections and uses this to disconnect the handler when removing a tab.

User avatar
scriptkid
Home away from home
Home away from home
Posts: 1178
Joined: Wed Jan 12, 2005 12:06
Location: The Hague, The Netherlands
Contact:

Postby scriptkid » Wed May 14, 2008 06:55

Sounds like a good catch to me, thanks for reporting :)

It's in Mantis: http://www.cegui.org.uk/mantis/view.php?id=192
Check out my released snake game using Cegui!

fedyakin
Not too shy to talk
Not too shy to talk
Posts: 22
Joined: Thu Apr 17, 2008 06:13
Location: Arizona, United States of America

Thanks

Postby fedyakin » Fri Jun 06, 2008 22:31

I see that this has been fixed already; thanks a lot :D

User avatar
CrazyEddie
CEGUI Project Lead
Posts: 6760
Joined: Wed Jan 12, 2005 12:06
Location: England
Contact:

Postby CrazyEddie » Sat Jun 07, 2008 08:17

We aim to please :)

Thanks again for raising the issue in the first place.

CE.


Return to “Offtopic Discussion”

Who is online

Users browsing this forum: No registered users and 8 guests