Fixed up the DistanceJoint

The main change is to not make it crash when its anchors or length are
set before it is being created. In addition, the choosing of defaults
for localAnchorA, localAnchorB and length has been improved.

Also fixes changed signal in Box2DDistanceJoint::setLocalAnchorA.
Fixed up the FrictionJoint

Made sure it doesn't crash when anchors are set before the joint is
created. Separated defaults for localAnchorA and localAnchorB.