summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMinh Nguyễn <mxn@1ec5.org>2015-12-02 15:08:51 -0800
committerMinh Nguyễn <mxn@1ec5.org>2015-12-13 17:26:53 -0800
commit73324ae2f886ac32fc673c996b00faf0383d93c0 (patch)
tree829dee646209180689a993ef85d3ba7cf6e76668 /include
parent62e6c04c730b7c461b418c093da63aef3e1fa9e6 (diff)
downloadqtlocation-mapboxgl-73324ae2f886ac32fc673c996b00faf0383d93c0.tar.gz
[osx] Commented private headers and implementation files
Diffstat (limited to 'include')
-rw-r--r--include/mbgl/osx/MGLMapView+IBAdditions.h37
-rw-r--r--include/mbgl/osx/MGLMapView.h9
2 files changed, 44 insertions, 2 deletions
diff --git a/include/mbgl/osx/MGLMapView+IBAdditions.h b/include/mbgl/osx/MGLMapView+IBAdditions.h
index 8dacd5ec7b..b524328c56 100644
--- a/include/mbgl/osx/MGLMapView+IBAdditions.h
+++ b/include/mbgl/osx/MGLMapView+IBAdditions.h
@@ -6,19 +6,27 @@ NS_ASSUME_NONNULL_BEGIN
@interface MGLMapView (IBAdditions)
+#if TARGET_INTERFACE_BUILDER
+
// Core properties that can be manipulated in the Attributes inspector in
// Interface Builder. These redeclarations merely add the IBInspectable keyword.
// They appear here to ensure that they appear above the convenience properties;
// inspectables declared in MGLMapView.h are always sorted before those in
// MGLMapView+IBAdditions.h, due to ASCII sort order.
-#if TARGET_INTERFACE_BUILDER
// We want this property to look like a URL bar in the Attributes inspector, but
// just calling it styleURL would violate Cocoa naming conventions and conflict
// with the existing NSURL property. Fortunately, IB strips out the two
// underscores for display.
+
+/**
+ URL of the style currently displayed in the receiver.
+
+ The URL may be a full HTTP or HTTPS URL, a Mapbox URL indicating the style’s
+ map ID (`mapbox://styles/<user>/<style>`), or a path to a local file
+ relative to the application’s resource path.
+ */
@property (nonatomic, nullable) IBInspectable NSString *styleURL__;
-#endif
// Convenience properties related to the initial viewport. These properties
// are not meant to be used outside of Interface Builder. latitude and longitude
@@ -26,19 +34,44 @@ NS_ASSUME_NONNULL_BEGIN
// must use the type double because Interface Builder is unaware that
// CLLocationDegrees is a typedef for double.
+/** The initial center latitude. */
@property (nonatomic) IBInspectable double latitude;
+
+/** The initial center longitude. */
@property (nonatomic) IBInspectable double longitude;
+
@property (nonatomic) IBInspectable double zoomLevel;
// Renamed properties. Interface Builder derives the display name of each
// inspectable from the runtime name, but runtime names don’t always make sense
// in UI.
+/**
+ A Boolean value that determines whether the user may zoom the map, changing
+ its zoom level.
+ */
@property (nonatomic) IBInspectable BOOL allowsZooming;
+
+/**
+ A Boolean value that determines whether the user may scroll around the map,
+ changing its center coordinate.
+ */
@property (nonatomic) IBInspectable BOOL allowsScrolling;
+
+/**
+ A Boolean value that determines whether the user may rotate the map,
+ changing its direction.
+ */
@property (nonatomic) IBInspectable BOOL allowsRotating;
+
+/**
+ A Boolean value that determines whether the user may tilt the map, changing
+ its pitch.
+ */
@property (nonatomic) IBInspectable BOOL allowsTilting;
+#endif
+
@end
NS_ASSUME_NONNULL_END
diff --git a/include/mbgl/osx/MGLMapView.h b/include/mbgl/osx/MGLMapView.h
index 32f068a4ce..a604a7951c 100644
--- a/include/mbgl/osx/MGLMapView.h
+++ b/include/mbgl/osx/MGLMapView.h
@@ -38,6 +38,15 @@ IB_DESIGNABLE
- (void)setCenterCoordinate:(CLLocationCoordinate2D)coordinate animated:(BOOL)animated;
+/**
+ The zoom level of the receiver.
+
+ In addition to affecting the visual size and detail of features on the map,
+ the zoom level affects the size of the vector tiles that are loaded. At zoom
+ level 0, each tile covers the entire world map; at zoom level 1, it covers ¼
+ of the world; at zoom level 2, <sup>1</sup>⁄<sub>16</sub> of the world, and
+ so on.
+ */
@property (nonatomic) double zoomLevel;
@property (nonatomic, readonly) double maximumZoomLevel;
@property (nonatomic, readonly) double minimumZoomLevel;