Skip to content

Draggable: $.ui.ddmanager.current release on draggable _destroy #1366

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 5 commits into from
Closed

Draggable: $.ui.ddmanager.current release on draggable _destroy #1366

wants to merge 5 commits into from

Conversation

eshcharc
Copy link
Contributor

Fixes: #10667

@eshcharc
Copy link
Contributor Author

Fixed, and now passes all tests / style guides

@@ -91,6 +91,11 @@ $.widget("ui.draggable", $.ui.mouse, {
this.element.removeClass( "ui-draggable ui-draggable-dragging ui-draggable-disabled" );
this._removeHandleClassName();
this._mouseDestroy();

if ($.ui.ddmanager && $.ui.ddmanager.current && $.ui.ddmanager.current.element &&
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it ever the case that current exists but current.element does not?

This still doesn't conform to the style guide, but we can fix that when we merge. For reference:

  • Use element[ 0 ] instead of element.get( 0 ); there's never a reason to use .get().
  • We use liberal spacing, which you're missing.
  • The indentation for the second line of the conditional is wrong.

@tjvantoll tjvantoll mentioned this pull request Oct 21, 2014
@eshcharc eshcharc closed this Oct 21, 2014
@eshcharc eshcharc reopened this Oct 21, 2014
@@ -84,6 +84,8 @@ $.widget("ui.draggable", $.ui.mouse, {
},

_destroy: function() {
var ddmanager = $.ui.ddmanager;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is unnecessary.

@scottgonzalez
Copy link
Member

Closing due to inactivity and lack of a CLA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants