Porting https://github.com/phetsims/scenery/commit/5f577b9e2ba47ef709a1e51c705ab89c5b6b8622
Porting https://github.com/phetsims/scenery/commit/02f6a0201f905ce051a3f3096f8d06be692397b4
Porting https://github.com/phetsims/scenery/commit/9ba21746dd266ff0bc88be1d016911dbf2746dde and https://github.com/phetsims/scenery/commit/07760d3bb260f9ccc518ab54c36580945b432ed7