Okay, serinde, I think I have the specifics. Things got a little dicey in Numenor before the end. As we know, some of the Numenoreans began to plan to break the Ban on the Valar on seeking the Undying Lands, and they became divided between the rebels and the Faithful. The last legitimate king in the line was Tar-Palantir. After his death, his nephew, Ar-Pharazon, seized the throne, so that changed the line of the kingship. (The legitimate heir was a daughter. I wonder if she would have broken the Ban!) And then came the drowning of Numenor.
Elendil was the leader of the Faithful, so that was one reason why he was king in Middle-earth. But his direct ancestor was Tar-Elendil, the fourth King of Numenor:
In the days of Tar-Elendil the first ships of the Numenoreans came back to Middle-earth. His elder child was a daughter, Silmarien. Her son was Valandil, first of the Lord of Andunie in the west of the land, renowned for their friendship with the Eldar. From him were descended Amandil, the last lord, and his son Elendil the Tall.
I like it that Tolkien really gave two reasons for Elendil's legitimacy: he was true leader of the Faithful and he had the bloodline.
Does that explain it, serinde?