Skip to content

Commit e1e43e3

Browse files
committed
Draggable: Add ui-draggable class.
1 parent 1337573 commit e1e43e3

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

ui/jquery.ui.draggable.js

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ $.widget( "ui.draggable", {
4141
this.element.css( "position", "relative" );
4242
}
4343

44+
this.element.addClass( "ui-draggable" );
4445
this._bind({ mousedown: "_mouseDown" });
4546
},
4647

@@ -56,7 +57,7 @@ $.widget( "ui.draggable", {
5657

5758
// Take into account scrollbar
5859
position.top -= scrollTop;
59-
position.left -= scrollLeft
60+
position.left -= scrollLeft;
6061

6162
return position;
6263
}
@@ -258,7 +259,7 @@ $.widget( "ui.draggable", {
258259
this.tempPosition = {
259260
left: newLeft,
260261
top: newTop
261-
}
262+
};
262263

263264
// Refresh offset cache with new positions
264265
this.offset.left = this.startOffset.left + newLeft;
@@ -297,6 +298,10 @@ $.widget( "ui.draggable", {
297298
position: this.position,
298299
offset: this.offset
299300
};
301+
},
302+
303+
_destroy: function() {
304+
this.element.removeClass( "ui-draggable" );
300305
}
301306
});
302307

0 commit comments

Comments
 (0)