Chart stars One Direction are to keep their name after reaching a deal with a US act with whom they had been locked in a legal dispute.