SearchInputWidget: Actually connect to change event
authorEd Sanders <esanders@wikimedia.org>
Mon, 9 Oct 2017 09:12:21 +0000 (10:12 +0100)
committerEd Sanders <esanders@wikimedia.org>
Mon, 9 Oct 2017 09:12:21 +0000 (10:12 +0100)
This makes the clear indicator-button work, not sure if it
ever worked in the past.

Change-Id: Ia54add0fa5475c37871d82e7750ea4dedbf9dfe3

resources/src/mediawiki.widgets/mw.widgets.SearchInputWidget.js

index 8707bfa..194f714 100644 (file)
                        } );
                }.bind( this ) );
 
+               this.connect( this, {
+                       change: 'onChange'
+               } );
+
                this.$element.addClass( 'oo-ui-textInputWidget-type-search' );
                this.updateSearchIndicator();
                this.connect( this, {
         * @see OO.ui.SearchInputWidget#onChange
         */
        mw.widgets.SearchInputWidget.prototype.onChange = function () {
-               mw.widgets.SearchInputWidget.parent.prototype.onChange.call( this );
                this.updateSearchIndicator();
        };