Commit Graph

5798 Commits

Author SHA1 Message Date
John Firebaugh
15969f1369 Remove Map dependency from Source::invalidateTiles 2015-04-06 10:30:02 -07:00
John Firebaugh
750cfb6f58 Remove Map dependency from Source::load 2015-04-06 10:30:01 -07:00
John Firebaugh
e72ee04482 Move SourceInfo into source.hpp/cpp 2015-04-06 10:30:01 -07:00
John Firebaugh
7e0e55e542 Eliminate StyleSource
Fixes #695
2015-04-06 10:30:01 -07:00
Minh Nguyễn
87d9507854 Merge pull request #1204 from friedbunny/location-shadow
Smooth edges of user location annotation icon's shadow
2015-04-03 21:40:10 -07:00
Jason Wray
9cdd2b1c56 Smooth edges of user location annotation icon's shadow 2015-04-03 19:52:41 -07:00
Justin R. Miller
5f94ee532c update docs for umbrella header 2015-04-03 15:56:52 -07:00
Minh Nguyễn
b9eb3e7147 Merge pull request #1201 from mapbox/1ec5-objc
iOS projects require -ObjC in OTHER_LDFLAGS
2015-04-03 15:05:44 -07:00
Minh Nguyễn
db4b6bd510 iOS projects require -ObjC in OTHER_LDFLAGS
#1184 added `-[NSProcessInfo(MGLAdditions) mgl_isInterfaceBuilderDesignablesAgent]`, which only gets pulled in if you add `-ObjC` to `OTHER_LDFLAGS`.
2015-04-03 14:51:15 -07:00
John Firebaugh
41c4d50f8a Remove unused 2015-04-03 13:51:33 -07:00
John Firebaugh
cca7f6978a Remove unused 2015-04-03 13:51:33 -07:00
Minh Nguyễn
e6e340afd1 Merge pull request #1184 from mapbox/1070-kvo
Style API cleanup, designables, inspectables
2015-04-03 13:22:35 -07:00
Mike Morris
5091259c9d 1.0.3 [publish binary] 2015-04-03 15:55:31 -04:00
Mike Morris
97c7912f02 update changelog 2015-04-03 15:46:24 -04:00
Mike Morris
ca0da9626e NanAssignPersistent source in NodeMap constructor, fixes #109 2015-04-03 15:43:40 -04:00
Minh Nguyễn
d1fb43e371 Inspectable toggles
Added inspectables for toggling zooming, panning, rotating, and showing the user location for parity with `MKMapView`.
2015-04-03 12:41:38 -07:00
Justin R. Miller
6eb79338f3 allow setting nil mapID for default style 2015-04-03 12:41:37 -07:00
Justin R. Miller
2916ae2735 formatting & docs changes
Ran this through `./ios/docs/install_docs.sh` to double-check things.

 * Less-specific initializers above more-specific per Apple convention.
 * Shores up `accessToken` docs as property, not a method.
 * Edited comments for consistency and/or to keep them out of the docs.
2015-04-03 12:40:51 -07:00
Minh Nguyễn
836de8bc1c Made lat/lon/zoom inspectable
Declared these IB-specific inspectables in a separate category that developers are not expected to import. Currently these inspectables are order-dependent due to #1181.

Ref #929
2015-04-03 12:34:36 -07:00
Minh Nguyễn
da13225a81 Made MGLMapView designable in IB
When an access token is set in the Attributes inspector (or as a user-defined runtime attribute), we draw some lovely Mapbox branding so the view shows up. (Manipulating invisible rectangles is a frustrating exercise, I’m told.) In the absence of an access token, the view displays a helpful message with directions for obtaining and setting the access token.

Along the way, completely opt out of `MGLMapboxEvents` when targeting Interface Builder, because touching Core Location throws an exception in that environment and it doesn’t make sense to record any metrics when designing on the Interface Builder canvas. Also, don’t start `mbgl::Map` at all (and don’t update it) because none of the runtime drawing code should ever be run in the designable. Normally these chunks of code would be excluded in IB using the TARGET_INTERFACE_BUILDER preprocessor macro. However, Mapbox GL is being packaged as a static library, so the macro is only evaluated when the library is prebuilt, even if the library eventually makes its way into the CocoaPods-generated framework. Instead, we detect that we’re being run by the IBDesignablesAgentCocoaTouch process.

Overrode `-[MGLMapView initWithFrame:]` to call `-commonInit`. We’ve marked this initializer unavailable in the header, but IB still calls it regardless.

Fixes #929.
2015-04-03 12:16:00 -07:00
Minh Nguyễn
e18e4b0de5 Removed redundant initializers and setters
This change removes most of the ways you used to be able to apply a style to the map. Building on #1163, `styleURL` (HTTP(S), mapbox:, asset:) is the canonical way to apply a style, and `mapID` is a convenient shorthand for Mapbox-hosted styles. A relative style URL is interpreted as a path relative to the app’s main bundle. We now construct asset: URLs in lieu of “bundled style names”.
2015-04-03 12:14:51 -07:00
Minh Nguyễn
6a1e7d5707 Fixed race condition after setting access token
`Map` should be able to deal with having no access token or JSON even while it’s running. Most of `Map` accounts for this situation, but `reloadStyle()` incorrectly assumes that one or the other is set. This change corrects the assumption in `reloadStyle()`.

Also expose the access token and style name to clients as ordinary KVO-compliant properties. Actually, they’re not so ordinary because they’re inspectable!

Ref #1070, #1147
2015-04-03 12:07:53 -07:00
Ansis Brammanis
148294d3ac Merge branch 'master' into new-labelling
Conflicts:
	src/mbgl/renderer/symbol_bucket.cpp
	src/mbgl/renderer/symbol_bucket.hpp
	src/mbgl/text/collision.cpp
	src/mbgl/text/glyph_store.cpp
	src/mbgl/text/placement.cpp
	src/mbgl/text/rotation_range.cpp
2015-04-03 12:04:31 -07:00
Justin R. Miller
999ebb371e Merge pull request #1194 from mapbox/fix-lat-lon-zoom-order
fixes #1181: fix lat/lng & zoom ordering problems
2015-04-03 09:38:47 -07:00
Brad Leege
841fba352b Merge pull request #1196 from mapbox/1195-speed-course
Speed And Course Attributes
2015-04-03 11:36:30 -05:00
Brad Leege
8413da0d68 #1195 - Adding speed and course attributes to location event 2015-04-03 11:10:35 -05:00
Justin R. Miller
c253232473 account for GL-level min zoom 2015-04-03 09:06:20 -07:00
Minh Nguyễn
6a04f3d51d Merge pull request #1187 from mapbox/1ec5-settings
Polished privacy settings
2015-04-03 02:27:08 -07:00
Justin R. Miller
0a736c3a76 fixes #1181: fix lat/lng & zoom ordering problems 2015-04-02 19:56:47 -07:00
Justin R. Miller
ba5a04e81c Merge pull request #1193 from mapbox/location-fixes
fix compilation error with private category property
2015-04-02 19:55:32 -07:00
Justin R. Miller
540ef12b4e fix compilation error with private category property 2015-04-02 19:28:37 -07:00
Justin R. Miller
dafce83acd Merge pull request #1192 from mapbox/location-and-docs-tweaks
improvements to iOS docs & user location framework
2015-04-02 17:50:32 -07:00
Justin R. Miller
dbd22ae61a reverting to title/subtitle setters for user location 2015-04-02 17:12:05 -07:00
Justin R. Miller
9a416c449c Improvements to docs & user location framework.
* Cleans up & documents more APIs, especially in location.
 * Moves `coordinate` internal and makes use of `location` to retrieve it.
 * Moves `title` & `subtitle` internal since part of `MGLAnnotation` protocol.
 * Enables `isUpdating` by privately associating weakly with a map view.
2015-04-02 16:58:24 -07:00
Ansis Brammanis
466febd615 don't create infinitely many boxes for zero or negative height symbols
line-height or padding can make the height of a shaped object <= 0.
In these cases either create no boxes, or create boxes with a minimum
height to avoid creating too many of them.

-js: 9e78c02d8b22b60a08fdb28fd29eef1642f62d94
2015-04-02 16:48:43 -07:00
John Firebaugh
3bd180dbe8 Merge pull request #1155 from mapbox/1155-update-as-needed
Only run Style::updateProperties when required
2015-04-02 16:38:08 -07:00
John Firebaugh
12c07b916b Rework easing transition code
This brings the easing transition code a bit closer to how easings work
in gl-js. Instead of having an array of individual transitions for scale,
rotate, and pan, there is a single transition function that does all the
required calculations. This permits us to:

* Eliminate the "timeout" transition. (Fixes #126)
* Replace start/stopPanning() et al with setGestureInProgress(). Apps or
  SDKs are expected to make paired calls to setGestureInProgress(). This
  state will be ORed with the active easing state to determine when to
  use texture interpolation. (Fixes #79)
* Run style recalculations only when an ease transition that affects the
  zoom is in progress. (Fixes #1155)
2015-04-02 16:12:29 -07:00
John Firebaugh
9e38d7cc2b Move Update to its own header file 2015-04-02 15:30:13 -07:00
John Firebaugh
7f58840991 Remove unused 2015-04-02 15:30:12 -07:00
Mike Morris
186fbad236 update changelog 2015-04-02 17:59:00 -04:00
Brad Leege
7c05f941a8 Merge pull request #1188 from mapbox/1185-events-querystring
Events = True
2015-04-02 16:57:19 -05:00
Mike Morris
3090f498fd 1.0.2 [publish binary] 2015-04-02 17:55:47 -04:00
Mike Morris
6a3d6d2372 Merge pull request #108 from mapbox/init-display
init display connection on module load
2015-04-02 17:54:06 -04:00
Mike Morris
d9c446a075 init display connection on module load
add sudo: required

move source up to initialization on NodeMap

static sharedDisplay method
2015-04-02 17:21:16 -04:00
Brad Leege
94bc3c811f #1185 - Adding "events=true" query string to all non metrics http requests if metrics are not disabled 2015-04-02 16:15:25 -05:00
Ansis Brammanis
68ae21d8f4 fix android and Release builds 2015-04-02 13:33:50 -07:00
Ansis Brammanis
1dcd1cf509 remove tests for deleted rotation_range 2015-04-02 12:52:55 -07:00
Minh Nguyễn
44d360501e Polished privacy settings
Added footer text to explain the purpose of the Mapbox Metrics setting. Added strings from the plist to an existing unused .strings file and converted that .strings file to UTF-8 for diffability.
2015-04-02 12:43:32 -07:00
Ansis Brammanis
02d2ddef52 fix quad offsets by subtracting buffer
-js doesn't have this here because it subtracts the buffer earlier.
617e590c83/js/symbol/glyph_source.js (L75)

We should match -js eventually.
2015-04-02 12:39:30 -07:00
Ansis Brammanis
7b02800ad9 remove old symbol collision types 2015-04-02 12:16:42 -07:00