Your comment of transferring a firearm with out an ID has been shown as false ... 
If one state has the requirement to show an ID to vote the scenario is valid and the same.  
If you view it as an infringement of rights in one case, you should conclude its an infringement of rights in the other.  There is no provision in the 2nd amendment that states because transfers can be done privately they are not subject to regulation the you can only vote through the public sphere is nonsense.