mirror of
https://github.com/stylersnico/librenms.git
synced 2026-07-23 08:03:16 +02:00
renamed jQuery adapter for Draggable class to $.fn.drag. Fixes #17.
Prevents name collisions with jQuery UI draggable module.
This commit is contained in:
@@ -315,10 +315,10 @@
|
||||
|
||||
|
||||
//jQuery adapter
|
||||
$.fn.draggable = function ( options ) {
|
||||
$.fn.drag = function ( options ) {
|
||||
return this.each(function () {
|
||||
if (!$.data(this, 'draggable')) {
|
||||
$.data(this, 'draggable', new Draggable( this, options ));
|
||||
if (!$.data(this, 'drag')) {
|
||||
$.data(this, 'drag', new Draggable( this, options ));
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
@@ -410,7 +410,7 @@
|
||||
}, 60)
|
||||
});
|
||||
|
||||
this.drag_api = this.$el.draggable(draggable_options).data('draggable');
|
||||
this.drag_api = this.$el.drag(draggable_options).data('draggable');
|
||||
return this;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user