Skip to content

Commit 31fd8d6

Browse files
bastianonmvieron
authored andcommittedOct 26, 2013
fix(gridster): overlapping widget problem
1 parent 1b13617 commit 31fd8d6

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed
 

‎src/jquery.gridster.js

+8-4
Original file line numberDiff line numberDiff line change
@@ -1734,10 +1734,14 @@
17341734
* @return {Class} Returns the instance of the Gridster Class.
17351735
*/
17361736
fn.move_widget_down = function($widget, y_units) {
1737-
var el_grid_data = $widget.coords().grid;
1738-
var actual_row = el_grid_data.row;
1739-
var moved = [];
1740-
var y_diff = y_units;
1737+
var el_grid_data, actual_row, moved, y_diff;
1738+
1739+
if (y_units <= 0) { return false; }
1740+
1741+
el_grid_data = $widget.coords().grid;
1742+
actual_row = el_grid_data.row;
1743+
moved = [];
1744+
y_diff = y_units;
17411745

17421746
if (!$widget) { return false; }
17431747

0 commit comments

Comments
 (0)
Please sign in to comment.