Cleanup GUI Checkbox C++ code by removing broken, non-obvious internal text rendering.
Description
Description
Details
Details
- Auditors
elexis - Committed
JoshuaJB Jan 2 2014, 4:28 AM - Parents
- rP14475: small code cleanup
- Branches
- Unknown
- Tags
Event Timeline
Comment Actions
If removing the DrawText call is right, then this should not only remove the DrawText call but also CCheckBox::SetupText(), the according Settings, and IGUITextOwner inheritance.
non-obvious internal text rendering
sounds like the text either might still rendered in a non obvious place, or that the previous code was non obvious.
As far as I see DrawText is the only place where text is rendered, and that is only called from IGUIObject classes (the leaf classes).
Marked as TODO in rP18419.
Comment Actions
Rest of the text code removed in rP22952.
Not sure if it wouldnt be better if the class supports rendering text (most other GUIs do?), also the implementation didnt duplicate the text rendering like other classes do (CInput).
But given that now the entire GUI uses its own labels, one would have to rewrite most checkboxes to make use of that feature if it was implemented, so good enough for me until someone wants to implement it back.