Commit Graph

1084 Commits

Author SHA1 Message Date
Jesse Bounds
22cc375da0 [ios] Avoid updating sprite backed annotations in view update method (#6199)
Previously, annotations backed by sprite had their frames updated
by the view backed annotation update method. This guards against
that by aborting an update for an annotation if an associated
view cannot be found.

In addition, some dead code is removed.
2016-08-29 16:20:29 -07:00
Jason Wray
c075a879b8 ios-v3.4.0-alpha.3 2016-08-29 14:17:18 -04:00
Jason Wray
8dff7ab2f0 [ios] Improve user location annotation documentation
- Add note to mapView:viewForAnnotation: delegate method.
- Edit docs in iosapp's implementation of that delegate method.
2016-08-26 17:48:27 -04:00
Jason Wray
018f395442 [ios] Ignore non-conforming user location annotation views 2016-08-26 17:48:27 -04:00
Justin R. Miller
2501b2cc7b [ios] preserve annotation transforms during perspective scaling 2016-08-26 14:29:31 -07:00
Jason Wray
01b0b0bf0b [ios] Move OHHTTPStubs to Git submodule and update to 5.2.0 2016-08-25 13:41:19 -04:00
Jason Wray
9cdbac043d [ios] Clean-up user location annotation heading calculations
- Use MGLRadiansFromDegrees().
- Make indentation more readable.
2016-08-24 21:56:52 -04:00
Jason Wray
cb59589954 [ios] Stop exaggerating heading accuracy indicator size
- 1.5× exaggeration has been removed.
- Maximum accuracy (smallest size) has been increased to 20°.
2016-08-24 21:56:52 -04:00
Minh Nguyễn
5836738906 Document -mapViewDidFailLoadingMap:withError: (#6145)
* [macos] Implement -mapViewDidFailLoadingMap:withError:

* [ios] Documented -mapViewDidFailLoadingMap:withError:
2016-08-24 14:47:28 -07:00
Minh Nguyễn
2523f33ac4 [ios, macos] Expose name and default position of current style (#6127)
* [ios] Reset to style’s default position

* [ios, macos] Added name property to MGLStyle
2016-08-24 11:43:54 -07:00
Thiago Marcos P. Santos
7a84a0e4ea [ios] Fix typo
s/Reponse/Response
2016-08-24 18:17:56 +03:00
Jason Wray
a5b089de62 [ios, macos] Move debug mask options to shared header (#6094)
* [ios, macos] Move debug mask options to shared header

* Limit buffer debug modes to macOS

... because these modes use OpenGL features that aren't supported by iOS.

* Try a different tact: exclude "iPhone"

... which is actually all iOS-like devices.
2016-08-23 20:14:22 -04:00
Jason Wray
fcb710fafe [ios] Disable implicit animation of user annotation pitch changes (#6122)
- Subtly improves the performance of the shadow, while performing the pitch gesture.
2016-08-23 13:59:26 -04:00
Jason Wray
c034ba4ee1 [ios, macos] Update changelog with database performance note 2016-08-23 13:26:02 -04:00
Minh Nguyễn
ea41ed0769 [ios] Segmented changes by topic 2016-08-19 17:42:37 -07:00
Minh Nguyễn
0a2fec272d [ios, macos] Updated changelogs 2016-08-19 17:33:22 -07:00
Jason Wray
da7cb247ae ios-v3.4.0-alpha.2 2016-08-19 20:03:41 -04:00
Jesse Bounds
9450323f9e [ios] Automate upload of build output to Fabric
This adds a script that automates the process of uploading the
required build output to Fabric. It requires the `FABRIC_KIT_API_KEY`
env variable and another new script called `validate-fabric-zip.sh`.
2016-08-19 16:22:42 -07:00
Jason Wray
256689a33d [ios, macos] Make Xcode 7.3 the minimum required version
- Removes nullability shims for Xcode 6.
- Removes MGLTypes.h from files where it was only being used for
  nullability support.
- Accepts that `NS_SWIFT_NAME` is not fully supported by Xcode 7.2 and
  lower.
- Adds documentation about Xcode 7.3 requirement.
2016-08-18 11:35:32 -04:00
Fredrik Karlsson
a202941360 [ios, macos] reuse utility function 2016-08-18 14:26:05 +02:00
Fredrik Karlsson
f7069523b4 [ios, macos] fixes #5974 Move style classes API to MGLStyle 2016-08-18 14:26:05 +02:00
Fredrik Karlsson
02b908633e [ios] #fixes 5961 omit style filter until it's implemented 2016-08-18 14:26:05 +02:00
Fredrik Karlsson
5d307d098b [ios, macos] Fixes #5975 Add source getter to MGLStyle 2016-08-18 14:26:04 +02:00
Konstantin Käfer
c55b9ca0f8 [build] remove unneeded ios.xcscmblueprint 2016-08-18 12:33:38 +02:00
Minh Nguyễn
61df0b1bfa [ios, macos] Use local GeoJSON for runtime styling demo
Also changed the menu item to something more descriptive.

Fixes #6021.
2016-08-17 23:16:59 -07:00
Minh Nguyễn
0062cf2f94 [ios, macos] Added MGLBaseStyleLayer_Private.h to project 2016-08-16 16:48:02 -07:00
Minh Nguyễn
5539a90c48 [ios, macos] Renamed Objective-C++ headers to .h
Also removed a redundant reference to MGLStyle_Private.h in ios.xcodeproj.

Fixes #5952.
2016-08-16 16:46:04 -07:00
Jason Wray
1de65e2a51 [ios] Improve user location annotation performance (#6019)
* [ios] Don't animate zoom-induced accuracy ring size changes

Improves perceived and actual performance by eliminating the implicit animation that occurred when the accuracy ring changed size during zooms. This previously would pile up animations as the zoom changed, causing an unsightly wobbling effect.

* [ios] Pre-calculate shadow paths for user dot and puck

Performance enhancement suggested by https://developer.apple.com/library/ios/documentation/Cocoa/Conceptual/CoreAnimation_guide/ImprovingAnimationPerformance/ImprovingAnimationPerformance.html

* [ios] Rasterize pulsating inner dot of user location annotation

Supposed performance enhancement and also improves edge smoothness.
2016-08-16 17:38:18 -04:00
Jason Wray
f489ec2ee1 [ios] Refactored user location annotation into a customizable class (#5882)
A new class, `MGLUserLocationAnnotationView`, has been added that inherits from `MGLAnnotationView`. 

Use a subclass of `MGLUserLocationAnnotationView` to customize the appearance of the user location annotation. Use your custom view with the `MGLMapView.userLocation` annotation via the `-mapView:viewForAnnotation:` delegate method.
2016-08-16 15:16:59 -04:00
Justin R. Miller
01b94de107 fixes #5957: automatically call update() for iOS runtime style API 2016-08-16 11:29:26 -07:00
Konstantin Käfer
18176605f6 [core] support "scheme": "tms" in TileJSON files 2016-08-16 11:04:30 +02:00
Minh Nguyễn
1daba5d04b [ios, macos] Accept absolute file paths as style URLs (#6026)
It turns out that mbgl::AssetFileSource supports absolute file URLs in addition to relative file URLs. So replace the file: scheme with asset: while percent-escaping as necessary.

Also added amsterdam.geojson to macos.xcodeproj for consistency with ios.xcodeproj.
2016-08-16 10:17:11 +02:00
Minh Nguyễn
e147887e35 [core, android, ios, macos] Replaced getPointAnnotationsInBounds() w/ queryPointAnnotations() (#5165)
queryPointAnnotations() accepts a screen rectangle instead of a geographic bounding box, so marker hit testing works at the edges of a rotated, tilted map view.

Fixes #5151.
2016-08-12 15:45:18 -07:00
Jason Wray
ff5d60ecee [ios] Exclude NSData category's header from dynamic framework
This private category on NSData is for gzip compression, which is only used internally.
2016-08-11 20:11:14 -04:00
Minh Nguyễn
a3e20bae32 [ios, macos] Updated changelogs 2016-08-11 14:07:38 -07:00
Jesse Bounds
07aaaa08cf 3.4.0-alpha.1
Update changelog and bump version in the podspecs.
2016-08-11 11:42:53 -07:00
Minh Nguyễn
9a96877742 [ios, macos] Upgraded project build settings for Xcode 8 (#5935)
Set CLANG_WARN_INFINITE_RECURSION and CLANG_WARN_SUSPICIOUS_MOVE as recommended by Xcode 8.
2016-08-11 10:52:18 -07:00
Fredrik Karlsson
2354c87411 Runtime styling API for iOS/macOS (#5727)
* [ios] wip runtime styling

* [ios, macos] Outlined header templates

* [ios, macos] cleanup and use appropiate data types

* [ios, macos] removed refs to mbgl and added convenient color methods on UIColor and NSColor

* [ios, macos] updated header template, included doc string

* [ios, macos] outlined template for layer implementation files

* [ios, macos] moved script to platform/darwin and updated comments

* [ios, macos] Cleaned up the implementation template

* [ios, macos] removed unused function and added support for more datatypes

* [ios, macos] overhauling the type protocols

* [ios, macos] removed unnecessary style classes

* [ios, macos] added support for more types

* [ios, macos] fixed string and number prop values

* [ios, macos] enum getters

* [ios, macos] added removeLayer() and removed unused layer ref

* [ios, macos] fixed remaining layer types and converted style layer into a protocol

* [ios, macos] fixed addLayer() and added example for line layer

* [ios] GeoJSON source now works

* [ios] fixed raster layer and raster source

* [ios] fixed attr prop number and outlined prop function

* [ios] wip functions

* [ios] bool and float function fix

* [ios] cleanup

* [macos] fixed support for macos

* [ios] fixed string functions

* [ios] extended array functions

* [ios] added tests and fixed a few bugs

* [ios] less verbose functions and improved tests

* [ios, macos] Removed unnecessary use of default arguments

Default arguments aren’t supported in Node v4, and they aren’t needed here anyways, because we’re only testing for truthiness.

* [ios, macos] Enum setters

Rely on a macro instead of category methods to specialize the setter implementation for enum attributes, since generic types are disallowed in Objective-C method signatures and mbgl::style::PropertyType must be type-qualified.

* [ios, macos] Got macOS closer to parity w/ iOS

Added various classes and test classes to the macOS workspace. Also fixed lots of compiler errors and updated macosapp runtime styling example to use the new dictionary syntax for function stops.

Updated all conversions from Objective-C stops to C++ stops to enumerate over the dictionary. Fixed compiler errors in enum setter implementations.

Also corrected path to script in generated file comments.

* [ios, macos] Added EJS templates to project

* [ios, macos] Code formatting

Made code format more consistent.

* [ios, macos] Spelled out ID

Cocoa convention is to always spell out “ID” as “identifier”, in part to avoid confusion with the id keyword. Also, URL is capitalized in most contexts, including property names.

* [ios, macos] Grouped related headers together

* [ios, macos] Cleaned up layer transformation

Also added support for converting background layers into Objective-C.

* [ios, macos] Cleaned up tests

Also made the tests work on macOS by introducing a new window to host the map.

* [ios, macos] Replaced TODOs with #warnings

* [ios] convert array based property values

* [ios, macos] color function/undefined getter

* [ios, macos] fixed function/undefined getters for bool and float properties

* [ios, macos] more function/undefined property getters

* [ios, macos] more type conversion and cleanup

* [ios, macos] disable macos runtime styling tests for now

* [ios, macos] cleaned up style code script

* [ios, macos] more type conversion

* [ios] added a base layer to handle visibility min/max zoom

* [macos] fixed base layer

* [ios, macos] use accessor methods

* [ios, macos] cleanup

* [ios, macos] add geojson to ios and macos

* [macos] rebase fix

* [ios, macos] fixed enum getters and added tests for enums

* [ios, macos] added an update method to base layer

* [ios, macos] added some documentation

* [ios, macos] docs

* [ios, macos] removed refs to filters for now

* [ios, macos] various tail work

* [ios, macos] missing import and incorrect type
2016-08-11 13:14:45 -04:00
Jesse Bounds
89190f8d89 [ios] Account for center offset when tapping annotation views (#5931)
This adjusts the tap point for the map's single tap gesture
recognizer to use the coordinate to point translated point of the actual
annotation the view represents. This fixes an issue where views that
were offset in the point coordinate system were not selected when
tapped since their associated annotations were actually at the origin
of the offset.
2016-08-11 09:28:24 -07:00
Jesse Bounds
d782fc952f [ios] Guard against nil data task (#5932) 2016-08-11 09:23:58 -07:00
Jason Wray
82f19b94f7 Merge branch 'release-ios-v3.3.0'
After v3.3.4.
2016-08-08 17:31:11 -04:00
Jason Wray
c64a0c2486 ios-v3.3.4
Bump version number and update changelog.
2016-08-08 15:25:20 -04:00
Jason Wray
ae88c01c94 [ios] Hit test the user location annotation dot specifically
Rather than try to exclude layers in the touch hit test, this
specifically only checks against the main layer for the user dot or
puck.

Back-port of e4a9173a2a5c585dda3fa7a0f955cff1552f8d25.
2016-08-06 17:59:35 -07:00
Konstantin Käfer
94ceeb739d [build] fix iOS packaging 2016-08-05 11:42:22 +02:00
Konstantin Käfer
e46b580c67 [build] unify naming of Makefile targets
`make foo` just builds
`make run-foo` builds and runs
2016-08-05 11:42:22 +02:00
Konstantin Käfer
692fe1f3ff [build] switch to CMake
This is very much a work in progress.
2016-08-05 11:42:22 +02:00
Jason Wray
d305fbebee Merge branch 'release-ios-v3.3.0'
Merge release branch after v3.3.2 and v3.3.3.
2016-08-03 17:40:22 -07:00
Minh Nguyễn
2d65cddda5 [ios] Migrated playground to Swift 3 (#5847)
Fixes #5846.
2016-08-02 15:29:50 -07:00
Jesse Bounds
b928ac5bd4 ios-v3.3.3
Bump version number and update changelog.
2016-07-29 10:38:49 -07:00
Jason Wray
85183dd46e ios-v3.3.2 2016-07-28 15:11:49 -07:00