Performance update for strokeCollideTest

When compared strokes have the same parent, some optimizations were
possible