Update j.ui.autocomplete which partially broke due to jQuery update in r89866
authorLeo Koppelkamm <diebuche@users.mediawiki.org>
Fri, 8 Jul 2011 13:50:11 +0000 (13:50 +0000)
committerLeo Koppelkamm <diebuche@users.mediawiki.org>
Fri, 8 Jul 2011 13:50:11 +0000 (13:50 +0000)
resources/jquery.ui/jquery.ui.autocomplete.js

index 9342483..41c1393 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * jQuery UI Autocomplete 1.8.11
+ * jQuery UI Autocomplete 1.8.14
  *
  * Copyright 2011, AUTHORS.txt (http://jqueryui.com/about)
  * Dual licensed under the MIT or GPL Version 2 licenses.
@@ -490,12 +490,12 @@ $.widget("ui.menu", {
                this.deactivate();
                if (this.hasScroll()) {
                        var offset = item.offset().top - this.element.offset().top,
-                               scroll = this.element.attr("scrollTop"),
+                               scroll = this.element.scrollTop(),
                                elementHeight = this.element.height();
                        if (offset < 0) {
-                               this.element.attr("scrollTop", scroll + offset);
+                               this.element.scrollTop( scroll + offset);
                        } else if (offset >= elementHeight) {
-                               this.element.attr("scrollTop", scroll + offset - elementHeight + item.height());
+                               this.element.scrollTop( scroll + offset - elementHeight + item.height());
                        }
                }
                this.active = item.eq(0)
@@ -601,7 +601,7 @@ $.widget("ui.menu", {
        },
 
        hasScroll: function() {
-               return this.element.height() < this.element.attr("scrollHeight");
+               return this.element.height() < this.element[ $.fn.prop ? "prop" : "attr" ]("scrollHeight");
        },
 
        select: function( event ) {