Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 53b65f2

Browse files
committed
optimization #1
1 parent d1c711c commit 53b65f2

File tree

1 file changed

+6
-7
lines changed

1 file changed

+6
-7
lines changed

src/project/WorkingSetView.js

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -356,15 +356,14 @@ define(function (require, exports, module) {
356356
$(window).on("mousemove.wsvdragging", function (e) {
357357

358358
function drag(e) {
359-
_deactivateAllViews(isCurrentFile);
360-
// we've dragged the item so set
361-
// dragged to true so we don't try and open it
362-
dragged = true;
359+
if (!dragged) {
360+
_deactivateAllViews(isCurrentFile);
361+
// we've dragged the item so set
362+
// dragged to true so we don't try and open it
363+
dragged = true;
364+
}
363365
// reset the scrolling direction to no-scroll
364366
scrollDir = 0;
365-
// reset start so we don't drag again until the mouse
366-
// is moved 3 pixels to help prevent jitter
367-
startPageY = e.pageY;
368367
// Find out where to to drag it to
369368
var ht = hitTest(e);
370369

0 commit comments

Comments
 (0)