Complete left and right flip functionality