diff options
author | Minh Nguyễn <mxn@1ec5.org> | 2016-04-20 10:26:28 -0700 |
---|---|---|
committer | Minh Nguyễn <mxn@1ec5.org> | 2016-04-20 14:23:57 -0700 |
commit | 2aaa8b94746d50c89a4430a6787f9c28fb0e8a70 (patch) | |
tree | da23d59bf54989e44591e8172f48b84dd52e7b84 /CONTRIBUTING.md | |
parent | 72086edb6e95905bd85ab1e0b485fec16379735b (diff) | |
download | qtlocation-mapboxgl-2aaa8b94746d50c89a4430a6787f9c28fb0e8a70.tar.gz |
[ios, osx] Ignore invalid observation context
If a subclass of MGLMapView registers itself as an observer of a non-multipoint annotation’s coordinate key path but fails to handle the change in its -observeValueForKeyPath:ofObject:change:context: implementation, the context would likely be a value other than the annotation’s tag. In that case, avoid doing anything in response to the coordinate changing. Even if the context in that case happens to match the annotation’s tag – say, because the developer passed in NULL (which is equal to 0) for the first added annotation (which would have a tag of 0) – the result would be an unnecessary but harmless update.
Diffstat (limited to 'CONTRIBUTING.md')
0 files changed, 0 insertions, 0 deletions