Joesph III, Claim to Polish Throne