Ticket #7270 (closed bug: fixed)

Opened 3 years ago

Last modified 2 years ago

JQuery UI Draggable IFrameFix

Reported by: VIRGOFX Owned by:
Priority: minor Milestone: 1.8.13
Component: ui.draggable Version: 1.8.11
Keywords: Cc:
Blocking: Blocked by:

Description

The JQuery UI Draggable has a problem when using the options [iframeFix = true] where the options.distance is greater then 0.

The draggable is creating the iframefix containers when the draggable starts. If the distance is set to 0, the start is fired immediately upon mouse click. However, if distance is > 0, which is useful when a click event needs to be registered on the draggable, the iframefix containers are not applied until the mousemove event registers an appropriate distance. However, when dragging over iframes, this won't register the mousemove correctly and subsequently won't start the dragging.

The iframeFix containers need to be moved from [start of dragging] to [mouseCapture].

Here is a jsFiddle test case:  http://jsfiddle.net/VXbPE/

Note: When dragging the black resizer .. it may take 3-4 times before you notice it doesn't drag with the mouse. Once you release the mouse/and or move the resizer closer to it's original position (e.g. away from the iframes) it will [start] and set the iframefix containers.

Change History

comment:1 Changed 3 years ago by VIRGOFX

Updated test case:  http://jsfiddle.net/VXbPE/3/

comment:2 Changed 3 years ago by rdworth

  • Status changed from new to open

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

  • Status changed from open to closed
  • Resolution set to fixed

Merge pull request #187 from virgofx/master.

Fix #7270 - Draggable iFrameFix

Changeset: 3d5d58d85437ae11688c0407200fd36bed7c9426

comment:4 Changed 3 years ago by Mark Johnson

Draggable: Modified the iframe shims to load prior to dragging. Fixed #7270. (cherry picked from commit b1c8a13a1669dca4c4bde97fe2cc8b76f661b432)

Changeset: 15b9e9d176a7796f1582ba5c0a7d06e4ad7cc8e9

comment:5 Changed 3 years ago by scott.gonzalez

  • Milestone changed from 1.9 to 1.8.13

comment:6 Changed 2 years ago by jscheel

This fix breaks click events on draggables that are in the same position as an iframe. Here is an example with instructions:  http://jsfiddle.net/jscheel/MruUn/

comment:7 Changed 2 years ago by scott.gonzalez

You can apply a different z-index that works for your app:  http://jsfiddle.net/MruUn/1/

We should probably move the styles related to the iframe fix into a stylesheet instead of hard-coding the styles.

Note: See TracTickets for help on using tickets.