You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Sep 6, 2021. It is now read-only.
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
This is a possible fix for issue #2306. It changes click to mouseup as the event to close an entry in the list of recent projects.
It seems that jquery click event is not triggered if the mouse is already over the svg element when the old one is removed and the new one rendered, but mouseup is.
I'd say it has something to do with the lack of mouseenter, but I haven't been able to replicate it anywhere else outside this.
this change seems to fix the issue but i couldn't find out why
i tested this and found out that the checkHovers() Funtions seems to be the root of our problem, because when commenting out the call to that functions it works nicely for me
Hi @WebsiteDeveloper. I'm also still puzzled by this... my intuition is that somehow if the element doesn't detect the mouseover, jquery won't trigger the click event (it actually doesn't seem to even trigger mousedown), but I haven't been able to reproduce it anywhere else so far...
I've tried your solution and if I switch the line in checkHovers with your suggestion, then, after closing one project, the close arrow won't appear again until I move the mouse. Can you please verify if this happens to you?
I've tested it on this branch merged with master, and alone just in master and in both cases the close icon won't show.
@WebsiteDeveloper Maybe I didn't get your suggestion right. As you say, $(this).triggerHandler("mouseenter"); triggers the event handlers to the li nodes. The issue is that the mouseenter callback that calls showDeleteButton is placed on the a nodes, so the button won't show unless you move the mouse after deleting one item. Am I missing something?
If we could get it to work, I'd rather have something like what you suggest, as to me, it looks closer to the original intent of the code.
Actually when i print out this on the console i get <li><a class="recent-folder-link">...</a></li>
which means the hover handlers get also called for the <a> nodes so for me it actually works fine
maybe you could verify that by adding a console.log(this) statement before the call to triggerHandler on line 96
Sorry, but it's still not working for me. I also can't quite see why triggering it from the <li> nodes should cause it to trigger the handlers on the <a> elements...
Could you maybe put your code together in a branch and push it to your github account so I could clone it and check it myself?
@WebsiteDeveloper Thanks for putting the branch together. I just cloned it, but sadly it's still not working for me.
Are you by any chance on Windows? I'm running on MacOS, so maybe this is somehow platform-specific... I don't have access to any windows machine to check it out so maybe someone else could pitch in...
@jbalsas it seems to be platform specific because i am running a windows 7 machine
maybe it has something to do with the brackets shell handling of certain mouse events @njx could you please look at this
@WebsiteDeveloper Thanks for reviewing this pull request. I also tried your solution, but it doesn't work on Mac 10.8. After removing the first item from list, the (x) icon is not displayed on the item that moves under the mouse (and click doesn't do anything), so it's actually worse.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
None yet
4 participants
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.
This is a possible fix for issue #2306. It changes
click
tomouseup
as the event to close an entry in the list of recent projects.It seems that jquery
click
event is not triggered if the mouse is already over the svg element when the old one is removed and the new one rendered, butmouseup
is.I'd say it has something to do with the lack of
mouseenter
, but I haven't been able to replicate it anywhere else outside this.