Draggable on mousedown

Draggable on mousedown


I have code that creates a draggable container using a handle. I
would like to enable the draggable on mousedown events on the handle
and disable the draggable on mouseup events. Basically, have the
draggable enabled only when the user is holding the mouse down.
nDiv.draggable({ handle: '#toolbar', stop: function(e,ui)
{ } }).draggable("disable");
    cDiv.mousedown( function() {
            $(this).css("cursor", "move");
            $(this).parents(".tile").draggable("enable");
        }
    );
    cDiv.mouseup( function() {
            $(this).css("cursor", "auto");
            $(this).parents(".tile").draggable("disable");
        }
    );
The issue i'm having is that this code works only every other mouse
down. Any clues.
thanks