-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Animated MGLMapView methods should accept completion handlers #1581
Comments
Plumbed camera options all the way through to MGLMapView. Added a method that lets you specify a direction in addition to center point and zoom level. Added Map::jumpTo() for parity with mapbox-gl-js. Replaced usage of Map::setLatLng() and Map::setLatLngZoom() with Map::jumpTo() or Map::easeTo() within MGLMapView. Replaced MGLMapView.pitch with MGLMapCamera for setting all supported degrees of freedom simultaneously. Simultaneously move and rotate with course. Support customizable timing functions on iOS. iosapp now persists an archived MGLMapCamera instead of separate viewpoint properties and also synchronizes user defaults on termination. This change implements persistence entirely in Objective-C, eliminating the use of the Objective-C++ implementation. Fixes #1643, fixes #1834. Ref #1581.
Plumbed camera options all the way through to MGLMapView. Added a method that lets you specify a direction in addition to center point and zoom level. Added Map::jumpTo() for parity with mapbox-gl-js. Replaced usage of Map::setLatLng() and Map::setLatLngZoom() with Map::jumpTo() or Map::easeTo() within MGLMapView. Replaced MGLMapView.pitch with MGLMapCamera for setting all supported degrees of freedom simultaneously. Simultaneously move and rotate with course. Support customizable timing functions on iOS. iosapp now persists an archived MGLMapCamera instead of separate viewpoint properties and also synchronizes user defaults on termination. This change implements persistence entirely in Objective-C, eliminating the use of the Objective-C++ implementation. Fixes #1643, fixes #1834. Ref #1581.
Here here! |
Was their any further discussion on this, or does their at least exist a work around to determine when an mapbox animation has been completed? |
+1 |
GL JS can do this; so should the iOS SDK. The most straightforward way to implement it would be to have |
Plumbed camera options all the way through to MGLMapView. Added a method that lets you specify a direction in addition to center point and zoom level. Added Map::jumpTo() for parity with mapbox-gl-js. Replaced usage of Map::setLatLng() and Map::setLatLngZoom() with Map::jumpTo() or Map::easeTo() within MGLMapView. Replaced MGLMapView.pitch with MGLMapCamera for setting all supported degrees of freedom simultaneously. Simultaneously move and rotate with course. Support customizable timing functions on iOS. iosapp now persists an archived MGLMapCamera instead of separate viewpoint properties and also synchronizes user defaults on termination. This change implements persistence entirely in Objective-C, eliminating the use of the Objective-C++ implementation. Fixes mapbox#1643, fixes mapbox#1834. Ref mapbox#1581.
@kdgwill, |
Added transition frame and finish functions to CameraOptions. Added Objective-C equivalents to the three main entry points to easeTo() in MGLMapView. Fixes #1581.
Added transition frame and finish functions to CameraOptions. Added Objective-C equivalents to the three main entry points to easeTo() in MGLMapView. Fixes #1581.
Methods like
-[MGLMapView setCenterCoordinate:animated:]
should have corresponding methods that take completion handlers (callback blocks) as parameters, like-[MGLMapView setCenterCoordinate:animated:completionHandler:]
. Completion handlers feel much more natural in modern Objective-C and especially Swift, and they’d make it much easier to chain together animated changes to the map.The text was updated successfully, but these errors were encountered: