I believe he was elected, since there wasn't a direct descendant, if I recall correctly.
Of course, a chief cannot be elected; he must be recognized by the Lord Lyon. He must, in other words, have a proven descent from the last chief, must have the last name of the clan, etc. I am the member of a clan society, recognized by a chief whose proven ancestry is quite old, yet he had to drop a hyphen in his name to be recognized as the chief of the clan by the Lord Lyon (as is only correct).