From 67f04e4e42e67c1b73a97efc1c46cf986cec4794 Mon Sep 17 00:00:00 2001 From: Felix Nagel Date: Sat, 31 Aug 2013 03:09:57 +0200 Subject: [PATCH] Selectmenu: update button text when selected option is added --- ui/jquery.ui.selectmenu.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ui/jquery.ui.selectmenu.js b/ui/jquery.ui.selectmenu.js index bc7eae1bd..6685229d5 100644 --- a/ui/jquery.ui.selectmenu.js +++ b/ui/jquery.ui.selectmenu.js @@ -179,6 +179,8 @@ $.widget( "ui.selectmenu", { // Make sure menu is selected item aware this.menu.menu( "focus", null, item ); this._setAria( item.data( "ui-selectmenu-item" ) ); + + this._setText( this.buttonText, item.text() ); // Set disabled state this._setOption( "disabled", !!this.element.prop( "disabled" ) ); -- 2.39.5