Show user position inside Map view

If you want more, look at my new blog!

The code in this article works only with the custom Map class, so you need first apply the patch i’ve described here.

To view user’s current position you need to edit Map.m into PhoneGapLib’s project, placed into Documents folder, then find this line:

//mapView.showsUserLocation=true;

and just remove the double slashes:

mapView.showsUserLocation=true;

If all is gone fine, just clean and compile your project and you will see a green pointer on Cupertino (if you are working with the simulator).

 

This entry was posted in GPS, iPhone, Objective C. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s