Controls the device's heading services.
More...
Inherits NSObject.
Controls the device's heading services.
The VgMyCompassDataSource uses iOS CLLocationManager to communicate with interested parties. Below is a list of Notifications that are observered/posted.
Observes:
- VgMyCompassRequestNotification: when observed will try and align it's internal state with that requested
- VgMyMapInteractionNotification: if the compass is enabled and this notification is received then the compass is disabled
Posts:
- VgMyCompassDataNotification: when active will broadcast this signals as the devices heading changes
- VgCompassNotification: will broadcast when the compass's state changes.
INTEGRATION GUIDE: In order for the compass data source to work, the follow steps need to be performed in the application:
- link the application with the CoreLocation.framework
- add the NSLocationWhenInUseUsageDescription key to the app's plist.
- add the VgMyCompassView to the apps interface (this allows the user to enable/disable the compass).
- add the VgMyMapViewResponder as a subview of the map view so it can capture map interaction events
- The map view must register to receive VgMyCompassDataNotification. This will be used for updating the maps heading.
- Examples:
- /Users/hbriceno/src/visioglobe/mobile/Projects/SDK/VisioDevKit/samples/navigationModule/Inc/Apple/VgMyViewController.h.
+ (BOOL) isCompassAvailable |
|
|
|
- Returns
- YES if the compass is available on the device, otherwise NO.
The documentation for this class was generated from the following file: