]> source.dussan.org Git - jquery-ui.git/commitdiff
Tooltip: Proper handled of disabled option.
authorScott González <scott.gonzalez@gmail.com>
Sat, 28 May 2011 19:25:05 +0000 (15:25 -0400)
committerScott González <scott.gonzalez@gmail.com>
Sat, 28 May 2011 19:25:05 +0000 (15:25 -0400)
ui/jquery.ui.tooltip.js

index 756fe0f7b1948905d6f3686cb82423c4cd83dd0f..56e5fa5c2db9e9500d9735a393d0026d961767c4 100644 (file)
@@ -36,13 +36,13 @@ $.widget( "ui.tooltip", {
                });
        },
 
-       enable: function() {
-               this.options.disabled = false;
-       },
-
-       disable: function() {
+       _setOption: function( key, value ) {
                // only set option, disable element style changes
-               this.options.disabled = true;
+               if ( key === "disabled" ) {
+                       this.options[ key ] = value;
+                       return;
+               }
+               this._super( "_setOption", key, value );
        },
 
        open: function( event ) {