Added hit testing legacy code.