Opened 12 years ago
Closed 10 years ago
#6049 closed bug (worksforme)
Link in sortable (portlets) - IE8
Reported by: | raziel057 | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | 2.0.0 |
Component: | ui.sortable | Version: | 1.8.4 |
Keywords: | IE8 | Cc: | |
Blocked by: | Blocking: |
Description
If you try to add a link in the content of one portlet on the sample page: http://jqueryui.com/demos/sortable/portlets.html
With IE8, try to move the box which contains the link in the same column (on the top or bottom an other box) and try to click on the link after that. When you click on the link for the first time, it doesn't react.
Attachments (2)
Change History (7)
Changed 12 years ago by
Attachment: | simpletest.html added |
---|
comment:1 Changed 12 years ago by
The problem exists with a simple sortable list too.
It seems to come from an event handler which applies on links an is executed before href property. The event is apply when eleemnt is dragged.
comment:2 Changed 12 years ago by
If add the following code In widget ui.mouse, _mouseInit function the problem is solved!(see http://dev.jqueryui.com/ticket/4773)
// Prevent click on links in IE if ($.browser.msie) { this._mouseUnselectable = this.element.attr('unselectable'); this.element.attr('unselectable', 'on'); }
Here the modified _mouseInit function:
_mouseInit: function() { var self = this; this.element .bind('mousedown.'+this.widgetName, function(event) { return self._mouseDown(event); }) .bind('click.'+this.widgetName, function(event) { if(self._preventClickEvent) { // Prevent text selection in IE if ($.browser.msie) { this._mouseUnselectable = this.element.attr('unselectable'); this.element.attr('unselectable', 'on'); } self._preventClickEvent = false; event.stopImmediatePropagation(); return false; } }); this.started = false; },
Could you please review the modification and add the patch for a next version of jquery ui?
Thanks
comment:3 Changed 12 years ago by
As a workarround (without modification in widget ui=mouse, I add unbind instrtuction in simpletest2.html
$(function() { $("#sortable") .sortable() .unbind('click.sortable'); });
But I must be a temporary solution.
comment:4 Changed 10 years ago by
Milestone: | 1.next → 2.0.0 |
---|
comment:5 Changed 10 years ago by
Resolution: | → worksforme |
---|---|
Status: | new → closed |
Thanks for taking the time to contribute to the jQuery UI project! I can no longer reproduce the issue using the latest jQuery and jQuery UI. http://jsfiddle.net/sfYHu/2/
If you can still reproduce it, please feel free to reply to this ticket with a test case showing the problem. Thanks!
Llink inside a portlet