Page MenuHomePhabricator

OOjs UI: MenuWidget.off('select') disables default behavior
Closed, DeclinedPublic

Description

Steps to reproduce:

  1. load a page with an OoUiInlineMenuWidget (I used the one in MultimediaViewer master, behind the "Use this file" button)
  2. get the menu widget behind it, run off('select') (with the current version of MultimediaViewer, this can be done from the console via mw.mmv.bootstrap.viewer.ui.panel.fileReuse.tabs.embed.embedWtSizeSwitch.getMenu().off('select') )

Expected result: any custom handlers are removed, but default behavior is unaffected

Actual result: default behavior is disabled - the selection (the content of the .oo-ui-inlineMenuWidget-handle class) does not change when selecting an option.


Version: unspecified
Severity: minor

Details

Reference
bz63094

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 3:02 AM
bzimport added a project: OOUI.
bzimport set Reference to bz63094.

I think this is fixed, I have seen code using unqualified off() work without problem recently.

Confirmed from my testing; sorry for the problem!