jquery draggable throws error when 'mouseup' is triggered

Posted by Moustard on Stack Overflow See other posts from Stack Overflow or by Moustard
Published on 2010-05-26T19:34:38Z Indexed on 2010/05/26 19:51 UTC
Read the original article Hit count: 118

Filed under:

If you build a simple dragger:

$(document).ready(
function()
{
    $('#tomove').draggable(
    {
        axis:   'x',
        drag: function(event, ui) 
        {
            mouseUp();
        }
    });
}

);

And you try to stop it programmatically:

function mouseUp()

{ if($('#tomove').offset().left > 400) { $('#tomove').trigger('mouseup'); } }

You will get this message in error console:

this.helper is null

Is there any way to fix this? Thanks for your help.

© Stack Overflow or respective owner

Related posts about jquery-ui