A layer can now have multiple groups via a new 'groups' property

- Fixed a regression which caused events to fire recursively in some
cases