Add compatibility for jquery >= 2.0.0