Refactor: Switch between iOS6 and iOS7 element access: elementByName() vs. elementByXPath()