Fix infinite recursion on show and hide methods.