summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Firebaugh <john.firebaugh@gmail.com>2016-02-02 20:20:47 -0800
committerJohn Firebaugh <john.firebaugh@gmail.com>2016-02-02 20:20:47 -0800
commit032c8fba3c8e3c122dd399b5c9341d92ad9d286f (patch)
tree1b38001c084df2c81a73ca7f63b77d285019db1e
parentb78bc7c555165f654866a1c6c962955add52473f (diff)
downloadqtlocation-mapboxgl-032c8fba3c8e3c122dd399b5c9341d92ad9d286f.tar.gz
[core] Remove unused
-rw-r--r--include/mbgl/map/map.hpp1
-rw-r--r--src/mbgl/annotation/annotation_manager.cpp14
-rw-r--r--src/mbgl/annotation/annotation_manager.hpp1
-rw-r--r--src/mbgl/annotation/point_annotation_impl.cpp4
-rw-r--r--src/mbgl/annotation/point_annotation_impl.hpp1
-rw-r--r--src/mbgl/annotation/shape_annotation_impl.cpp12
-rw-r--r--src/mbgl/annotation/shape_annotation_impl.hpp1
-rw-r--r--src/mbgl/map/map.cpp4
8 files changed, 0 insertions, 38 deletions
diff --git a/include/mbgl/map/map.hpp b/include/mbgl/map/map.hpp
index b9aa0c1381..3a85030169 100644
--- a/include/mbgl/map/map.hpp
+++ b/include/mbgl/map/map.hpp
@@ -165,7 +165,6 @@ public:
void removeAnnotations(const AnnotationIDs&);
AnnotationIDs getPointAnnotationsInBounds(const LatLngBounds&);
- LatLngBounds getBoundsForAnnotations(const AnnotationIDs&);
void addCustomLayer(const std::string& id,
CustomLayerInitializeFunction,
diff --git a/src/mbgl/annotation/annotation_manager.cpp b/src/mbgl/annotation/annotation_manager.cpp
index 1d9c021fa6..52f8b08ad3 100644
--- a/src/mbgl/annotation/annotation_manager.cpp
+++ b/src/mbgl/annotation/annotation_manager.cpp
@@ -71,20 +71,6 @@ AnnotationIDs AnnotationManager::getPointAnnotationsInBounds(const LatLngBounds&
return result;
}
-LatLngBounds AnnotationManager::getBoundsForAnnotations(const AnnotationIDs& ids) const {
- LatLngBounds result = LatLngBounds::getExtendable();
-
- for (const auto& id : ids) {
- if (pointAnnotations.find(id) != pointAnnotations.end()) {
- result.extend(pointAnnotations.at(id)->bounds());
- } else if (shapeAnnotations.find(id) != shapeAnnotations.end()) {
- result.extend(shapeAnnotations.at(id)->bounds());
- }
- }
-
- return result;
-}
-
std::unique_ptr<AnnotationTile> AnnotationManager::getTile(const TileID& tileID) {
if (pointAnnotations.empty() && shapeAnnotations.empty())
return nullptr;
diff --git a/src/mbgl/annotation/annotation_manager.hpp b/src/mbgl/annotation/annotation_manager.hpp
index bc3f73e2ca..163c7129c7 100644
--- a/src/mbgl/annotation/annotation_manager.hpp
+++ b/src/mbgl/annotation/annotation_manager.hpp
@@ -31,7 +31,6 @@ public:
void removeAnnotations(const AnnotationIDs&);
AnnotationIDs getPointAnnotationsInBounds(const LatLngBounds&) const;
- LatLngBounds getBoundsForAnnotations(const AnnotationIDs&) const;
void addIcon(const std::string& name, std::shared_ptr<const SpriteImage>);
void removeIcon(const std::string& name);
diff --git a/src/mbgl/annotation/point_annotation_impl.cpp b/src/mbgl/annotation/point_annotation_impl.cpp
index c84912750f..8e1aab2edf 100644
--- a/src/mbgl/annotation/point_annotation_impl.cpp
+++ b/src/mbgl/annotation/point_annotation_impl.cpp
@@ -25,8 +25,4 @@ void PointAnnotationImpl::updateLayer(const TileID& tileID, AnnotationTileLayer&
featureProperties));
}
-LatLngBounds PointAnnotationImpl::bounds() const {
- return LatLngBounds(point.position, point.position);
-}
-
} // namespace mbgl
diff --git a/src/mbgl/annotation/point_annotation_impl.hpp b/src/mbgl/annotation/point_annotation_impl.hpp
index 47c3bffea2..8e99856eb7 100644
--- a/src/mbgl/annotation/point_annotation_impl.hpp
+++ b/src/mbgl/annotation/point_annotation_impl.hpp
@@ -43,7 +43,6 @@ public:
PointAnnotationImpl(const AnnotationID, const PointAnnotation&);
- LatLngBounds bounds() const;
void updateLayer(const TileID&, AnnotationTileLayer&) const;
const AnnotationID id;
diff --git a/src/mbgl/annotation/shape_annotation_impl.cpp b/src/mbgl/annotation/shape_annotation_impl.cpp
index 40f5d1997c..418d3adaed 100644
--- a/src/mbgl/annotation/shape_annotation_impl.cpp
+++ b/src/mbgl/annotation/shape_annotation_impl.cpp
@@ -147,16 +147,4 @@ void ShapeAnnotationImpl::updateTile(const TileID& tileID, AnnotationTile& tile)
}
}
-LatLngBounds ShapeAnnotationImpl::bounds() const {
- LatLngBounds result;
-
- for (const auto& segment : shape.segments) {
- for (const auto& point : segment) {
- result.extend(point);
- }
- }
-
- return result;
-}
-
} // namespace mbgl
diff --git a/src/mbgl/annotation/shape_annotation_impl.hpp b/src/mbgl/annotation/shape_annotation_impl.hpp
index 5095d4310f..41069dbfd2 100644
--- a/src/mbgl/annotation/shape_annotation_impl.hpp
+++ b/src/mbgl/annotation/shape_annotation_impl.hpp
@@ -22,7 +22,6 @@ public:
ShapeAnnotationImpl(const AnnotationID, const ShapeAnnotation&, const uint8_t maxZoom);
- LatLngBounds bounds() const;
void updateStyle(Style&);
void updateTile(const TileID&, AnnotationTile&);
diff --git a/src/mbgl/map/map.cpp b/src/mbgl/map/map.cpp
index e435ec32bf..cab1d42b38 100644
--- a/src/mbgl/map/map.cpp
+++ b/src/mbgl/map/map.cpp
@@ -465,10 +465,6 @@ AnnotationIDs Map::getPointAnnotationsInBounds(const LatLngBounds& bounds) {
return data->getAnnotationManager()->getPointAnnotationsInBounds(bounds);
}
-LatLngBounds Map::getBoundsForAnnotations(const AnnotationIDs& annotations) {
- return data->getAnnotationManager()->getBoundsForAnnotations(annotations);
-}
-
#pragma mark - Style API
void Map::addCustomLayer(const std::string& id,