[[ Bug 14028 ]] Use the control's visibility state when drawing
Merge pull request #1486 from runrevsebastien/bugfix-14028

[[ Bug 14028 ]] Use the control's visibility state when drawing