Get item data from change event in select widget items

Fix a bug in MediaEditDialog that resulted from sync issues when the
'select' event is fired for OO.ui.ButtonSelectWidget widgets.

Use the details of the selected item given from the event rather than
checking the state of the widget with getSelectedItem().

Change-Id: Ifbbf722ff374e10b680a6b55ab99f5fc86480c40
Merge "Get item data from change event in select widget items"