mirror of https://github.com/stella-emu/stella.git
fixed memory leak in EventMappingWidget
This commit is contained in:
parent
6187d3b542
commit
489188a2e2
|
@ -128,7 +128,7 @@ EventMappingWidget::EventMappingWidget(GuiObject* boss, const GUI::Font& font,
|
|||
addFocusWidget(myComboButton);
|
||||
|
||||
VariantList combolist = instance().eventHandler().getComboList(mode);
|
||||
myComboDialog = new ComboDialog(boss, font, combolist);
|
||||
myComboDialog = make_unique<ComboDialog>(boss, font, combolist);
|
||||
}
|
||||
|
||||
// Show message for currently selected event
|
||||
|
|
|
@ -90,7 +90,7 @@ class EventMappingWidget : public Widget, public CommandSender
|
|||
StringListWidget* myActionsList{nullptr};
|
||||
EditTextWidget* myKeyMapping{nullptr};
|
||||
|
||||
ComboDialog* myComboDialog{nullptr};
|
||||
unique_ptr<ComboDialog> myComboDialog;
|
||||
|
||||
// Since this widget can be used for different collections of events,
|
||||
// we need to specify exactly which group of events we are remapping
|
||||
|
|
Loading…
Reference in New Issue