]> source.dussan.org Git - jquery-ui.git/commitdiff
Core: Deprecate .enableSelection() and .disableSelection(). Fixes #7755 - Core: Depre...
authorScott González <scott.gonzalez@gmail.com>
Thu, 23 Aug 2012 11:30:29 +0000 (07:30 -0400)
committerScott González <scott.gonzalez@gmail.com>
Thu, 23 Aug 2012 11:30:29 +0000 (07:30 -0400)
ui/jquery.ui.core.js

index 0e33f11ed8014991ff8bab3f0dae2e2b732432a3..d37698422b48bff5683d8703ab9ccf5043c8daae 100644 (file)
@@ -125,17 +125,6 @@ $.fn.extend({
                                $( this ).removeAttr( "id" );
                        }
                });
-       },
-
-       disableSelection: function() {
-               return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
-                       ".ui-disableSelection", function( event ) {
-                               event.preventDefault();
-                       });
-       },
-
-       enableSelection: function() {
-               return this.unbind( ".ui-disableSelection" );
        }
 });
 
@@ -268,6 +257,20 @@ $(function() {
 
 
 // deprecated
+
+$.fn.extend({
+       disableSelection: function() {
+               return this.bind( ( $.support.selectstart ? "selectstart" : "mousedown" ) +
+                       ".ui-disableSelection", function( event ) {
+                               event.preventDefault();
+                       });
+       },
+
+       enableSelection: function() {
+               return this.unbind( ".ui-disableSelection" );
+       }
+});
+
 $.extend( $.ui, {
        // $.ui.plugin is deprecated.  Use the proxy pattern instead.
        plugin: {