The bottom bar issue is strange. Maybe right click and make sure the frame slider is maxed... I do not see how switching between windowed and fullscreen could have any influence however.
The target switching is possibly lag related. The code should be fine. Or maybe you click besides the icon, which I think will select the group member you are curing.