Fix transition end detection for Android

Some Android versions have the "transition" and "animation" properties
set on element style objects despite not supporting un-prefxied animations
and transitions.  This change adds an additional sanity check to make sure
the correct event handlers are added for transition groups.
Small style fixup
Merge pull request #1276 from marcins/bugfix/1275-transitiongroup-android

Fix transition end detection for Android