Fixed Neighborhood Complete Screen Rendering Early#3690
Open
srihariKrishnaswamy wants to merge 2 commits into
Open
Fixed Neighborhood Complete Screen Rendering Early#3690srihariKrishnaswamy wants to merge 2 commits into
srihariKrishnaswamy wants to merge 2 commits into
Conversation
Collaborator
Author
|
I'm gonna wait till you take a look to delete that now unused method, so just putting that here! |
Member
|
@srihariKrishnaswamy this still isn't working quite like how I imagined! Here's what I'm expecting:
I tested three times. The first time, the neighborhood complete modal popped up when I was getting close to the end of the intersection, but I wasn't able to finish it before that happened. The second time and third times I got a "you're quite far away from the route" message showing up instead of the one that we wanted. Then the neighborhood complete showed up too early again. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Resolves #3680
In this PR, I added some logic to see if we were on the very last un-audited street in a neighborhood, and made sure to show the neighborhood complete screen after that street finishes. I also added logic to delay the display of that overlay to the point where the user jumps to a new street after completing a neighborhood. This necessitated a number of small changes in TaskContainer & MapService, including the addition of a new flag field (to log the fact that we need to display the overlay) that is toggled on when the neighborhood is finished, and turned back off when the overlay is displayed.
Since the code for what jumps happen after a neighborhood is finished is pretty complex & there are a number of different methods that could handle it on a case-by case basis, I made sure to call the new function that conditionally renders the overlay in a few different places so we don't miss out on a case where a neighborhood is complete and the overlay needs to be rendered.
Also, in order to do this, I had to make it so that the old function that was in charge of rendering the overlay is not used anymore, but as of now I left the code in there just because I'm a little iffy on deleting it without a review!
Testing instructions
Things to check before submitting the PR