AsyncDisplayKit icon indicating copy to clipboard operation
AsyncDisplayKit copied to clipboard

[ASMapNode] Snapshot size / zoom level may not always be invalidated at the right times.

Open tomizimobile opened this issue 10 years ago • 5 comments

I'm seeing that my ASMapNode instances all have a really zoomed-in look to them - the pin and text all look huge. I dug into it a little bit, and I think it's because each part of my setup of the node (setRegion:, setAnnotations:) is causing the node to take a snapshot. Since this takes a little while, by time the node is properly sized, -resetSnapshotter and -takeSnapshot are skipped over due to the line if (!_snapshotter.isLoading) {. I don't have the time to rework this, but I'm hoping someone familiar with the code can come up with a workaround or fix.

tomizimobile avatar Dec 22 '15 14:12 tomizimobile

@aaronschubert0 could you look at this at your earliest convenience? I'd decided to sit on 1.9.4 for a couple days for stability testing with Pinterest and other things, and was thinking about launching it tonight because a few reports have come in about bugs that are actually fixed. If there's any chance you can fix this tomorrow, I'd love to launch 1.9.4 shortly thereafter. If you won't have a chance (family or away from computer), don't feel bad - just let me know and I will work on it tomorrow.

@tomizimobile thanks for doing enough debugging to describe the issue - we'll get it patched up for you quickly!

appleguy avatar Dec 23 '15 07:12 appleguy

Hey @appleguy will take a look at this today and get a fix out! Thanks @tomizimobile for reporting this, will message back after I've investigated.

aaronschubert0 avatar Dec 23 '15 09:12 aaronschubert0

@tomizimobile Just PR'd a fix. ASMapNode now cancels any previous snapshot request and will always displays the latest requested snapshot.

aaronschubert0 avatar Dec 23 '15 10:12 aaronschubert0

@tomizimobile thanks for reporting this. ASMapNode was kinda half-finished but is now in a much better state. 1.9.4 is the first release it's ready for action, so that's a learning experience for me that I shouldn't have announced it in 1.9.3. Please try out master when you get a chance, or you'll see 1.9.4 in the next couple days.

appleguy avatar Dec 23 '15 20:12 appleguy

@appleguy @aaronschubert0 Looks great! Thanks for the quick turnaround

tomizimobile avatar Dec 23 '15 21:12 tomizimobile