Opened 14 years ago

Closed 14 years ago

#3731 closed bug (fixed)

dialog window can't be closed

Reported by: dypa Owned by:
Priority: critical Milestone: 1.7
Component: ui.dialog Version: 1.6rc4
Keywords: дибилы :) Cc:
Blocked by: Blocking:

Description

  1. open the page http://ui.jquery.com/demos/dialog
  2. drag dialog window to the top of the page while dialog will not be out side of the window

the same problem when dialog window is draged out of the body width && height (apperes scrool)

sorry for my bad english

Attachments (2)

1.png (139.0 KB) - added by dypa 14 years ago.
2.png (137.0 KB) - added by dypa 14 years ago.

Download all attachments as: .zip

Change History (5)

Changed 14 years ago by dypa

Attachment: 1.png added

Changed 14 years ago by dypa

Attachment: 2.png added

comment:1 Changed 14 years ago by Scott González

Milestone: TBD1.6

Suggested solution:

on drag stop:

  • if the top of the dialog is above the top of the document, move the top to 0
  • if the right side of the dialog is to the left of the left side of the document, move the left to 0
  • if the left side of the dialog is to the right of the right side of the document, move the left to document width - dialog width

I'm not sure the last rule is needed as the document will normally stretch if the dialog is dragged to the right.

comment:2 Changed 14 years ago by Scott González

This could probably also be handled by setting containment to document when initializing the draggable.

comment:3 Changed 14 years ago by Scott González

Resolution: fixed
Status: newclosed

Fixed in r1486.

Note: See TracTickets for help on using tickets.