A Statistical Study of Shear Motion of the Footpoints in Two-Ribbon Flares