Should not be used at all, added for a corner case
on OSX network backend where the request is processed on
a worker thread managed by OSX and we need to wait for
that reply before destroying the thread that pushed the
request.
This reverts commit 6709bdcacd.
There was an issue with the script that removes '-lwebp' from WebP
linker flags, since we're statically linking. This is now fixed.
Map and Transform methods assume an origin at the top-left corner of the view, like iOS, Android, and GLFW but unlike OS X. Transform is responsible for flipping coordinates between the top-left origin of Map and the bottom-left origin of TransformState.
Fixes#3574.
If you use many different caches, expired weak_ptrs will pile up in the unordered_map, but that is an edge case, and you probably shouldn't do that anyway.
I regenerated assets.zip so that all file paths have an `assets/` prefix, as the Android AssetFileSource implementation asserts, and removed `TEST_DATA` from the paths.
* Move asset:// URL handling to DefaultFileSource.
* AssetFileSource implements FileSource interface and follows familiar implementation patterns.
* Move default implementation to platform/default, zip implementation to platform/android.
* Don't bother with modified / expires / etag -- assets are not cached so it doesn't matter.
* Don't bother with interleaving individual IO calls on the implementation thread. That adds a lot of complexity for very little benefit.
In the cache response case, we don't want the failedRequests logic; cached errors, should they occur, shouldn't affect the scheduling behavior for real requests.
We already had a condition that checks if a response is immediately available for an incoming request. Call the callback there, rather than in addObserver.
In every case where setResponse is called, notify was called soon after. In one case immediately, in another, after intervening functions which are safe to reorder after notifications.
The null-check of response is safe to eliminate because response must not be null inside setResponse.
There is no need for the timer to be created only under certain conditions. Stopping a non-started timer is a no-op. Therefore it can simply be a direct member.
While here, rename the variable. It's a timer, not a request.
Force drop the table when the version doesn't match. Previously
it was assumed (my bad) that CREATE TABLE IF NOT EXISTS would
compare the table schema, which is not true.
Setting the viewport size from the main thread has no affect
on Linux and thus, the map doesn't scale. We now set the
viewport size on the beforeRender() hook that gets called
from the Map thread.