Skip to main content

Bug Tracker

Side navigation

#2171 closed enhancement (invalid)

Opened January 15, 2008 10:33PM UTC

Closed July 21, 2010 01:49AM UTC

allow containing draggable elements within the window

Reported by: scottgonzalez Owned by: paul
Priority: minor Milestone: 1.2.3
Component: ui Version: 1.2.2
Keywords: draggable containment window Cc:
Blocked by: Blocking:
Description

Add support for containing draggable elements within the window.

$('#drag').draggable({
    containment: window
});

I've added a patch, but the behavior is a little strange in Opera because if you move your mouse out of the window while dragging, the page will scroll. The containment behaves as expected in other tested browsers (IE 6, Firefox 2, Safari 3 for Windows).

Attachments (2)
Change History (3)

Changed February 01, 2008 09:08PM UTC by scott.gonzal comment:1

I just added a new patch which includes fixed position support (requires patch from #2161).

Changed February 01, 2008 09:13PM UTC by scott.gonzal comment:2

In IE, the containment is off by the size of the scrollbar for elements that have fixed or absolute positioning.

Changed July 21, 2010 01:49AM UTC by scottgonzalez comment:3

resolution: → invalid
status: newclosed