From 23252571a4ee5b733049143b4ba78ee01caf0d08 Mon Sep 17 00:00:00 2001 From: Roan Kattouw Date: Fri, 23 Jun 2017 12:42:23 -0700 Subject: [PATCH] Migrate from FloatingMenuSelectWidget (deprecated) to MenuSelectWidget Bug: T168679 Change-Id: I987a4b12560d03cc5eec7f8a57020a3e726a040f --- modules/ui/mw.echo.ui.ActionMenuPopupWidget.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/ui/mw.echo.ui.ActionMenuPopupWidget.js b/modules/ui/mw.echo.ui.ActionMenuPopupWidget.js index f435f7be5..70c079508 100644 --- a/modules/ui/mw.echo.ui.ActionMenuPopupWidget.js +++ b/modules/ui/mw.echo.ui.ActionMenuPopupWidget.js @@ -4,7 +4,7 @@ * * We don't currently have anything that properly answers the complete * design for our popup menus in OOUI, so this widget serves two purposes: - * 1. The FloatingMenuSelectWidget is intended to deliver a menu that relates + * 1. The MenuSelectWidget is intended to deliver a menu that relates * directly to its anchor, so its sizing is dictated by whatever anchors * it. This is not what we require, so we have to override the 'click' event * to reset the width of the menu. @@ -31,8 +31,8 @@ this.menuWidth = config.menuWidth || 300; // Menu - this.menu = new OO.ui.FloatingMenuSelectWidget( { - $container: this.$element, + this.menu = new OO.ui.MenuSelectWidget( { + $floatableContainer: this.$element, classes: [ 'mw-echo-ui-actionMenuPopupWidget-menu' ], widget: this } ); @@ -81,7 +81,7 @@ /** * Get the widget's action menu * - * @return {OO.ui.FloatingMenuSelectWidget} Menu + * @return {OO.ui.MenuSelectWidget} Menu */ mw.echo.ui.ActionMenuPopupWidget.prototype.getMenu = function () { return this.menu;