Fixed issues with control hiding.