Skip to main content

Search and Top Navigation

#8757 closed bug (fixed)

Opened October 31, 2012 12:38PM UTC

Closed November 19, 2012 02:09PM UTC

Draggable: Resizable handle with inner element does not work, when its also draggable

Reported by: MatteS75 Owned by:
Priority: minor Milestone: 1.10.0
Component: ui.draggable Version: 1.9.1
Keywords: haspatch Cc:
Blocked by: Blocking:
Description

Creating a handle with an inner element renders the resize handle useless.

1. Create a resizable div with an inner div with the handle classes setup

2. Add another div inside the handle div

3. Initialize the draggable

4. Initialize the resizable

Now the resizable handle does not work.

Removing the inner div, and it does work.

This might seems to be the same as http://bugs.jqueryui.com/ticket/8756, but it might not be. Fixing that bug might make this scenario fail still.

Applying the workaround for this, and it still does not work: http://jsfiddle.net/MatteS75/A7N6L/

Attachments (0)
Change History (8)

Changed October 31, 2012 01:46PM UTC by scottgonzalez comment:1

resolution: → notabug
status: newclosed

I'm going to close this as not a bug since this isn't something we support. If this is still broken when (if) the other ticket is resolved, then feel free to file a new ticket.

Changed October 31, 2012 02:14PM UTC by MatteS75 comment:2

_comment0: If its helping someone else, this is the code change that fixes it: \ \ @@ -5909,7 +5909,7 @@ \ var o = this.options; \ \ // among others, prevent a drag on a resizable-handle \ - if (this.helper || o.disabled || $(event.target).is('.ui-resizable-handle')) \ + if (this.helper || o.disabled || $(event.target).is('.ui-resizable-handle') || $(event.target).closest('.ui-resizable-handle').length > 0) \ return false; \ \ 1351692882632618

If its helping someone else, this is the code change that fixes it:

@@ -5909,7 +5909,7 @@
 		var o = this.options;
 
 		// among others, prevent a drag on a resizable-handle
-		if (this.helper || o.disabled || $(event.target).is('.ui-resizable-handle'))
+		if (this.helper || o.disabled || $(event.target).is('.ui-resizable-handle') || $(event.target).closest('.ui-resizable-handle').length > 0)
 			return false;


Changed November 05, 2012 06:24PM UTC by scottgonzalez comment:3

resolution: notabug
status: closedreopened

Reopening based on pending PR.

Changed November 05, 2012 06:24PM UTC by scottgonzalez comment:4

component: ui.resizableui.draggable
status: reopenedopen

Changed November 05, 2012 07:20PM UTC by mikesherov comment:5

Replying to [comment:1 scott.gonzalez]:

I'm going to close this as not a bug since this isn't something we support. If this is still broken when (if) the other ticket is resolved, then feel free to file a new ticket.

Why was this reopened? Not sure what the "pending" PR is?

Changed November 05, 2012 07:38PM UTC by scottgonzalez comment:6

keywords: → haspatch

I'm waiting on a new PR based on https://github.com/jquery/jquery-ui/pull/807#issuecomment-10081536

If that doesn't come soon, we can just update his commit and land it.

Changed November 09, 2012 01:44PM UTC by mikesherov comment:7

summary: Resizable handle with inner element does not work, when its also draggableDraggable: Resizable handle with inner element does not work, when its also draggable

Changed November 19, 2012 02:09PM UTC by mathias.stenbom comment:8

resolution: → fixed
status: openclosed

Draggable: made handles work with complex markup. Fixes #8757 - Draggable: Resizable handle with inner element does not work, when its also draggable

Changeset: cf9fbce13931732dc4b06d491ef2a01c4921faf1