Fix bug: onDragLeave doesn't reset over-class #643
Fix bug: onDragLeave doesn't reset over-class #643denkan wants to merge 3 commits intonervgh:masterfrom denkan:master
Conversation
|
Yea, sorry... should've known it wasn't that simple :) Great module btw! |
|
Alright, I couldn't really put it out of my mind. A bit hacky but seems to work... |
|
I just bower installed ur directive same issue , the over-class still persist after on drag out |
|
This is what i finally used in manipulating it from my controller var element=angular.element(document.getElementById("basic"));
element.on('dragleave', function () {
element.removeClass("nv-file-over");
element.removeClass("test"); //used for my over-class
console.log('dragleave');
});
` |
|
the request should have been merged already, am working on a project here , so i dont really have time to check, it should be updated for the next version , so bower install should give the latest updates. Thanks |
It looks like your code will cause the flicker effect again. |
|
This fix is the best one and fully solves the issue. Unlike #720. |
Fixed bug causing nv-file-over (over-class) not resetting when leaving element.
Issue e.g. #514 and #231.
Fixed by removing the check (and cancel) if the event.currentTarget is same as the nv-file-over element. Seems like we don't need it because the onDragOver event will put it right back anyway.
Tested in Chrome, Firefox, Safari.
Could need testing in IE?