Implemented rectangle insideShape hit testing.