Skip to content

On drag - header/background text selection (Chrome/Firefox) #5

Open

Description

When you drag a dialog quickly in chrome and FF, the header text still gets selected along with any background elements you pass over.

Fix: Simply add return false; to the end of the _dragStart method to cancel selection.

_dragStart: function (event)
{
    if (event.rightClick) return;

    MUX.Dialog.currentDialogParams = {
        box: this.box,
        mouse: {
            x: event.client.x,
            y: event.client.y
        },
        browser: $(window).getSize()
    }

    $(document).addEvents({
        mousemove: MUX.Dialog._dragMoving,
        mouseup: MUX.Dialog._dragEnd
    });

    return false;
}

Seriously though, I love this class. Very elegant!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions