Tuesday, December 24, 2013

A MKMapView question, please answer master.

I put a MapView in a UIView. Then [mapView addSubview: UIButton] mapView added to the controls. My aim is when you want to drag the map, controls like Annotation same move along the map. The current situation is the result controls do not move on the screen. Will want to achieve the above functions that how to do? Thank you!
Reply:
How do you say, you can not achieve this requirement, because you [mapView addSubview: UIButton] actually put the button on mapview, when you drag the map mapview itself does not move, just move the object inside the container, so button will certainly not move.
Reply:
Add a FRAME or a new layer, a new layer on the add button.
Reply:
addsubview approach is not feasible. If you can know the map in a specific point, move or change into hours may be able to handle the position.

No comments:

Post a Comment