summaryrefslogtreecommitdiff
path: root/src/mbgl/map/transform.hpp
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2017-04-11 13:40:17 -0700
committerJohn Firebaugh <john.firebaugh@gmail.com>2017-04-11 14:50:22 -0700
commit62576e24a0e98a73c1396150f1f09acb838080e6 (patch)
tree0a322ed0db5965071e9f78ef6e12bf83056b8421 /src/mbgl/map/transform.hpp
parentb71d86599d5e7c265b320300b18cfc0ea082c6d2 (diff)
downloadqtlocation-mapboxgl-62576e24a0e98a73c1396150f1f09acb838080e6.tar.gz
[core] Revert use of optional<EdgeInsets>, because EdgeInsets has a natural "empty" state
Diffstat (limited to 'src/mbgl/map/transform.hpp')
-rw-r--r--src/mbgl/map/transform.hpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/mbgl/map/transform.hpp b/src/mbgl/map/transform.hpp
index f0feae0911..993f8f2c5f 100644
--- a/src/mbgl/map/transform.hpp
+++ b/src/mbgl/map/transform.hpp
@@ -29,7 +29,7 @@ public:
// Camera
/** Returns the current camera options. */
- CameraOptions getCameraOptions(optional<EdgeInsets>) const;
+ CameraOptions getCameraOptions(const EdgeInsets&) const;
/** Instantaneously, synchronously applies the given camera options. */
void jumpTo(const CameraOptions&);
@@ -47,13 +47,13 @@ public:
@param offset The distance to pan the map by, measured in pixels from
top to bottom and from left to right. */
void moveBy(const ScreenCoordinate& offset, const AnimationOptions& = {});
- void setLatLng(const LatLng&, const AnimationOptions& = {});
- void setLatLng(const LatLng&, optional<EdgeInsets>, const AnimationOptions& = {});
+ void setLatLng(const LatLng&, const AnimationOptions& = {});
+ void setLatLng(const LatLng&, const EdgeInsets&, const AnimationOptions& = {});
void setLatLng(const LatLng&, optional<ScreenCoordinate>, const AnimationOptions& = {});
void setLatLngZoom(const LatLng&, double zoom, const AnimationOptions& = {});
- void setLatLngZoom(const LatLng&, double zoom, optional<EdgeInsets>, const AnimationOptions& = {});
- LatLng getLatLng(optional<EdgeInsets> = {}) const;
- ScreenCoordinate getScreenCoordinate(optional<EdgeInsets> = {}) const;
+ void setLatLngZoom(const LatLng&, double zoom, const EdgeInsets&, const AnimationOptions& = {});
+ LatLng getLatLng(const EdgeInsets& = {}) const;
+ ScreenCoordinate getScreenCoordinate(const EdgeInsets& = {}) const;
// Bounds
@@ -84,7 +84,7 @@ public:
/** Sets the scale factor, keeping the center point fixed within the inset view.
@param scale The new scale factor.
@param padding The viewport padding that affects the fixed center point. */
- void setScale(double scale, optional<EdgeInsets> padding, const AnimationOptions& = {});
+ void setScale(double scale, const EdgeInsets& padding, const AnimationOptions& = {});
/** Sets the zoom level, keeping the given point fixed within the view.
@param zoom The new zoom level. */
void setZoom(double zoom, const AnimationOptions& = {});
@@ -96,7 +96,7 @@ public:
/** Sets the zoom level, keeping the center point fixed within the inset view.
@param zoom The new zoom level.
@param padding The viewport padding that affects the fixed center point. */
- void setZoom(double zoom, optional<EdgeInsets> padding, const AnimationOptions& = {});
+ void setZoom(double zoom, const EdgeInsets& padding, const AnimationOptions& = {});
/** Returns the zoom level. */
double getZoom() const;
/** Returns the scale factor. */
@@ -118,7 +118,7 @@ public:
@param angle The new angle of rotation, measured in radians
counterclockwise from true north.
@param padding The viewport padding that affects the fixed center point. */
- void setAngle(double angle, optional<EdgeInsets> padding, const AnimationOptions& = {});
+ void setAngle(double angle, const EdgeInsets& padding, const AnimationOptions& = {});
/** Returns the angle of rotation.
@return The angle of rotation, measured in radians counterclockwise from
true north. */