summaryrefslogtreecommitdiff
path: root/src/text
diff options
context:
space:
mode:
authorKonstantin Käfer <mail@kkaefer.com>2014-03-24 17:15:54 +0100
committerKonstantin Käfer <mail@kkaefer.com>2014-03-24 17:15:54 +0100
commit5c11bcf5c0dbe3975a50ec333b5fdac689a73ea2 (patch)
tree323d71f463a9e6f64d6c0c3e5a9aebe09144f809 /src/text
parent8b573f9fa29b724206c9ec0592525421d3e273c8 (diff)
downloadqtlocation-mapboxgl-5c11bcf5c0dbe3975a50ec333b5fdac689a73ea2.tar.gz
don't treat negative values as placement failure
Diffstat (limited to 'src/text')
-rw-r--r--src/text/placement.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/text/placement.cpp b/src/text/placement.cpp
index be329eda30..852236b71f 100644
--- a/src/text/placement.cpp
+++ b/src/text/placement.cpp
@@ -305,10 +305,9 @@ void Placement::addFeature(TextBucket& bucket,
PlacementProperty place =
collision.place(glyphs, anchor, anchor.scale, maxPlacementScale,
padding, horizontal);
-
- if (place.zoom >= 0.0f) {
+ if (place) {
bucket.addGlyphs(glyphs, place.zoom, place.rotationRange,
- zoom - zOffset);
+ zoom - zOffset);
}
}
}