Open
Conversation
Owner
|
Hi @ChargeIn , Don't think if we make the proposed changes will this corner case still work. |
Contributor
Author
|
Hey, thanks for the review. I think the edge case will still work. The reason is that I only took way the "check" to push directly back to the direction you are coming from. In the case you are described we will check recursively and with each recursion the direction is different so it should not be effected. Screencast.From.2026-01-28.22-30-28.mp4 |
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.
Hey, I was trying to fix #933.
What I notices is that the grid starts a recursive chain to pushes all items to the north and once it hit the border it works it self back from the top checking all the other possible solutions -> Leading to Number 1 being pushed down by Number 2 creating the swap effect.
There are multiple solution how this could be solved. E.g. we could track if the push would collide with there chained pushed coming from the opposite direction.
But I was wondering what is the use case for this last check? In the code you are checking for swap in a separate function so there should not really be a need to check for a push in the direction you are coming from.
Can you please give a small example? Otherwise the code attach will fix the issue.
I create a patch file to test the issue. After applying you can find the test view under the path "/test"
add_test_view.patch