Added range check to -setActiveLink: